Commit cfe75a30 authored by Aurel's avatar Aurel

allow user to choose simulation state of documents displayed in report

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@20587 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 5a515a21
...@@ -75,6 +75,7 @@ aggregation_level = context.REQUEST.get(\'aggregation_level\')\n ...@@ -75,6 +75,7 @@ aggregation_level = context.REQUEST.get(\'aggregation_level\')\n
from_date = context.REQUEST.get(\'from_date\')\n from_date = context.REQUEST.get(\'from_date\')\n
to_date = context.REQUEST.get(\'at_date\')\n to_date = context.REQUEST.get(\'at_date\')\n
group_by = context.REQUEST.get(\'group_by\')\n group_by = context.REQUEST.get(\'group_by\')\n
simulation_state = context.REQUEST.get(\'simulation_state\')\n
\n \n
selection_columns = [(\'group_by\', "Group by")]\n selection_columns = [(\'group_by\', "Group by")]\n
if from_date is None:\n if from_date is None:\n
...@@ -132,7 +133,8 @@ else:\n ...@@ -132,7 +133,8 @@ else:\n
raise ValueError, "unknown type for report"\n raise ValueError, "unknown type for report"\n
\n \n
params=dict(period_list=interval_list, report_type=report_type,\n params=dict(period_list=interval_list, report_type=report_type,\n
doc_portal_type=doc_portal_type, line_portal_type=line_portal_type)\n doc_portal_type=doc_portal_type, line_portal_type=line_portal_type,\n
simulation_state=simulation_state)\n
\n \n
# stat columns of the listbox\n # stat columns of the listbox\n
stat_columns = stat_columns + interval_column_list + total_stat_list\n stat_columns = stat_columns + interval_column_list + total_stat_list\n
...@@ -208,6 +210,7 @@ return result\n ...@@ -208,6 +210,7 @@ return result\n
<string>from_date</string> <string>from_date</string>
<string>to_date</string> <string>to_date</string>
<string>group_by</string> <string>group_by</string>
<string>simulation_state</string>
<string>selection_columns</string> <string>selection_columns</string>
<string>None</string> <string>None</string>
<string>Products.ZSQLCatalog.SQLCatalog</string> <string>Products.ZSQLCatalog.SQLCatalog</string>
......
...@@ -127,6 +127,7 @@ elif to_date is not None:\n ...@@ -127,6 +127,7 @@ elif to_date is not None:\n
sort_on_list = [ (\'delivery.destination_section_uid\', \'ASC\'), (\'delivery.start_date\',\'ASC\')]\n sort_on_list = [ (\'delivery.destination_section_uid\', \'ASC\'), (\'delivery.start_date\',\'ASC\')]\n
result_list = context.portal_catalog.searchResults(limit=None,query=query,\n result_list = context.portal_catalog.searchResults(limit=None,query=query,\n
portal_type=doc_portal_type,\n portal_type=doc_portal_type,\n
simulation_state=simulation_state,\n
sort_on=sort_on_list,\n sort_on=sort_on_list,\n
**catalog_params)\n **catalog_params)\n
\n \n
...@@ -325,7 +326,7 @@ return line_list\n ...@@ -325,7 +326,7 @@ return line_list\n
</item> </item>
<item> <item>
<key> <string>_params</string> </key> <key> <string>_params</string> </key>
<value> <string>period_list, report_type, doc_portal_type, line_portal_type, **kw</string> </value> <value> <string>period_list, report_type, doc_portal_type, line_portal_type, simulation_state,**kw</string> </value>
</item> </item>
<item> <item>
<key> <string>errors</string> </key> <key> <string>errors</string> </key>
...@@ -345,7 +346,7 @@ return line_list\n ...@@ -345,7 +346,7 @@ return line_list\n
<dictionary> <dictionary>
<item> <item>
<key> <string>co_argcount</string> </key> <key> <string>co_argcount</string> </key>
<value> <int>4</int> </value> <value> <int>5</int> </value>
</item> </item>
<item> <item>
<key> <string>co_varnames</string> </key> <key> <string>co_varnames</string> </key>
...@@ -355,6 +356,7 @@ return line_list\n ...@@ -355,6 +356,7 @@ return line_list\n
<string>report_type</string> <string>report_type</string>
<string>doc_portal_type</string> <string>doc_portal_type</string>
<string>line_portal_type</string> <string>line_portal_type</string>
<string>simulation_state</string>
<string>kw</string> <string>kw</string>
<string>Products.PythonScripts.standard</string> <string>Products.PythonScripts.standard</string>
<string>Object</string> <string>Object</string>
......
...@@ -112,6 +112,7 @@ ...@@ -112,6 +112,7 @@
<string>your_group</string> <string>your_group</string>
<string>your_delivery_mode</string> <string>your_delivery_mode</string>
<string>your_incoterm</string> <string>your_incoterm</string>
<string>your_simulation_state</string>
</list> </list>
</value> </value>
</item> </item>
......
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<tuple>
<global name="ProxyField" module="Products.ERP5Form.ProxyField"/>
<tuple/>
</tuple>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>delegated_list</string> </key>
<value>
<list>
<string>items</string>
</list>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>your_simulation_state</string> </value>
</item>
<item>
<key> <string>message_values</string> </key>
<value>
<dictionary>
<item>
<key> <string>external_validator_failed</string> </key>
<value> <string>The input failed the external validator.</string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>overrides</string> </key>
<value>
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>tales</string> </key>
<value>
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>items</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent>
</value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>values</string> </key>
<value>
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string>your_simulation_state</string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string>Base_viewReportFieldLibrary</string> </value>
</item>
<item>
<key> <string>items</string> </key>
<value>
<list/>
</value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string>Click to edit the target</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
<record id="2" aka="AAAAAAAAAAI=">
<pickle>
<tuple>
<global name="TALESMethod" module="Products.Formulator.TALESField"/>
<tuple/>
</tuple>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_text</string> </key>
<value> <string>python:here.Base_getTranslatedWorkflowStateItemList(wf_id=\'order_workflow\')</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
...@@ -115,6 +115,7 @@ ...@@ -115,6 +115,7 @@
<string>your_group</string> <string>your_group</string>
<string>your_incoterm</string> <string>your_incoterm</string>
<string>your_order</string> <string>your_order</string>
<string>your_simulation_state</string>
</list> </list>
</value> </value>
</item> </item>
......
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<tuple>
<global name="ProxyField" module="Products.ERP5Form.ProxyField"/>
<tuple/>
</tuple>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>delegated_list</string> </key>
<value>
<list>
<string>title</string>
<string>items</string>
</list>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>your_simulation_state</string> </value>
</item>
<item>
<key> <string>message_values</string> </key>
<value>
<dictionary>
<item>
<key> <string>external_validator_failed</string> </key>
<value> <string>The input failed the external validator.</string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>overrides</string> </key>
<value>
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>tales</string> </key>
<value>
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>items</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent>
</value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>values</string> </key>
<value>
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string>your_simulation_state</string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string>Base_viewDialogFieldLibrary</string> </value>
</item>
<item>
<key> <string>items</string> </key>
<value>
<list/>
</value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string>Click to edit the target</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Simulation State</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
<record id="2" aka="AAAAAAAAAAI=">
<pickle>
<tuple>
<global name="TALESMethod" module="Products.Formulator.TALESField"/>
<tuple/>
</tuple>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_text</string> </key>
<value> <string>python:here.Base_getTranslatedWorkflowStateItemList(wf_id=\'order_workflow\')</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
302 304
\ 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