diff options
author | Étienne Loks <etienne.loks@iggdrasil.net> | 2017-08-29 14:50:44 +0200 |
---|---|---|
committer | Étienne Loks <etienne.loks@iggdrasil.net> | 2017-08-29 14:51:37 +0200 |
commit | e7e161c2e610b442b4d72d9d749687ff87b993f9 (patch) | |
tree | 413ba34f39b460d24fbd49b75e6769d84c02bbb1 | |
parent | afe97dd3964f003c4c55d5abfe8f8ed523e6a1c1 (diff) | |
download | Ishtar-e7e161c2e610b442b4d72d9d749687ff87b993f9.tar.bz2 Ishtar-e7e161c2e610b442b4d72d9d749687ff87b993f9.zip |
Sheet: add a specific sheet_address_section (refs #3401)
3 files changed, 8 insertions, 4 deletions
diff --git a/archaeological_warehouse/templates/ishtar/sheet_warehouse.html b/archaeological_warehouse/templates/ishtar/sheet_warehouse.html index eb31392e4..3d39f9845 100644 --- a/archaeological_warehouse/templates/ishtar/sheet_warehouse.html +++ b/archaeological_warehouse/templates/ishtar/sheet_warehouse.html @@ -14,6 +14,7 @@ {% field_li "Person in charge" item.person_in_charge %} {% include "ishtar/blocks/sheet_creation_section.html" %} </ul> +{% include "ishtar/blocks/sheet_address_section.html" %} {% field "Comment" item.comment "<pre>" "</pre>" %} {% if item.containers.count %} diff --git a/ishtar_common/templates/ishtar/blocks/sheet_address_section.html b/ishtar_common/templates/ishtar/blocks/sheet_address_section.html new file mode 100644 index 000000000..917258173 --- /dev/null +++ b/ishtar_common/templates/ishtar/blocks/sheet_address_section.html @@ -0,0 +1,6 @@ +{% load i18n %} +{% if item.address or item.address_complement or item.postal_code or item.town %} +<p><label>{% trans "Address" %}</label><pre>{% if item.address %}{{item.address}}{% endif %}{% if item.address_complement %} +{{item.address_complement}}{% endif %}{% if item.postal_code or item.town %} +{{item.postal_code}} {{item.town}}{% endif %}</pre> +</p>{% endif %} diff --git a/ishtar_common/templates/ishtar/sheet_organization.html b/ishtar_common/templates/ishtar/sheet_organization.html index 66048095b..411aa2de3 100644 --- a/ishtar_common/templates/ishtar/sheet_organization.html +++ b/ishtar_common/templates/ishtar/sheet_organization.html @@ -7,10 +7,7 @@ {% window_nav item window_id 'show-organization' 'organization_modify' %} <p><label>{% trans "Name" %}</label> <span class='value'>{{item.name}}</span></p> <p><label>{%trans "Created by:"%}</label> <span class='value'>{{ item.history_creator.ishtaruser.person }}</span></p> -{% if item.address %}<p><label>{% trans "Address" %}</label> <span class='value'>{{item.address}}</span></p> {% endif %} -{% if item.address_complement %}<p><label>{% trans "Address complement" %}</label> <span class='value'>{{item.address_complement}}</span></p> {% endif %} -{% if item.postal_code %}<p><label>{% trans "Postal code" %}</label> <span class='value'>{{item.postal_code}}</span></p> {% endif %} -{% if item.town %}<p><label>{% trans "Town" %}</label> <span class='value'>{{item.town}}</span></p> {% endif %} +{% include "ishtar/blocks/sheet_address_section.html" %} {% if item.phone %}<p><label>{% trans "Phone" %}</label> <span class='value'>{{item.phone}}</span></p> {% endif %} {% if item.mobile_phone %}<p><label>{% trans "Mobile phone" %}</label> <span class='value'>{{item.mobile_phone}}</span></p> {% endif %} |