Browse Source

Change bu filter wording

pull/2845/head
Kat 6 months ago
parent
commit
6aa3febdd8
  1. 2
      app/helpers/logs_helper.rb
  2. 4
      spec/requests/lettings_logs_controller_spec.rb
  3. 4
      spec/requests/sales_logs_controller_spec.rb

2
app/helpers/logs_helper.rb

@ -10,7 +10,7 @@ module LogsHelper
def bulk_upload_options(bulk_upload)
array = bulk_upload ? [bulk_upload.id] : []
array.index_with { |_bulk_upload_id| "With logs from bulk upload" }
array.index_with { |_bulk_upload_id| "Only logs from this bulk upload" }
end
def search_label_for_controller(controller)

4
spec/requests/lettings_logs_controller_spec.rb

@ -609,7 +609,7 @@ RSpec.describe LettingsLogsController, type: :request do
it "displays filter" do
get "/lettings-logs?bulk_upload_id[]=#{bulk_upload.id}"
expect(page).to have_content("With logs from bulk upload")
expect(page).to have_content("Only logs from this bulk upload")
end
it "hides collection year filter" do
@ -695,7 +695,7 @@ RSpec.describe LettingsLogsController, type: :request do
context "without bulk_upload_id" do
it "does not display filter" do
get "/lettings-logs"
expect(page).not_to have_content("With logs from bulk upload")
expect(page).not_to have_content("Only logs from this bulk upload")
end
it "displays button to create a new log" do

4
spec/requests/sales_logs_controller_spec.rb

@ -452,7 +452,7 @@ RSpec.describe SalesLogsController, type: :request do
it "displays filter" do
get "/sales-logs?bulk_upload_id[]=#{bulk_upload.id}"
expect(page).to have_content("With logs from bulk upload")
expect(page).to have_content("Only logs from this bulk upload")
end
it "hides collection year filter" do
@ -536,7 +536,7 @@ RSpec.describe SalesLogsController, type: :request do
context "without bulk_upload_id" do
it "does not display filter" do
get "/sales-logs"
expect(page).not_to have_content("With logs from bulk upload")
expect(page).not_to have_content("Only logs from this bulk upload")
end
it "displays button to create a new log" do

Loading…
Cancel
Save