source: products/qPloneGoogleMaps/tags/0.1.0/browser/markersview.py @ 1591

Last change on this file since 1591 was 1, checked in by myroslav, 15 years ago

Building directory structure

  • Property svn:eol-style set to native
File size: 746 bytes
Line 
1# zope 3 imports
2from zope.interface import implements
3
4# Five imports
5from Products.Five.browser import BrowserView
6
7# Product imports
8from Products.qPloneGoogleMaps.interfaces.markers import IMarkersView
9from Products.qPloneGoogleMaps.adapters.markers import IMarkersListing
10
11class MarkersView(BrowserView):
12
13    implements(IMarkersView)
14         
15    def __init__(self, context, request):
16        """ init view """
17        self.context = context
18        self.request = request
19        adapter = IMarkersListing(self.context, None)
20        if adapter:
21            self.markers = adapter.listMarkers()
22        else:
23            self.markers = None
24
25    def listMarkers(self):
26        """ return contained markers """
27        return self.markers
Note: See TracBrowser for help on using the repository browser.