Commit 59490eba authored by Fabien Morin's avatar Fabien Morin

improve status messages

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@31145 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent dc5fe3b9
...@@ -78,7 +78,8 @@ else:\n ...@@ -78,7 +78,8 @@ else:\n
)\n )\n
\n \n
if count != 0:\n if count != 0:\n
msg = \'%s %s\' % (count, context.Base_translateString(\'Items created.\'))\n msg = context.Base_translateString(\'${count} Apparel Colour Range Variation created.\',\n
mapping={\'count\': count})\n
\n \n
context.Base_redirect(form_id=form_id,\n context.Base_redirect(form_id=form_id,\n
keep_items=dict(portal_status_message=msg))\n keep_items=dict(portal_status_message=msg))\n
......
...@@ -62,7 +62,7 @@ cell_id_list = []\n ...@@ -62,7 +62,7 @@ cell_id_list = []\n
msg = context.Base_translateString(\'No Composition found.\')\n msg = context.Base_translateString(\'No Composition found.\')\n
colour_range = context.getSpecialiseValue(portal_type=\'Apparel Colour Range\')\n colour_range = context.getSpecialiseValue(portal_type=\'Apparel Colour Range\')\n
if colour_range is None:\n if colour_range is None:\n
msg = context.Base_translateString(\'Apparel Colour Range must be defined\')\n msg = context.Base_translateString(\'Apparel Colour Range must be defined.\')\n
\n \n
elif len(colour_range.contentValues(portal_type=\'Apparel Colour Range Variation\')) != 0:\n elif len(colour_range.contentValues(portal_type=\'Apparel Colour Range Variation\')) != 0:\n
colour_variation = colour_range.contentValues(portal_type=\'Apparel Colour Range Variation\')[0]\n colour_variation = colour_range.contentValues(portal_type=\'Apparel Colour Range Variation\')[0]\n
...@@ -89,9 +89,8 @@ elif len(colour_range.contentValues(portal_type=\'Apparel Colour Range Variation ...@@ -89,9 +89,8 @@ elif len(colour_range.contentValues(portal_type=\'Apparel Colour Range Variation
portal_type=\'Mapped Value\')\n portal_type=\'Mapped Value\')\n
new_cell.setQuantity(cell.getQuantity())\n new_cell.setQuantity(cell.getQuantity())\n
if len(poly_list):\n if len(poly_list):\n
msg = \'%s %s\' % (len(poly_list), context.Base_translateString(\'Items pasted.\'))\n msg = context.Base_translateString(\'${count} Composition created.\',\n
else:\n mapping={\'count\': len(poly_list)})\n
msg = context.Base_translateString(\'No Composition found.\')\n
\n \n
return context.Base_redirect(form_id=form_id,\n return context.Base_redirect(form_id=form_id,\n
keep_items = dict(portal_status_message=msg))\n keep_items = dict(portal_status_message=msg))\n
......
233 234
\ No newline at end of file \ No newline at end of file
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