Commit c3bed357 authored by Jean-Paul Smets's avatar Jean-Paul Smets

Updated Base_edit to support reuse from erp5_web. Added proxy Manager to...

Updated Base_edit to support reuse from erp5_web. Added proxy Manager to Folder_reindexObjectList so that reindexing does not fail. Updated worklist to use new portal_type variable. Use compact titles in predicates.

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@13356 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 811127a8
......@@ -247,18 +247,24 @@ try:\n
except ActivityPendingError,e:\n
message = N_("%s" % e)\n
\n
if not(ignore_layout) and context.getApplicableLayout() :\n
redirect_url = \'%s/%s?editable_mode=1\' % (context.REQUEST.URL1, form_id)\n
elif not selection_index:\n
redirect_url = \'%s/%s?portal_status_message=%s\' % (context.absolute_url(),\n
ignore_layout = int(ignore_layout)\n
editable_mode = int(editable_mode)\n
\n
if not selection_index:\n
redirect_url = \'%s/%s?ignore_layout:int=%s&editable_mode:int=%s&portal_status_message=%s\' % (\n
context.absolute_url(),\n
form_id,\n
ignore_layout,\n
editable_mode,\n
message)\n
else:\n
redirect_url = \'%s/%s?selection_index=%s&selection_name=%s&portal_status_message=%s\' % (\n
redirect_url = \'%s/%s?selection_index=%s&selection_name=%s&ignore_layout:int=%s&editable_mode=%s&portal_status_message=%s\' % (\n
context.absolute_url(),\n
form_id,\n
selection_index,\n
selection_name,\n
ignore_layout,\n
editable_mode,\n
message)\n
\n
return request[\'RESPONSE\'].redirect(redirect_url)\n
......@@ -280,7 +286,7 @@ return request[\'RESPONSE\'].redirect(redirect_url)\n
</item>
<item>
<key> <string>_params</string> </key>
<value> <string>form_id, selection_index=0, selection_name=\'\', dialog_id=\'\', ignore_layout=None</string> </value>
<value> <string>form_id, selection_index=0, selection_name=\'\', dialog_id=\'\', ignore_layout=0, editable_mode=1</string> </value>
</item>
<item>
<key> <string>errors</string> </key>
......@@ -300,7 +306,7 @@ return request[\'RESPONSE\'].redirect(redirect_url)\n
<dictionary>
<item>
<key> <string>co_argcount</string> </key>
<value> <int>5</int> </value>
<value> <int>6</int> </value>
</item>
<item>
<key> <string>co_varnames</string> </key>
......@@ -311,6 +317,7 @@ return request[\'RESPONSE\'].redirect(redirect_url)\n
<string>selection_name</string>
<string>dialog_id</string>
<string>ignore_layout</string>
<string>editable_mode</string>
<string>Products.Formulator.Errors</string>
<string>FormValidationError</string>
<string>Products.CMFActivity.Errors</string>
......@@ -344,6 +351,7 @@ return request[\'RESPONSE\'].redirect(redirect_url)\n
<string>_apply_</string>
<string>encapsulated_editor</string>
<string>e</string>
<string>int</string>
</tuple>
</value>
</item>
......@@ -359,7 +367,8 @@ return request[\'RESPONSE\'].redirect(redirect_url)\n
<int>0</int>
<string></string>
<string></string>
<none/>
<int>0</int>
<int>1</int>
</tuple>
</value>
</item>
......
......@@ -83,7 +83,8 @@ new_object = module.newContent(portal_type=portal_type)\n
\n
# Redirect to new content with translated message\n
portal_status_message = translateString("New ${portal_type} created.", mapping = dict(portal_type = portal_type))\n
return new_object.Base_redirect(\'view\', keep_items = dict(portal_status_message=portal_status_message))\n
return new_object.Base_redirect(\'view\', keep_items = dict(portal_status_message=portal_status_message,\n
editable_mode=1))\n
</string> </value>
</item>
<item>
......
......@@ -109,6 +109,14 @@ for id in id_list:\n
<key> <string>_params</string> </key>
<value> <string>id_list, object_tag=None, object_after_tag=None, object_priority=1, sql_catalog_id=None, passive_commit=1</string> </value>
</item>
<item>
<key> <string>_proxy_roles</string> </key>
<value>
<tuple>
<string>Manager</string>
</tuple>
</value>
</item>
<item>
<key> <string>errors</string> </key>
<value>
......
......@@ -81,10 +81,10 @@ category_list = []\n
\n
for item in mixed_list:\n
if item==\'destination_region\':\n
item = \'region\'\n
category_list += [\'destination_region/\' + x for x in context.portal_categories[item].getCategoryChildRelativeUrlList()]\n
item = \'region\' # This must be made more generic\n
category_list += [\'destination_region/\' + x for x in context.portal_categories[item].getCategoryChildCompactLogicalPathItemList(base=1)]\n
else:\n
category_list += context.portal_categories[item].getCategoryChildRelativeUrlList()\n
category_list += context.portal_categories[item].getCategoryChildCompactLogicalPathItemList(base=1)\n
\n
return category_list\n
</string> </value>
......
......@@ -30,7 +30,7 @@
<key> <string>actbox_url</string> </key>
<value> <string encoding="cdata"><![CDATA[
Base_viewSearchResultList?validation_state=draft&reset=1
Base_viewSearchResultList?validation_state=draft&portal_type=%(portal_type)s&reset=1
]]></string> </value>
</item>
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment