Skip to content

Commit

Permalink
[Automated] Merged master into target k8s
Browse files Browse the repository at this point in the history
  • Loading branch information
va-vsp-bot authored Apr 10, 2024
2 parents 014ffb0 + 04f6238 commit e972834
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 2 deletions.
8 changes: 8 additions & 0 deletions lib/pdf_fill/forms/va21p530v2.rb
Original file line number Diff line number Diff line change
Expand Up @@ -678,6 +678,12 @@ def combine_previous_names_and_service(previous_names)
end.join('; ')
end

def format_currency_spacing
return if @form_data['amountGovtContribution'].blank?

@form_data['amountGovtContribution'] = @form_data['amountGovtContribution'].rjust(5)
end

def set_state_to_no_if_national
national = @form_data['nationalOrFederal']
@form_data['cemetaryLocationQuestion'] = 'none' if national
Expand Down Expand Up @@ -758,6 +764,8 @@ def merge_fields(_options = {})

convert_location_of_death

format_currency_spacing

%w[
nationalOrFederal
govtContributions
Expand Down
2 changes: 1 addition & 1 deletion spec/fixtures/pdf_fill/21P-530V2/kitchen_sink.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"transportationExpenses":true,
"plotExpenseResponsibility":true,
"govtContributions":true,
"amountGovtContribution":"50000",
"amountGovtContribution":"5000",
"nationalOrFederal":true,
"name":"name of cemetery",
"finalRestingPlace":{"location":"other", "other":"other"},
Expand Down
2 changes: 1 addition & 1 deletion spec/fixtures/pdf_fill/21P-530V2/merge_fields.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"transportationExpenses":true,
"plotExpenseResponsibility":true,
"govtContributions":true,
"amountGovtContribution":"50000",
"amountGovtContribution":" 5000",
"nationalOrFederal":true,
"name":"name of cemetery",
"finalRestingPlace":{"location":{"cemetery":"Off", "privateResidence":"Off", "mausoleum":"Off", "other":"On"}, "other":"other"},
Expand Down

0 comments on commit e972834

Please sign in to comment.