source: products/quintagroup.plonegooglesitemaps/trunk/quintagroup/plonegooglesitemaps/browser/mobilesitemapview.py @ 1593

Last change on this file since 1593 was 1593, checked in by mylan, 14 years ago

Add content from qPloneGoogleSitemaps. Fix all imports

  • Property svn:eol-style set to native
File size: 750 bytes
Line 
1from DateTime import DateTime
2from commonview import *
3
4MOBILE_INTERFACES = ['quintagroup.mobileextender.interfaces.IMobile',]
5
6class MobileSitemapView(CommonSitemapView):
7    """
8    Mobile Sitemap browser view
9    """
10    implements(ISitemapView)
11
12    additional_maps = (
13        ('modification_date', lambda x:DateTime(x.ModificationDate).HTML4()),
14    )
15
16    def getFilteredObjects(self):
17        path = self.portal.getPhysicalPath()
18        portal_types = self.context.getPortalTypes()
19        review_states = self.context.getStates()
20        return self.portal_catalog(path = path,
21                portal_type = portal_types,
22                review_state = review_states, 
23                object_provides = MOBILE_INTERFACES,
24                )
Note: See TracBrowser for help on using the repository browser.