Merge lp:~openerp-dev/openobject-addons/trunk-bug-1187689-ssh into lp:openobject-addons

Proposed by Sunil Sharma(OpenERP)
Status: Needs review
Proposed branch: lp:~openerp-dev/openobject-addons/trunk-bug-1187689-ssh
Merge into: lp:openobject-addons
Diff against target: 25 lines (+2/-2)
2 files modified
purchase/purchase_view.xml (+1/-1)
purchase/wizard/purchase_line_invoice.py (+1/-1)
To merge this branch: bzr merge lp:~openerp-dev/openobject-addons/trunk-bug-1187689-ssh
Reviewer Review Type Date Requested Status
OpenERP Core Team Pending
Review via email: mp+204451@code.launchpad.net

Description of the change

Hello,

       I have fix this bug, cannot recreate the invoice based on purchase order lines when you delete invoice the draft state.

Thanks
Sunil Sharma (SSH)

To post a comment you must log in.
9087. By Niko (OpenERP)

[IMP] Add some video to manisfest ( website, website_blog, website_event, website_ecommerce)

Unmerged revisions

9094. By Sunil Sharma(OpenERP)

[MRG]:lp:openobject-addons

9093. By Sunil Sharma(OpenERP)

[fix]:purchase_line_invoice:recreate the invoice based on purchase order line when you delete invoice in the draft state

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'purchase/purchase_view.xml'
2--- purchase/purchase_view.xml 2014-01-29 19:08:34 +0000
3+++ purchase/purchase_view.xml 2014-02-03 10:59:27 +0000
4@@ -499,7 +499,7 @@
5 <field name="name">On Purchase Order Lines</field>
6 <field name="type">ir.actions.act_window</field>
7 <field name="res_model">purchase.order.line</field>
8- <field name="domain">[('order_id.invoice_method','&lt;&gt;','picking'), ('state','in',('confirmed','done')), ('invoiced', '=', False)]</field>
9+ <field name="domain">[('order_id.invoice_method','&lt;&gt;','picking'), ('state','in',('confirmed','done')), ('invoice_lines','=',False)]</field>
10 <field name="view_type">form</field>
11 <field name="view_mode">tree,form</field>
12 <field name="search_view_id" ref="purchase_order_line_search"/>
13
14=== modified file 'purchase/wizard/purchase_line_invoice.py'
15--- purchase/wizard/purchase_line_invoice.py 2013-10-27 12:31:04 +0000
16+++ purchase/wizard/purchase_line_invoice.py 2014-02-03 10:59:27 +0000
17@@ -93,7 +93,7 @@
18 return inv_id
19
20 for line in purchase_line_obj.browse(cr, uid, record_ids, context=context):
21- if (not line.invoiced) and (line.state not in ('draft', 'cancel')):
22+ if (not line.invoice_lines) and (line.state not in ('draft', 'cancel')) :
23 if not line.partner_id.id in invoices:
24 invoices[line.partner_id.id] = []
25 acc_id = purchase_obj._choose_account_from_po_line(cr, uid, line, context=context)

Subscribers

People subscribed via source and target branches

to all changes: