Skip to content

Commit

Permalink
Set price of agreement when sourcing with a framework
Browse files Browse the repository at this point in the history
  • Loading branch information
yvaucher authored and gurneyalex committed Nov 14, 2014
1 parent c5886fd commit 15e8b69
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions framework_agreement_sourcing/model/logistic_requisition.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,11 @@ def _prepare_line_source(self, cr, uid, line,
if not agreement.product_id.id == line.product_id.id:
raise ValueError(
"Product mismatch for agreement and requisition line")
res['framework_agreement_id'] = agreement.id
res['procurement_method'] = 'fw_agreement'
res.update({
'framework_agreement_id': agreement.id,
'procurement_method': 'fw_agreement',
'unit_cost': agreement.get_price(qty, line.currency_id),
})
else:
if line.product_id.type == 'product':
res['procurement_method'] = 'procurement'
Expand Down

0 comments on commit 15e8b69

Please sign in to comment.