Commit 193e8121 authored by Jérome Perrin's avatar Jérome Perrin

use getParentValue instead of getParent


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@9010 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent e8f935a4
......@@ -69,7 +69,7 @@
<item>
<key> <string>_body</string> </key>
<value> <string>line = brain.getObject()\n
return "%s/view" % line.getParent().absolute_url()\n
return "%s/view" % line.getParentValue().absolute_url()\n
</string> </value>
</item>
<item>
......
......@@ -81,11 +81,11 @@ LOG("movements = %s"%movement_list)\n
deliveries_keys = {}\n
for movement in movement_list :\n
# in case of invoice rule (ie. starting from Invoice)\n
line = movement.getParent().getParent().getOrderValue()\n
line = movement.getParentValue().getParentValue().getOrderValue()\n
\n
if line is None : \n
# in case of invoicing rule (ie. starting from Order)\n
line = movement.getParent().getParent().getDeliveryValue()\n
line = movement.getParentValue().getParentValue().getDeliveryValue()\n
\n
deliveries_keys[line.getExplanationValue()] = 1\n
\n
......
......@@ -96,8 +96,8 @@ LOG("simulation_movement_list %s " % simulation_movement_list)\n
causality_value_set = {}\n
for simulation_movement in simulation_movement_list :\n
LOG("simulation_movement %s " % simulation_movement.getPath())\n
if simulation_movement.getParent() != simulation_movement.getRootAppliedRule():\n
explanation_value = simulation_movement.getParent().getParent().getExplanationValue()\n
if simulation_movement.getParentValue() != simulation_movement.getRootAppliedRule():\n
explanation_value = simulation_movement.getParentValue().getValueParent().getExplanationValue()\n
else :\n
explanation_value = simulation_movement.getExplanationValue()\n
if explanation_value is not None :\n
......
......@@ -69,9 +69,9 @@
<item>
<key> <string>_body</string> </key>
<value> <string># XXX Set a resource for the supply line inside a resource\n
if context.getParent().getPortalType() in \\\n
if context.getParentValue().getPortalType() in \\\n
context.getPortalResourceTypeList():\n
context.setResourceValue(context.getParent())\n
context.setResourceValue(context.getParentValue())\n
# Predicate ?\n
context.setMappedValuePropertyList([\n
\'base_price\', \'additional_price\',\n
......
......@@ -69,9 +69,9 @@
<item>
<key> <string>_body</string> </key>
<value> <string># XXX Set a resource for the supply line inside a resource\n
if context.getParent().getPortalType() in \\\n
if context.getParentValue().getPortalType() in \\\n
context.getPortalResourceTypeList():\n
context.setResourceValue(context.getParent())\n
context.setResourceValue(context.getParentValue())\n
# Predicate ?\n
context.setMappedValuePropertyList([\n
\'base_price\', \'additional_price\',\n
......
......@@ -97,9 +97,9 @@ else:\n
selected_base_category_list = context.getPVariationBaseCategoryList()\n
if selected_base_category_list == []:\n
# XXX Compatibility...\n
if context.getParent().getPortalType() in \\\n
if context.getParentValue().getPortalType() in \\\n
context.getPortalResourceTypeList():\n
selected_base_category_list = context.getParent().\\\n
selected_base_category_list = context.getParentValue().\\\n
getPVariationBaseCategoryList()\n
else:\n
property_id = \'%s_variation_base_category_list\' % base_id[len(\'path_\'):]\n
......
......@@ -69,9 +69,9 @@
<item>
<key> <string>_body</string> </key>
<value> <string># XXX Set a resource for the supply line inside a resource\n
if context.getParent().getPortalType() in \\\n
if context.getParentValue().getPortalType() in \\\n
context.getPortalResourceTypeList():\n
context.setResourceValue(context.getParent())\n
context.setResourceValue(context.getParentValue())\n
# Predicate ?\n
context.setMappedValuePropertyList([\n
\'base_price\', \'additional_price\',\n
......
......@@ -69,7 +69,7 @@
<item>
<key> <string>_body</string> </key>
<value> <string># trigger the simulation update from the parent line\n
sci[\'object\'].getParent().edit()\n
sci[\'object\'].getParentValue().edit()\n
</string> </value>
</item>
<item>
......
......@@ -69,7 +69,7 @@
<item>
<key> <string>_body</string> </key>
<value> <string># trigger the simulation update from the parent invoice\n
sci[\'object\'].getParent().edit()\n
sci[\'object\'].getParentValue().edit()\n
</string> </value>
</item>
<item>
......
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