-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Implement order completed form view (#602)
* Implement order completed form view From: https://eaflood.atlassian.net/browse/RUBY-767 This implement the view for the completed form state on order copy cards journey, as per wireframe.
- Loading branch information
Showing
6 changed files
with
55 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
<div class="error-summary flash-message" role="alert" aria-labelledby="message-summary-heading-1" tabindex="-1"> | ||
<%= message %> | ||
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
<div class="error-summary flash-success" role="alert" aria-labelledby="message-summary-heading-1" tabindex="-1"> | ||
<%= message %> | ||
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
<h1 class="heading-large"><%= t(".heading") %></h1> | ||
|
||
<% if @transient_registration.temp_payment_method == "card" %> | ||
<%= render("shared/success", message: t(".payment_success_message_html", email: @transient_registration.contact_email)) %> | ||
<% else %> | ||
<%= render("shared/message", message: t(".awaiting_payment_message_html", email: @transient_registration.contact_email)) %> | ||
<% end %> | ||
|
||
<div class="text"> | ||
<div class="form-group"> | ||
<table> | ||
<tr> | ||
<th><%= t(".details_table.cards_label") %></th> | ||
<td><%= @transient_registration.temp_cards %></td> | ||
</tr> | ||
<tr> | ||
<th><%= t(".details_table.total_cost") %></th> | ||
<td>£ <%= display_pence_as_pounds(@transient_registration.total_registration_card_charge) %></td> | ||
</tr> | ||
<tr> | ||
<th><%= t(".details_table.reference") %></th> | ||
<td><%= @transient_registration.reg_identifier %></td> | ||
</tr> | ||
</table> | ||
</div> | ||
<div class="form-group"> | ||
<%= link_to t(".dashboard"), Rails.application.routes.url_helpers.root_path, class: "button" %> | ||
<%= link_to t(".details_page", reg_identifier: @transient_registration.reg_identifier), Rails.application.routes.url_helpers.registration_path(@transient_registration.reg_identifier), class: "button" %> | ||
</div> | ||
</div> |
13 changes: 13 additions & 0 deletions
13
config/locales/forms/copy_cards_order_completed_forms/en.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
en: | ||
waste_carriers_engine: | ||
copy_cards_order_completed_forms: | ||
new: | ||
heading: "Confirmation of order" | ||
awaiting_payment_message_html: "Order is awaiting payment.<br>We've sent an email with payment details to %{email}." | ||
payment_success_message_html: "Order completed.<br>Payment has cleared.<br>We have sent a confirmation email to %{email}." | ||
details_table: | ||
cards_label: "Number of cards ordered" | ||
total_cost: "Total cost" | ||
reference: "Reference" | ||
dashboard: "Go to registration search" | ||
details_page: "Details for %{reg_identifier}" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters