Commit 7aa170fc authored by Yusei Tahara's avatar Yusei Tahara

2008-08-29 yusei

* Correct message text.

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@23300 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 59dacd2a
...@@ -69,23 +69,25 @@ ...@@ -69,23 +69,25 @@
This script creates a new event with given metadata and\n This script creates a new event with given metadata and\n
attaches it to the current bug.\n attaches it to the current bug.\n
"""\n """\n
translateString = context.Base_translateString\n Base_translateString = context.Base_translateString\n
portal_type = \'Bug\'\n portal_type = \'Bug\'\n
module = context.getDefaultModule(portal_type)\n module = context.getDefaultModule(portal_type)\n
\n \n
if portal_type not in module.getVisibleAllowedContentTypeList():\n if portal_type not in module.getVisibleAllowedContentTypeList():\n
return context.Base_redirect(form_id, keep_items=dict(\n return context.Base_redirect(form_id,\n
portal_status_message=translateString("You Don\'t Have Permission to Add New Bug")))\n keep_items=dict(\n
portal_status_message=Base_translateString("You do not have permission to add new bug")))\n
\n \n
# Create a new event\n # Create a new event\n
bug = module.newContent(portal_type=portal_type, \n bug = module.newContent(portal_type=portal_type,\n
description=description, \n description=description,\n
title=title, \n title=title,\n
follow_up=context.getRelativeUrl())\n follow_up=context.getRelativeUrl())\n
\n \n
# Redirect to even\n # Redirect to even\n
portal_status_message = translateString("Created and associated a new ${portal_type} to the ticket.", \n portal_status_message = Base_translateString(\n
mapping = dict(portal_type = translateString(portal_type)))\n "Created and associated a new ${portal_type} to the ticket.",\n
mapping = dict(portal_type=Base_translateString(portal_type)))\n
return bug.Base_redirect(\'view\', keep_items = dict(portal_status_message=portal_status_message), **kw)\n return bug.Base_redirect(\'view\', keep_items = dict(portal_status_message=portal_status_message), **kw)\n
</string> </value> </string> </value>
</item> </item>
...@@ -135,7 +137,7 @@ return bug.Base_redirect(\'view\', keep_items = dict(portal_status_message=porta ...@@ -135,7 +137,7 @@ return bug.Base_redirect(\'view\', keep_items = dict(portal_status_message=porta
<string>kw</string> <string>kw</string>
<string>_getattr_</string> <string>_getattr_</string>
<string>context</string> <string>context</string>
<string>translateString</string> <string>Base_translateString</string>
<string>portal_type</string> <string>portal_type</string>
<string>module</string> <string>module</string>
<string>dict</string> <string>dict</string>
......
...@@ -73,8 +73,9 @@ translateString = context.Base_translateString\n ...@@ -73,8 +73,9 @@ translateString = context.Base_translateString\n
module = context.getDefaultModule(portal_type)\n module = context.getDefaultModule(portal_type)\n
\n \n
if portal_type not in module.getVisibleAllowedContentTypeList():\n if portal_type not in module.getVisibleAllowedContentTypeList():\n
return context.Base_redirect(form_id, keep_items=dict(\n return context.Base_redirect(form_id,\n
portal_status_message=translateString("You Don\'t Have Permission to Add New Event")))\n keep_items=dict(\n
portal_status_message=translateString("You do not have permission to add new event")))\n
\n \n
# Create a new event\n # Create a new event\n
event = module.newContent(portal_type=portal_type, description=description, title=title, follow_up=context.getRelativeUrl())\n event = module.newContent(portal_type=portal_type, description=description, title=title, follow_up=context.getRelativeUrl())\n
...@@ -86,8 +87,9 @@ else:\n ...@@ -86,8 +87,9 @@ else:\n
event.plan()\n event.plan()\n
\n \n
# Redirect to even\n # Redirect to even\n
portal_status_message = translateString("Created and associated a new ${portal_type} to the ticket.", \n portal_status_message = translateString(\n
mapping = dict(portal_type = translateString(portal_type)))\n "Created and associated a new ${portal_type} to the ticket.", \n
mapping=dict(portal_type = translateString(portal_type)))\n
return event.Base_redirect(\'view\', keep_items = dict(portal_status_message=portal_status_message), **kw)\n return event.Base_redirect(\'view\', keep_items = dict(portal_status_message=portal_status_message), **kw)\n
</string> </value> </string> </value>
</item> </item>
......
2008-08-29 yusei
* Correct message text.
2008-08-28 yusei 2008-08-28 yusei
* Use Base_translateString or translateString instead of N_ for translation message. * Use Base_translateString or translateString instead of N_ for translation message.
......
296 297
\ No newline at end of file \ No newline at end of file
...@@ -98,12 +98,12 @@ else:\n ...@@ -98,12 +98,12 @@ else:\n
commit_recurs = removed\n commit_recurs = removed\n
\n \n
if changelog is None :\n if changelog is None :\n
request.set(\'portal_status_message\', translateString(\'Please Set a ChangeLog Message\'))\n request.set(\'portal_status_message\', translateString(\'Please set a ChangeLog Message\'))\n
request.set(\'cancel_url\', context.absolute_url() + \'/BusinessTemplate_viewSvnStatus?do_extract=False&portal_status_message=Commit%20cancelled.\')\n request.set(\'cancel_url\', context.absolute_url() + \'/BusinessTemplate_viewSvnStatus?do_extract=False&portal_status_message=Commit%20cancelled.\')\n
return context.asContext(added=added, modified=modified, removed=removed).BusinessTemplate_viewSvnChangelog()\n return context.asContext(added=added, modified=modified, removed=removed).BusinessTemplate_viewSvnChangelog()\n
\n \n
if changelog.strip() == \'\' :\n if changelog.strip() == \'\' :\n
request.set(\'portal_status_message\', translateString("Error: ChangeLog Message can\'t be Empty"))\n request.set(\'portal_status_message\', translateString("Error: ChangeLog Message can not be empty"))\n
request.set(\'cancel_url\', context.absolute_url() + \'/BusinessTemplate_viewSvnStatus?do_extract=False&portal_status_message=Commit%20cancelled.\')\n request.set(\'cancel_url\', context.absolute_url() + \'/BusinessTemplate_viewSvnStatus?do_extract=False&portal_status_message=Commit%20cancelled.\')\n
return context.asContext(added=added, modified=modified, removed=removed).BusinessTemplate_viewSvnChangelog()\n return context.asContext(added=added, modified=modified, removed=removed).BusinessTemplate_viewSvnChangelog()\n
\n \n
......
2008-08-29 yusei
* Correct message text.
2008-08-28 yusei 2008-08-28 yusei
* Extract translation message from tal:dfeine expression. * Extract translation message from tal:dfeine expression.
* Use Base_translateString or translateString instead of N_ for translation message. * Use Base_translateString or translateString instead of N_ for translation message.
......
327 328
\ 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