From 1df2033c836d763e0ec85501e26ace2abbd05edf Mon Sep 17 00:00:00 2001 From: Étienne Loks Date: Thu, 3 Aug 2017 17:59:59 +0200 Subject: Admin: improve files and common * Town admin: OSM overlay * add a File lookup * improve considerably File edition (make it usable) --- archaeological_files/models.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'archaeological_files/models.py') diff --git a/archaeological_files/models.py b/archaeological_files/models.py index a9a277280..0d5b4b3e8 100644 --- a/archaeological_files/models.py +++ b/archaeological_files/models.py @@ -151,10 +151,10 @@ class File(ClosedItem, BaseHistorizedItem, OwnPerms, ValueGetter, permit_reference = models.TextField(_(u"Permit reference"), blank=True, null=True) end_date = models.DateField(_(u"Closing date"), null=True, blank=True) - main_town = models.ForeignKey(Town, verbose_name=_(u"Town"), null=True, + main_town = models.ForeignKey(Town, verbose_name=_(u"Main town"), null=True, blank=True, related_name='file_main') towns = models.ManyToManyField(Town, verbose_name=_(u"Towns"), - related_name='file') + related_name='file', blank=True) creation_date = models.DateField( _(u"Creation date"), default=datetime.date.today, blank=True, null=True) -- cgit v1.2.3