From 5f2d5f26c8e8bedf8dab4df352ee655668a6180e Mon Sep 17 00:00:00 2001 From: Sebastien Robin <seb@nexedi.com> Date: Fri, 7 Sep 2007 14:29:40 +0000 Subject: [PATCH] Provide everything necessary in order to set an alarm wich check the stock. Also, improved alarm forms in order to see easily history of results git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@16160 20353a03-c40f-0410-a6d1-a30d3c3de9de --- .../Alarm_activateCheckStockTable.xml | 144 +++++ .../erp5_core/Alarm_checkStockTable.xml | 150 ++++++ .../Alarm_getActiveProcessResultList.xml | 145 +++++ .../erp5_core/Alarm_getDescriptionUrl.xml | 14 +- .../Alarm_getLatestResultResultList.xml | 142 +++++ .../Alarm_getOrderedActiveProcessList.xml | 170 ++++++ .../erp5_core/Alarm_showReport.xml | 145 +++++ .../erp5_core/Alarm_showReport/listbox.xml | 506 ++++++++++++++++++ .../portal_skins/erp5_core/Alarm_view.xml | 7 +- .../erp5_core/Alarm_view/listbox.xml | 28 +- .../erp5_core/Base_zGetAllFromStock.xml | 43 +- .../ERP5Site_getStockTableFilterDict.xml | 198 +++++++ 12 files changed, 1657 insertions(+), 35 deletions(-) create mode 100644 product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Alarm_activateCheckStockTable.xml create mode 100644 product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Alarm_checkStockTable.xml create mode 100644 product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Alarm_getActiveProcessResultList.xml create mode 100644 product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Alarm_getLatestResultResultList.xml create mode 100644 product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Alarm_getOrderedActiveProcessList.xml create mode 100644 product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Alarm_showReport.xml create mode 100644 product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Alarm_showReport/listbox.xml create mode 100644 product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/ERP5Site_getStockTableFilterDict.xml diff --git a/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Alarm_activateCheckStockTable.xml b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Alarm_activateCheckStockTable.xml new file mode 100644 index 0000000000..5a2944958e --- /dev/null +++ b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Alarm_activateCheckStockTable.xml @@ -0,0 +1,144 @@ +<?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>Python_magic</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>Script_magic</string> </key> + <value> <int>3</int> </value> + </item> + <item> + <key> <string>__ac_local_roles__</string> </key> + <value> + <none/> + </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>active_process = context.newActiveProcess()\n +result = context.Alarm_checkStockTable(active_process=\'/\'.join(active_process.getPhysicalPath()))\n +active_process.postResult(result)\n +</string> </value> + </item> + <item> + <key> <string>_code</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>_filepath</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>_params</string> </key> + <value> <string></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>0</int> </value> + </item> + <item> + <key> <string>co_varnames</string> </key> + <value> + <tuple> + <string>_getattr_</string> +<string>context</string> + <string>active_process</string> + <string>result</string> + </tuple> + </value> + </item> + </dictionary> + </state> + </object> + </value> + </item> + <item> + <key> <string>func_defaults</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>id</string> </key> + <value> <string>Alarm_activateCheckStockTable</string> </value> + </item> + <item> + <key> <string>warnings</string> </key> + <value> + <tuple/> + </value> + </item> + </dictionary> + </pickle> + </record> +</ZopeData> diff --git a/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Alarm_checkStockTable.xml b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Alarm_checkStockTable.xml new file mode 100644 index 0000000000..949e67b69c --- /dev/null +++ b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Alarm_checkStockTable.xml @@ -0,0 +1,150 @@ +<?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>Python_magic</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>Script_magic</string> </key> + <value> <int>3</int> </value> + </item> + <item> + <key> <string>__ac_local_roles__</string> </key> + <value> + <none/> + </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>return context.ERP5Site_checkStockTable(bundle_object_count=bundle_object_count,\n + bundle_offset=bundle_offset,\n + property_override_method_id=\'ERP5Site_getStockTableFilterDict\',\n + active_process=active_process)\n +</string> </value> + </item> + <item> + <key> <string>_code</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>_filepath</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>_params</string> </key> + <value> <string>bundle_object_count=100, bundle_offset=0, active_process=None</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>3</int> </value> + </item> + <item> + <key> <string>co_varnames</string> </key> + <value> + <tuple> + <string>bundle_object_count</string> + <string>bundle_offset</string> + <string>active_process</string> + <string>_getattr_</string> +<string>context</string> + </tuple> + </value> + </item> + </dictionary> + </state> + </object> + </value> + </item> + <item> + <key> <string>func_defaults</string> </key> + <value> + <tuple> + <int>100</int> + <int>0</int> + <none/> + </tuple> + </value> + </item> + <item> + <key> <string>id</string> </key> + <value> <string>Alarm_checkStockTable</string> </value> + </item> + <item> + <key> <string>warnings</string> </key> + <value> + <tuple/> + </value> + </item> + </dictionary> + </pickle> + </record> +</ZopeData> diff --git a/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Alarm_getActiveProcessResultList.xml b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Alarm_getActiveProcessResultList.xml new file mode 100644 index 0000000000..e63835b9a8 --- /dev/null +++ b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Alarm_getActiveProcessResultList.xml @@ -0,0 +1,145 @@ +<?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>Python_magic</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>Script_magic</string> </key> + <value> <int>3</int> </value> + </item> + <item> + <key> <string>__ac_local_roles__</string> </key> + <value> + <none/> + </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>active_process = context.getPortalObject().restrictedTraverse(active_process)\n +return active_process.getResultList()\n +</string> </value> + </item> + <item> + <key> <string>_code</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>_filepath</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>_params</string> </key> + <value> <string>active_process=None, **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>active_process</string> + <string>kw</string> + <string>_getattr_</string> +<string>context</string> + </tuple> + </value> + </item> + </dictionary> + </state> + </object> + </value> + </item> + <item> + <key> <string>func_defaults</string> </key> + <value> + <tuple> + <none/> + </tuple> + </value> + </item> + <item> + <key> <string>id</string> </key> + <value> <string>Alarm_getActiveProcessResultList</string> </value> + </item> + <item> + <key> <string>warnings</string> </key> + <value> + <tuple/> + </value> + </item> + </dictionary> + </pickle> + </record> +</ZopeData> diff --git a/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Alarm_getDescriptionUrl.xml b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Alarm_getDescriptionUrl.xml index 80b14f84ad..b82586d6bf 100644 --- a/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Alarm_getDescriptionUrl.xml +++ b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Alarm_getDescriptionUrl.xml @@ -3,11 +3,8 @@ <record id="1" aka="AAAAAAAAAAE="> <pickle> <tuple> - <tuple> - <string>Products.PythonScripts.PythonScript</string> - <string>PythonScript</string> - </tuple> - <none/> + <global name="PythonScript" module="Products.PythonScripts.PythonScript"/> + <tuple/> </tuple> </pickle> <pickle> @@ -74,9 +71,9 @@ object = brain.getObject()\n if object is None:\n return None\n \n -url = object.absolute_url()\n -method = \'ActiveProcess_showReport\'\n -kw = { \n +url = context.absolute_url()\n +method = \'Alarm_showReport\'\n +kw = { \'active_process\' : \'portal_activities/%s\' % object.process_id,\n \'reset\' : \'1\', \n }\n \n @@ -131,6 +128,7 @@ return url + \'/\' + method + \'?\' + make_query(kw)\n <string>_getattr_</string> <string>object</string> <string>None</string> + <string>context</string> <string>url</string> <string>method</string> <string>kw</string> diff --git a/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Alarm_getLatestResultResultList.xml b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Alarm_getLatestResultResultList.xml new file mode 100644 index 0000000000..ace704af86 --- /dev/null +++ b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Alarm_getLatestResultResultList.xml @@ -0,0 +1,142 @@ +<?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>Python_magic</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>Script_magic</string> </key> + <value> <int>3</int> </value> + </item> + <item> + <key> <string>__ac_local_roles__</string> </key> + <value> + <none/> + </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>return context.getLastActiveProcess().getResultList()\n +</string> </value> + </item> + <item> + <key> <string>_code</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>_filepath</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>_params</string> </key> + <value> <string>*args, **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>0</int> </value> + </item> + <item> + <key> <string>co_varnames</string> </key> + <value> + <tuple> + <string>args</string> + <string>kw</string> + <string>_getattr_</string> +<string>context</string> + </tuple> + </value> + </item> + </dictionary> + </state> + </object> + </value> + </item> + <item> + <key> <string>func_defaults</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>id</string> </key> + <value> <string>Alarm_getLatestResultResultList</string> </value> + </item> + <item> + <key> <string>warnings</string> </key> + <value> + <tuple/> + </value> + </item> + </dictionary> + </pickle> + </record> +</ZopeData> diff --git a/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Alarm_getOrderedActiveProcessList.xml b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Alarm_getOrderedActiveProcessList.xml new file mode 100644 index 0000000000..7aa2b08835 --- /dev/null +++ b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Alarm_getOrderedActiveProcessList.xml @@ -0,0 +1,170 @@ +<?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>Python_magic</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>Script_magic</string> </key> + <value> <int>3</int> </value> + </item> + <item> + <key> <string>__ac_local_roles__</string> </key> + <value> + <none/> + </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 encoding="cdata"><![CDATA[ + +def sort_date(a,b):\n + return - cmp(a.getStartDate(), b.getStartDate())\n +\n +process_list = context.getCausalityRelatedValueList()\n +process_list.sort(sort_date)\n +return_list = []\n +for process in process_list:\n + process_id = process.getId()\n + start_date = process.getStartDate()\n + sense_value = 0\n + for result in process.getResultList():\n + if result.severity > result.INFO:\n + sense_value = 1\n + return_list.append(context.asContext(process_id=process.getId(), \n + start_date=process.getStartDate(),\n + sense_value=sense_value))\n +return return_list\n + + +]]></string> </value> + </item> + <item> + <key> <string>_code</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>_filepath</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>_params</string> </key> + <value> <string>**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>0</int> </value> + </item> + <item> + <key> <string>co_varnames</string> </key> + <value> + <tuple> + <string>kw</string> + <string>sort_date</string> + <string>_getattr_</string> + <string>context</string> + <string>process_list</string> + <string>return_list</string> + <string>_getiter_</string> + <string>process</string> + <string>process_id</string> + <string>start_date</string> + <string>sense_value</string> + <string>result</string> + </tuple> + </value> + </item> + </dictionary> + </state> + </object> + </value> + </item> + <item> + <key> <string>func_defaults</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>id</string> </key> + <value> <string>Alarm_getOrderedActiveProcessList</string> </value> + </item> + <item> + <key> <string>warnings</string> </key> + <value> + <tuple/> + </value> + </item> + </dictionary> + </pickle> + </record> +</ZopeData> diff --git a/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Alarm_showReport.xml b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Alarm_showReport.xml new file mode 100644 index 0000000000..20d2a20e0a --- /dev/null +++ b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Alarm_showReport.xml @@ -0,0 +1,145 @@ +<?xml version="1.0"?> +<ZopeData> + <record id="1" aka="AAAAAAAAAAE="> + <pickle> + <tuple> + <global name="ERP5Form" module="Products.ERP5Form.Form"/> + <tuple/> + </tuple> + </pickle> + <pickle> + <dictionary> + <item> + <key> <string>__ac_local_roles__</string> </key> + <value> + <none/> + </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/> + </value> + </item> + </dictionary> + </state> + </object> + </value> + </item> + <item> + <key> <string>_objects</string> </key> + <value> + <tuple/> + </value> + </item> + <item> + <key> <string>_owner</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>action</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>encoding</string> </key> + <value> <string>UTF-8</string> </value> + </item> + <item> + <key> <string>enctype</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>group_list</string> </key> + <value> + <list> + <string>left</string> + <string>right</string> + <string>center</string> + <string>bottom</string> + <string>hidden</string> + </list> + </value> + </item> + <item> + <key> <string>groups</string> </key> + <value> + <dictionary> + <item> + <key> <string>bottom</string> </key> + <value> + <list> + <string>listbox</string> + </list> + </value> + </item> + <item> + <key> <string>center</string> </key> + <value> + <list/> + </value> + </item> + <item> + <key> <string>hidden</string> </key> + <value> + <list/> + </value> + </item> + <item> + <key> <string>left</string> </key> + <value> + <list/> + </value> + </item> + <item> + <key> <string>right</string> </key> + <value> + <list/> + </value> + </item> + </dictionary> + </value> + </item> + <item> + <key> <string>id</string> </key> + <value> <string>Alarm_showReport</string> </value> + </item> + <item> + <key> <string>method</string> </key> + <value> <string>POST</string> </value> + </item> + <item> + <key> <string>name</string> </key> + <value> <string>ActiveProcess_showReport</string> </value> + </item> + <item> + <key> <string>row_length</string> </key> + <value> <int>4</int> </value> + </item> + <item> + <key> <string>stored_encoding</string> </key> + <value> <string>UTF-8</string> </value> + </item> + <item> + <key> <string>title</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>unicode_mode</string> </key> + <value> <int>0</int> </value> + </item> + </dictionary> + </pickle> + </record> +</ZopeData> diff --git a/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Alarm_showReport/listbox.xml b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Alarm_showReport/listbox.xml new file mode 100644 index 0000000000..6a8353a78b --- /dev/null +++ b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Alarm_showReport/listbox.xml @@ -0,0 +1,506 @@ +<?xml version="1.0"?> +<ZopeData> + <record id="1" aka="AAAAAAAAAAE="> + <pickle> + <tuple> + <global name="ListBox" module="Products.ERP5Form.ListBox"/> + <tuple/> + </tuple> + </pickle> + <pickle> + <dictionary> + <item> + <key> <string>id</string> </key> + <value> <string>listbox</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>all_columns</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>alternate_name</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>columns</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>count_method</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>css_class</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>default_params</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>description</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>domain_root_list</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>domain_tree</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>editable</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>editable_columns</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>enabled</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>external_validator</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>global_attributes</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>hidden</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>lines</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>list_action</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>list_method</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>meta_types</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>page_template</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>portal_types</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>report_root_list</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>report_tree</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>search</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>search_columns</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>select</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>selection_name</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>sort</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>sort_columns</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>stat_columns</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>stat_method</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>title</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>url_columns</string> </key> + <value> <string></string> </value> + </item> + </dictionary> + </value> + </item> + <item> + <key> <string>tales</string> </key> + <value> + <dictionary> + <item> + <key> <string>all_columns</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>alternate_name</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>columns</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>count_method</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>css_class</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>default_params</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>description</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>domain_root_list</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>domain_tree</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>editable</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>editable_columns</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>enabled</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>external_validator</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>global_attributes</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>hidden</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>lines</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>list_action</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>list_method</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>meta_types</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>page_template</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>portal_types</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>report_root_list</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>report_tree</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>search</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>search_columns</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>select</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>selection_name</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>sort</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>sort_columns</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>stat_columns</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>stat_method</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>title</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>url_columns</string> </key> + <value> <string></string> </value> + </item> + </dictionary> + </value> + </item> + <item> + <key> <string>values</string> </key> + <value> + <dictionary> + <item> + <key> <string>all_columns</string> </key> + <value> + <list/> + </value> + </item> + <item> + <key> <string>alternate_name</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>columns</string> </key> + <value> + <list> + <tuple> + <string>summary</string> + <string>Summary</string> + </tuple> + <tuple> + <string>severity</string> + <string>Severity</string> + </tuple> + <tuple> + <string>detail</string> + <string>Details</string> + </tuple> + </list> + </value> + </item> + <item> + <key> <string>count_method</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>css_class</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>default_params</string> </key> + <value> + <list/> + </value> + </item> + <item> + <key> <string>description</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>domain_root_list</string> </key> + <value> + <list/> + </value> + </item> + <item> + <key> <string>domain_tree</string> </key> + <value> <int>0</int> </value> + </item> + <item> + <key> <string>editable</string> </key> + <value> <int>1</int> </value> + </item> + <item> + <key> <string>editable_columns</string> </key> + <value> + <list/> + </value> + </item> + <item> + <key> <string>enabled</string> </key> + <value> <int>1</int> </value> + </item> + <item> + <key> <string>external_validator</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>global_attributes</string> </key> + <value> + <list/> + </value> + </item> + <item> + <key> <string>hidden</string> </key> + <value> <int>0</int> </value> + </item> + <item> + <key> <string>lines</string> </key> + <value> <int>20</int> </value> + </item> + <item> + <key> <string>list_action</string> </key> + <value> <string>list</string> </value> + </item> + <item> + <key> <string>list_method</string> </key> + <value> + <persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent> + </value> + </item> + <item> + <key> <string>meta_types</string> </key> + <value> + <list/> + </value> + </item> + <item> + <key> <string>page_template</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>portal_types</string> </key> + <value> + <list/> + </value> + </item> + <item> + <key> <string>report_root_list</string> </key> + <value> + <list/> + </value> + </item> + <item> + <key> <string>report_tree</string> </key> + <value> <int>0</int> </value> + </item> + <item> + <key> <string>search</string> </key> + <value> <int>0</int> </value> + </item> + <item> + <key> <string>search_columns</string> </key> + <value> + <list/> + </value> + </item> + <item> + <key> <string>select</string> </key> + <value> <int>0</int> </value> + </item> + <item> + <key> <string>selection_name</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>sort</string> </key> + <value> + <list/> + </value> + </item> + <item> + <key> <string>sort_columns</string> </key> + <value> + <list/> + </value> + </item> + <item> + <key> <string>stat_columns</string> </key> + <value> + <list/> + </value> + </item> + <item> + <key> <string>stat_method</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>title</string> </key> + <value> <string>listbox</string> </value> + </item> + <item> + <key> <string>url_columns</string> </key> + <value> + <list/> + </value> + </item> + </dictionary> + </value> + </item> + </dictionary> + </pickle> + </record> + <record id="2" aka="AAAAAAAAAAI="> + <pickle> + <tuple> + <global name="Method" module="Products.Formulator.MethodField"/> + <tuple/> + </tuple> + </pickle> + <pickle> + <dictionary> + <item> + <key> <string>method_name</string> </key> + <value> <string>Alarm_getActiveProcessResultList</string> </value> + </item> + </dictionary> + </pickle> + </record> +</ZopeData> diff --git a/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Alarm_view.xml b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Alarm_view.xml index 43a2d2ea37..ae3ae0432e 100644 --- a/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Alarm_view.xml +++ b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Alarm_view.xml @@ -3,11 +3,8 @@ <record id="1" aka="AAAAAAAAAAE="> <pickle> <tuple> - <tuple> - <string>Products.ERP5Form.Form</string> - <string>ERP5Form</string> - </tuple> - <none/> + <global name="ERP5Form" module="Products.ERP5Form.Form"/> + <tuple/> </tuple> </pickle> <pickle> diff --git a/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Alarm_view/listbox.xml b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Alarm_view/listbox.xml index 8422892957..5e574708d1 100644 --- a/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Alarm_view/listbox.xml +++ b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Alarm_view/listbox.xml @@ -3,11 +3,8 @@ <record id="1" aka="AAAAAAAAAAE="> <pickle> <tuple> - <tuple> - <string>Products.ERP5Form.ListBox</string> - <string>ListBox</string> - </tuple> - <none/> + <global name="ListBox" module="Products.ERP5Form.ListBox"/> + <tuple/> </tuple> </pickle> <pickle> @@ -335,7 +332,7 @@ <value> <list> <tuple> - <string>id</string> + <string>process_id</string> <string>ID</string> </tuple> <tuple> @@ -343,7 +340,7 @@ <string>Date</string> </tuple> <tuple> - <string>getSenseValue</string> + <string>sense_value</string> <string>Problem Detected</string> </tuple> </list> @@ -434,6 +431,10 @@ <list/> </value> </item> + <item> + <key> <string>page_template</string> </key> + <value> <string></string> </value> + </item> <item> <key> <string>portal_types</string> </key> <value> @@ -499,7 +500,7 @@ <value> <list> <tuple> - <string>id</string> + <string>process_id</string> <string>Alarm_getDescriptionUrl</string> </tuple> <tuple> @@ -507,7 +508,7 @@ <string>Alarm_getDescriptionUrl</string> </tuple> <tuple> - <string>getSenseValue</string> + <string>sense_value</string> <string>Alarm_getDescriptionUrl</string> </tuple> </list> @@ -522,18 +523,15 @@ <record id="2" aka="AAAAAAAAAAI="> <pickle> <tuple> - <tuple> - <string>Products.Formulator.MethodField</string> - <string>Method</string> - </tuple> - <none/> + <global name="Method" module="Products.Formulator.MethodField"/> + <tuple/> </tuple> </pickle> <pickle> <dictionary> <item> <key> <string>method_name</string> </key> - <value> <string>getCausalityRelatedValueList</string> </value> + <value> <string>Alarm_getOrderedActiveProcessList</string> </value> </item> </dictionary> </pickle> diff --git a/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_zGetAllFromStock.xml b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_zGetAllFromStock.xml index 98d99ee3c0..43bb9da7bf 100644 --- a/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_zGetAllFromStock.xml +++ b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_zGetAllFromStock.xml @@ -3,11 +3,8 @@ <record id="1" aka="AAAAAAAAAAE="> <pickle> <tuple> - <tuple> - <string>Products.ZSQLMethods.SQL</string> - <string>SQL</string> - </tuple> - <none/> + <global name="SQL" module="Products.ZSQLMethods.SQL"/> + <tuple/> </tuple> </pickle> <pickle> @@ -54,10 +51,32 @@ </object> </value> </item> + <item> + <key> <string>allow_simple_one_argument_traversal</string> </key> + <value> + <none/> + </value> + </item> <item> <key> <string>arguments_src</string> </key> <value> <string>limit</string> </value> </item> + <item> + <key> <string>cache_time_</string> </key> + <value> <int>0</int> </value> + </item> + <item> + <key> <string>class_file_</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>class_name_</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>connection_hook</string> </key> + <value> <string></string> </value> + </item> <item> <key> <string>connection_id</string> </key> <value> <string>erp5_sql_connection</string> </value> @@ -66,6 +85,14 @@ <key> <string>id</string> </key> <value> <string>Base_zGetAllFromStock</string> </value> </item> + <item> + <key> <string>max_cache_</string> </key> + <value> <int>0</int> </value> + </item> + <item> + <key> <string>max_rows_</string> </key> + <value> <int>0</int> </value> + </item> <item> <key> <string>src</string> </key> <value> <string encoding="cdata"><![CDATA[ @@ -80,9 +107,11 @@ LIMIT <dtml-var expr="limit[0]">, <dtml-var expr="limit[1]"> <value> <object> <klass> - <global name="SQL" module="Shared.DC.ZRDB.DA"/> + <global name="__newobj__" module="copy_reg"/> </klass> - <none/> + <tuple> + <global name="SQL" module="Shared.DC.ZRDB.DA"/> + </tuple> <state> <dictionary> <item> diff --git a/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/ERP5Site_getStockTableFilterDict.xml b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/ERP5Site_getStockTableFilterDict.xml new file mode 100644 index 0000000000..4bbc85aeb8 --- /dev/null +++ b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/ERP5Site_getStockTableFilterDict.xml @@ -0,0 +1,198 @@ +<?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>Python_magic</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>Script_magic</string> </key> + <value> <int>3</int> </value> + </item> + <item> + <key> <string>__ac_local_roles__</string> </key> + <value> + <none/> + </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 DateTime import DateTime\n +\n +def getSourceAndDestinationList(instance):\n + return (instance.getSourceUid(), instance.getDestinationUid())\n +\n +def getSourcePaymentAndDestinationPaymentList(instance):\n + return (instance.getSourcePaymentUid(), instance.getDestinationPaymentUid())\n +\n +def getSimulationState(instance):\n + return instance.getSimulationState()\n +\n +def stripDate(date):\n + """\n + Strip everything from the given DateTime parameter,\n + leaving just year, month and day.\n + """\n + if not same_type(date, DateTime()):\n + return date\n + return DateTime(date.Date())\n +\n +def getStartDateAndStopDate(instance):\n + start_date = stripDate(instance.getStartDate())\n + stop_date = stripDate(instance.getStopDate())\n + return (start_date, stop_date)\n +\n +def getSourceSectionAndDestinationSectionList(instance):\n + return (instance.getSourceSectionUid(), instance.getDestinationSectionUid())\n +\n +def getTotalPrice(instance):\n + price = instance.getTotalPrice()\n + if price is None:\n + return None\n + return (instance.getDestinationInventoriatedTotalAssetPrice(), instance.getSourceInventoriatedTotalAssetPrice())\n +\n +def getQuantity(instance):\n + quantity = instance.getInventoriatedQuantity()\n + if quantity is None:\n + return None\n + return (quantity, -quantity)\n +\n +return {\n + \'node_uid\': getSourceAndDestinationList,\n + \'payment_uid\': getSourcePaymentAndDestinationPaymentList,\n + \'section_uid\': getSourceSectionAndDestinationSectionList,\n + \'mirror_section_uid\': getSourceSectionAndDestinationSectionList,\n + \'date\': getStartDateAndStopDate,\n + \'mirror_date\': getStartDateAndStopDate,\n + \'total_price\': getTotalPrice,\n + \'quantity\': getQuantity,\n + \'mirror_node_uid\': getSourceAndDestinationList,\n + \'simulation_state\': getSimulationState,\n +}\n +</string> </value> + </item> + <item> + <key> <string>_code</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>_filepath</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>_params</string> </key> + <value> <string></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>0</int> </value> + </item> + <item> + <key> <string>co_varnames</string> </key> + <value> + <tuple> + <string>DateTime</string> + <string>getSourceAndDestinationList</string> + <string>getSourcePaymentAndDestinationPaymentList</string> + <string>getSimulationState</string> + <string>stripDate</string> + <string>getStartDateAndStopDate</string> + <string>getSourceSectionAndDestinationSectionList</string> + <string>getTotalPrice</string> + <string>getQuantity</string> + </tuple> + </value> + </item> + </dictionary> + </state> + </object> + </value> + </item> + <item> + <key> <string>func_defaults</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>id</string> </key> + <value> <string>ERP5Site_getStockTableFilterDict</string> </value> + </item> + <item> + <key> <string>warnings</string> </key> + <value> + <tuple/> + </value> + </item> + </dictionary> + </pickle> + </record> +</ZopeData> -- 2.30.9