source: products/qPloneGoogleMaps/tags/0.1.0/skins/qPloneGoogleMaps/prefs_mapkeys_set.cpy

Last change on this file was 1, checked in by myroslav, 17 years ago

Building directory structure

  • Property svn:eol-style set to native
File size: 704 bytes
Line 
1## Script (Python) "prefs_mapkeys_set"
2##bind container=container
3##bind context=context
4##bind namespace=
5##bind script=script
6##bind subpath=traverse_subpath
7##parameters= map_api_keys
8##title=
9##
10
11from Products.CMFCore.utils import getToolByName
12from Products.qPloneGoogleMaps.config import PROPERTY_SHEET, PROPERTY_FIELD
13
14portal_props = getToolByName(context, 'portal_properties')
15
16if not hasattr(portal_props, PROPERTY_SHEET):
17    portal_props.addPropertySheet(PROPERTY_SHEET, 'Maps Properties')
18
19property_sheet = getattr(portal_props, PROPERTY_SHEET)
20property_sheet.manage_changeProperties(context.REQUEST)
21
22return state.set(status='success', portal_status_message = '%s updated.' % PROPERTY_SHEET)
Note: See TracBrowser for help on using the repository browser.