mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-05-05 08:31:00 -04:00
remove components related to MOU and agreement (#476)
Co-authored-by: Kenneth Kehl <@kkehl@flexion.us>
This commit is contained in:
@@ -30,12 +30,6 @@ class Organisation(JSONModel, SortByNameMixin):
|
||||
'active',
|
||||
'organisation_type',
|
||||
'email_branding_id',
|
||||
'agreement_signed',
|
||||
'agreement_signed_at',
|
||||
'agreement_signed_by_id',
|
||||
'agreement_signed_version',
|
||||
'agreement_signed_on_behalf_of_name',
|
||||
'agreement_signed_on_behalf_of_email_address',
|
||||
'domains',
|
||||
'request_to_go_live_notes',
|
||||
'count_of_live_services',
|
||||
@@ -68,11 +62,10 @@ class Organisation(JSONModel, SortByNameMixin):
|
||||
)
|
||||
|
||||
@classmethod
|
||||
def create(cls, name, organisation_type, agreement_signed=False):
|
||||
def create(cls, name, organisation_type):
|
||||
return cls(organisations_client.create_organisation(
|
||||
name=name,
|
||||
organisation_type=organisation_type,
|
||||
agreement_signed=agreement_signed,
|
||||
))
|
||||
|
||||
def __init__(self, _dict):
|
||||
@@ -81,7 +74,6 @@ class Organisation(JSONModel, SortByNameMixin):
|
||||
|
||||
if self._dict == {}:
|
||||
self.name = None
|
||||
self.agreement_signed = None
|
||||
self.domains = []
|
||||
self.organisation_type = None
|
||||
self.request_to_go_live_notes = None
|
||||
@@ -150,12 +142,6 @@ class Organisation(JSONModel, SortByNameMixin):
|
||||
return self.email_branding['name']
|
||||
return 'GOV.UK'
|
||||
|
||||
@cached_property
|
||||
def agreement_signed_by(self):
|
||||
if self.agreement_signed_by_id:
|
||||
from app.models.user import User
|
||||
return User.from_id(self.agreement_signed_by_id)
|
||||
|
||||
def update(self, delete_services_cache=False, **kwargs):
|
||||
response = organisations_client.update_organisation(
|
||||
self.id,
|
||||
|
||||
@@ -516,16 +516,6 @@ class Service(JSONModel, SortByNameMixin):
|
||||
def get_api_key(self, id):
|
||||
return self._get_by_id(self.api_keys, id)
|
||||
|
||||
@property
|
||||
def able_to_accept_agreement(self):
|
||||
return (
|
||||
self.organisation.agreement_signed is not None
|
||||
or self.organisation_type in {
|
||||
Organisation.TYPE_NHS_GP,
|
||||
Organisation.TYPE_NHS_LOCAL,
|
||||
}
|
||||
)
|
||||
|
||||
|
||||
class Services(SerialisedModelCollection):
|
||||
model = Service
|
||||
|
||||
Reference in New Issue
Block a user