[7.0] purchase.order.lines invoiced status set to TRUE even when invoice is in draft state

Bug #1175599 reported by Alex Comba - Agile BG
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Odoo Addons (MOVED TO GITHUB)
Opinion
Undecided
Unassigned

Bug Description

Steps:
====
1. create a new PO
2. set Invoicing Control as "Based on Purchase Order Lines"
3. confirm PO
4. create invoice from menu: Purchase --> Invoice Control --> On Purchase Order Lines

The generated purchase.order.lines changes its invoiced status to TRUE, it should not change the state at all as the invoice is still in draft state. I would expect to get the same behaviour of the sale.order.lines, for this reason I want to point out the bug #1165533 that I also set as duplicate of bug #974074.

I'm using:
====
Ubuntu 12.10, FF 20.0

OpenERP 7.0 with:
 # server revno 4697
 # addons revno 9090
 # web revno 3913

Cheers.

description: updated
description: updated
Revision history for this message
Amit Parik (amit-parik) wrote :

Hello Alex,

I have checked the same thing for both purchase order and sale order. I have created a invoice from sale order line/purchase order line both, When both invoices on draft state then for both invoiced is checked.

I think which is quite fine because If its didn't checked then we can create invoice from that order lines. I think create invoice based on order line then after deleted it. Its bad practice :-o .

Atul is not quite good enough for lp:974074. I think Atul was taking about the sale order and bug reported are talking about the sale order line. The behavior is still same for sale order line when you deleted the draft invoice sale order lines state still on "Invoiced" state. And yes, for sale order you can say that when you paid the invoice then invoiced is checked.

There is one difference for sale order and purchase order which is when you delete the draft invoice for sale order then sale order goes into "Invoice exception" state and from here you can recreate your invoice but on purchase order when you delete the draft invoice , you can create again invoice for same order.

Also the invoice from purchase order is supplier invoice and there is a no sense we have to deleted it because its sent from the supplier.

@Alex: please let me know which kind of behavior you expect, for mean while I am setting this as an "Opinion".

Thank you!

Changed in openobject-addons:
status: New → Opinion
Revision history for this message
Amit Parik (amit-parik) wrote :

Hello Alex,

I have checked on stable version which have different behavior then trunk. On trunk I have checked that same behavior as ago and on stable7 as explained by Atul on lp:974074.

Thank you!

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.