mirror of
https://github.com/cisagov/manage.get.gov.git
synced 2025-08-15 22:14:15 +02:00
Slight abstraction
This commit is contained in:
parent
1841b2f728
commit
7ea27e3aa2
2 changed files with 33 additions and 35 deletions
|
@ -0,0 +1,27 @@
|
||||||
|
{% load i18n static %}
|
||||||
|
|
||||||
|
{% if start_opened %}
|
||||||
|
<details class="margin-top-1 dja-detail-table" open>
|
||||||
|
{% else %}
|
||||||
|
<details class="margin-top-1 dja-detail-table">
|
||||||
|
{% endif%}
|
||||||
|
<summary class="padding-1 dja-details-summary">Details</summary>
|
||||||
|
<div class="grid-container padding-left-0 padding-right-0 dja-details-contents">
|
||||||
|
<table>
|
||||||
|
<tbody>
|
||||||
|
<tr>
|
||||||
|
<th scope="row">Title</th>
|
||||||
|
<td>{{ user.title }}</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<th scope="row">Email</th>
|
||||||
|
<td>{{ user.email }}</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<th scope="row">Phone</th>
|
||||||
|
<td>{{ user.phone }}</td>
|
||||||
|
</tr>
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
</div>
|
||||||
|
</details>
|
|
@ -23,43 +23,13 @@ This is using a custom implementation fieldset.html (see admin/fieldset.html)
|
||||||
{% endif %}
|
{% endif %}
|
||||||
</div>
|
</div>
|
||||||
{% if field.field.name == "creator" %}
|
{% if field.field.name == "creator" %}
|
||||||
<ul>
|
{% include "django/admin/includes/domain_request_detail_table.html" with user=original.creator start_opened=True %}
|
||||||
{% if original.creator.title %}
|
|
||||||
<li>{{ original.creator.title }}</li>
|
|
||||||
{% endif %}
|
|
||||||
|
|
||||||
{% if original.creator.email %}
|
|
||||||
<li>{{ original.creator.email }}</li>
|
|
||||||
{% endif %}
|
|
||||||
|
|
||||||
{% if original.creator.phone %}
|
|
||||||
<li>{{ original.creator.phone }}</li>
|
|
||||||
{% endif %}
|
|
||||||
</ul>
|
|
||||||
{% elif field.field.name == "submitter" %}
|
{% elif field.field.name == "submitter" %}
|
||||||
<details class="dja-detail-table" open>
|
{% include "django/admin/includes/domain_request_detail_table.html" with user=original.submitter start_opened=True %}
|
||||||
<summary class="padding-1 dja-details-summary">Details</summary>
|
{% elif field.field.name == "authorizing_official" %}
|
||||||
<div class="grid-container padding-left-0 padding-right-0 dja-details-contents">
|
{% include "django/admin/includes/domain_request_detail_table.html" with user=original.authorizing_official start_opened=True %}
|
||||||
<table>
|
|
||||||
<tbody>
|
|
||||||
<tr>
|
|
||||||
<th scope="row">Title</th>
|
|
||||||
<td>{{ original.submitter.title }}</td>
|
|
||||||
</tr>
|
|
||||||
<tr>
|
|
||||||
<th scope="row">Email</th>
|
|
||||||
<td>{{ original.submitter.email }}</td>
|
|
||||||
</tr>
|
|
||||||
<tr>
|
|
||||||
<th scope="row">Phone</th>
|
|
||||||
<td>{{ original.submitter.phone }}</td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</div>
|
|
||||||
</details>
|
|
||||||
{% elif field.field.name == "other_contacts" %}
|
{% elif field.field.name == "other_contacts" %}
|
||||||
<details class="dja-detail-table">
|
<details class="margin-top-1 dja-detail-table">
|
||||||
<summary class="padding-1 dja-details-summary">Details</summary>
|
<summary class="padding-1 dja-details-summary">Details</summary>
|
||||||
<div class="grid-container padding-left-0 padding-right-0 dja-details-contents">
|
<div class="grid-container padding-left-0 padding-right-0 dja-details-contents">
|
||||||
<table>
|
<table>
|
||||||
|
@ -77,6 +47,7 @@ This is using a custom implementation fieldset.html (see admin/fieldset.html)
|
||||||
</div>
|
</div>
|
||||||
</details>
|
</details>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
{% if field.field.help_text %}
|
{% if field.field.help_text %}
|
||||||
<div class="help"{% if field.field.id_for_label %} id="{{ field.field.id_for_label }}_helptext"{% endif %}>
|
<div class="help"{% if field.field.id_for_label %} id="{{ field.field.id_for_label }}_helptext"{% endif %}>
|
||||||
<div>{{ field.field.help_text|safe }}</div>
|
<div>{{ field.field.help_text|safe }}</div>
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue