From 8bc0c9486bcf7d2a3cdf01e3c914d39114ec2e9d Mon Sep 17 00:00:00 2001 From: David Kennedy Date: Mon, 2 Oct 2023 10:23:04 -0400 Subject: [PATCH] roughed in subdomains --- src/registrar/config/urls.py | 5 +++++ src/registrar/templates/domain_dns.html | 3 ++- src/registrar/templates/domain_dnssec.html | 2 +- src/registrar/templates/domain_sidebar.html | 8 ++++++++ src/registrar/templates/domain_subdomains.html | 16 ++++++++++++++++ src/registrar/views/__init__.py | 1 + src/registrar/views/domain.py | 7 +++++++ 7 files changed, 40 insertions(+), 2 deletions(-) create mode 100644 src/registrar/templates/domain_subdomains.html diff --git a/src/registrar/config/urls.py b/src/registrar/config/urls.py index 3cf6d2dfc..30d531c10 100644 --- a/src/registrar/config/urls.py +++ b/src/registrar/config/urls.py @@ -90,6 +90,11 @@ urlpatterns = [ views.DomainNameserversView.as_view(), name="domain-nameservers", ), + path( + "domain//subdomains", + views.DomainSubdomainsView.as_view(), + name="domain-subdomains", + ), path( "domain//dnssec", views.DomainDNSSECView.as_view(), diff --git a/src/registrar/templates/domain_dns.html b/src/registrar/templates/domain_dns.html index dafede300..9b3b7500b 100644 --- a/src/registrar/templates/domain_dns.html +++ b/src/registrar/templates/domain_dns.html @@ -14,7 +14,8 @@ {% url 'domain-nameservers' pk=domain.id as url %}

DNS name servers

-

Subdomain records

+ {% url 'domain-subdomains' pk=domain.id as url %} +

Subdomain records

{% url 'domain-dnssec' pk=domain.id as url %}

DNSSEC

diff --git a/src/registrar/templates/domain_dnssec.html b/src/registrar/templates/domain_dnssec.html index 1c774f83a..25ea8857d 100644 --- a/src/registrar/templates/domain_dnssec.html +++ b/src/registrar/templates/domain_dnssec.html @@ -7,6 +7,6 @@

DNSSEC

-

DNSSEC, or DNS Security Extensions, is additional security layer to protect your website. Enabling DNSSEC ensures that when someone visits your website, they can be certain that it's connecting to the correct server, preventing potential hijacking or tampering with your domain's records. Read more about DNSSEC and why it is important.

+

DNSSEC, or DNS Security Extensions, is additional security layer to protect your website. Enabling DNSSEC ensures that when someone visits your website, they can be certain that it's connecting to the correct server, preventing potential hijacking or tampering with your domain's records. Read more about DNSSEC and why it is important.

{% endblock %} {# domain_content #} diff --git a/src/registrar/templates/domain_sidebar.html b/src/registrar/templates/domain_sidebar.html index 672052ed6..dd056f40f 100644 --- a/src/registrar/templates/domain_sidebar.html +++ b/src/registrar/templates/domain_sidebar.html @@ -29,6 +29,14 @@ +
  • + {% url 'domain-subdomains' pk=domain.id as url %} + + Subdomain records + +
  • {% url 'domain-dnssec' pk=domain.id as url %} Subdomain records + +

    Subdomains allow you to host multiple services under the same domain and create subsets of your website. For example, blogs are often set up as a subdomain (blog.example.gov).

    + +

    Subdomains cannot be requested through the .gov registrar. Those must be set up ... NEED ADDITIONAL COPY HERE

    + +

    If you use subdomains, enter those records (also known as glue records) below.

    + +{% endblock %} {# domain_content #} diff --git a/src/registrar/views/__init__.py b/src/registrar/views/__init__.py index 27522d40e..18441205d 100644 --- a/src/registrar/views/__init__.py +++ b/src/registrar/views/__init__.py @@ -5,6 +5,7 @@ from .domain import ( DomainOrgNameAddressView, DomainDNSView, DomainNameserversView, + DomainSubdomainsView, DomainDNSSECView, DomainYourContactInformationView, DomainSecurityEmailView, diff --git a/src/registrar/views/domain.py b/src/registrar/views/domain.py index 788b084eb..9dae2cb68 100644 --- a/src/registrar/views/domain.py +++ b/src/registrar/views/domain.py @@ -214,6 +214,13 @@ class DomainNameserversView(DomainPermissionView, FormMixin): return super().form_valid(formset) +class DomainSubdomainsView(DomainPermissionView): + + """Domain subdomains editing view.""" + + template_name = "domain_subdomains.html" + + class DomainDNSSECView(DomainPermissionView): """Domain DNSSEC editing view."""