Skip to content

Commit

Permalink
put is_usa back, swap out received date
Browse files Browse the repository at this point in the history
  • Loading branch information
evansmith committed Dec 4, 2024
1 parent 70d9d4a commit 94920e3
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions app/sidekiq/central_mail/submit_central_form686c_job.rb
Original file line number Diff line number Diff line change
Expand Up @@ -170,14 +170,14 @@ def generate_metadata
veteran_information = form['veteran_information'].presence || claim.parsed_form['veteran_information']
form_pdf_metadata = get_hash_and_pages(form_path)
address = form['veteran_contact_information']['veteran_address']
receive_date = claim.created_at.in_time_zone('Central Time (US & Canada)')
is_usa = address['country_name'] == 'USA'
metadata = {
'veteranFirstName' => veteran_information['full_name']['first'],
'veteranLastName' => veteran_information['full_name']['last'],
'fileNumber' => veteran_information['file_number'] || veteran_information['ssn'],
'receiveDt' => receive_date.strftime('%Y-%m-%d %H:%M:%S'),
'receiveDt' => claim.created_at.in_time_zone('Central Time (US & Canada)').strftime('%Y-%m-%d %H:%M:%S'),
'uuid' => claim.guid,
'zipCode' => address['country_name'] == 'USA' ? address['zip_code'] : FOREIGN_POSTALCODE,
'zipCode' => is_usa ? address['zip_code'] : FOREIGN_POSTALCODE,
'source' => 'va.gov',
'hashV' => form_pdf_metadata[:hash],
'numberAttachments' => attachment_paths.size,
Expand Down

0 comments on commit 94920e3

Please sign in to comment.