Commit 9807970c authored by Jérome Perrin's avatar Jérome Perrin

update TitleMovementGroup to support the fact that title has a default value

(the id)


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@29108 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent df6c024e
......@@ -46,11 +46,11 @@ class TitleMovementGroup(MovementGroup):
return True, property_dict
def _getTitle(self,movement):
order_value = movement.getOrderValue()
title = ''
if order_value is not None:
if "Line" in order_value.getPortalType():
title = order_value.getTitle()
elif "Cell" in order_value.getPortalType():
title = order_value.getParentValue().getTitle()
order_movement_value = movement.getOrderValue()
title = None
if order_movement_value is not None:
if 'Cell' in order_movement_value.getPortalType():
order_movement_value = order_movement_value.getParentValue()
if order_movement_value.hasTitle():
title = order_movement_value.getTitle()
return title
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