From 5acc89f528f5d6057bf2d93dfaaa8beb7771c08d Mon Sep 17 00:00:00 2001 From: csae8092 Date: Fri, 19 Jul 2024 12:46:37 +0200 Subject: [PATCH] added tag and related cases cols --- archiv/tables.py | 5 ++--- archiv/views.py | 4 ++-- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/archiv/tables.py b/archiv/tables.py index e54d6e4..c589ca0 100644 --- a/archiv/tables.py +++ b/archiv/tables.py @@ -53,14 +53,13 @@ class CourtDecissionTable(tables.Table): merge = MergeColumn(verbose_name="keep | remove", accessor="pk") keyword = tables.columns.ManyToManyColumn(verbose_name="Keywords") author = tables.columns.ManyToManyColumn(verbose_name="Authors") + related_decision = tables.columns.ManyToManyColumn(verbose_name="Related decisions") + tag = tables.columns.ManyToManyColumn(verbose_name="Tags") kwic = tables.columns.TemplateColumn( template_code="{{ record.kwic|safe }}", verbose_name="Keyword in Context", orderable=False, ) - rank = tables.columns.TemplateColumn( - template_code="{{ record.rank|safe }}", verbose_name="Search Rank" - ) class Meta: model = CourtDecission diff --git a/archiv/views.py b/archiv/views.py index 423ef2c..3df70ea 100644 --- a/archiv/views.py +++ b/archiv/views.py @@ -180,8 +180,8 @@ class CourtDecissionListView(CustomListView): filter_class = CourtDecissionListFilter formhelper_class = CourtDecissionFilterFormHelper table_class = CourtDecissionTable - init_columns = ["id", "file_number", "party", "kwic"] - exclude_columns = ["full_text", "vector_column"] + init_columns = ["id", "file_number", "party"] + exclude_columns = ["full_text", "vector_column", "year_book_issue"] enable_merge = True def get_queryset(self, **kwargs):