[Erp5-report] r29523 - in /erp5/trunk/products/ERP5/bootstrap/erp5_core: SkinTemplateItem/p...
nobody at svn.erp5.org
nobody at svn.erp5.org
Fri Oct 9 15:11:24 CEST 2009
Author: jerome
Date: Fri Oct 9 15:11:22 2009
New Revision: 29523
URL: http://svn.erp5.org?rev=29523&view=rev
Log:
- don't include (s) in messages, use plural ("If you are not sure whether a
noun should be singular or plural, use plural" from
http://www.erp5.org/GuidelinesForNamingConvention )
- use Base_redirect
Modified:
erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Folder_copy.xml
erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Folder_cut.xml
erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Folder_paste.xml
erp5/trunk/products/ERP5/bootstrap/erp5_core/bt/revision
Modified: erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Folder_copy.xml
URL: http://svn.erp5.org/erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Folder_copy.xml?rev=29523&r1=29522&r2=29523&view=diff
==============================================================================
--- erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Folder_copy.xml [utf8] (original)
+++ erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Folder_copy.xml [utf8] Fri Oct 9 15:11:22 2009
@@ -65,10 +65,12 @@
\n
if uids != []:\n
context.manage_copyObjects(uids=uids, REQUEST=request, RESPONSE=request.RESPONSE)\n
- message = Base_translateString("Item(s) copied.")\n
+ message = Base_translateString("Items copied.")\n
else:\n
message = Base_translateString("Please select one or more items to copy first.")\n
-return request.RESPONSE.redirect(context.absolute_url() + \'/\' + form_id + \'?portal_status_message=%s\' % message)\n
+\n
+return context.Base_redirect(form_id,\n
+ keep_items=dict(portal_status_message=message))\n
</string> </value>
</item>
<item>
@@ -79,7 +81,7 @@
</item>
<item>
<key> <string>_params</string> </key>
- <value> <string>form_id, uids=[], listbox_uid=[],selection_name=\'\'</string> </value>
+ <value> <string>form_id, uids=[], listbox_uid=[], selection_name=\'\'</string> </value>
</item>
<item>
<key> <string>_proxy_roles</string> </key>
@@ -122,6 +124,7 @@
<string>selected_uids</string>
<string>request</string>
<string>message</string>
+ <string>dict</string>
</tuple>
</value>
</item>
Modified: erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Folder_cut.xml
URL: http://svn.erp5.org/erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Folder_cut.xml?rev=29523&r1=29522&r2=29523&view=diff
==============================================================================
--- erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Folder_cut.xml [utf8] (original)
+++ erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Folder_cut.xml [utf8] Fri Oct 9 15:11:22 2009
@@ -96,10 +96,11 @@
qs = \'?portal_status_message=%s\' % message \n
else:\n
context.manage_cutObjects(uids=uids, REQUEST=request)\n
- message = Base_translateString("Item(s) cut.")\n
+ message = Base_translateString("Items cut.")\n
else:\n
message = Base_translateString("Please select one or more items to cut first.")\n
-return request.RESPONSE.redirect(context.absolute_url() + \'/\' + form_id + \'?portal_status_message=%s\' % message)\n
+\n
+return context.Base_redirect(form_id, keep_items=dict(portal_status_message=message))\n
]]></string> </value>
@@ -112,7 +113,7 @@
</item>
<item>
<key> <string>_params</string> </key>
- <value> <string>form_id,selection_name=\'\',uids=[],listbox_uid=[]</string> </value>
+ <value> <string>form_id, selection_name=\'\', uids=[], listbox_uid=[]</string> </value>
</item>
<item>
<key> <string>errors</string> </key>
@@ -159,6 +160,7 @@
<string>message</string>
<string>repr</string>
<string>qs</string>
+ <string>dict</string>
</tuple>
</value>
</item>
Modified: erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Folder_paste.xml
URL: http://svn.erp5.org/erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Folder_paste.xml?rev=29523&r1=29522&r2=29523&view=diff
==============================================================================
--- erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Folder_paste.xml [utf8] (original)
+++ erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Folder_paste.xml [utf8] Fri Oct 9 15:11:22 2009
@@ -70,21 +70,23 @@
for portal_type in portal_type_list:\n
if portal_type not in allowed_type_list:\n
error_message = Base_translateString(\'Sorry, you can not paste these items here.\')\n
+\n
if context.cb_dataValid and error_message==\'\':\n
try:\n
new_item_list = context.manage_pasteObjects(REQUEST[\'__cp\'])\n
except KeyError:\n
- msg = Base_translateString(\'Nothing to paste.\')\n
- return REQUEST.RESPONSE.redirect(context.absolute_url() + \'/\' + form_id + \'?portal_status_message=%s\' % msg)\n
+ return context.Base_redirect(form_id,\n
+ keep_items=dict(portal_status_message=Base_translateString(\'Nothing to paste.\')))\n
else:\n
new_id_list = [i[\'new_id\'] for i in new_item_list]\n
- msg = Base_translateString(\'Item(s) paste in progress.\')\n
- return REQUEST.RESPONSE.redirect(context.absolute_url() + \'/\' + form_id + \'?portal_status_message=%s\' % msg)\n
-elif context.cb_dataValid and error_message!=\'\':\n
- return REQUEST.RESPONSE.redirect(context.absolute_url() + \'/\' + form_id + \'?portal_status_message=%s\' % error_message)\n
-else:\n
- error_message = Base_translateString(\'Copy or cut one or more items to paste first.\')\n
- return REQUEST.RESPONSE.redirect(context.absolute_url() + \'/\' + form_id + \'?portal_status_message=%s\' % error_message)\n
+ return context.Base_redirect(form_id,\n
+ keep_items=dict(portal_status_message=Base_translateString(\'Items paste in progress.\')))\n
+\n
+elif context.cb_dataValid and error_message != \'\':\n
+ return context.Base_redirect(form_id, keep_items=dict(portal_status_message=error_message))\n
+\n
+error_message = Base_translateString(\'Copy or cut one or more items to paste first.\')\n
+return context.Base_redirect(form_id, keep_items=dict(portal_status_message=error_message))\n
</string> </value>
</item>
<item>
@@ -139,7 +141,7 @@
<string>_getitem_</string>
<string>new_item_list</string>
<string>KeyError</string>
- <string>msg</string>
+ <string>dict</string>
<string>i</string>
<string>new_id_list</string>
</tuple>
Modified: erp5/trunk/products/ERP5/bootstrap/erp5_core/bt/revision
URL: http://svn.erp5.org/erp5/trunk/products/ERP5/bootstrap/erp5_core/bt/revision?rev=29523&r1=29522&r2=29523&view=diff
==============================================================================
--- erp5/trunk/products/ERP5/bootstrap/erp5_core/bt/revision [utf8] (original)
+++ erp5/trunk/products/ERP5/bootstrap/erp5_core/bt/revision [utf8] Fri Oct 9 15:11:22 2009
@@ -1,1 +1,1 @@
-1328
+1329
More information about the Erp5-report
mailing list