Commit 44433fd7 authored by Xiaowu Zhang's avatar Xiaowu Zhang

erp5_produciton_planning: use workflow instead of action

parent 4152bda3
<workflow_chain>
<chain>
<type>Production Planning</type>
<workflow>edit_workflow, production_planning_workflow</workflow>
<workflow>edit_workflow, production_planning_interaction_workflow, production_planning_workflow</workflow>
</chain>
</workflow_chain>
\ No newline at end of file
context.manage_delObjects(ids=[x.getId() for x in context.contentValues(portal_type='Production Planning Cell')])
......@@ -54,7 +54,7 @@
</item>
<item>
<key> <string>id</string> </key>
<value> <string>ProductionPlanning_applyChange</string> </value>
<value> <string>ProductionPlanning_afterClone</string> </value>
</item>
</dictionary>
</pickle>
......
context.activate().ProductionPlanning_applyChange()
context.apply()
message = context.Base_translateString("Changes are applying.")
return context.Base_redirect('view',keep_items={'portal_status_message': message})
<?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>_params</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>ProductionPlanning_applyChangeByActivity</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>
<string>default</string>
<string>display_width</string>
<string>editable</string>
<string>title</string>
</list>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>your_warning</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>
</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>
</dictionary>
</value>
</item>
<item>
<key> <string>values</string> </key>
<value>
<dictionary>
<item>
<key> <string>default</string> </key>
<value> <string>Production Planning Change will be Applied</string> </value>
</item>
<item>
<key> <string>display_width</string> </key>
<value> <int>20</int> </value>
</item>
<item>
<key> <string>editable</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>field_id</string> </key>
<value> <string>my_string_field</string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string>Base_viewFieldLibrary</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Warning</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
from Products.ERP5Type.DateUtils import addToDate
from DateTime import DateTime
from Products.ZSQLCatalog.SQLCatalog import Query, ComplexQuery
portal = context.getPortalObject()
if not start_date:
start_date = context.getStartDate()
......@@ -19,7 +18,7 @@ date_dict = {
'saturday': 6,
'sunday': 0
}
if not start_date:
if not start_date or not start_date or not period:
return [],[]
tmp_date = start_date
day_number = tmp_date.dow()
......@@ -36,7 +35,9 @@ while tmp_date < stop_date:
line_list = []
for product in portal.portal_catalog(portal_type='Product', product_line_relative_url='product_line/car', sort_on=(('uid', 'ascending'),)):
line_list.append((int(product.getUid()), '%s/%s'% (product.getReference(), product.getTitle())))
# Now check date
if context.getValidationState() in ('draft'):
continue
# Now check existed production order to add more columns
product_uid = product.getUid()
query_list = [
Query(portal_type='Production Order'),
......@@ -51,6 +52,22 @@ for product in portal.portal_catalog(portal_type='Product', product_line_relativ
tmp_start_date = production_order.getStartDate()
if tmp_start_date.Date() not in column_dict:
column_dict[tmp_start_date.Date()] = '%s, week %s' % (tmp_start_date.Date(), tmp_start_date.week())
#Not lost already created cell
for cell_keys in context.getCellKeys():
cell_id = context.keyToId(cell_keys)
if cell_id is not None:
cell = context.get(cell_id)
if cell is not None:
[_, tmp_start_date] = cell_keys
if tmp_start_date not in column_dict:
column_dict[tmp_start_date] = '%s, week %s' % (tmp_start_date, DateTime(tmp_start_date).week())
column_list = []
for date, value in sorted(column_dict.items()):
column_list.append((date, value))
......
# Delete previous contents
context.manage_delObjects(ids=[x.getId() for x in context.contentValues(portal_type='Production Planning Cell')])
context.render()
context.setCellRange([],[])
context.activate().ProductionPlanning_renderProductionMatrixStatus()
message = context.Base_translateString("Production Planning Status is rerendering.")
return context.Base_redirect('view',keep_items={'portal_status_message': message})
<?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>default</string>
<string>display_width</string>
<string>editable</string>
<string>title</string>
</list>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>your_warning</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>
</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>
</dictionary>
</value>
</item>
<item>
<key> <string>values</string> </key>
<value>
<dictionary>
<item>
<key> <string>default</string> </key>
<value> <string>Production Planning Status will be Rerendered</string> </value>
</item>
<item>
<key> <string>display_width</string> </key>
<value> <int>20</int> </value>
</item>
<item>
<key> <string>editable</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>field_id</string> </key>
<value> <string>my_string_field</string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string>Base_viewFieldLibrary</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Warning</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
......@@ -223,7 +223,7 @@
</item>
<item>
<key> <string>enabled</string> </key>
<value> <int>1</int> </value>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>external_validator</string> </key>
......@@ -279,7 +279,7 @@
<dictionary>
<item>
<key> <string>_text</string> </key>
<value> <string>python: context.getValidationState() not in (\'rendering\')</string> </value>
<value> <string>python: here.getValidationState() not in (\'draft\',\'rendering\', \'applying\')</string> </value>
</item>
</dictionary>
</pickle>
......
......@@ -286,7 +286,7 @@
<dictionary>
<item>
<key> <string>_text</string> </key>
<value> <string>python: context.getValidationState() not in (\'rendering\')</string> </value>
<value> <string>python: here.getValidationState() not in (\'draft\',\'rendering\', \'applying\')</string> </value>
</item>
</dictionary>
</pickle>
......
......@@ -11,7 +11,6 @@
<value>
<list>
<string>date_only</string>
<string>editable</string>
<string>required</string>
<string>title</string>
</list>
......@@ -70,10 +69,6 @@
<key> <string>date_only</string> </key>
<value> <int>1</int> </value>
</item>
<item>
<key> <string>editable</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>field_id</string> </key>
<value> <string>my_start_date</string> </value>
......
......@@ -11,7 +11,6 @@
<value>
<list>
<string>date_only</string>
<string>editable</string>
<string>required</string>
<string>title</string>
</list>
......@@ -70,10 +69,6 @@
<key> <string>date_only</string> </key>
<value> <int>1</int> </value>
</item>
<item>
<key> <string>editable</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>field_id</string> </key>
<value> <string>my_stop_date</string> </value>
......
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="InteractionWorkflowDefinition" module="Products.ERP5.InteractionWorkflow"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_objects</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>creation_guard</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>description</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>groups</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>production_planning_interaction_workflow</string> </value>
</item>
<item>
<key> <string>manager_bypass</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Production Plannning Interaction Workflow</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="Interaction" module="Products.ERP5.Interaction"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_mapping</string> </key>
<value>
<dictionary/>
</value>
</item>
<item>
<key> <string>_objects</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>interactions</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
......@@ -2,128 +2,99 @@
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ERP5 Form" module="erp5.portal_type"/>
<global name="InteractionDefinition" module="Products.ERP5.Interaction"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_objects</string> </key>
<value>
<tuple/>
</value>
<key> <string>actbox_category</string> </key>
<value> <string>workflow</string> </value>
</item>
<item>
<key> <string>action</string> </key>
<value> <string>ProductionPlanning_rerenderProductionPlanningStatus</string> </value>
<key> <string>actbox_name</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>description</string> </key>
<key> <string>actbox_url</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>edit_order</string> </key>
<key> <string>activate_script_name</string> </key>
<value>
<list/>
<list>
<string>ProductionPlanning_applyProductionPlanningChanges</string>
</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>
<key> <string>after_script_name</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>group_list</string> </key>
<key> <string>before_commit_script_name</string> </key>
<value>
<list>
<string>left</string>
<string>right</string>
<string>center</string>
<string>bottom</string>
<string>hidden</string>
</list>
<tuple/>
</value>
</item>
<item>
<key> <string>groups</string> </key>
<key> <string>description</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>guard</string> </key>
<value>
<dictionary>
<item>
<key> <string>bottom</string> </key>
<value>
<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>
<string>your_warning</string>
</list>
</value>
</item>
<item>
<key> <string>right</string> </key>
<value>
<list/>
</value>
</item>
</dictionary>
<none/>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>ProductionPlanning_rerenderProductionPlanningStatusDialog</string> </value>
<value> <string>ProductionPlanning_applyProductionPlanningChanges</string> </value>
</item>
<item>
<key> <string>method</string> </key>
<value> <string>POST</string> </value>
</item>
<item>
<key> <string>name</string> </key>
<value> <string>ProductionPlanning_rerenderProductionPlanningStatusDialog</string> </value>
<key> <string>method_id</string> </key>
<value>
<list>
<string>applyChange</string>
</list>
</value>
</item>
<item>
<key> <string>pt</string> </key>
<value> <string>form_dialog</string> </value>
<key> <string>once_per_transaction</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>row_length</string> </key>
<value> <int>4</int> </value>
<key> <string>portal_type_filter</string> </key>
<value>
<list>
<string>Production Planning</string>
</list>
</value>
</item>
<item>
<key> <string>stored_encoding</string> </key>
<value> <string>UTF-8</string> </value>
<key> <string>portal_type_group_filter</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Rerender Production Planning Status</string> </value>
<key> <string>script_name</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>unicode_mode</string> </key>
<key> <string>temporary_document_disallowed</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>update_action</string> </key>
<key> <string>title</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>update_action_title</string> </key>
<value> <string></string> </value>
<key> <string>trigger_type</string> </key>
<value> <int>2</int> </value>
</item>
</dictionary>
</pickle>
......
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="InteractionDefinition" module="Products.ERP5.Interaction"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>actbox_category</string> </key>
<value> <string>workflow</string> </value>
</item>
<item>
<key> <string>actbox_name</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>actbox_url</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>activate_script_name</string> </key>
<value>
<list>
<string>ProductionPlanning_renderProductionPlanningStatus</string>
</list>
</value>
</item>
<item>
<key> <string>after_script_name</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>before_commit_script_name</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>description</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>guard</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>ProductionPlanning_renderProductionPlanningStatus</string> </value>
</item>
<item>
<key> <string>method_id</string> </key>
<value>
<list>
<string>render</string>
</list>
</value>
</item>
<item>
<key> <string>once_per_transaction</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>portal_type_filter</string> </key>
<value>
<list>
<string>Production Planning</string>
</list>
</value>
</item>
<item>
<key> <string>portal_type_group_filter</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>script_name</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>temporary_document_disallowed</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>trigger_type</string> </key>
<value> <int>2</int> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="Scripts" module="Products.DCWorkflow.Scripts"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_mapping</string> </key>
<value>
<dictionary/>
</value>
</item>
<item>
<key> <string>_objects</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>scripts</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
from DateTime import DateTime
from Products.ERP5Type.DateUtils import addToDate
production_planning = state_change['object']
portal = context.getPortalObject()
portal = production_planning.getPortalObject()
created_production_order_dict = {}
for cell_keys in context.getCellKeys():
cell_id = context.keyToId(cell_keys)
for cell_keys in production_planning.getCellKeys():
cell_id = production_planning.keyToId(cell_keys)
if cell_id is not None:
cell = context.get(cell_id)
cell = production_planning.get(cell_id)
if cell is not None:
production_order_line = cell.getSpecialiseValue()
if production_order_line:
......@@ -16,7 +17,7 @@ for cell_keys in context.getCellKeys():
portal.portal_workflow.doActionFor(
production_order_line,
"edit_action",
comment='Modified by production planning %s' % context.getRelativeUrl())
comment='Modified by production planning %s' % production_planning.getRelativeUrl())
else:
# It's a new cell, create producton order&production order line
[resource_uid,start_date] = cell_keys
......@@ -51,7 +52,7 @@ for cell_keys in context.getCellKeys():
portal.portal_workflow.doActionFor(
production_order_line,
"edit_action",
comment='Added by production planning %s' % context.getRelativeUrl())
comment='Added by production planning %s' % production_planning.getRelativeUrl())
if portal.portal_workflow.isTransitionPossible(context, 'record'):
context.record()
if portal.portal_workflow.isTransitionPossible(production_planning, 'apply'):
production_planning.apply()
......@@ -50,11 +50,19 @@
</item>
<item>
<key> <string>_params</string> </key>
<value> <string></string> </value>
<value> <string>state_change</string> </value>
</item>
<item>
<key> <string>_proxy_roles</string> </key>
<value>
<tuple>
<string>Manager</string>
</tuple>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>ProductionPlanning_rerenderProductionPlanningStatus</string> </value>
<value> <string>ProductionPlanning_applyProductionPlanningChanges</string> </value>
</item>
</dictionary>
</pickle>
......
from DateTime import DateTime
from Products.ERP5Type.DateUtils import addToDate
from Products.ZSQLCatalog.SQLCatalog import Query, ComplexQuery
portal = context.getPortalObject()
line_list, column_list = context.ProductionPlanning_getCellRange()
production_planning = state_change['object']
portal = production_planning.getPortalObject()
line_list, column_list = production_planning.ProductionPlanning_getCellRange()
line_ids = map(lambda x: x[0], line_list)
column_ids = map(lambda x: x[0], column_list)
context.setCellRange(line_ids, column_ids, base_id='cell')
production_planning.setCellRange(line_ids, column_ids, base_id='cell')
start_date = DateTime(column_list[0][0])
stop_date = addToDate(DateTime(column_list[-1][0]), {'day':1})
......@@ -27,12 +29,11 @@ for product in portal.portal_catalog(portal_type='Product', product_line_relativ
column = '%s' % production_order.getStartDate().Date()
for production_order_line in production_order.searchFolder(portal_type='Production Order Line', strict_resource_uid=product_uid):
k = (line, column)
if not context.hasInRange(*k, **kd):
context.log('Waring: Production order date %s is not in range which should not be, need to check' % start_date)
if context.hasCell(*k, **kd):
raise ValueError('Duplicated production order for %s at %s' % (product.getReference(), start_date))
new_cell = context.newCell(*k, **kd)
new_cell.edit(
quantity = production_order_line.getQuantity(),
specialise_value = production_order_line)
context.record()
if not production_planning.hasInRange(*k, **kd):
production_planning.log('Waring: Production order date %s is not in range which should not be, need to check' % start_date)
if not production_planning.hasCell(*k, **kd):
new_cell = production_planning.newCell(*k, **kd)
new_cell.edit(
quantity = production_order_line.getQuantity(),
specialise_value = production_order_line)
production_planning.record()
......@@ -50,11 +50,19 @@
</item>
<item>
<key> <string>_params</string> </key>
<value> <string></string> </value>
<value> <string>state_change</string> </value>
</item>
<item>
<key> <string>_proxy_roles</string> </key>
<value>
<tuple>
<string>Manager</string>
</tuple>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>ProductionPlanning_renderProductionMatrixStatus</string> </value>
<value> <string>ProductionPlanning_renderProductionPlanningStatus</string> </value>
</item>
</dictionary>
</pickle>
......
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="Variables" module="Products.DCWorkflow.Variables"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_mapping</string> </key>
<value>
<dictionary/>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>variables</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="Worklists" module="Products.DCWorkflow.Worklists"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_mapping</string> </key>
<value>
<dictionary/>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>worklists</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
......@@ -12,6 +12,12 @@
<dictionary/>
</value>
</item>
<item>
<key> <string>_objects</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>scripts</string> </value>
......
......@@ -2,129 +2,100 @@
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ERP5 Form" module="erp5.portal_type"/>
<global name="StateDefinition" module="Products.DCWorkflow.States"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_objects</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>action</string> </key>
<value> <string>ProductionPlanning_applyChangeByActivity</string> </value>
</item>
<item>
<key> <string>description</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>edit_order</string> </key>
<key> <string>id</string> </key>
<value> <string>applied</string> </value>
</item>
<item>
<key> <string>permission_roles</string> </key>
<value>
<list/>
<persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent>
</value>
</item>
<item>
<key> <string>encoding</string> </key>
<value> <string>UTF-8</string> </value>
<key> <string>title</string> </key>
<value> <string>Applied</string> </value>
</item>
<item>
<key> <string>enctype</string> </key>
<value> <string></string> </value>
<key> <string>transitions</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>group_list</string> </key>
<key> <string>type_list</string> </key>
<value>
<list>
<string>left</string>
<string>right</string>
<string>center</string>
<string>bottom</string>
<string>hidden</string>
</list>
<tuple/>
</value>
</item>
</dictionary>
</pickle>
</record>
<record id="2" aka="AAAAAAAAAAI=">
<pickle>
<global name="PersistentMapping" module="Persistence.mapping"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>groups</string> </key>
<key> <string>data</string> </key>
<value>
<dictionary>
<item>
<key> <string>bottom</string> </key>
<key> <string>Access contents information</string> </key>
<value>
<list/>
<tuple>
<string>Assignee</string>
<string>Assignor</string>
<string>Associate</string>
<string>Auditor</string>
<string>Manager</string>
<string>Owner</string>
</tuple>
</value>
</item>
<item>
<key> <string>center</string> </key>
<key> <string>Add portal content</string> </key>
<value>
<list/>
<tuple/>
</value>
</item>
<item>
<key> <string>hidden</string> </key>
<key> <string>Delete objects</string> </key>
<value>
<list/>
<tuple/>
</value>
</item>
<item>
<key> <string>left</string> </key>
<key> <string>Modify portal content</string> </key>
<value>
<list>
<string>your_warning</string>
</list>
<tuple/>
</value>
</item>
<item>
<key> <string>right</string> </key>
<key> <string>View</string> </key>
<value>
<list/>
<tuple>
<string>Assignee</string>
<string>Assignor</string>
<string>Associate</string>
<string>Auditor</string>
<string>Manager</string>
<string>Owner</string>
</tuple>
</value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>ProductionPlanning_applyChangeDialog</string> </value>
</item>
<item>
<key> <string>method</string> </key>
<value> <string>POST</string> </value>
</item>
<item>
<key> <string>name</string> </key>
<value> <string>ProductionPlanning_applyChangeDialog</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>Apply Changes</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>
......
......@@ -28,7 +28,7 @@
<key> <string>transitions</string> </key>
<value>
<tuple>
<string>record</string>
<string>apply</string>
</tuple>
</value>
</item>
......
......@@ -29,6 +29,7 @@
<value>
<tuple>
<string>render</string>
<string>render_action</string>
</tuple>
</value>
</item>
......
......@@ -28,10 +28,12 @@
<key> <string>transitions</string> </key>
<value>
<tuple>
<string>apply</string>
<string>apply_change</string>
<string>apply_change_action</string>
<string>cancel</string>
<string>cancel_action</string>
<string>render</string>
<string>render_action</string>
</tuple>
</value>
</item>
......
......@@ -68,10 +68,7 @@
<key> <string>Add portal content</string> </key>
<value>
<tuple>
<string>Assignee</string>
<string>Assignor</string>
<string>Manager</string>
<string>Owner</string>
</tuple>
</value>
</item>
......@@ -79,10 +76,7 @@
<key> <string>Delete objects</string> </key>
<value>
<tuple>
<string>Assignee</string>
<string>Assignor</string>
<string>Manager</string>
<string>Owner</string>
</tuple>
</value>
</item>
......@@ -90,10 +84,7 @@
<key> <string>Modify portal content</string> </key>
<value>
<tuple>
<string>Assignee</string>
<string>Assignor</string>
<string>Manager</string>
<string>Owner</string>
</tuple>
</value>
</item>
......
......@@ -42,7 +42,7 @@
</item>
<item>
<key> <string>new_state_id</string> </key>
<value> <string>applying</string> </value>
<value> <string>applied</string> </value>
</item>
<item>
<key> <string>script_name</string> </key>
......@@ -50,7 +50,7 @@
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Apply</string> </value>
<value> <string></string> </value>
</item>
<item>
<key> <string>trigger_type</string> </key>
......
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="TransitionDefinition" module="Products.DCWorkflow.Transitions"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>actbox_category</string> </key>
<value> <string>workflow</string> </value>
</item>
<item>
<key> <string>actbox_icon</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>actbox_name</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>actbox_url</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>after_script_name</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>description</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>guard</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>apply_change</string> </value>
</item>
<item>
<key> <string>new_state_id</string> </key>
<value> <string>applying</string> </value>
</item>
<item>
<key> <string>script_name</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Apply Change</string> </value>
</item>
<item>
<key> <string>trigger_type</string> </key>
<value> <int>2</int> </value>
</item>
</dictionary>
</pickle>
</record>
<record id="2" aka="AAAAAAAAAAI=">
<pickle>
<global name="Guard" module="Products.DCWorkflow.Guard"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>permissions</string> </key>
<value>
<tuple>
<string>Modify portal content</string>
</tuple>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
......@@ -2,70 +2,58 @@
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ActionInformation" module="Products.CMFCore.ActionInformation"/>
<global name="TransitionDefinition" module="Products.DCWorkflow.Transitions"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>action</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent>
</value>
<key> <string>actbox_category</string> </key>
<value> <string>workflow</string> </value>
</item>
<item>
<key> <string>categories</string> </key>
<value>
<tuple>
<string>action_type/object_action</string>
</tuple>
</value>
<key> <string>actbox_icon</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>category</string> </key>
<value> <string>object_action</string> </value>
<key> <string>actbox_name</string> </key>
<value> <string>Apply Production Planning Changes</string> </value>
</item>
<item>
<key> <string>condition</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAM=</string> </persistent>
</value>
<key> <string>actbox_url</string> </key>
<value> <string>%(content_url)s/Base_viewWorkflowActionDialog?workflow_action=apply_change_action</string> </value>
</item>
<item>
<key> <string>description</string> </key>
<value>
<none/>
</value>
<key> <string>after_script_name</string> </key>
<value> <string>apply_change</string> </value>
</item>
<item>
<key> <string>icon</string> </key>
<key> <string>description</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>apply_production_planning_change</string> </value>
</item>
<item>
<key> <string>permissions</string> </key>
<key> <string>guard</string> </key>
<value>
<tuple>
<string>Modify portal content</string>
</tuple>
<persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent>
</value>
</item>
<item>
<key> <string>portal_type</string> </key>
<value> <string>Action Information</string> </value>
<key> <string>id</string> </key>
<value> <string>apply_change_action</string> </value>
</item>
<item>
<key> <string>new_state_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>priority</string> </key>
<value> <float>10.0</float> </value>
<key> <string>script_name</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Apply Production Planning Changes</string> </value>
<value> <string>Apply Change Action</string> </value>
</item>
<item>
<key> <string>visible</string> </key>
<key> <string>trigger_type</string> </key>
<value> <int>1</int> </value>
</item>
</dictionary>
......@@ -73,26 +61,17 @@
</record>
<record id="2" aka="AAAAAAAAAAI=">
<pickle>
<global name="Expression" module="Products.CMFCore.Expression"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>text</string> </key>
<value> <string>string:${object_url}/ProductionPlanning_applyChangeDialog</string> </value>
</item>
</dictionary>
</pickle>
</record>
<record id="3" aka="AAAAAAAAAAM=">
<pickle>
<global name="Expression" module="Products.CMFCore.Expression"/>
<global name="Guard" module="Products.DCWorkflow.Guard"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>text</string> </key>
<value> <string>python: here.getValidationState() in (\'recorded\')</string> </value>
<key> <string>permissions</string> </key>
<value>
<tuple>
<string>Modify portal content</string>
</tuple>
</value>
</item>
</dictionary>
</pickle>
......
......@@ -2,70 +2,58 @@
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ActionInformation" module="Products.CMFCore.ActionInformation"/>
<global name="TransitionDefinition" module="Products.DCWorkflow.Transitions"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>action</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent>
</value>
<key> <string>actbox_category</string> </key>
<value> <string>workflow</string> </value>
</item>
<item>
<key> <string>categories</string> </key>
<value>
<tuple>
<string>action_type/object_action</string>
</tuple>
</value>
<key> <string>actbox_icon</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>category</string> </key>
<value> <string>object_action</string> </value>
<key> <string>actbox_name</string> </key>
<value> <string>Render Production Planning Status</string> </value>
</item>
<item>
<key> <string>condition</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAM=</string> </persistent>
</value>
<key> <string>actbox_url</string> </key>
<value> <string>%(content_url)s/Base_viewWorkflowActionDialog?workflow_action=render_action</string> </value>
</item>
<item>
<key> <string>description</string> </key>
<value>
<none/>
</value>
<key> <string>after_script_name</string> </key>
<value> <string>render</string> </value>
</item>
<item>
<key> <string>icon</string> </key>
<key> <string>description</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>rerender_production_planning_status</string> </value>
</item>
<item>
<key> <string>permissions</string> </key>
<key> <string>guard</string> </key>
<value>
<tuple>
<string>Modify portal content</string>
</tuple>
<persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent>
</value>
</item>
<item>
<key> <string>portal_type</string> </key>
<value> <string>Action Information</string> </value>
<key> <string>id</string> </key>
<value> <string>render_action</string> </value>
</item>
<item>
<key> <string>new_state_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>priority</string> </key>
<value> <float>5.0</float> </value>
<key> <string>script_name</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Rerender Production Planning Status</string> </value>
<value> <string>Render Action</string> </value>
</item>
<item>
<key> <string>visible</string> </key>
<key> <string>trigger_type</string> </key>
<value> <int>1</int> </value>
</item>
</dictionary>
......@@ -73,26 +61,17 @@
</record>
<record id="2" aka="AAAAAAAAAAI=">
<pickle>
<global name="Expression" module="Products.CMFCore.Expression"/>
<global name="Guard" module="Products.DCWorkflow.Guard"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>text</string> </key>
<value> <string>string:${object_url}/ProductionPlanning_rerenderProductionPlanningStatusDialog</string> </value>
</item>
</dictionary>
</pickle>
</record>
<record id="3" aka="AAAAAAAAAAM=">
<pickle>
<global name="Expression" module="Products.CMFCore.Expression"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>text</string> </key>
<value> <string>python: here.getValidationState() in (\'recorded\')</string> </value>
<key> <string>permissions</string> </key>
<value>
<tuple>
<string>Modify portal content</string>
</tuple>
</value>
</item>
</dictionary>
</pickle>
......
Production Planning Cell | view
Production Planning Module | view
Production Planning | apply_production_planning_change
Production Planning | production_planning_preference
Production Planning | rerender_production_planning_status
Production Planning | view
System Preference | production_planning_preference
\ No newline at end of file
Production Planning | edit_workflow
Production Planning | production_planning_interaction_workflow
Production Planning | production_planning_workflow
\ No newline at end of file
production_planning_interaction_workflow
production_planning_workflow
\ No newline at end of file
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment