Cancelling sale order should affect Procurements,production orders

Bug #588220 reported by David Janssens
30
This bug affects 5 people
Affects Status Importance Assigned to Milestone
Odoo Addons (MOVED TO GITHUB)
Fix Released
Medium
OpenERP R&D Addons Team 3

Bug Description

When canceling sale orders after they are confirmed, the created procurements are not canceled (still 'confirmed' for example).

Related branches

Revision history for this message
Vinay Rana (OpenERP) (vra-openerp) wrote :

Hello David and Numérigraphe,

Can you please check the attached patch and notify me?

Thanks.

Changed in openobject-addons:
status: New → In Progress
summary: - cancelling sale order
+ Cancelling sale order should affect Procurements,production orders
Changed in openobject-addons:
milestone: none → 6.0
status: In Progress → Confirmed
Revision history for this message
Santi Argüeso(Pexego) (santiago-pexego) wrote :

I think this minimal patch is not the solution at all.
You can not simply change the state of the procurement. You have to cancel the related movements and picking an trigger the workflow of the procurement NOT change the state.

If your procurement type is make to order, if there are related productions or purchase orders you must cancel them if they are not in progress and the procurement generated form production order have to be cancelled also.

I know this is not easy but i think that is the correct way for working

Moreover, if your procurement is make to stock and it has launched an orderpoint i think it must be undo so you don need those products yet

Changed in openobject-addons:
assignee: nobody → OpenERP R&D Addons Team 3 (openerp-dev-addons3)
importance: Undecided → Medium
milestone: 6.0 → none
status: Confirmed → Triaged
Revision history for this message
qdp (OpenERP) (qdp) wrote :

what we gonna do is: we call the method cancel of the procurement workflow so that if it can cancel it will do it, but we don't write the state (and if it cannot cancel itself then nevermind).

Revision history for this message
Numérigraphe (numerigraphe) wrote :

I suppose that's right, but I humbly admit the manufacturing experts are more qualified - I'm subscribing them.
Lionel.

Revision history for this message
Numérigraphe (numerigraphe) wrote :

Also, please make sure that a second procurement is not created whenever a canceled order is confirmed again, and the initial procurement couldn't be canceled.
Lionel Sausin.

Revision history for this message
Joël Grand-Guillaume @ camptocamp (jgrandguillaume-c2c) wrote :

Hi,

I agree with Quentin (qdp).

Regards,

Joël

Changed in openobject-addons:
status: Triaged → In Progress
qdp (OpenERP) (qdp)
Changed in openobject-addons:
milestone: none → 6.0-rc2
Revision history for this message
Meera Trambadia (OpenERP) (mtr-openerp) wrote :

Hello David Janssens,

Its fixed in https://code.launchpad.net/~openerp-dev/openobject-addons/trunk-dev-addons3 branch.
Revision ID: mra@mra-laptop-20101217114853-kukmk0h8b1yes89c
Revision no: 4731

Thanks
mtr

Changed in openobject-addons:
status: In Progress → Fix Released
Revision history for this message
Meera Trambadia (OpenERP) (mtr-openerp) wrote :

Hello Ferdinand,

I have checked sales manager dashboard - sales by month.
It gives the sale order lines which are in 'manual','progress','done' state which belongs to the current fiscal year.Now the buttons are working in the graph view.

@AMP:I have checked "Sales Analysis" report's no of Lines in Group by months gives the correct values.

Its fixed in https://code.launchpad.net/~openerp-commiter/openobject-addons/trunk-dev-addons3-mtr1 branch.
Revision ID: mtr@mtr-20101228115016-d6sv8evl5b6mbmsh
Revision no: 4665

Thanks
mtr

Revision history for this message
Meera Trambadia (OpenERP) (mtr-openerp) wrote :
Revision history for this message
Joël Grand-Guillaume @ camptocamp (jgrandguillaume-c2c) wrote :

Dear all,

I just figure out that this bug affect the 5.0 as well, but you didn't back port the fix !!

To reproduce:

1 ) Create an SO with MTO product/Buy
2) Confirm SO
3) Cancel Picking + Cancel SO
4) Run Scheduler

=> The SO is reseted to Shipping Exception... That's not what we want.

We except the SO to cancel the related procurement as you made it for 6.0...

I post the patch => tested in production on my side.

Please apply ASAP to last 5.0 stable.

Regards,

Joël

Changed in openobject-addons:
status: Fix Released → New
Revision history for this message
Olivier Dony (Odoo) (odo-openerp) wrote :

On 09/05/2011 03:43 PM, Joël Grand-Guillaume @ CampToCamp wrote:
> Please apply ASAP to last 5.0 stable.

Hi Joel,

Thanks for the feedback and for testing the original patch on 5.0!

However, it is important to stick to our bug management policy. Let me explain: the current bug management policy (since November 2010) specifies that there is no automatic backport of bugfixes, expect for a few specific cases (High importance bugs and security issues). Backports must be requested and justified via OPW/OpenERP Enterprise channel.
The many reasons for this policy have been explained and can be found in our documentation[1]. The documentation also explains what the different bug Importance values mean[2].

As a result, the bug should be kept Fix Released for now. If a backport is requested via OPW, a new "affects 5.0" will be added by the OPW team and assigned to themselves to reflect this.

Thanks for your understanding and cooperation!

PS: As a member of OpenERP Drivers, it is doubly important for you to be aware of this

[1] http://bit.ly/openerp-bug-policy
[2] http://bit.ly/openerp-bug-process

Changed in openobject-addons:
milestone: 6.0-rc2 → none
status: New → Fix Released
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.