Label the search box dependent on message type

It doesn’t make sense to say ‘Search by email address or phone number’
when you’re only looking at emails.
This commit is contained in:
Chris Hill-Scott
2018-08-07 14:44:09 +01:00
parent bb4c77fd59
commit 214bfa9873
3 changed files with 32 additions and 4 deletions

View File

@@ -183,7 +183,10 @@ def view_notifications(service_id, message_type=None):
status=request.args.get('status') or 'sending,delivered,failed',
page=request.args.get('page', 1),
to=request.form.get('to', ''),
search_form=SearchNotificationsForm(to=request.form.get('to', '')),
search_form=SearchNotificationsForm(
message_type=message_type,
to=request.form.get('to', ''),
),
download_link=url_for(
'.download_notifications_csv',
service_id=current_service.id,