diff options
Diffstat (limited to 'archaeological_operations/templates/ishtar')
3 files changed, 25 insertions, 23 deletions
diff --git a/archaeological_operations/templates/ishtar/blocks/window_tables/administrativacts.html b/archaeological_operations/templates/ishtar/blocks/window_tables/administrativacts.html new file mode 100644 index 000000000..9feb51e72 --- /dev/null +++ b/archaeological_operations/templates/ishtar/blocks/window_tables/administrativacts.html @@ -0,0 +1,18 @@ +{% load i18n %} +<table> + <caption>{{caption}}</caption> + <tr> + <th>{% trans "Ref." %}</th> + <th>{% trans "Type" %}</th> + <th>{% trans "Date" %}</th> + </tr> + {% for act in data %} + <tr> + <td>{{act.full_ref}}</td> + <td class='string'>{{act.act_type}}</td> + <td>{{act.signature_date}}</td> + </tr> + {% empty %} + <tr><td colspan="4" class='no_items'>{% trans "No administrative act associated" %}</td></tr> + {% endfor %} +</table> diff --git a/archaeological_operations/templates/ishtar/sheet_administrativeact.html b/archaeological_operations/templates/ishtar/sheet_administrativeact.html index da80f6747..2cceb0222 100644 --- a/archaeological_operations/templates/ishtar/sheet_administrativeact.html +++ b/archaeological_operations/templates/ishtar/sheet_administrativeact.html @@ -11,6 +11,7 @@ <h3>{% trans "General"%}</h3> <p><label>{%trans "Year:"%}</label> <span class='value strong'>{{ item.year }}</span></p> {% if item.index %}<p><label>{%trans "Numerical reference:"%}</label> <span class='value strong'>{{ item.index }}</span></p>{% endif %} +{% if item.ref_sra %}<p><label>{%trans "Internal reference:"%}</label> <span class='value strong'>{{ item.ref_sra }}</span></p>{% endif %} <p><label>{%trans "Type:"%}</label> <span class='value'>{{ item.act_type }}</span></p> <p><label>{%trans "Signature date:"%}</label> <span class='value'>{{ item.signature_date }}</span></p> <p><label>{%trans "In charge:"%}</label> <span class='value'>{{ item.in_charge.full_label }}</span></p> diff --git a/archaeological_operations/templates/ishtar/sheet_operation.html b/archaeological_operations/templates/ishtar/sheet_operation.html index 9d9b845e3..b403d29df 100644 --- a/archaeological_operations/templates/ishtar/sheet_operation.html +++ b/archaeological_operations/templates/ishtar/sheet_operation.html @@ -1,5 +1,5 @@ {% extends "ishtar/sheet.html" %} -{% load i18n window_tables %} +{% load i18n window_tables window_ope_tables %} {% block head_sheet %} {{block.super}} @@ -100,25 +100,8 @@ {% endfor %} </table> -<table> - <caption>{%trans "Administrative acts"%}</caption> - <tr> - <th>{% trans "Year" %}</th> - <th>{% trans "Ref." %}</th> - <th>{% trans "Type" %}</th> - <th>{% trans "Date" %}</th> - </tr> - {% for act in item.administrative_act.all %} - <tr> - <td>{{act.signature_date.year}}</td> - <td>{% if act.ref_sra %}{{act.ref_sra}}{% endif %}</td> - <td class='string'>{{act.act_type}}</td> - <td class="string">{{act.signature_date}}</td> - </tr> - {% empty %} - <tr><td colspan="4" class='no_items'>{% trans "No acts associated to this operation" %}</td></tr> - {% endfor %} -</table> +{% trans "Administrativ acts" as administrativeacts_label %} +{% table_administrativact administrativeacts_label item.administrative_act.all %} {% trans "Document from this operation" as operation_docs %} {% if item.source.count %} {% table_document operation_docs item.source.all %}{% endif %} @@ -140,7 +123,7 @@ <td class='string'>{{ context_record.datings.all|join:", " }}</td>{# periods ?#} <td class='string'>{{ context_record.description }}</td> <td class='string'>{{ context_record.parcel.section }} - {{context_record.parcel.parcel_number}}</td> - <td class='link'><a href="#" onclick='load_window("{%url show-contextrecord context_record.pk ''%}")'>{% trans "Details" %}</a></td> + <td class='link'><a href="#" class='display_details' onclick='load_window("{%url show-contextrecord context_record.pk ''%}")'>{% trans "Details" %}</a></td> </tr> {% empty %} <tr><td colspan="6" class='no_items'>{% trans "No context record associated to this operation" %}</td></tr> @@ -183,8 +166,8 @@ <td class="ref">{{ context_record.parcel.short_label }}</td> <td class='ref'>{{ find.get_last_find.container.reference|default:""}}</td> <td class='string'>{{ find.get_last_find.container.location|default:""}}</td> - <td class='link'><a href="#">{% trans "Details" %}</a></td> - {#<a href="#" onclick='load_window("{% url show-find find.pk%}");'>{%trans "Details"%}</a></td>#} + <td class='link'><a class='display_details' href="#">{% trans "Details" %}</a></td> + {#<a href="#" class='display_details' onclick='load_window("{% url show-find find.pk%}");'>{%trans "Details"%}</a></td>#} </tr> {% empty %} <tr><td colspan="9" class='no_items'>{% trans "No find associated to context record" %} {{context_record.short_label}}</td></tr> |
