Commit c5930551 authored by Romain Courteaud's avatar Romain Courteaud

Handle classification parameter from ContributionTool_viewContributeFileDialog

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@26266 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 177874ae
......@@ -60,14 +60,15 @@
"""\n
\n
translateString = context.Base_translateString\n
portal_type = kw.get(\'portal_type\', None)\n
\n
\n
# ingest file (asynchronously)\n
if portal_type:\n
doc = context.portal_contributions.newContent(file = file,\n
portal_type = portal_type)\n
doc = context.portal_contributions.newContent(file=file,\n
portal_type=portal_type,\n
classification=classification)\n
else:\n
doc = context.portal_contributions.newContent(file=file)\n
doc = context.portal_contributions.newContent(file=file, classification=classification)\n
\n
msg = translateString("${portal_type} created successfully.",\n
mapping = {\'portal_type\':doc.getPortalType()})\n
......@@ -82,7 +83,7 @@ return context.Base_redirect(\'view\', keep_items = {\'portal_status_message\':m
</item>
<item>
<key> <string>_params</string> </key>
<value> <string>dialog_id=None, form_id=None, file=None, **kw</string> </value>
<value> <string>dialog_id=None, form_id=None, file=None, portal_type=None, classification=None, **kw</string> </value>
</item>
<item>
<key> <string>errors</string> </key>
......@@ -102,7 +103,7 @@ return context.Base_redirect(\'view\', keep_items = {\'portal_status_message\':m
<dictionary>
<item>
<key> <string>co_argcount</string> </key>
<value> <int>3</int> </value>
<value> <int>5</int> </value>
</item>
<item>
<key> <string>co_varnames</string> </key>
......@@ -111,12 +112,12 @@ return context.Base_redirect(\'view\', keep_items = {\'portal_status_message\':m
<string>dialog_id</string>
<string>form_id</string>
<string>file</string>
<string>portal_type</string>
<string>classification</string>
<string>kw</string>
<string>_getattr_</string>
<string>context</string>
<string>translateString</string>
<string>None</string>
<string>portal_type</string>
<string>doc</string>
<string>msg</string>
</tuple>
......@@ -134,6 +135,8 @@ return context.Base_redirect(\'view\', keep_items = {\'portal_status_message\':m
<none/>
<none/>
<none/>
<none/>
<none/>
</tuple>
</value>
</item>
......
38
\ No newline at end of file
40
\ 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