Merge lp:~vauxoo/addons-vauxoo/7.0-purchase_test_data_check_total-dev_luis into lp:addons-vauxoo/7.0

Proposed by Luis Torres - http://www.vauxoo.com
Status: Merged
Merged at revision: 871
Proposed branch: lp:~vauxoo/addons-vauxoo/7.0-purchase_test_data_check_total-dev_luis
Merge into: lp:addons-vauxoo/7.0
Diff against target: 13 lines (+3/-0)
1 file modified
purchase_test_data_imp/test/purchase_order_product_can_be_purchased.yml (+3/-0)
To merge this branch: bzr merge lp:~vauxoo/addons-vauxoo/7.0-purchase_test_data_check_total-dev_luis
Reviewer Review Type Date Requested Status
Moisés López - http://www.vauxoo.com Pending
Review via email: mp+191315@code.launchpad.net

Description of the change

Se agrego que antes de validar la factura se le coloque la validación del monto total, para que sea posible la validación de esta

To post a comment you must log in.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'purchase_test_data_imp/test/purchase_order_product_can_be_purchased.yml'
2--- purchase_test_data_imp/test/purchase_order_product_can_be_purchased.yml 2013-10-11 21:39:38 +0000
3+++ purchase_test_data_imp/test/purchase_order_product_can_be_purchased.yml 2013-10-15 23:21:02 +0000
4@@ -110,6 +110,9 @@
5
6 #~ Validate invoice for this purchase order
7 if invoice_id:
8+ if invoice_id.get('res_id', False):
9+ cost_invoice = account_invoice_obj.browse(cr, uid, invoice_id.get('res_id'), context=context).amount_total or 0
10+ account_invoice_obj.write(cr, uid, [invoice_id.get('res_id')], {'check_total' : cost_invoice}, context=context)
11 try:
12 wf_service = netsvc.LocalService("workflow")
13 wf_service.trg_validate(uid, 'account.invoice', invoice_id.get('res_id') , 'invoice_open', cr)