Commit 0cedfad7 authored by Kazuhiko Shiozaki's avatar Kazuhiko Shiozaki

define submit method for Delivery_viewSolveDivergenceDialog.


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@33538 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 77f2ffe2
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<tuple>
<global name="PythonScript" module="Products.PythonScripts.PythonScript"/>
<tuple/>
</tuple>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>Script_magic</string> </key>
<value> <int>3</int> </value>
</item>
<item>
<key> <string>_bind_names</string> </key>
<value>
<object>
<klass>
<global name="NameAssignments" module="Shared.DC.Scripts.Bindings"/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key> <string>_asgns</string> </key>
<value>
<dictionary>
<item>
<key> <string>name_container</string> </key>
<value> <string>container</string> </value>
</item>
<item>
<key> <string>name_context</string> </key>
<value> <string>context</string> </value>
</item>
<item>
<key> <string>name_m_self</string> </key>
<value> <string>script</string> </value>
</item>
<item>
<key> <string>name_subpath</string> </key>
<value> <string>traverse_subpath</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key> <string>_body</string> </key>
<value> <string>from ZTUtils import make_query\n
request= context.REQUEST\n
listbox = request.get(\'listbox\')\n
line_list = context.Delivery_getSolverDecisionList(listbox=listbox)\n
for listbox_key in listbox:\n
listbox_dict = listbox[listbox_key]\n
line = [x for x in line_list if x.getPath() == listbox_key][0]\n
uid = line.getUid()\n
for property in (\'solver\', \'solver_configuration\', \'delivery_solver\', \'comment\',):\n
value = listbox_dict.get(property, None)\n
key = \'field_listbox_%s_%s\' % (property, uid)\n
request.form[key] = request.other[key] = value\n
if property == \'solver_configuration\':\n
if value is not None:\n
line.updateConfiguration(**value.as_dict())\n
else:\n
line.setProperty(property, value)\n
\n
solver_process = line.getParentValue()\n
solver_process.buildTargetSolverList()\n
solver_process.solve()\n
\n
redirect_url = \'%s/%s?%s\' % (\n
context.absolute_url(),\n
\'view\',\n
make_query({\'ignore_layout\':request.get(\'ignore_layout\', 1),\n
\'editable_mode\':request.get(\'editable_mode\', 1),\n
\'portal_status_message\':\'Divergence solvers started in background.\',\n
})\n
)\n
request[ \'RESPONSE\' ].redirect( redirect_url )\n
</string> </value>
</item>
<item>
<key> <string>_code</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>_params</string> </key>
<value> <string>listbox=[],**kw</string> </value>
</item>
<item>
<key> <string>errors</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>func_code</string> </key>
<value>
<object>
<klass>
<global name="FuncCode" module="Shared.DC.Scripts.Signature"/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key> <string>co_argcount</string> </key>
<value> <int>1</int> </value>
</item>
<item>
<key> <string>co_varnames</string> </key>
<value>
<tuple>
<string>listbox</string>
<string>kw</string>
<string>ZTUtils</string>
<string>make_query</string>
<string>_getattr_</string>
<string>context</string>
<string>request</string>
<string>line_list</string>
<string>_getiter_</string>
<string>listbox_key</string>
<string>_getitem_</string>
<string>listbox_dict</string>
<string>append</string>
<string>$append0</string>
<string>x</string>
<string>line</string>
<string>uid</string>
<string>property</string>
<string>None</string>
<string>value</string>
<string>key</string>
<string>_write_</string>
<string>_apply_</string>
<string>solver_process</string>
<string>redirect_url</string>
</tuple>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key> <string>func_defaults</string> </key>
<value>
<tuple>
<list/>
</tuple>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>Delivery_submitSolveDivergenceDialog</string> </value>
</item>
<item>
<key> <string>warnings</string> </key>
<value>
<tuple/>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
......@@ -38,7 +38,7 @@
</item>
<item>
<key> <string>action</string> </key>
<value> <string>Workflow_statusModify</string> </value>
<value> <string>Delivery_submitSolveDivergenceDialog</string> </value>
</item>
<item>
<key> <string>description</string> </key>
......@@ -93,10 +93,10 @@
<value>
<list>
<string>listbox_divergence</string>
<string>listbox_solver_configuration</string>
<string>listbox_solver</string>
<string>listbox_delivery_solver</string>
<string>listbox_comment</string>
<string>listbox_solver_configuration</string>
</list>
</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