Commit 4eda5ae1 authored by Rafael Monnerat's avatar Rafael Monnerat

Fix when the Category is None and Diverge.



git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@10599 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 8b41538e
......@@ -81,25 +81,25 @@ class CategoryDivergenceTester(PropertyDivergenceTester):
delivery_mvt_category_list.sort()
simulation_category_list.sort()
if delivery_mvt_category_list != simulation_category_list:
if delivery_mvt_category_list != simulation_category_list:
delivery_mvt_category_title_list = []
for mvt_category in delivery_mvt_category_list:
category_value = delivery_mvt.resolveCategory(mvt_category)
if category_value.getPortalType() == 'Category':
delivery_mvt_category_title_list.append(category_value.getTranslatedTitle())
else:
delivery_mvt_category_title_list.append(category_value.getTitle())
if category_value is not None:
if category_value.getPortalType() == 'Category':
delivery_mvt_category_title_list.append(category_value.getTranslatedTitle())
else:
delivery_mvt_category_title_list.append(category_value.getTitle())
simulation_category_title_list = []
for mvt_category in simulation_category_list:
category_value = delivery_mvt.resolveCategory(mvt_category)
if category_value.getPortalType() == 'Category':
simulation_category_title_list.append(category_value.getTranslatedTitle())
else:
simulation_category_title_list.append(category_value.getTitle())
if category_value is not None:
if category_value.getPortalType() == 'Category':
simulation_category_title_list.append(category_value.getTranslatedTitle())
else:
simulation_category_title_list.append(category_value.getTitle())
delivery_mvt_property = ' , '.join(delivery_mvt_category_title_list)
simulation_mvt_property = ' , '.join(simulation_category_title_list)
......
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