Commit 6fa1a936 authored by wenjie.zheng's avatar wenjie.zheng

Merge branch 'generic_master' into erp5_workflow_converted

parents 01687bc0 50f1c236
......@@ -169,8 +169,8 @@ return [ ReportSection(\n
period_start_date=\n
period_start_date.earliestTime(),\n
section_uid=section_uid,\n
function_category=function,\n
funding_cateory=funding,\n
function=function,\n
funding=funding,\n
project=project,\n
portal_type=portal_type,\n
simulation_state=simulation_state,\n
......
......@@ -165,7 +165,7 @@
type: "uuid",\n
sub_storage: {\n
type: "indexeddb",\n
database: "officejs-local"\n
database: "officejs"\n
}\n
}\n
};\n
......@@ -382,7 +382,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>946.20489.39650.26470</string> </value>
<value> <string>947.12629.17894.55808</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -400,7 +400,7 @@
</tuple>
<state>
<tuple>
<float>1444412978.56</float>
<float>1447936126.33</float>
<string>UTC</string>
</tuple>
</state>
......
......@@ -379,6 +379,16 @@
<td>${description}</td>\n
<td></td>\n
</tr>\n
<tr>\n
<td>open</td>\n
<td>${base_url}/web_page_module/Zuite_waitForActivities</td>\n
<td></td>\n
</tr>\n
<tr>\n
<td>assertTextPresent</td>\n
<td>Done.</td>\n
<td></td>\n
</tr>\n
<tr>\n
<td>open</td>\n
<td>${base_url}/web_page_module/</td>\n
......
......@@ -70,15 +70,18 @@ if not from_url:\n
if context.getSourceValue():\n
sender_phone = context.getSourceValue().getDefaultMobileTelephoneValue()\n
if not sender_phone:\n
raise ValueError("The sender should have a default mobile phone")\n
raise ValueError("The sender(%s) should have a default mobile phone" % context.getSourceValue())\n
#We use title of sender\n
from_title = sender_phone.getTitle() \n
from_title = sender_phone.getTitle()\n
from_url = sender_phone.asURL()\n
\n
if not body:\n
body = context.getTextContent()\n
\n
context.portal_sms.send(text=body,recipient=to_url,sender=from_url,sender_title=from_title,message_type="text", \n
if not context.getStartDate():\n
context.setStartDate(DateTime())\n
\n
context.portal_sms.send(text=body,recipient=to_url,sender=from_url,sender_title=from_title,message_type="text",\n
test=download, document_relative_url=context.getRelativeUrl(), **kw)\n
</string> </value>
</item>
......
##############################################################################
#
# Copyright (c) 2013 Nexedi SA and Contributors. All Rights Reserved.
#
# WARNING: This program as such is intended to be used by professional
# programmers who take the whole responsibility of assessing all potential
# consequences resulting from its eventual inadequacies and bugs
# End users who are looking for a ready-to-use solution with commercial
# guarantees and support are strongly adviced to contract a Free Software
# Service Company
#
# This program is Free Software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
#
##############################################################################
def SolverDecision_renderSolverConfiguration(self, delivery):
self.REQUEST["here"] = delivery
self.REQUEST["cell"] = self
field = self.Delivery_viewSolveDivergenceDialog.listbox_solver_configuration
return field.widget.render(field, "field_listbox_solver_configuration_%s" % self.getUid(),
None, self.REQUEST)
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="Extension Component" module="erp5.portal_type"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_recorded_property_dict</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent>
</value>
</item>
<item>
<key> <string>default_reference</string> </key>
<value> <string>SimulationFastInputUtils</string> </value>
</item>
<item>
<key> <string>description</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>extension.erp5.SimulationFastInputUtils</string> </value>
</item>
<item>
<key> <string>portal_type</string> </key>
<value> <string>Extension Component</string> </value>
</item>
<item>
<key> <string>sid</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>text_content_error_message</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>text_content_warning_message</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>version</string> </key>
<value> <string>erp5</string> </value>
</item>
<item>
<key> <string>workflow_history</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAM=</string> </persistent>
</value>
</item>
</dictionary>
</pickle>
</record>
<record id="2" aka="AAAAAAAAAAI=">
<pickle>
<global name="PersistentMapping" module="Persistence.mapping"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>data</string> </key>
<value>
<dictionary/>
</value>
</item>
</dictionary>
</pickle>
</record>
<record id="3" aka="AAAAAAAAAAM=">
<pickle>
<global name="PersistentMapping" module="Persistence.mapping"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>data</string> </key>
<value>
<dictionary>
<item>
<key> <string>component_validation_workflow</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAQ=</string> </persistent>
</value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
<record id="4" aka="AAAAAAAAAAQ=">
<pickle>
<global name="WorkflowHistoryList" module="Products.ERP5Type.patches.WorkflowTool"/>
</pickle>
<pickle>
<tuple>
<none/>
<list>
<dictionary>
<item>
<key> <string>action</string> </key>
<value> <string>validate</string> </value>
</item>
<item>
<key> <string>validation_state</string> </key>
<value> <string>validated</string> </value>
</item>
</dictionary>
</list>
</tuple>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="Folder" module="OFS.Folder"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_local_properties</string> </key>
<value>
<tuple>
<dictionary>
<item>
<key> <string>id</string> </key>
<value> <string>business_template_skin_layer_priority</string> </value>
</item>
<item>
<key> <string>type</string> </key>
<value> <string>float</string> </value>
</item>
</dictionary>
</tuple>
</value>
</item>
<item>
<key> <string>_objects</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>business_template_skin_layer_priority</string> </key>
<value> <float>30.0</float> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>erp5_simulation_fast_input</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="PythonScript" module="Products.PythonScripts.PythonScript"/>
</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>portal = context.getPortalObject()\n
solver_process = context.getSolverValueList()[-1]\n
solver_decision_uid = int(solver_decision_uid)\n
solver_decision = None\n
for solver_decision in solver_process.objectValues(portal_type="Solver Decision"):\n
if solver_decision.getUid() == solver_decision_uid:\n
break\n
assert solver_decision is not None, \\\n
"unable to find solver decision with uid : %r on %r" % (\n
solver_decision_uid, solver)\n
solver_value = None\n
if solver:\n
solver_value = portal.restrictedTraverse(solver)\n
solver_decision.setSolverValue(solver_value)\n
else:\n
solver_decision.setSolverList([])\n
\n
#return solver_decision.Delivery_viewSolveDivergenceDialog.listbox_solver_configuration.widget.render(\n
return solver_decision.SolverDecision_renderSolverConfiguration(context)\n
</string> </value>
</item>
<item>
<key> <string>_params</string> </key>
<value> <string>solver=None, solver_decision_uid=None</string> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>Delivery_getSolveDivergenceDialogParameterFormBox</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ERP5 Form" module="erp5.portal_type"/>
</pickle>
<pickle>
<dictionary>
<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>action</string> </key>
<value> <string>Delivery_submitSolveDivergenceDialog</string> </value>
</item>
<item>
<key> <string>description</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>edit_order</string> </key>
<value>
<list/>
</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>
<string>gadget_solve_divergence_dialog</string>
</list>
</value>
</item>
<item>
<key> <string>center</string> </key>
<value>
<list/>
</value>
</item>
<item>
<key> <string>hidden</string> </key>
<value>
<list>
<string>listbox_solver</string>
<string>listbox_comment</string>
<string>listbox_divergence</string>
<string>listbox_solver_configuration</string>
</list>
</value>
</item>
<item>
<key> <string>left</string> </key>
<value>
<list>
<string>your_workflow_action</string>
</list>
</value>
</item>
<item>
<key> <string>right</string> </key>
<value>
<list/>
</value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>Delivery_viewSolveDivergenceDialog</string> </value>
</item>
<item>
<key> <string>method</string> </key>
<value> <string>POST</string> </value>
</item>
<item>
<key> <string>name</string> </key>
<value> <string>Delivery_viewSolveActionsDialog</string> </value>
</item>
<item>
<key> <string>pt</string> </key>
<value> <string>form_dialog</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>Solve Divergences</string> </value>
</item>
<item>
<key> <string>unicode_mode</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>update_action</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>update_action_title</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ProxyField" module="Products.ERP5Form.ProxyField"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>delegated_list</string> </key>
<value>
<list/>
</value>
</item>
<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>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>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>listbox</string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string>erp5_simulation/Delivery_viewSolveDivergenceDialog</string> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string>Click to edit the target</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ProxyField" module="Products.ERP5Form.ProxyField"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>delegated_list</string> </key>
<value>
<list/>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>listbox_comment</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>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>listbox_comment</string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string>erp5_simulation/Delivery_viewSolveDivergenceDialog</string> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string>Click to edit the target</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ProxyField" module="Products.ERP5Form.ProxyField"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>delegated_list</string> </key>
<value>
<list/>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>listbox_divergence</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>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>listbox_divergence</string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string>erp5_simulation/Delivery_viewSolveDivergenceDialog</string> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string>Click to edit the target</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ProxyField" module="Products.ERP5Form.ProxyField"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>delegated_list</string> </key>
<value>
<list/>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>listbox_solver</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>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>listbox_solver</string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string>erp5_simulation/Delivery_viewSolveDivergenceDialog</string> </value>
</item>
<item>
<key> <string>size</string> </key>
<value> <int>3</int> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string>Click to edit the target</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ProxyField" module="Products.ERP5Form.ProxyField"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>id</string> </key>
<value> <string>listbox_solver_configuration</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>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>listbox_solver_configuration</string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string>erp5_simulation/Delivery_viewSolveDivergenceDialog</string> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string>Click to edit the target</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ProxyField" module="Products.ERP5Form.ProxyField"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>delegated_list</string> </key>
<value>
<list/>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>your_workflow_action</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>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_workflow_action</string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string>erp5_simulation/Delivery_viewSolveDivergenceDialog</string> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string>Click to edit the target</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ExternalMethod" module="Products.ExternalMethod.ExternalMethod"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_function</string> </key>
<value> <string>SolverDecision_renderSolverConfiguration</string> </value>
</item>
<item>
<key> <string>_module</string> </key>
<value> <string>SimulationFastInputUtils</string> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>SolverDecision_renderSolverConfiguration</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="File" module="OFS.Image"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_Cacheable__manager_id</string> </key>
<value> <string>http_cache</string> </value>
</item>
<item>
<key> <string>_EtagSupport__etag</string> </key>
<value> <string>ts47152215.08</string> </value>
</item>
<item>
<key> <string>__name__</string> </key>
<value> <string>gadget_solve_divergence_dialog.html</string> </value>
</item>
<item>
<key> <string>content_type</string> </key>
<value> <string>text/html</string> </value>
</item>
<item>
<key> <string>data</string> </key>
<value> <string encoding="cdata"><![CDATA[
<!DOCTYPE html>\n
<html>\n
<head>\n
<meta http-equiv="Content-type" content="text/html; charset=utf-8" />\n
<meta name="viewport" content="width=device-width, user-scalable=no" />\n
<script src="handlebars.js" type="text/javascript"></script>\n
\n
\n
<script src="rsvp.js" type="text/javascript"></script>\n
<script src="renderjs.js" type="text/javascript"></script>\n
<script src="jio_sha256.amd.js" type="text/javascript"></script>\n
<script src="jio.js" type="text/javascript"></script>\n
<script src="gadget_solve_divergence_dialog.js" type="text/javascript"></script>\n
\n
</head>\n
\n
<body>\n
<div class="gadget_solve_divergence_dialog"></div>\n
</body>\n
</html>
]]></string> </value>
</item>
<item>
<key> <string>precondition</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>size</string> </key>
<value> <int>648</int> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="File" module="OFS.Image"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_Cacheable__manager_id</string> </key>
<value> <string>http_cache</string> </value>
</item>
<item>
<key> <string>_EtagSupport__etag</string> </key>
<value> <string>ts47172081.7</string> </value>
</item>
<item>
<key> <string>__name__</string> </key>
<value> <string>gadget_solve_divergence_dialog.js</string> </value>
</item>
<item>
<key> <string>content_type</string> </key>
<value> <string>application/javascript</string> </value>
</item>
<item>
<key> <string>data</string> </key>
<value> <string encoding="cdata"><![CDATA[
/*global window, document, rJS, RSVP, Handlebars, jIO, location, console */\n
/*jslint nomen: true, maxlen:80, indent:2*/\n
// We should not use "document" since a gadget should be embedded and\n
// must not deals with other parts. Though here we use this gadget to\n
// modify an existing dialog, we do not have nice structure of a full\n
// renderjs web page\n
\n
\n
// horrible copy/paste, this code is now present in latest renderjs,\n
// until we can use it, just duplicate the code and remove it when\n
// renderjs is up to date\n
function loopEventListener(target, type, useCapture, callback) {\n
"use strict";\n
//////////////////////////\n
// Infinite event listener (promise is never resolved)\n
// eventListener is removed when promise is cancelled/rejected\n
//////////////////////////\n
var handle_event_callback,\n
callback_promise;\n
\n
function cancelResolver() {\n
if ((callback_promise !== undefined) &&\n
(typeof callback_promise.cancel === "function")) {\n
callback_promise.cancel();\n
}\n
}\n
\n
function canceller() {\n
if (handle_event_callback !== undefined) {\n
target.removeEventListener(type, handle_event_callback, useCapture);\n
}\n
cancelResolver();\n
}\n
function itsANonResolvableTrap(resolve, reject) {\n
\n
handle_event_callback = function (evt) {\n
evt.stopPropagation();\n
evt.preventDefault();\n
cancelResolver();\n
callback_promise = new RSVP.Queue()\n
.push(function () {\n
return callback(evt);\n
})\n
.push(undefined, function (error) {\n
if (!(error instanceof RSVP.CancellationError)) {\n
canceller();\n
reject(error);\n
}\n
});\n
};\n
\n
target.addEventListener(type, handle_event_callback, useCapture);\n
}\n
return new RSVP.Promise(itsANonResolvableTrap, canceller);\n
}\n
// end of horrible copy/paste\n
\n
\n
(function (rJS, jIO, Handlebars, RSVP, document, window) {\n
"use strict";\n
rJS(window)\n
.ready(function (g) {\n
g.props = {};\n
})\n
.ready(function (g) {\n
return g.getElement().push(function (element) {\n
g.props.element = element;\n
});\n
})\n
.declareService(function (gadget) {\n
console.log("location",location);\n
var basedir = location.pathname.split(\'/\').slice(0, -1).join(\'/\') + \'/\',\n
divergence_choice_list = [],\n
i,\n
divergence_element_choice,\n
divergence_element_choice_list = document.querySelectorAll(\n
\'input[type="radio"]\'),\n
listener_list = [];\n
\n
function fillDialog(event) {\n
console.log("fillDialog, event", event);\n
console.log("fillDialog, value", event.target.value);\n
var solver_decision_uid = event.target.name.split("_").pop();\n
return new RSVP.Queue()\n
.push(function () {\n
return jIO.util.ajax(\n
{\n
"type": "POST",\n
"url": basedir + \'Delivery_getSolveDivergenceDialogParameterFormBox?solver=\' + event.target.value + "&solver_decision_uid=" + solver_decision_uid,\n
"xhrFields": {\n
withCredentials: true\n
}\n
}\n
);\n
})\n
.push(function (data) {\n
event.srcElement.parentElement.parentElement.querySelectorAll(\n
".listbox-table-data-cell")[2].innerHTML = data.target.response;\n
});\n
}\n
\n
console.log("divergence_element_choice_list", divergence_element_choice_list);\n
for (i = 0; i < divergence_element_choice_list.length; i++) {\n
divergence_element_choice = divergence_element_choice_list[i];\n
console.log("divergence_element_choice.name", divergence_element_choice.name);\n
if (divergence_element_choice.name.startsWith("field_listbox_solver_") === true) {\n
//divergence_choice_list.push(divergence_element_choice);\n
divergence_choice_list.push(loopEventListener(\n
divergence_element_choice,\n
\'change\',\n
false,\n
fillDialog\n
));\n
}\n
}\n
return divergence_choice_list;\n
});\n
}(rJS, jIO, Handlebars, RSVP, document, window));
]]></string> </value>
</item>
<item>
<key> <string>precondition</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>size</string> </key>
<value> <int>4104</int> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
Copyright (c) Nexedi SA
\ No newline at end of file
erp5_simulation
\ No newline at end of file
Fast input to solve divergences of simulation
\ No newline at end of file
GPL
\ No newline at end of file
extension.erp5.SimulationFastInputUtils
\ No newline at end of file
erp5_simulation_fast_input
\ No newline at end of file
erp5_simulation_fast_input
\ No newline at end of file
001
\ No newline at end of file
......@@ -80,7 +80,7 @@ for property_sheet in portal.portal_property_sheets.objectValues():\n
if constraint_type:\n
if property_sheet_id in property_sheet_by_type_dict:\n
type_per_constraint_type.setdefault(\n
constraint_type, []).extend(\n
constraint_type, set()).update(\n
property_sheet_by_type_dict[property_sheet_id])\n
type_list_append(constraint_type)\n
if type_list:\n
......@@ -89,7 +89,7 @@ for property_sheet in portal.portal_property_sheets.objectValues():\n
constraint_type_per_type = {}\n
for property_sheet_id, category_list in constraint_type_per_id.iteritems():\n
for portal_type in property_sheet_by_type_dict.get(property_sheet_id, []):\n
constraint_type_per_type.setdefault(portal_type, []).extend(category_list)\n
constraint_type_per_type.setdefault(portal_type, set()).update(category_list)\n
\n
portal_type_tool = portal.portal_types\n
portal_type_list = constraint_type_per_type.keys()\n
......
......@@ -197,58 +197,16 @@
\n
\n
<tr>\n
<td>waitForElementPresent</td>\n
<td>//a[@class="responsive ui-btn ui-icon-spinner ui-btn-icon-left ui-first-child ui-last-child "]</td>\n
<td></td>\n
</tr>\n
\n
<tr>\n
<td>waitForElementPresent</td>\n
<td>//a[@class="responsive ui-btn ui-icon-pencil ui-btn-icon-left ui-first-child ui-last-child "]</td>\n
<td></td>\n
</tr>\n
\n
<tr>\n
<td>waitForElementPresent</td>\n
<td>//a[@class="responsive ui-btn ui-icon-spinner ui-btn-icon-left ui-first-child ui-last-child "]</td>\n
<td></td>\n
</tr>\n
\n
<tr>\n
<td>waitForElementPresent</td>\n
<td>//a[@class="responsive ui-btn ui-icon-pencil ui-btn-icon-left ui-first-child ui-last-child "]</td>\n
<td></td>\n
</tr>\n
\n
<tr>\n
<td>waitForElementPresent</td>\n
<td>//a[@class="responsive ui-btn ui-icon-spinner ui-btn-icon-left ui-first-child ui-last-child "]</td>\n
<td></td>\n
</tr>\n
\n
<tr>\n
<td>waitForElementPresent</td>\n
<td>//a[@class="responsive ui-btn ui-icon-pencil ui-btn-icon-left ui-first-child ui-last-child "]</td>\n
<td></td>\n
</tr>\n
\n
\n
<tr>\n
<td>waitForElementPresent</td>\n
<td>//a[@class="responsive ui-btn ui-icon-spinner ui-btn-icon-left ui-first-child ui-last-child "]</td>\n
<td>waitForElementNotPresent</td>\n
<td>//a[@data-i18n = "Title 2"]</td>\n
<td></td>\n
</tr>\n
\n
<tr>\n
<td>waitForElementPresent</td>\n
<td>//a[@class="responsive ui-btn ui-icon-pencil ui-btn-icon-left ui-first-child ui-last-child "]</td>\n
<td></td>\n
</tr>\n
\n
\n
<tr>\n
<td>waitForElementPresent</td>\n
<td>//input[@title=\'Title\']</td>\n
<td>//a[@data-i18n=\'Title 3\']</td>\n
<td></td>\n
</tr>\n
\n
......@@ -267,58 +225,15 @@
</tr>\n
\n
<tr>\n
<td>waitForElementPresent</td>\n
<td>//a[@class="responsive ui-btn ui-icon-spinner ui-btn-icon-left ui-first-child ui-last-child "]</td>\n
<td></td>\n
</tr>\n
\n
<tr>\n
<td>waitForElementPresent</td>\n
<td>//a[@class="responsive ui-btn ui-icon-pencil ui-btn-icon-left ui-first-child ui-last-child "]</td>\n
<td></td>\n
</tr>\n
\n
<tr>\n
<td>waitForElementPresent</td>\n
<td>//a[@class="responsive ui-btn ui-icon-spinner ui-btn-icon-left ui-first-child ui-last-child "]</td>\n
<td></td>\n
</tr>\n
\n
<tr>\n
<td>waitForElementPresent</td>\n
<td>//a[@class="responsive ui-btn ui-icon-pencil ui-btn-icon-left ui-first-child ui-last-child "]</td>\n
<td></td>\n
</tr>\n
\n
<tr>\n
<td>waitForElementPresent</td>\n
<td>//a[@class="responsive ui-btn ui-icon-spinner ui-btn-icon-left ui-first-child ui-last-child "]</td>\n
<td></td>\n
</tr>\n
\n
<tr>\n
<td>waitForElementPresent</td>\n
<td>//a[@class="responsive ui-btn ui-icon-pencil ui-btn-icon-left ui-first-child ui-last-child "]</td>\n
<td></td>\n
</tr>\n
\n
\n
<tr>\n
<td>waitForElementPresent</td>\n
<td>//a[@class="responsive ui-btn ui-icon-spinner ui-btn-icon-left ui-first-child ui-last-child "]</td>\n
<td></td>\n
</tr>\n
\n
<tr>\n
<td>waitForElementPresent</td>\n
<td>//a[@class="responsive ui-btn ui-icon-pencil ui-btn-icon-left ui-first-child ui-last-child "]</td>\n
<td>waitForElementNotPresent</td>\n
<td>//a[@data-i18n = "Title 3"]</td>\n
<td></td>\n
</tr>\n
\n
\n
<tr>\n
<td>waitForElementPresent</td>\n
<td>//input[@title=\'Title\']</td>\n
<td>//a[@data-i18n=\'Title 4\']</td>\n
<td></td>\n
</tr>\n
\n
......@@ -336,58 +251,16 @@
<td></td>\n
</tr>\n
\n
<tr>\n
<td>waitForElementPresent</td>\n
<td>//a[@class="responsive ui-btn ui-icon-spinner ui-btn-icon-left ui-first-child ui-last-child "]</td>\n
<td></td>\n
</tr>\n
\n
<tr>\n
<td>waitForElementPresent</td>\n
<td>//a[@class="responsive ui-btn ui-icon-pencil ui-btn-icon-left ui-first-child ui-last-child "]</td>\n
<td></td>\n
</tr>\n
\n
<tr>\n
<td>waitForElementPresent</td>\n
<td>//a[@class="responsive ui-btn ui-icon-spinner ui-btn-icon-left ui-first-child ui-last-child "]</td>\n
<td></td>\n
</tr>\n
\n
<tr>\n
<td>waitForElementPresent</td>\n
<td>//a[@class="responsive ui-btn ui-icon-pencil ui-btn-icon-left ui-first-child ui-last-child "]</td>\n
<td></td>\n
</tr>\n
\n
<tr>\n
<td>waitForElementPresent</td>\n
<td>//a[@class="responsive ui-btn ui-icon-spinner ui-btn-icon-left ui-first-child ui-last-child "]</td>\n
<td></td>\n
</tr>\n
\n
<tr>\n
<td>waitForElementPresent</td>\n
<td>//a[@class="responsive ui-btn ui-icon-pencil ui-btn-icon-left ui-first-child ui-last-child "]</td>\n
<td></td>\n
</tr>\n
\n
\n
<tr>\n
<td>waitForElementPresent</td>\n
<td>//a[@class="responsive ui-btn ui-icon-spinner ui-btn-icon-left ui-first-child ui-last-child "]</td>\n
<td></td>\n
</tr>\n
\n
<tr>\n
<td>waitForElementPresent</td>\n
<td>//a[@class="responsive ui-btn ui-icon-pencil ui-btn-icon-left ui-first-child ui-last-child "]</td>\n
<td>waitForElementNotPresent</td>\n
<td>//a[@data-i18n = "Title 4"]</td>\n
<td></td>\n
</tr>\n
\n
<tr>\n
<td>waitForElementPresent</td>\n
<td>//input[@title=\'Title\']</td>\n
<td>//a[@data-i18n=\'Title 3\']</td>\n
<td></td>\n
</tr>\n
\n
......
......@@ -61,6 +61,11 @@
<td>//div[@data-gadget-url=\'${base_url}/web_site_module/renderjs_runner/gadget_erp5_pt_form_list.html\']</td>\n
<td></td>\n
</tr>\n
<tr>\n
<td>waitForTextPresent</td>\n
<td>Title 1</td>\n
<td></td>\n
</tr>\n
\n
<!-- Enter a search query to create a selection parameter -->\n
<tr>\n
......@@ -73,12 +78,12 @@
<td>//div[@data-gadget-scope=\'erp5_searchfield\']//input[@value=\'header-submit\' and @type=\'submit\']</td>\n
<td></td>\n
</tr>\n
\n
<tr>\n
<td>pause</td>\n
<td>1000</td>\n
<td>waitForTextNotPresent</td>\n
<td>Title 1</td>\n
<td></td>\n
</tr>\n
\n
<tr>\n
<td>waitForTextPresent</td>\n
<td>Title 1</td>\n
......
......@@ -94,6 +94,11 @@
<td>//div[@data-gadget-url=\'${base_url}/web_site_module/renderjs_runner/gadget_erp5_pt_form_list.html\']</td>\n
<td></td>\n
</tr>\n
<tr>\n
<td>waitForTextPresent</td>\n
<td>Title 3</td>\n
<td></td>\n
</tr>\n
\n
<!-- Enter a search query to create a selection parameter -->\n
<tr>\n
......@@ -107,16 +112,73 @@
<td></td>\n
</tr>\n
<tr>\n
<td>pause</td>\n
<td>1000</td>\n
<td>waitForTextNotPresent</td>\n
<td>Title 3</td>\n
<td></td>\n
</tr>\n
<tr>\n
<td>waitForTextPresent</td>\n
<td>Title 3</td>\n
<td></td>\n
</tr>\n
\n
<!-- Sort -->\n
<tr>\n
<td>waitForElementPresent</td>\n
<td>//form[@class=\'sort_form\']</td>\n
<td></td>\n
</tr>\n
\n
<tr>\n
<td>click</td>\n
<td>//form[@class=\'sort_form\']/button</td>\n
<td></td>\n
</tr>\n
\n
<tr>\n
<td>waitForElementPresent</td>\n
<td>//form[@class=\'plus\']</td>\n
<td></td>\n
</tr>\n
<tr>\n
<td>click</td>\n
<td>//form[@class=\'plus\']/button</td>\n
<td></td>\n
</tr>\n
\n
\n
<tr>\n
<td>waitForElementPresent</td>\n
<td>//div[@class=\'sort_item_container ui-controlgroup ui-corner_all\']/div[1]</td>\n
<td></td>\n
</tr>\n
\n
<tr>\n
<td>select</td>\n
<td>//div[@class=\'sort_item_container ui-controlgroup ui-corner_all\']/div[1]/div[2]//select</td>\n
<td>descending</td>\n
</tr>\n
\n
\n
<tr>\n
<td>click</td>\n
<td>//form[@class="submit"]//button</td>\n
<td></td>\n
</tr>\n
\n
<tr>\n
<td>waitForTextNotPresent</td>\n
<td>Title 3</td>\n
<td></td>\n
</tr>\n
<tr>\n
<td>waitForTextPresent</td>\n
<td>Title 3</td>\n
<td></td>\n
</tr>\n
\n
\n
<!-- Go to the first element -->\n
<tr>\n
<td>click</td>\n
<td>//div[@data-gadget-scope=\'field_listbox\']//a[text()=\'Title 3\' and contains(@href, \'#!index\')]</td>\n
......
......@@ -61,6 +61,11 @@
<td>//div[@data-gadget-url=\'${base_url}/web_site_module/renderjs_runner/gadget_erp5_pt_form_list.html\']</td>\n
<td></td>\n
</tr>\n
<tr>\n
<td>waitForTextPresent</td>\n
<td>Title 1</td>\n
<td></td>\n
</tr>\n
\n
<!-- Enter a search query to create a selection parameter -->\n
<tr>\n
......@@ -73,12 +78,12 @@
<td>//div[@data-gadget-scope=\'erp5_searchfield\']//input[@value=\'header-submit\' and @type=\'submit\']</td>\n
<td></td>\n
</tr>\n
\n
<tr>\n
<td>pause</td>\n
<td>1000</td>\n
<td>waitForTextNotPresent</td>\n
<td>Title 1</td>\n
<td></td>\n
</tr>\n
\n
<tr>\n
<td>waitForTextPresent</td>\n
<td>Title 1</td>\n
......
......@@ -61,6 +61,11 @@
<td>//div[@data-gadget-url=\'${base_url}/web_site_module/renderjs_runner/gadget_erp5_pt_form_list.html\']</td>\n
<td></td>\n
</tr>\n
<tr>\n
<td>waitForTextPresent</td>\n
<td>Title 1</td>\n
<td></td>\n
</tr>\n
\n
<!-- Enter a search query to create a selection parameter -->\n
<tr>\n
......@@ -74,11 +79,10 @@
<td></td>\n
</tr>\n
<tr>\n
<td>pause</td>\n
<td>1000</td>\n
<td>waitForTextNotPresent</td>\n
<td>Title 1</td>\n
<td></td>\n
</tr>\n
\n
<tr>\n
<td>waitForTextPresent</td>\n
<td>Title 1</td>\n
......
......@@ -94,6 +94,11 @@
<td>//div[@data-gadget-url=\'${base_url}/web_site_module/renderjs_runner/gadget_erp5_pt_form_list.html\']</td>\n
<td></td>\n
</tr>\n
<tr>\n
<td>waitForTextPresent</td>\n
<td>Title 3</td>\n
<td></td>\n
</tr>\n
\n
<!-- Enter a search query to create a selection parameter -->\n
<tr>\n
......@@ -106,17 +111,74 @@
<td>//div[@data-gadget-scope=\'erp5_searchfield\']//input[@value=\'header-submit\' and @type=\'submit\']</td>\n
<td></td>\n
</tr>\n
\n
<tr>\n
<td>pause</td>\n
<td>1000</td>\n
<td>waitForTextNotPresent</td>\n
<td>Title 1</td>\n
<td></td>\n
</tr>\n
\n
<tr>\n
<td>waitForTextPresent</td>\n
<td>Title 1</td>\n
<td></td>\n
</tr>\n
\n
<!-- Sort -->\n
<tr>\n
<td>waitForElementPresent</td>\n
<td>//form[@class=\'sort_form\']</td>\n
<td></td>\n
</tr>\n
\n
<tr>\n
<td>click</td>\n
<td>//form[@class=\'sort_form\']/button</td>\n
<td></td>\n
</tr>\n
\n
<tr>\n
<td>waitForElementPresent</td>\n
<td>//form[@class=\'plus\']</td>\n
<td></td>\n
</tr>\n
<tr>\n
<td>click</td>\n
<td>//form[@class=\'plus\']/button</td>\n
<td></td>\n
</tr>\n
\n
\n
<tr>\n
<td>waitForElementPresent</td>\n
<td>//div[@class=\'sort_item_container ui-controlgroup ui-corner_all\']/div[1]</td>\n
<td></td>\n
</tr>\n
\n
<tr>\n
<td>select</td>\n
<td>//div[@class=\'sort_item_container ui-controlgroup ui-corner_all\']/div[1]/div[2]//select</td>\n
<td>descending</td>\n
</tr>\n
\n
\n
<tr>\n
<td>click</td>\n
<td>//form[@class="submit"]//button</td>\n
<td></td>\n
</tr>\n
\n
<tr>\n
<td>waitForTextNotPresent</td>\n
<td>Title 3</td>\n
<td></td>\n
</tr>\n
<tr>\n
<td>waitForTextPresent</td>\n
<td>Title 3</td>\n
<td></td>\n
</tr>\n
\n
<!-- Go to the last element -->\n
<tr>\n
<td>click</td>\n
<td>//div[@data-gadget-scope=\'field_listbox\']//a[text()=\'Title 1\' and contains(@href, \'#!index\')]</td>\n
......
......@@ -44,6 +44,7 @@ from Products.ERP5.mixin.explainable import ExplainableMixin
parent_to_movement_simulation_state = {
'cancelled' : 'cancelled',
'rejected' : 'cancelled',
'draft' : 'draft',
'auto_planned' : 'auto_planned',
'planned' : 'planned',
......
......@@ -139,7 +139,7 @@ class AlarmTool(TimerServiceMixin, BaseTool):
if alarm.isActive() or not alarm.isEnabled():
# do nothing if already active, or not enabled
continue
if alarm.isAutomaticSolve():
if alarm.getProperty('automatic_solve'):
alarm.solve()
else:
alarm.activeSense()
......
......@@ -148,6 +148,10 @@
<string>my_view_mode_listbox_description</string>
<string>my_view_mode_read_only_id</string>
<string>my_view_mode_reference_as_name</string>
<string>listbox_modification_date</string>
<string>listbox_description</string>
<string>listbox_owner_title</string>
<string>listbox_creation_date</string>
</list>
</value>
</item>
......
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ProxyField" module="Products.ERP5Form.ProxyField"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>delegated_list</string> </key>
<value>
<list>
<string>date_only</string>
<string>editable</string>
</list>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>listbox_creation_date</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>target</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>values</string> </key>
<value>
<dictionary>
<item>
<key> <string>date_only</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>editable</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>field_id</string> </key>
<value> <string>your_date</string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string>Base_viewFieldLibrary</string> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string>Click to edit the target</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ProxyField" module="Products.ERP5Form.ProxyField"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>delegated_list</string> </key>
<value>
<list>
<string>editable</string>
</list>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>listbox_description</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>target</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>values</string> </key>
<value>
<dictionary>
<item>
<key> <string>editable</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>field_id</string> </key>
<value> <string>my_view_mode_description</string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string>Base_viewFieldLibrary</string> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string>Click to edit the target</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ProxyField" module="Products.ERP5Form.ProxyField"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>delegated_list</string> </key>
<value>
<list>
<string>date_only</string>
<string>editable</string>
</list>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>listbox_modification_date</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>target</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>values</string> </key>
<value>
<dictionary>
<item>
<key> <string>date_only</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>editable</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>field_id</string> </key>
<value> <string>your_date</string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string>Base_viewFieldLibrary</string> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string>Click to edit the target</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
......@@ -134,7 +134,7 @@
</item>
<item>
<key> <string>storage_id</string> </key>
<value> <string>default_address</string> </value>
<value> <string>default_birthplace_address</string> </value>
</item>
</dictionary>
</pickle>
......
......@@ -1208,16 +1208,24 @@ class ERP5ReportTestCase(ERP5TypeTestCase):
in the report_section.
"""
result = None
here = report_section.getObject(self.portal)
report_section.pushReport(self.portal)
form = getattr(here, report_section.getFormId())
self.portal.REQUEST['here'] = here
if form.has_field('listbox'):
result = form.listbox.get_value('default',
render_format='list',
REQUEST=self.portal.REQUEST)
report_section.popReport(self.portal)
return result
# Use an independent request, because this is what happens when using
# deferred style
request_form = self.portal.REQUEST.form
try:
# XXX maybe there is better API than just replacing the dict
self.portal.REQUEST.form = dict()
here = report_section.getObject(self.portal)
report_section.pushReport(self.portal)
form = getattr(here, report_section.getFormId())
self.portal.REQUEST['here'] = here
if form.has_field('listbox'):
result = form.listbox.get_value('default',
render_format='list',
REQUEST=self.portal.REQUEST)
return result
finally:
report_section.popReport(self.portal)
self.portal.REQUEST.form = request_form
def checkLineProperties(self, line, **kw):
"""Check properties of a report line.
......
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