Skip to content

Commit 47efc1b

Browse files
committed
Hide default batches heading if there are none
This ensures that if no default batches have been selected the heading isn't displayed as there will be no content below it which looks strange.
1 parent 427aa7e commit 47efc1b

2 files changed

Lines changed: 2 additions & 1 deletion

File tree

app/controllers/sessions/record_controller.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ def set_todays_batches
9292
end
9393
end
9494

95-
@todays_batches = all_batches.compact
95+
@todays_batches = all_batches.compact_blank
9696
end
9797

9898
def set_programme

spec/features/hpv_vaccination_administered_spec.rb

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -112,6 +112,7 @@ def and_sync_vaccination_records_to_nhs_on_create_feature_is_enabled
112112

113113
def when_i_go_to_a_patient_that_is_ready_to_vaccinate
114114
visit session_record_path(@session)
115+
expect(page).not_to have_content("Default batches")
115116
click_link @patient.full_name
116117
end
117118

0 commit comments

Comments
 (0)