mirror of
https://github.com/cisagov/manage.get.gov.git
synced 2025-05-19 02:49:21 +02:00
Remove refs to submitter in domain request
This commit is contained in:
parent
ecafaa58c9
commit
f1c8f52456
1 changed files with 3 additions and 23 deletions
|
@ -339,13 +339,12 @@ class DomainRequest(TimeStampedModel):
|
||||||
help_text="The suborganization that this domain request is included under",
|
help_text="The suborganization that this domain request is included under",
|
||||||
)
|
)
|
||||||
|
|
||||||
# This is the domain request user who created this domain request. The contact
|
# This is the domain request user who created this domain request.
|
||||||
# information that they gave is in the `submitter` field
|
|
||||||
creator = models.ForeignKey(
|
creator = models.ForeignKey(
|
||||||
"registrar.User",
|
"registrar.User",
|
||||||
on_delete=models.PROTECT,
|
on_delete=models.PROTECT,
|
||||||
related_name="domain_requests_created",
|
related_name="domain_requests_created",
|
||||||
help_text="Person who submitted the domain request; will not receive email updates",
|
help_text="Person who submitted the domain request. Will receive email updates.",
|
||||||
)
|
)
|
||||||
|
|
||||||
investigator = models.ForeignKey(
|
investigator = models.ForeignKey(
|
||||||
|
@ -483,17 +482,6 @@ class DomainRequest(TimeStampedModel):
|
||||||
help_text="Other domain names the creator provided for consideration",
|
help_text="Other domain names the creator provided for consideration",
|
||||||
)
|
)
|
||||||
|
|
||||||
# This is the contact information provided by the domain requestor. The
|
|
||||||
# user who created the domain request is in the `creator` field.
|
|
||||||
submitter = models.ForeignKey(
|
|
||||||
"registrar.Contact",
|
|
||||||
null=True,
|
|
||||||
blank=True,
|
|
||||||
related_name="submitted_domain_requests",
|
|
||||||
on_delete=models.PROTECT,
|
|
||||||
help_text='Person listed under "your contact information" in the request form; will receive email updates',
|
|
||||||
)
|
|
||||||
|
|
||||||
purpose = models.TextField(
|
purpose = models.TextField(
|
||||||
null=True,
|
null=True,
|
||||||
blank=True,
|
blank=True,
|
||||||
|
@ -715,9 +703,6 @@ class DomainRequest(TimeStampedModel):
|
||||||
contact information. If there is not creator information, then do
|
contact information. If there is not creator information, then do
|
||||||
nothing.
|
nothing.
|
||||||
|
|
||||||
If the waffle flag "profile_feature" is active, then this email will be sent to the
|
|
||||||
domain request creator rather than the submitter
|
|
||||||
|
|
||||||
Optional args:
|
Optional args:
|
||||||
bcc_address: str -> the address to bcc to
|
bcc_address: str -> the address to bcc to
|
||||||
|
|
||||||
|
@ -732,7 +717,7 @@ class DomainRequest(TimeStampedModel):
|
||||||
custom_email_content: str -> Renders an email with the content of this string as its body text.
|
custom_email_content: str -> Renders an email with the content of this string as its body text.
|
||||||
"""
|
"""
|
||||||
|
|
||||||
recipient = self.creator if flag_is_active(None, "profile_feature") else self.submitter
|
recipient = self.creator
|
||||||
if recipient is None or recipient.email is None:
|
if recipient is None or recipient.email is None:
|
||||||
logger.warning(
|
logger.warning(
|
||||||
f"Cannot send {new_status} email, no creator email address for domain request with pk: {self.pk}."
|
f"Cannot send {new_status} email, no creator email address for domain request with pk: {self.pk}."
|
||||||
|
@ -1170,9 +1155,6 @@ class DomainRequest(TimeStampedModel):
|
||||||
def _is_purpose_complete(self):
|
def _is_purpose_complete(self):
|
||||||
return self.purpose is not None
|
return self.purpose is not None
|
||||||
|
|
||||||
def _is_submitter_complete(self):
|
|
||||||
return self.submitter is not None
|
|
||||||
|
|
||||||
def _has_other_contacts_and_filled(self):
|
def _has_other_contacts_and_filled(self):
|
||||||
# Other Contacts Radio button is Yes and if all required fields are filled
|
# Other Contacts Radio button is Yes and if all required fields are filled
|
||||||
return (
|
return (
|
||||||
|
@ -1227,8 +1209,6 @@ class DomainRequest(TimeStampedModel):
|
||||||
and self._is_senior_official_complete()
|
and self._is_senior_official_complete()
|
||||||
and self._is_requested_domain_complete()
|
and self._is_requested_domain_complete()
|
||||||
and self._is_purpose_complete()
|
and self._is_purpose_complete()
|
||||||
# NOTE: This flag leaves submitter as empty (request wont submit) hence set to True
|
|
||||||
and (self._is_submitter_complete() if not has_profile_feature_flag else True)
|
|
||||||
and self._is_other_contacts_complete()
|
and self._is_other_contacts_complete()
|
||||||
and self._is_additional_details_complete()
|
and self._is_additional_details_complete()
|
||||||
and self._is_policy_acknowledgement_complete()
|
and self._is_policy_acknowledgement_complete()
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue