Esempio n. 1
0
 def getAllHebergements(self):
     """
     Returns all hebs that can be shown on map
     """
     requestView = getMultiAdapter((self.context, self.request),
                                   name="utilsView")
     results = requestView.getAllHebergements()
     return makeJSON(results)
Esempio n. 2
0
 def getGoogleBlacklist(self):
     """
     get list of google blacklisted items so javascript can check on it
     """
     wrapper = getSAWrapper('gites_wallons')
     MapBlacklist = wrapper.getMapper('map_blacklist')
     query = select([MapBlacklist.blacklist_id],
                    MapBlacklist.blacklist_provider_pk == 'google')
     googleBlacklist = [result.blacklist_id for result in query.execute().fetchall()]
     return makeJSON(googleBlacklist)
Esempio n. 3
0
 def getAllMapData(self):
     """
     Returns all "other" map data for the map
     """
     allMapDatas = self._fetcher.allMapDatas()
     return makeJSON(allMapDatas)
Esempio n. 4
0
 def getMapInfos(self):
     """
     get info of default zoom and map center depending on context
     """
     mapInfos = self._fetcher.mapInfos()
     return makeJSON(mapInfos)
Esempio n. 5
0
 def getHebergements(self):
     localHebergements = list(self._fetcher.fetch())
     return makeJSON(localHebergements)