comparison src/pages/photos/album/page_meta.py @ 1070:46622cb54e6c

pages (photos): new photos/album page to use photo album view when displaying files, and display comments is available.
author Goffi <goffi@goffi.org>
date Sun, 18 Mar 2018 11:38:34 +0100
parents
children 1c09f41e2f52
comparison
equal deleted inserted replaced
1069:2dab7692eae7 1070:46622cb54e6c
1 #!/usr/bin/env python2.7
2 # -*- coding: utf-8 -*-
3
4 from libervia.server.constants import Const as C
5 from sat.core.log import getLogger
6 log = getLogger('pages/photo/album')
7
8 name = u'photos_album'
9 access = C.PAGES_ACCESS_PROFILE
10 template = u"photo/album.html"
11
12 def parse_url(self, request):
13 self.getPathArgs(request, ['service', '*path'], min_args=1, service='jid', path='')
14
15 def prepare_render(self, request):
16 data = self.getRData(request)
17 data['thumb_limit'] = 1200
18 data['retrieve_comments'] = True
19 files_page = self.getPageByName(u'files_list')
20 return files_page.prepare_render(self, request)
21
22 def on_data_post(self, request):
23 blog_page = self.getPageByName(u'blog')
24 return blog_page.on_data_post(self, request)