Let the Notify team invite people to an organisation

We want to start granting access to the org page. But it will be a bit
weird if the invites come from us personally, since the people we’re
inviting don’t know us.

It makes more sense, and sounds more official if the invites appear to
come from the ‘GOV.UK Notify team’ instead.
This commit is contained in:
Chris Hill-Scott
2020-03-05 11:26:08 +00:00
parent b952b35714
commit bdfeb08055
2 changed files with 13 additions and 2 deletions

View File

@@ -48,7 +48,11 @@ def invite_user_to_org(organisation_id):
recipient=invited_org_user.email_address,
service=template.service,
personalisation={
'user_name': invited_org_user.invited_by.name,
'user_name': (
'The GOV.UK Notify team'
if invited_org_user.invited_by.platform_admin
else invited_org_user.invited_by.name
),
'organisation_name': invited_org_user.organisation.name,
'url': invited_org_user_url(
invited_org_user.id,