[6.0][6.1][7.0][trunk][sale] Sale exception: Recreate Packing duplicates confirmed moves

Bug #947838 reported by Numérigraphe on 2012-03-06
24
This bug affects 3 people
Affects Status Importance Assigned to Milestone
Odoo Addons (MOVED TO GITHUB)
Confirmed
Medium
OpenERP R&D Addons Team 3
OpenERP Community Backports (Addons)
Status tracked in 7.0
6.1
Low
Yann Papouin
7.0
Low
Unassigned

Bug Description

When delivering a sale order:
- confirm the picking
- cancel a single stock move
=> the sale order eventually goes into "exception" state (normal: 1 move canceled = 1 procurement canceled = sale exception).
But when you click "recreate packing", a new picking will be created with :
- a new version of the canceled move
- AND a new version of the confirmed moves
The confirmed moves and the related procurements get duplicated, resulting in goods being purchased/manufactured twice, and sent twice to the customer.
Lionel Sausin.

Related branches

description: updated
summary: - Sale exception: recreate packing ignores confirmed moves
+ Sale exception: recreate packing duplicates confirmed moves

Hello,

Would you please check this also lp : 897082

Thanks!

Changed in openobject-addons:
status: New → Confirmed
importance: Undecided → Medium
assignee: nobody → OpenERP R&D Addons Team 3 (openerp-dev-addons3)
tags: added: shipping-exception
Changed in openobject-addons:
assignee: OpenERP R&D Addons Team 3 (openerp-dev-addons3) → OpenERP Publisher's Warranty Team (openerp-opw)
tags: added: maintenance
removed: shipping-exception
tags: added: shipping-exception
Numérigraphe (numerigraphe) wrote :

Removing assignment because the maintenance team refused to get in charge of this bug.
Lionel.

Changed in openobject-addons:
assignee: OpenERP Publisher's Warranty Team (openerp-opw) → nobody
Amit Parik (amit-parik) on 2012-10-23
tags: removed: maintenance
Amit Parik (amit-parik) wrote :

Hello,

"Shipping Exception" not available on trunk anymore, So this issue doesn't affect on trunk.

So I am closing this issue.

Thank you!

Changed in openobject-addons:
status: Confirmed → Invalid
importance: Medium → Undecided

Hello Lionel,

I have analysed your bug and here is my conclusion.

This seems like more a generic business process where you can only see the 'remaining' moves to be created IF and Only IF the ancestor Delivery/picking is 'Done'. Making it easy, if the previous order's move is not done, recreation of picking is going to create new move!

In our case, what we do is, we cancel a move (out of 2). Now the Original picking has one move cancelled, and another in any state other than cancel or done.

When you "recreate packing" your sale order it checks the state of all line's procurements one by one. In our case, system does have an older picking which is not yet done, so system tries to recreate the picking with same moves(2).

So, if you have completed(set done) your original picking, you would get only one move in the new picking getting generated from recreation.

Hope this clears some view.

Kindly correct my analysis if I have gone wrong.

Regards,
Anil,
Serpent Consulting Services.

Lionel,

If you wish to get it corrected, here we present a solution attached.

Will await a Feedback.

Thanks.

Lionel,

Would you mind looking at the patch please?

Thanks.

Numérigraphe (numerigraphe) wrote :

Dear Anil Kesariya,
Thanks for your patch.
I find it a bit hard to read with all the double-negations. Do you intend to skip all Sale Order Lines that have Stock Moves unless one was canceled?
If so, what about the attached patch?
Lionel

Lionel,

Absolutely yes, you caught it right.

Your patch seem better!

Thanks.

Numérigraphe (numerigraphe) wrote :

Re-opening as Opinion. don't know what more we can do about this.
Serpent Consulting Services, will you make a merge proposal?
Lionel.

Changed in openobject-addons:
status: Invalid → Opinion

Lionel,

Your patch is final, so we propose you do it.

Thanks.

Changed in ocb-addons:
status: New → Confirmed
summary: - Sale exception: recreate packing duplicates confirmed moves
+ [NEW] [6.1][7.0][trunk][sale] Sale exception: Recreate Packing
+ duplicates confirmed moves
summary: - [NEW] [6.1][7.0][trunk][sale] Sale exception: Recreate Packing
- duplicates confirmed moves
+ [6.1][7.0][trunk][sale] Sale exception: Recreate Packing duplicates
+ confirmed moves
summary: - [6.1][7.0][trunk][sale] Sale exception: Recreate Packing duplicates
+ [6.0][6.1][7.0][trunk][sale] Sale exception: Recreate Packing duplicates
confirmed moves
Changed in openobject-addons:
status: Opinion → Confirmed
Changed in ocb-addons:
importance: Undecided → Low
status: Confirmed → Fix Committed
Amit Parik (amit-parik) on 2013-11-13
Changed in openobject-addons:
assignee: nobody → OpenERP R&D Addons Team 3 (openerp-dev-addons3)
importance: Undecided → Medium
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Duplicates of this bug

Other bug subscribers