Commit d6800917 authored by Romain Courteaud's avatar Romain Courteaud

slapos_accounting: XXX support Open Order Cell

parent 825a7b46
......@@ -46,8 +46,15 @@ if open_sale_order.getValidationState() == 'validated':
person = open_sale_order.getDestinationDecisionValue(portal_type="Person")
if person is not None:
for open_order_line in open_sale_order.contentValues(
open_order_path_list = []
for line in open_sale_order.contentValues(
portal_type='Open Sale Order Line'):
if line.hasCellContent(base_id='path'):
open_order_path_list.extend(line.getCellValueList(base_id='path'))
else:
open_order_path_list.append(line)
for open_order_line in open_order_path_list:
current_start_date = open_order_line.getStartDate()
current_stop_date = open_order_line.getStopDate()
......@@ -76,8 +83,8 @@ if open_sale_order.getValidationState() == 'validated':
open_order_line.edit(
stop_date=stop_date,
activate_kw=activate_kw)
storeWorkflowComment(open_order_line,
'Stop date updated to %s' % stop_date)
#storeWorkflowComment(open_order_line,
# 'Stop date updated to %s' % stop_date)
if instance_tree.getSlapState() == 'destroy_requested':
# Line should be deleted
......
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