From cc701ee77ee21e2be07710a14759fb873e82f403 Mon Sep 17 00:00:00 2001 From: Étienne Loks Date: Wed, 9 Sep 2020 14:53:28 +0200 Subject: Sheet organization: show publication --- ishtar_common/models.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'ishtar_common/models.py') diff --git a/ishtar_common/models.py b/ishtar_common/models.py index df9fe0c20..001c1894f 100644 --- a/ishtar_common/models.py +++ b/ishtar_common/models.py @@ -5423,6 +5423,7 @@ class Document(BaseHistorizedItem, QRCodeItem, OwnPerms, ImageModel, 'authors__cached_label': 'authors__cached_label', 'authors__person__pk': 'authors__person__pk', "container_id": "container_id", + 'publisher__pk': 'publisher__pk' } # alternative names of fields for searches @@ -5663,8 +5664,9 @@ class Document(BaseHistorizedItem, QRCodeItem, OwnPerms, ImageModel, source_type = models.ForeignKey(SourceType, verbose_name=_("Type"), on_delete=models.SET_NULL, null=True, blank=True) - publisher = models.ForeignKey(Organization, verbose_name=_("Publisher"), - blank=True, null=True) + publisher = models.ForeignKey( + Organization, verbose_name=_("Publisher"), blank=True, null=True, + related_name='publish') licenses = models.ManyToManyField(LicenseType, verbose_name=_("License"), blank=True) tags = models.ManyToManyField(DocumentTag, verbose_name=_("Tags"), -- cgit v1.2.3