wms icon indicating copy to clipboard operation
wms copied to clipboard

[14.0][FIX] stock_available_to_promise_release: Imp on chained moves cancel

Open TDu opened this issue 1 year ago • 4 comments

On move lines cancelation, the unrelease of the related transfers is being done. And it works well.

But when the module stock_picking_restrict_cancel_with_orig_move from stock-logistics-workflow is installed, they can conflict on the _action_cancel function from stock.move.line.

If the implementation of that function is first being called on this other module, an error will be raised before the unrelease of the moves can be done.

Both modules only depend on stock. This typically happens with chained moves.

The solution to also call the release of operation on the action_cancel of the stock picking, fixes the problem. Altough it is a litlle redundant with the implementation on stock move.

TDu avatar Jan 23 '24 15:01 TDu

Isn't it better to just mark stock_picking_restrict_cancel_with_orig_move as deprecated ?

jbaudoux avatar Jan 24 '24 11:01 jbaudoux

Isn't it better to just mark stock_picking_restrict_cancel_with_orig_move as deprecated ?

I don't know I would think that module has its use as well.

TDu avatar Jan 24 '24 13:01 TDu

There hasn't been any activity on this pull request in the past 4 months, so it has been marked as stale and it will be closed automatically if no further activity occurs in the next 30 days. If you want this PR to never become stale, please ask a PSC member to apply the "no stale" label.

github-actions[bot] avatar Aug 18 '24 12:08 github-actions[bot]

action_cancel on stock picking is calling _action_cancel on stock moves which is already doing the unrelease. So this looks useless. The issue may be on the test in stock move to see if it can be unreleased. There have been improvement in v16 for this.

I does indeed. But the explanation of why is in the commit message...

TDu avatar Aug 21 '24 07:08 TDu