mirror of
https://github.com/cisagov/manage.get.gov.git
synced 2025-06-02 02:28:32 +02:00
submission date added to home page for domain requests
This commit is contained in:
parent
eb61199d85
commit
2c28863a1c
3 changed files with 35 additions and 4 deletions
|
@ -0,0 +1,17 @@
|
||||||
|
# Generated by Django 4.2.7 on 2023-12-13 15:04
|
||||||
|
|
||||||
|
from django.db import migrations, models
|
||||||
|
|
||||||
|
|
||||||
|
class Migration(migrations.Migration):
|
||||||
|
dependencies = [
|
||||||
|
("registrar", "0055_alter_domain_state_alter_domainapplication_status_and_more"),
|
||||||
|
]
|
||||||
|
|
||||||
|
operations = [
|
||||||
|
migrations.AddField(
|
||||||
|
model_name="domainapplication",
|
||||||
|
name="submission_date",
|
||||||
|
field=models.DateField(blank=True, default=None, help_text="Date submitted", null=True),
|
||||||
|
),
|
||||||
|
]
|
|
@ -547,6 +547,14 @@ class DomainApplication(TimeStampedModel):
|
||||||
help_text="Acknowledged .gov acceptable use policy",
|
help_text="Acknowledged .gov acceptable use policy",
|
||||||
)
|
)
|
||||||
|
|
||||||
|
# submission date records when application is submitted
|
||||||
|
submission_date = models.DateField(
|
||||||
|
null=True,
|
||||||
|
blank=True,
|
||||||
|
default=None,
|
||||||
|
help_text="Date submitted",
|
||||||
|
)
|
||||||
|
|
||||||
def __str__(self):
|
def __str__(self):
|
||||||
try:
|
try:
|
||||||
if self.requested_domain and self.requested_domain.name:
|
if self.requested_domain and self.requested_domain.name:
|
||||||
|
|
|
@ -39,7 +39,7 @@
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
<th data-sortable scope="col" role="columnheader">Domain name</th>
|
<th data-sortable scope="col" role="columnheader">Domain name</th>
|
||||||
<th data-sortable scope="col" role="columnheader">Date created</th>
|
<th data-sortable scope="col" role="columnheader">Expires</th>
|
||||||
<th data-sortable scope="col" role="columnheader">Status</th>
|
<th data-sortable scope="col" role="columnheader">Status</th>
|
||||||
<th scope="col" role="columnheader"><span class="usa-sr-only">Action</span></th>
|
<th scope="col" role="columnheader"><span class="usa-sr-only">Action</span></th>
|
||||||
</tr>
|
</tr>
|
||||||
|
@ -50,7 +50,7 @@
|
||||||
<th th scope="row" role="rowheader" data-label="Domain name">
|
<th th scope="row" role="rowheader" data-label="Domain name">
|
||||||
{{ domain.name }}
|
{{ domain.name }}
|
||||||
</th>
|
</th>
|
||||||
<td data-sort-value="{{ domain.created_time|date:"U" }}" data-label="Date created">{{ domain.created_time|date }}</td>
|
<td data-sort-value="{{ domain.expiration_date|date:"U" }}" data-label="Expires">{{ domain.expiration_date|date }}</td>
|
||||||
<td data-label="Status">
|
<td data-label="Status">
|
||||||
{% if domain.state == "unknown" or domain.state == "dns needed"%}
|
{% if domain.state == "unknown" or domain.state == "dns needed"%}
|
||||||
DNS needed
|
DNS needed
|
||||||
|
@ -99,7 +99,7 @@
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
<th data-sortable scope="col" role="columnheader">Domain name</th>
|
<th data-sortable scope="col" role="columnheader">Domain name</th>
|
||||||
<th data-sortable scope="col" role="columnheader">Date created</th>
|
<th data-sortable scope="col" role="columnheader">Date submitted</th>
|
||||||
<th data-sortable scope="col" role="columnheader">Status</th>
|
<th data-sortable scope="col" role="columnheader">Status</th>
|
||||||
<th scope="col" role="columnheader"><span class="usa-sr-only">Action</span></th>
|
<th scope="col" role="columnheader"><span class="usa-sr-only">Action</span></th>
|
||||||
</tr>
|
</tr>
|
||||||
|
@ -110,7 +110,13 @@
|
||||||
<th th scope="row" role="rowheader" data-label="Domain name">
|
<th th scope="row" role="rowheader" data-label="Domain name">
|
||||||
{{ application.requested_domain.name|default:"New domain request" }}
|
{{ application.requested_domain.name|default:"New domain request" }}
|
||||||
</th>
|
</th>
|
||||||
<td data-sort-value="{{ application.created_at|date:"U" }}" data-label="Date created">{{ application.created_at|date }}</td>
|
<td data-sort-value="{{ application.submission_date|date:"U" }}" data-label="Date submitted">
|
||||||
|
{% if application.submission_date %}
|
||||||
|
{{ application.submission_date|date }}
|
||||||
|
{% else %}
|
||||||
|
Not submitted
|
||||||
|
{% endif %}
|
||||||
|
</td>
|
||||||
<td data-label="Status">{{ application.get_status_display }}</td>
|
<td data-label="Status">{{ application.get_status_display }}</td>
|
||||||
<td>
|
<td>
|
||||||
{% if application.status == "started" or application.status == "action needed" or application.status == "withdrawn" %}
|
{% if application.status == "started" or application.status == "action needed" or application.status == "withdrawn" %}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue