diff options
Diffstat (limited to 'archaeological_finds')
-rw-r--r-- | archaeological_finds/models_treatments.py | 2 | ||||
-rw-r--r-- | archaeological_finds/templates/ishtar/sheet_treatment.html | 5 | ||||
-rw-r--r-- | archaeological_finds/templates/ishtar/sheet_treatmentfile.html | 7 |
3 files changed, 13 insertions, 1 deletions
diff --git a/archaeological_finds/models_treatments.py b/archaeological_finds/models_treatments.py index 2efedbc22..4a453f538 100644 --- a/archaeological_finds/models_treatments.py +++ b/archaeological_finds/models_treatments.py @@ -567,6 +567,7 @@ class TreatmentSource(Source): Treatment, verbose_name=_(u"Treatment"), related_name="source") BOOL_FIELDS = ['duplicate'] TABLE_COLS = ['treatment__cached_label'] + Source.TABLE_COLS + COL_LABELS = {'treatment__cached_label': _(u"Treatment")} SHOW_URL = 'show-treatmentsource' class Meta: @@ -584,6 +585,7 @@ class TreatmentFileSource(Source): related_name="source") BOOL_FIELDS = ['duplicate'] TABLE_COLS = ['treatment_file__cached_label'] + Source.TABLE_COLS + COL_LABELS = {'treatment_file__cached_label': _(u"Treatment file")} SHOW_URL = 'show-treatmentfilesource' class Meta: diff --git a/archaeological_finds/templates/ishtar/sheet_treatment.html b/archaeological_finds/templates/ishtar/sheet_treatment.html index eeaa95dff..37688b267 100644 --- a/archaeological_finds/templates/ishtar/sheet_treatment.html +++ b/archaeological_finds/templates/ishtar/sheet_treatment.html @@ -56,6 +56,11 @@ {% trans "Related operations" as related_operations %} {% dynamic_table_document related_operations 'operations' 'related_treatment' item.pk 'TABLE_COLS' output %} +{% if item.source.count %} +{% trans "Associated documents" as associated_docs %} +{% dynamic_table_document associated_docs 'treatments_docs' 'treatment' item.pk '' output %} +{% endif %} + {% if item.administrative_act.count %} {% trans "Administrative acts" as admact_lbl %} {% table_administrativact admact_lbl item.administrative_act.all %} diff --git a/archaeological_finds/templates/ishtar/sheet_treatmentfile.html b/archaeological_finds/templates/ishtar/sheet_treatmentfile.html index 4b7405192..81311deb8 100644 --- a/archaeological_finds/templates/ishtar/sheet_treatmentfile.html +++ b/archaeological_finds/templates/ishtar/sheet_treatmentfile.html @@ -42,11 +42,16 @@ {% field "Contact" item.applicant.address_lbl %} {% endif %} -{% trans "Treatments" as treatments %} {% if item.treatments.count %} +{% trans "Treatments" as treatments %} {% dynamic_table_document treatments 'treatments' 'file' item.pk '' output '' 'treatment' %} {% endif %} +{% if item.source.count %} +{% trans "Associated documents" as associated_docs %} +{% dynamic_table_document associated_docs 'treatmentfiles_docs' 'treatment_file' item.pk '' output %} +{% endif %} + {% if item.administrative_act.count %} {% trans "Administrative acts" as admact_lbl %} {% table_administrativact admact_lbl item.administrative_act.all %} |