remove option for branding to sometimes not show search

it wouldn't show search if there were under a certain amount of letter
or email branding options - however we know there will always be more
than that amount so lets remove some complexity.

Also, rename the SearchTemplatesForm because it can search anything -
it just prompts you to search by name is all.
This commit is contained in:
Leo Hemsted
2019-02-07 11:39:23 +00:00
parent 7590b3dba9
commit f83910599c
10 changed files with 16 additions and 72 deletions
+3 -5
View File
@@ -35,7 +35,7 @@ from app.main.forms import (
OrganisationTypeForm,
RenameServiceForm,
RequestToGoLiveForm,
SearchTemplatesForm,
SearchByNameForm,
ServiceContactDetailsForm,
ServiceDataRetentionEditForm,
ServiceDataRetentionForm,
@@ -773,8 +773,7 @@ def service_set_email_branding(service_id):
return render_template(
'views/service-settings/set-email-branding.html',
form=form,
search_form=SearchTemplatesForm(),
show_search_box=(len(email_branding) > 6)
search_form=SearchByNameForm()
)
@@ -820,8 +819,7 @@ def service_set_letter_branding(service_id):
return render_template(
'views/service-settings/set-letter-branding.html',
form=form,
search_form=SearchTemplatesForm(),
show_search_box=(len(letter_branding) > 6)
search_form=SearchByNameForm()
)