[Erp5-report] r32509 mame - /erp5/trunk/bt5/erp5_web/SkinTemplateItem/portal_skins/erp5_web/
nobody at svn.erp5.org
nobody at svn.erp5.org
Fri Feb 12 17:29:17 CET 2010
Author: mame
Date: Fri Feb 12 17:29:16 2010
New Revision: 32509
URL: http://svn.erp5.org?rev=32509&view=rev
Log:
Clean WebSection_newWebPage
*Rename the script
*Keep the existing categories on WebPage instead of deleting them.
*Remove the reference generated on the WebPage.
*Redirect to the web page in the context of the web section (in order to view the section in the breadcrumb).
Removed:
erp5/trunk/bt5/erp5_web/SkinTemplateItem/portal_skins/erp5_web/WebSection_newWebPage.xml
Removed: erp5/trunk/bt5/erp5_web/SkinTemplateItem/portal_skins/erp5_web/WebSection_newWebPage.xml
URL: http://svn.erp5.org/erp5/trunk/bt5/erp5_web/SkinTemplateItem/portal_skins/erp5_web/WebSection_newWebPage.xml?rev=32508&view=auto
==============================================================================
--- erp5/trunk/bt5/erp5_web/SkinTemplateItem/portal_skins/erp5_web/WebSection_newWebPage.xml [utf8] (original)
+++ erp5/trunk/bt5/erp5_web/SkinTemplateItem/portal_skins/erp5_web/WebSection_newWebPage.xml (removed)
@@ -1,154 +1,0 @@
-<?xml version="1.0"?>
-<ZopeData>
- <record id="1" aka="AAAAAAAAAAE=">
- <pickle>
- <tuple>
- <global name="PythonScript" module="Products.PythonScripts.PythonScript"/>
- <tuple/>
- </tuple>
- </pickle>
- <pickle>
- <dictionary>
- <item>
- <key> <string>Script_magic</string> </key>
- <value> <int>3</int> </value>
- </item>
- <item>
- <key> <string>_bind_names</string> </key>
- <value>
- <object>
- <klass>
- <global name="NameAssignments" module="Shared.DC.Scripts.Bindings"/>
- </klass>
- <tuple/>
- <state>
- <dictionary>
- <item>
- <key> <string>_asgns</string> </key>
- <value>
- <dictionary>
- <item>
- <key> <string>name_container</string> </key>
- <value> <string>container</string> </value>
- </item>
- <item>
- <key> <string>name_context</string> </key>
- <value> <string>context</string> </value>
- </item>
- <item>
- <key> <string>name_m_self</string> </key>
- <value> <string>script</string> </value>
- </item>
- <item>
- <key> <string>name_subpath</string> </key>
- <value> <string>traverse_subpath</string> </value>
- </item>
- </dictionary>
- </value>
- </item>
- </dictionary>
- </state>
- </object>
- </value>
- </item>
- <item>
- <key> <string>_body</string> </key>
- <value> <string>request = context.REQUEST\n
-portal = context.getPortalObject()\n
-title = context.getTitle(\'Unknown\')\n
-translateString = context.Base_translateString\n
-web_page_module = portal.getDefaultModule(\'Web Page\')\n
-\n
-# Find the applicable language\n
-language = portal.Localizer.get_selected_language()\n
-\n
-# Create a new empty page\n
-web_page = web_page_module.newContent(portal_type = \'Web Page\', \n
- title="New Page of Section %s" % title,\n
- reference="default-%s" % context.getId(),\n
- version="1", language=language)\n
-\n
-# Copy categories into new Web Page\n
-category_list = context.getMembershipCriterionCategoryList()\n
-web_page.setCategoryList(category_list)\n
-\n
-# Return the new page in the section context\n
-return web_page.Base_redirect(\'view\',\n
- keep_items = dict(editable_mode=1,\n
- portal_status_message=translateString("New Web Page of section ${web_section}.",\n
- mapping = dict(web_section=title))))\n
-</string> </value>
- </item>
- <item>
- <key> <string>_code</string> </key>
- <value>
- <none/>
- </value>
- </item>
- <item>
- <key> <string>_params</string> </key>
- <value> <string></string> </value>
- </item>
- <item>
- <key> <string>errors</string> </key>
- <value>
- <tuple/>
- </value>
- </item>
- <item>
- <key> <string>func_code</string> </key>
- <value>
- <object>
- <klass>
- <global name="FuncCode" module="Shared.DC.Scripts.Signature"/>
- </klass>
- <tuple/>
- <state>
- <dictionary>
- <item>
- <key> <string>co_argcount</string> </key>
- <value> <int>0</int> </value>
- </item>
- <item>
- <key> <string>co_varnames</string> </key>
- <value>
- <tuple>
- <string>_getattr_</string>
- <string>context</string>
- <string>request</string>
- <string>portal</string>
- <string>title</string>
- <string>translateString</string>
- <string>web_page_module</string>
- <string>language</string>
- <string>web_page</string>
- <string>category_list</string>
- <string>dict</string>
- </tuple>
- </value>
- </item>
- </dictionary>
- </state>
- </object>
- </value>
- </item>
- <item>
- <key> <string>func_defaults</string> </key>
- <value>
- <none/>
- </value>
- </item>
- <item>
- <key> <string>id</string> </key>
- <value> <string>WebSection_newWebPage</string> </value>
- </item>
- <item>
- <key> <string>warnings</string> </key>
- <value>
- <tuple/>
- </value>
- </item>
- </dictionary>
- </pickle>
- </record>
-</ZopeData>
More information about the Erp5-report
mailing list