Merge pull request #660 from cisagov/jon/524

Fixes #524- Election office now doesnt show up when selected School District
This commit is contained in:
Jon 2023-06-01 12:10:08 -04:00 committed by GitHub
commit 47c365552b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -562,11 +562,13 @@ class DomainApplication(TimeStampedModel):
"""Show this step if the answer to the first question implies it.
This shows for answers that aren't "Federal" or "Interstate".
This also doesnt show if user selected "School District" as well (#524)
"""
user_choice = self.organization_type
excluded = [
DomainApplication.OrganizationChoices.FEDERAL,
DomainApplication.OrganizationChoices.INTERSTATE,
DomainApplication.OrganizationChoices.SCHOOL_DISTRICT,
]
return bool(user_choice and user_choice not in excluded)