add additional label to galleries
gitea-wip/combo/pipeline/head Build started... Details
gitea/combo/pipeline/head Build started... Details

This commit is contained in:
Frédéric Péters 2015-05-31 14:20:57 +02:00
parent 72a80d98cd
commit 9d4bfc331c
1 changed files with 6 additions and 0 deletions

View File

@ -34,6 +34,12 @@ class GalleryCell(CellBase):
gallery_template = template.loader.get_template('combo/gallery.html')
return gallery_template.render(context)
def get_additional_label(self):
if self.title:
return self.title
return ''
class Image(models.Model):
gallery = models.ForeignKey(GalleryCell, verbose_name=_('Gallery'))
image = models.ImageField(_('Image'),