From 6965d593f5254b0ef092edcf619fd5475c2a479b Mon Sep 17 00:00:00 2001
From: Rebecca Hsieh We’d like to know more about your organization. Include the following in your response:
+
+
*This question is required.
+{% endblock %} + +{% block form_fields %} + {% with attr_maxlength=1000 add_label_class="usa-sr-only" %} + {% input_with_errors forms.0.about_your_organization %} + {% endwith %} +{% endblock %} \ No newline at end of file diff --git a/src/registrar/templates/application_review.html b/src/registrar/templates/application_review.html index b9ac97871..be81303b8 100644 --- a/src/registrar/templates/application_review.html +++ b/src/registrar/templates/application_review.html @@ -46,9 +46,8 @@ Incomplete {% endif %} {% endif %} - {% if step == Step.TYPE_OF_WORK %} -{{ application.type_of_work|default:"Incomplete" }}
-{{ application.more_organization_information|default:"Incomplete" }}
+ {% if step == Step.ABOUT_YOUR_ORGANIZATION %} +{{ application.about_your_organization|default:"Incomplete" }}
{% endif %} {% if step == Step.AUTHORIZING_OFFICIAL %} {% if application.authorizing_official %} diff --git a/src/registrar/templates/application_status.html b/src/registrar/templates/application_status.html index 67e8e7664..a68c07c8a 100644 --- a/src/registrar/templates/application_status.html +++ b/src/registrar/templates/application_status.html @@ -77,12 +77,8 @@ {% include "includes/summary_item.html" with title='Organization name and mailing address' value=domainapplication address='true' heading_level=heading_level %} {% endif %} - {% if domainapplication.type_of_work %} - {% include "includes/summary_item.html" with title='Type of work' value=domainapplication.type_of_work heading_level=heading_level %} - {% endif %} - - {% if domainapplication.more_organization_information %} - {% include "includes/summary_item.html" with title='More information about your organization' value=domainapplication.more_organization_information heading_level=heading_level %} + {% if domainapplication.about_your_organization %} + {% include "includes/summary_item.html" with title='About your organization' value=domainapplication.about_your_organization heading_level=heading_level %} {% endif %} {% if domainapplication.authorizing_official %} diff --git a/src/registrar/templates/application_type_of_work.html b/src/registrar/templates/application_type_of_work.html deleted file mode 100644 index 9ad58936f..000000000 --- a/src/registrar/templates/application_type_of_work.html +++ /dev/null @@ -1,10 +0,0 @@ -{% extends 'application_form.html' %} -{% load field_helpers %} - - -{% block form_fields %} - {% with attr_maxlength=1000 %} - {% input_with_errors forms.0.type_of_work %} - {% input_with_errors forms.0.more_organization_information %} - {% endwith %} -{% endblock %} \ No newline at end of file diff --git a/src/registrar/templates/emails/includes/application_summary.txt b/src/registrar/templates/emails/includes/application_summary.txt index 07519a8f0..293dad2e4 100644 --- a/src/registrar/templates/emails/includes/application_summary.txt +++ b/src/registrar/templates/emails/includes/application_summary.txt @@ -10,9 +10,9 @@ Organization name and mailing address: {{ application.city }}, {{ application.state_territory }} {{ application.zipcode }}{% if application.urbanization %} {{ application.urbanization }}{% endif %}{% endspaceless %} -{% if application.type_of_work %}{# if block makes one newline if it's false #} -Type of work: -{% spaceless %}{{ application.type_of_work }}{% endspaceless %} +{% if application.about_your_organization %}{# if block makes one newline if it's false #} +About your organization: +{% spaceless %}{{ application.about_your_organization }}{% endspaceless %} {% endif %} Authorizing official: {% spaceless %}{% include "emails/includes/contact.txt" with contact=application.authorizing_official %}{% endspaceless %} diff --git a/src/registrar/tests/common.py b/src/registrar/tests/common.py index c312acca0..e21431321 100644 --- a/src/registrar/tests/common.py +++ b/src/registrar/tests/common.py @@ -250,7 +250,7 @@ class AuditedAdminMockData: is_policy_acknowledged: boolean = True, state_territory: str = "NY", zipcode: str = "10002", - type_of_work: str = "e-Government", + about_your_organization: str = "e-Government", anything_else: str = "There is more", authorizing_official: Contact = self.dummy_contact(item_name, "authorizing_official"), submitter: Contact = self.dummy_contact(item_name, "submitter"), @@ -267,7 +267,7 @@ class AuditedAdminMockData: is_policy_acknowledged=True, state_territory="NY", zipcode="10002", - type_of_work="e-Government", + about_your_organization="e-Government", anything_else="There is more", authorizing_official=self.dummy_contact(item_name, "authorizing_official"), submitter=self.dummy_contact(item_name, "submitter"), @@ -453,7 +453,7 @@ def completed_application( has_other_contacts=True, has_current_website=True, has_alternative_gov_domain=True, - has_type_of_work=True, + has_about_your_organization=True, has_anything_else=True, status=DomainApplication.STARTED, user=False, @@ -501,8 +501,8 @@ def completed_application( creator=user, status=status, ) - if has_type_of_work: - domain_application_kwargs["type_of_work"] = "e-Government" + if has_about_your_organization: + domain_application_kwargs["about_your_organization"] = "e-Government" if has_anything_else: domain_application_kwargs["anything_else"] = "There is more" diff --git a/src/registrar/tests/test_admin.py b/src/registrar/tests/test_admin.py index a24ee9a6e..b28a5dcec 100644 --- a/src/registrar/tests/test_admin.py +++ b/src/registrar/tests/test_admin.py @@ -441,8 +441,7 @@ class TestDomainApplicationAdmin(TestCase): "state_territory", "zipcode", "urbanization", - "type_of_work", - "more_organization_information", + "about_your_organization", "authorizing_official", "approved_domain", "requested_domain", @@ -466,8 +465,7 @@ class TestDomainApplicationAdmin(TestCase): expected_fields = [ "creator", - "type_of_work", - "more_organization_information", + "about_your_organization", "address_line1", "address_line2", "zipcode", diff --git a/src/registrar/tests/test_emails.py b/src/registrar/tests/test_emails.py index b5c6cd428..7bce52668 100644 --- a/src/registrar/tests/test_emails.py +++ b/src/registrar/tests/test_emails.py @@ -48,7 +48,7 @@ class TestEmails(TestCase): self.assertIn("Testy2 Tester2", body) self.assertIn("Current website for your organization:", body) self.assertIn("city.com", body) - self.assertIn("Type of work:", body) + self.assertIn("About your organization:", body) self.assertIn("Anything else", body) @boto3_mocking.patching @@ -126,26 +126,26 @@ class TestEmails(TestCase): self.assertRegex(body, r"city.gov\n\nPurpose of your domain:") @boto3_mocking.patching - def test_submission_confirmation_type_of_work_spacing(self): - """Test line spacing with type of work.""" - application = completed_application(has_type_of_work=True) + def test_submission_confirmation_about_your_organization_spacing(self): + """Test line spacing with about your organization.""" + application = completed_application(has_about_your_organization=True) with boto3_mocking.clients.handler_for("sesv2", self.mock_client_class): application.submit() _, kwargs = self.mock_client.send_email.call_args body = kwargs["Content"]["Simple"]["Body"]["Text"]["Data"] - self.assertIn("Type of work:", body) + self.assertIn("About your organization:", body) # spacing should be right between adjacent elements - self.assertRegex(body, r"10002\n\nType of work:") + self.assertRegex(body, r"10002\n\nAbout your organization:") @boto3_mocking.patching - def test_submission_confirmation_no_type_of_work_spacing(self): - """Test line spacing without type of work.""" - application = completed_application(has_type_of_work=False) + def test_submission_confirmation_no_about_your_organization_spacing(self): + """Test line spacing without about your organization.""" + application = completed_application(has_about_your_organization=False) with boto3_mocking.clients.handler_for("sesv2", self.mock_client_class): application.submit() _, kwargs = self.mock_client.send_email.call_args body = kwargs["Content"]["Simple"]["Body"]["Text"]["Data"] - self.assertNotIn("Type of work:", body) + self.assertNotIn("About your organization:", body) # spacing should be right between adjacent elements self.assertRegex(body, r"10002\n\nAuthorizing official:") diff --git a/src/registrar/tests/test_forms.py b/src/registrar/tests/test_forms.py index 173362943..95be195ba 100644 --- a/src/registrar/tests/test_forms.py +++ b/src/registrar/tests/test_forms.py @@ -13,7 +13,7 @@ from registrar.forms.application_wizard import ( TribalGovernmentForm, PurposeForm, AnythingElseForm, - TypeOfWorkForm, + AboutYourOrganizationForm, ) from registrar.forms.domain import ContactForm @@ -118,7 +118,7 @@ class TestFormValidation(TestCase): ["Response must be less than 1000 characters."], ) - def test_anything_else_form_type_of_work_character_count_invalid(self): + def test_anything_else_form_about_your_organization_character_count_invalid(self): """Response must be less than 1000 characters.""" form = AnythingElseForm( data={ @@ -147,43 +147,12 @@ class TestFormValidation(TestCase): ["Response must be less than 1000 characters."], ) - def test_anything_else_form_more_organization_information_character_count_invalid( - self, - ): - """Response must be less than 1000 characters.""" - form = TypeOfWorkForm( - data={ - "more_organization_information": "Bacon ipsum dolor amet fatback" - "shankle, drumstick doner chicken landjaeger turkey andouille." - "Buffalo biltong chuck pork chop tongue bresaola turkey. Doner" - "ground round strip steak, jowl tail chuck ribeye bacon" - "beef ribs swine filet ball tip pancetta strip steak sirloin" - "mignon ham spare ribs rump. Tail shank biltong beef ribs doner" - "buffalo swine bacon. Tongue cow picanha brisket bacon chuck" - "leberkas pork loin pork, drumstick capicola. Doner short loin" - "ground round fatback turducken chislic shoulder turducken" - "spare ribs, burgdoggen kielbasa kevin frankfurter ball tip" - "pancetta cupim. Turkey meatball andouille porchetta hamburger" - "pork chop corned beef. Brisket short ribs turducken, pork chop" - "chislic turkey ball pork chop leberkas rump, rump bacon, jowl" - "tip ham. Shankle salami tongue venison short ribs kielbasa" - "tri-tip ham hock swine hamburger. Flank meatball corned beef" - "cow sausage ball tip kielbasa ham hock. Ball tip cupim meatloaf" - "beef ribs rump jowl tenderloin swine sausage biltong" - "bacon rump tail boudin meatball boudin meatball boudin" - "strip steak pastrami." - } - ) - self.assertEqual( - form.errors["more_organization_information"], - ["Response must be less than 1000 characters."], - ) - def test_anything_else_form_character_count_invalid(self): """Response must be less than 1000 characters.""" - form = TypeOfWorkForm( + form = AboutYourOrganizationForm( data={ - "type_of_work": "Bacon ipsum dolor amet fatback strip steak pastrami" + "about_your_organization": "Bacon ipsum dolor amet fatback" + "strip steak pastrami" "shankle, drumstick doner chicken landjaeger turkey andouille." "Buffalo biltong chuck pork chop tongue bresaola turkey. Doner" "ground round strip steak, jowl tail chuck ribeye bacon" @@ -204,7 +173,7 @@ class TestFormValidation(TestCase): } ) self.assertEqual( - form.errors["type_of_work"], + form.errors["about_your_organization"], ["Response must be less than 1000 characters."], ) diff --git a/src/registrar/tests/test_views.py b/src/registrar/tests/test_views.py index 96ce76e1a..318cc261d 100644 --- a/src/registrar/tests/test_views.py +++ b/src/registrar/tests/test_views.py @@ -660,12 +660,14 @@ class DomainApplicationTests(TestWithUser, WebTest): self.app.set_cookie(settings.SESSION_COOKIE_NAME, session_id) contact_result = org_contact_form.submit() - # the post request should return a redirect to the type of work page - # if it was successful. + # the post request should return a redirect to the + # about your organization page if it was successful. self.assertEqual(contact_result.status_code, 302) - self.assertEqual(contact_result["Location"], "/register/type_of_work/") + self.assertEqual( + contact_result["Location"], "/register/about_your_organization/" + ) - def test_application_type_of_work_special(self): + def test_application_about_your_organization_special(self): """Special districts have to answer an additional question.""" type_page = self.app.get(reverse("application:")).follow() # django-webtest does not handle cookie-based sessions well because it keeps @@ -684,7 +686,7 @@ class DomainApplicationTests(TestWithUser, WebTest): self.app.set_cookie(settings.SESSION_COOKIE_NAME, session_id) contact_page = type_result.follow() - self.assertContains(contact_page, self.TITLES[Step.TYPE_OF_WORK]) + self.assertContains(contact_page, self.TITLES[Step.ABOUT_YOUR_ORGANIZATION]) def test_application_no_other_contacts(self): """Applicants with no other contacts have to give a reason.""" @@ -704,7 +706,7 @@ class DomainApplicationTests(TestWithUser, WebTest): actual_url_slug = no_contacts_page.request.path.split("/")[-2] self.assertEqual(expected_url_slug, actual_url_slug) - def test_application_type_of_work_interstate(self): + def test_application_about_your_organiztion_interstate(self): """Special districts have to answer an additional question.""" type_page = self.app.get(reverse("application:")).follow() # django-webtest does not handle cookie-based sessions well because it keeps @@ -723,7 +725,7 @@ class DomainApplicationTests(TestWithUser, WebTest): self.app.set_cookie(settings.SESSION_COOKIE_NAME, session_id) contact_page = type_result.follow() - self.assertContains(contact_page, self.TITLES[Step.TYPE_OF_WORK]) + self.assertContains(contact_page, self.TITLES[Step.ABOUT_YOUR_ORGANIZATION]) def test_application_tribal_government(self): """Tribal organizations have to answer an additional question.""" diff --git a/src/registrar/views/application.py b/src/registrar/views/application.py index 23d7348e9..878da262b 100644 --- a/src/registrar/views/application.py +++ b/src/registrar/views/application.py @@ -30,7 +30,7 @@ class Step(StrEnum): ORGANIZATION_FEDERAL = "organization_federal" ORGANIZATION_ELECTION = "organization_election" ORGANIZATION_CONTACT = "organization_contact" - TYPE_OF_WORK = "type_of_work" + ABOUT_YOUR_ORGANIZATION = "about_your_organization" AUTHORIZING_OFFICIAL = "authorizing_official" CURRENT_SITES = "current_sites" DOTGOV_DOMAIN = "dotgov_domain" @@ -77,7 +77,7 @@ class ApplicationWizard(ApplicationWizardPermissionView, TemplateView): Step.ORGANIZATION_FEDERAL: _("Federal government branch"), Step.ORGANIZATION_ELECTION: _("Election office"), Step.ORGANIZATION_CONTACT: _("Organization name and mailing address"), - Step.TYPE_OF_WORK: _("Type of work"), + Step.ABOUT_YOUR_ORGANIZATION: _("About your organization"), Step.AUTHORIZING_OFFICIAL: _("Authorizing official"), Step.CURRENT_SITES: _("Current website for your organization"), Step.DOTGOV_DOMAIN: _(".gov domain"), @@ -100,7 +100,9 @@ class ApplicationWizard(ApplicationWizardPermissionView, TemplateView): Step.ORGANIZATION_ELECTION: lambda w: w.from_model( "show_organization_election", False ), - Step.TYPE_OF_WORK: lambda w: w.from_model("show_type_of_work", False), + Step.ABOUT_YOUR_ORGANIZATION: lambda w: w.from_model( + "show_about_your_organization", False + ), Step.NO_OTHER_CONTACTS: lambda w: w.from_model( "show_no_other_contacts_rationale", False ), @@ -373,9 +375,9 @@ class OrganizationContact(ApplicationWizard): forms = [forms.OrganizationContactForm] -class TypeOfWork(ApplicationWizard): - template_name = "application_type_of_work.html" - forms = [forms.TypeOfWorkForm] +class AboutYourOrganization(ApplicationWizard): + template_name = "application_about_your_organization.html" + forms = [forms.AboutYourOrganizationForm] class AuthorizingOfficial(ApplicationWizard):