source: products/quintagroup.quills.extras/branches/wald/quintagroup/quills/extras/portlets/archive.py @ 1423

Last change on this file since 1423 was 662, checked in by chervol, 17 years ago

added license, readme and history updated, version burst

File size: 752 bytes
Line 
1from Products.Five.browser.pagetemplatefile import ViewPageTemplateFile
2
3from quills.app.portlets import archive
4
5class Renderer(archive.Renderer):
6
7    _template = ViewPageTemplateFile('archive.pt')
8   
9    @property
10    def getSubArchives(self):
11        res = []
12        arch = super(Renderer, self).getSubArchives
13        arch.reverse()
14        for y in arch:
15            ydata = {'title'  : y.Title(),
16                     'months': []}
17            months = y.getSubArchives()
18            months.reverse()
19            for m in months:
20                ydata['months'].append(
21                    {'murl':m.absolute_url() ,
22                     'mid' :m.getId(),
23                     'mlen':len(m)})
24            res.append(ydata)
25        return res
Note: See TracBrowser for help on using the repository browser.