Skip to content

Commit

Permalink
RST-5514 Adding date submitted by applicant information (#1445)
Browse files Browse the repository at this point in the history
  • Loading branch information
zaparka authored Jul 4, 2023
1 parent 1269dd2 commit ed6f99e
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 0 deletions.
4 changes: 4 additions & 0 deletions app/helpers/application_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -26,4 +26,8 @@ def selected_jurisdiction
return nil unless params['filter_applications']
params['filter_applications']["jurisdiction_id"]
end

def date_submitted(application)
application.created_at.strftime("%d %b %Y")
end
end
4 changes: 4 additions & 0 deletions app/views/online_applications/edit.html.slim
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,10 @@
- else
= t('error_messages.jurisdictions.none_in_office')

.govuk-form-group.group-level
p.util_mb-0 =t('date_submitted', scope: @form.i18n_scope)
p: strong= date_submitted(@online_application)

.govuk-form-group.group-level
legend.govuk-fieldset__legend
=t('date_received', scope: @form.i18n_scope)
Expand Down
1 change: 1 addition & 0 deletions config/locales/en.yml
Original file line number Diff line number Diff line change
Expand Up @@ -569,6 +569,7 @@ en-GB:
fee: How much is the court or tribunal fee?
form_name: Form number
form_name_hint: You'll find this on the bottom of the form, for example C100 or ADM1A
date_submitted: Date submitted by applicant
day_date_received: Day
month_date_received: Month
year_date_received: Year
Expand Down
3 changes: 3 additions & 0 deletions features/step_definitions/process_online_application_steps.rb
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,9 @@
expect(application_details_digital_page).to be_displayed
expect(process_online_application_page.content).to have_application_details_header
expect(process_online_application_page).to have_text 'Peter Smith'

expect(process_online_application_page).to have_text 'Date submitted by applicant'
expect(process_online_application_page).to have_text OnlineApplication.last.created_at.strftime("%d %b %Y")
end

And("I click next without selecting a jurisdiction") do
Expand Down

0 comments on commit ed6f99e

Please sign in to comment.