diff --git a/t/app/controller/waste_merton.t b/t/app/controller/waste_merton.t index 139dd405660..fd054ea3a37 100644 --- a/t/app/controller/waste_merton.t +++ b/t/app/controller/waste_merton.t @@ -538,9 +538,12 @@ FixMyStreet::override_config { $mech->get_ok('/waste/12345'); $mech->content_contains('Report a problem with a non-recyclable waste collection', 'Can report a problem with non-recyclable waste'); $mech->content_contains('Report a problem with a food waste collection', 'Can report a problem with food waste'); - $mech->content_contains('Report a problem with a paper and card collection', 'Can report a problem with paper and card'); - $mech->content_lacks('Report a problem with a textiles and shoes collection', 'Can not report a problem with a textiles collection'); - $mech->content_lacks('Report a problem with a batteries collection', 'Can not report a problem with a batteries collection'); + my $root = HTML::TreeBuilder->new_from_content($mech->content()); + my $panel = $root->look_down(id => 'panel-2240'); + is $panel->as_text =~ /.*Please note that missed collections can only be reported.*/, 1, "Paper can card past reporting deadline"; + $mech->content_lacks('Report a problem with a paper and card collection', 'Can not report a problem with paper and card as pas reporting deadline'); + $mech->content_lacks('Report a problem with a textiles and shoes collection', 'Can not report a problem with a textiles collection as orange bags'); + $mech->content_lacks('Report a problem with a batteries collection', 'Can not report a problem with a batteries collection as orange bagss'); $mech->follow_link_ok({ text => 'Report a problem with a non-recyclable waste collection' }); $mech->submit_form_ok( { with_fields => { category => 'Bin not returned' } }); $mech->submit_form_ok( { with_fields => { extra_Report_Type => '1', 'extra_Crew_Required_to_Return?' => '0' } }); diff --git a/templates/web/base/waste/services.html b/templates/web/base/waste/services.html index 1ea2533f5f4..02a9f8c0fd2 100644 --- a/templates/web/base/waste/services.html +++ b/templates/web/base/waste/services.html @@ -28,7 +28,7 @@ [% IF is_staff AND NOT unit.orange_bag %] Request an additional [% unit.service_name FILTER lower %] collection [% END %] - [% IF NOT unit.orange_bag %] + [% IF NOT unit.orange_bag AND unit.report_allowed %] Report a problem with a [% unit.service_name FILTER lower %] collection [% END %] [% END %]