Commit 0975765a authored by iv's avatar iv

ERP5Workflow: revert changes on automatic_update_property

+ rename update_always to automatic_update as is should be
parent 315c5f33
......@@ -27,7 +27,7 @@
<key> <string>categories</string> </key>
<value>
<tuple>
<string>elementary_type/int</string>
<string>elementary_type/boolean</string>
</tuple>
</value>
</item>
......@@ -47,10 +47,6 @@
<key> <string>portal_type</string> </key>
<value> <string>Standard Property</string> </value>
</item>
<item>
<key> <string>storage_id</string> </key>
<value> <string>update_always</string> </value>
</item>
</dictionary>
</pickle>
</record>
......
......@@ -469,7 +469,7 @@ class InteractionWorkflow(IdAsReferenceMixin("", "prefix"), Workflow):
variable_reference_list = []
variable_list = self.objectValues(portal_type='Variable')
variable_prop_id_to_show = ['description', 'variable_expression',
'for_catalog', 'for_status', 'update_always']
'for_catalog', 'for_status', 'automatic_update']
for vdef in variable_list:
variable_reference_list.append(vdef.getReference())
variables = SubElement(interaction_workflow, 'variables', attrib=dict(variable_list=str(variable_reference_list),
......@@ -478,7 +478,7 @@ class InteractionWorkflow(IdAsReferenceMixin("", "prefix"), Workflow):
variable = SubElement(variables, 'variable', attrib=dict(reference=vdef.getReference(),
portal_type=vdef.getPortalType()))
for property_id in sorted(variable_prop_id_to_show):
if property_id == 'update_always':
if property_id == 'automatic_update':
property_value = vdef.getAutomaticUpdate()
sub_object = SubElement(variable, property_id, attrib=dict(type='int'))
elif property_id == 'variable_value':
......
......@@ -50,7 +50,7 @@ class Variable(IdAsReferenceMixin("variable_", "prefix"), XMLObject):
for_status = 1
variable_value = ''
variable_expression = None # Overrides variable_value if set
update_always = 1
automatic_update = 1
default_reference = ''
# Declarative security
security = ClassSecurityInfo()
......
......@@ -901,7 +901,7 @@ class Workflow(IdAsReferenceMixin("", "prefix"), XMLObject):
variable_reference_list = []
variable_list = self.objectValues(portal_type='Variable')
variable_prop_id_to_show = ['description', 'variable_expression',
'for_catalog', 'for_status', 'update_always']
'for_catalog', 'for_status', 'automatic_update']
for vdef in variable_list:
variable_reference_list.append(vdef.getReference())
variables = SubElement(workflow, 'variables', attrib=dict(variable_list=str(variable_reference_list),
......@@ -910,7 +910,7 @@ class Workflow(IdAsReferenceMixin("", "prefix"), XMLObject):
variable = SubElement(variables, 'variable', attrib=dict(reference=vdef.getReference(),
portal_type=vdef.getPortalType()))
for property_id in sorted(variable_prop_id_to_show):
if property_id == 'update_always':
if property_id == 'automatic_update':
property_value = vdef.getAutomaticUpdate()
sub_object = SubElement(variable, property_id, attrib=dict(type='int'))
elif property_id == 'variable_value':
......
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