Browse Source

CLDC-2554 Update back to all logs link (#1811)

* Update resume link

* Add tests

* Update copy
CLDC-2105-merge-orgs-owning-org-dropdown
kosiakkatrina 1 year ago committed by GitHub
parent
commit
364fb1e198
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      app/views/bulk_upload_lettings_results/resume.html.erb
  2. 2
      app/views/bulk_upload_sales_results/resume.html.erb
  3. 7
      spec/requests/lettings_logs_controller_spec.rb
  4. 7
      spec/requests/sales_logs_controller_spec.rb

2
app/views/bulk_upload_lettings_results/resume.html.erb

@ -8,4 +8,4 @@
You’ve completed all the logs that had errors from your bulk upload.
</p>
<%= govuk_button_link_to "Back to all logs", lettings_logs_path, button: true %>
<%= govuk_button_link_to "Return to lettings logs", clear_filters_path(filter_type: "lettings_logs"), button: true %>

2
app/views/bulk_upload_sales_results/resume.html.erb

@ -8,4 +8,4 @@
You’ve completed all the logs that had errors from your bulk upload.
</p>
<%= govuk_button_link_to "Back to all logs", sales_logs_path, button: true %>
<%= govuk_button_link_to "Return to sales logs", clear_filters_path(filter_type: "sales_logs"), button: true %>

7
spec/requests/lettings_logs_controller_spec.rb

@ -562,6 +562,13 @@ RSpec.describe LettingsLogsController, type: :request do
expect(response).to redirect_to(resume_bulk_upload_lettings_result_path(bulk_upload))
end
it "allows returning to all logs" do
get "/lettings-logs?bulk_upload_id[]=#{bulk_upload.id}"
follow_redirect!
expect(page).to have_link("Return to lettings logs", href: clear_filters_path(filter_type: "lettings_logs"))
end
end
end

7
spec/requests/sales_logs_controller_spec.rb

@ -438,6 +438,13 @@ RSpec.describe SalesLogsController, type: :request do
expect(response).to redirect_to(resume_bulk_upload_sales_result_path(bulk_upload))
end
it "allows returning to all logs" do
get "/sales-logs?bulk_upload_id[]=#{bulk_upload.id}"
follow_redirect!
expect(page).to have_link("Return to sales logs", href: clear_filters_path(filter_type: "sales_logs"))
end
end
end

Loading…
Cancel
Save