diff --git a/bt5/erp5_budget/SkinTemplateItem/portal_skins/erp5_budget/BudgetCell_getEngagedBudget.xml b/bt5/erp5_budget/SkinTemplateItem/portal_skins/erp5_budget/BudgetCell_getEngagedBudget.xml
index dece48086b4b3e1cd93a966050706473e35a6e38..5ea5cc9056e82092b85d461ce1604729645875ef 100644
--- a/bt5/erp5_budget/SkinTemplateItem/portal_skins/erp5_budget/BudgetCell_getEngagedBudget.xml
+++ b/bt5/erp5_budget/SkinTemplateItem/portal_skins/erp5_budget/BudgetCell_getEngagedBudget.xml
@@ -50,10 +50,12 @@
         </item>
         <item>
             <key> <string>_body</string> </key>
-            <value> <string>kw = dict()\n
-budget = context.getParentValue().getParentValue()\n
+            <value> <string>line = context.getParentValue()\n
+budget = line.getParentValue()\n
 budget_model = budget.getSpecialiseValue(portal_type=\'Budget Model\')\n
-if budget_model is not None:\n
+if budget_model is None:\n
+  kw = {}\n
+else:\n
   kw = budget_model.getInventoryQueryDict(context)\n
 \n
 if from_date:\n
@@ -61,14 +63,16 @@ if from_date:\n
 if at_date:\n
   kw[\'at_date\'] = at_date\n
 \n
-kw.setdefault(\'explanation_simulation_state\', context.getPortalReservedInventoryStateList() \\\n
-                                            + context.getPortalCurrentInventoryStateList() \\\n
-                                            + context.getPortalTransitInventoryStateList())\n
+portal = budget.getPortalObject()\n
+kw.setdefault(\'stock_explanation_simulation_state\',\n
+              portal.getPortalReservedInventoryStateList() +\n
+              portal.getPortalCurrentInventoryStateList() +\n
+              portal.getPortalTransitInventoryStateList())\n
 \n
 # XXX use getBudgetConsumptionMethod ?\n
 if src__:\n
-  return \'-- %s\\n%s\' % (kw, context.portal_simulation.getCurrentInventoryAssetPrice(src__=src__, **kw))\n
-return (context.portal_simulation.getInventoryAssetPrice(**kw) or 0) * context.getParentValue().BudgetLine_getConsumptionSign()\n
+  return \'-- %s\\n%s\' % (kw, portal.portal_simulation.getCurrentInventoryAssetPrice(src__=src__, **kw))\n
+return (portal.portal_simulation.getInventoryAssetPrice(**kw) or 0) * line.BudgetLine_getConsumptionSign()\n
 </string> </value>
         </item>
         <item>
diff --git a/bt5/erp5_budget/bt/revision b/bt5/erp5_budget/bt/revision
index e8930b6df94cf1501f2663918ee3ceb4d40c709a..55f04f2ae2c5d17c6b2a2616018b96f869677221 100644
--- a/bt5/erp5_budget/bt/revision
+++ b/bt5/erp5_budget/bt/revision
@@ -1 +1 @@
-364
\ No newline at end of file
+365
\ No newline at end of file