Only show relevant choices of email branding

Users who work in local government can’t have GOV.UK branding on their
emails. And only those working for Companies House (for example) can
request the Companies House branding.

This commit adds:
- new choices of email branding, which offer the name of the branding,
  rather than the style
- logic to filter this list to only the applicable options, based on
  what we know about the user, service and organisation

This is a change from the previous approach which put the onus on users
to figure out the style of branding they wanted, when we might already
know that a lot of the options weren’t available to them, or would be
inconsistent with the branding of other services in their organisation.
This commit is contained in:
Chris Hill-Scott
2019-09-12 13:45:35 +01:00
parent 29a0611e42
commit 6d0d10e8de
7 changed files with 235 additions and 89 deletions

View File

@@ -83,6 +83,7 @@ class Organisation(JSONModel):
self.domains = []
self.organisation_type = None
self.request_to_go_live_notes = None
self.email_branding_id = None
def as_agreement_statement_for_go_live_request(self, fallback_domain):
if self.agreement_signed: