From 37cb695ba14761c5c579ace7797dcd99f5b486c2 Mon Sep 17 00:00:00 2001 From: Étienne Loks Date: Tue, 29 Sep 2015 02:43:19 +0200 Subject: Display dynamicaly large tables in windows --- archaeological_context_records/models.py | 2 +- .../templates/ishtar/sheet_contextrecord.html | 6 +++--- archaeological_context_records/views.py | 1 + 3 files changed, 5 insertions(+), 4 deletions(-) (limited to 'archaeological_context_records') diff --git a/archaeological_context_records/models.py b/archaeological_context_records/models.py index 9c5cf52f4..d86d4aaa9 100644 --- a/archaeological_context_records/models.py +++ b/archaeological_context_records/models.py @@ -19,7 +19,6 @@ from django.conf import settings from django.contrib.gis.db import models -from django.core.exceptions import ValidationError from django.core.urlresolvers import reverse from django.db.models.signals import post_delete from django.utils.translation import ugettext_lazy as _, ugettext, pgettext @@ -284,6 +283,7 @@ class RelationType(GeneralRelationType): verbose_name_plural = _(u"Relation types") ordering = ('order',) + class RecordRelations(GeneralRecordRelations, models.Model): left_record = models.ForeignKey(ContextRecord, related_name='right_relations') diff --git a/archaeological_context_records/templates/ishtar/sheet_contextrecord.html b/archaeological_context_records/templates/ishtar/sheet_contextrecord.html index 1a18f1cd5..8d1a4de63 100644 --- a/archaeological_context_records/templates/ishtar/sheet_contextrecord.html +++ b/archaeological_context_records/templates/ishtar/sheet_contextrecord.html @@ -66,7 +66,7 @@ {% if item.right_relations.count %}

{% trans "In relation with"%}

- +
@@ -87,7 +87,7 @@ {% endfor %} -
{% trans "Relation type" %} {% trans "ID" %}
+
{% endif %} @@ -126,7 +126,7 @@ {% trans "Document from this context record" as cr_docs %} {% if item.source.count %} {% table_document cr_docs item.source.all %}{% endif %} -
+
diff --git a/archaeological_context_records/views.py b/archaeological_context_records/views.py index d92e162c3..483630b3c 100644 --- a/archaeological_context_records/views.py +++ b/archaeological_context_records/views.py @@ -49,6 +49,7 @@ get_contextrecordsource = get_item( extra_request_keys={ 'context_record__parcel__town': 'context_record__parcel__town__pk', 'context_record__operation__year': 'context_record__operation__year', + 'context_record__operation': 'context_record__operation__pk', 'context_record__datings__period': 'context_record__datings__period__pk', 'context_record__unit': 'context_record__unit__pk', -- cgit v1.2.3
{%trans "Finds"%}
{% trans "Complete Id" %}