Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[15.0][MIG] stock_auto_move to v15 #1467

Merged
merged 35 commits into from
Mar 9, 2024

Conversation

hbrunn
Copy link
Member

@hbrunn hbrunn commented Dec 29, 2023

No description provided.

npiganeau and others added 30 commits December 29, 2023 11:10
* The `_apply` method should not be overridden. In case of three step
operation with the last step set to auto move. The override of the
`_apply` method was causing the second move to be automatic as well.

**Use case**: doing a reception operation in two steps where the moves on
the second step are set to be automatic (using the push rule in this
case), and the reception is done partially.
**Expected Result**: When doing a first reception step partially a back
order is created, and we expect the second step to have a back order for
the remaining qty as well.
**Current behavior**: The correct move is processed automatically but no
backorder is created. The reason for that behavior is we processing the
move directly (i.e calling `action_done` of the `stock.move`) without
going through the normal process (i.e processing the second step
picking).
**The solution to the problem**: The processing the of the automatic
stock move should follow the same behavior as done from the user interface.
I've added a new function in `stock.picking` model called
`_transfer_pickings_with_auto_move` to simulate the same behavior this
function is called inside the `action_assign` of the stock move instead
of calling the `action_done` of the move.
As in v>=12, stock.location.path and procurement.rule have been merged
into stock.rule, use the same field name.
If moves were created with a particular procurment group, don't
change it to automatic one. Do it only if it's void.
As unit of measure can be a different multiple than reference,
use product_uom_qty instead.
If in a first picking, we transfer partially one quantity and
say 'No backorder', the destination move should be split and
cancelled for the remaining quantities if 'propagate_cancel'
is set.
… (take2)

In case of partial flows with move cancel and mixed moves (auto and manual),
we need to create a backorder for manual quantities to not get a picking
with moves with mixed states (done, cancel, assigned).

We remove code that is never called on picking side
Currently translated at 100.0% (12 of 12 strings)

Translation: stock-logistics-workflow-14.0/stock-logistics-workflow-14.0-stock_auto_move
Translate-URL: https://translation.odoo-community.org/projects/stock-logistics-workflow-14-0/stock-logistics-workflow-14-0-stock_auto_move/ca/
OCA-git-bot and others added 5 commits December 29, 2023 11:10
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: stock-logistics-workflow-14.0/stock-logistics-workflow-14.0-stock_auto_move
Translate-URL: https://translation.odoo-community.org/projects/stock-logistics-workflow-14-0/stock-logistics-workflow-14-0-stock_auto_move/
Currently translated at 100.0% (11 of 11 strings)

Translation: stock-logistics-workflow-14.0/stock-logistics-workflow-14.0-stock_auto_move
Translate-URL: https://translation.odoo-community.org/projects/stock-logistics-workflow-14-0/stock-logistics-workflow-14-0-stock_auto_move/it/
@hbrunn
Copy link
Member Author

hbrunn commented Dec 29, 2023

/ocabot migration stock_auto_move

Copy link
Contributor

@AungKoKoLin1997 AungKoKoLin1997 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@OCA-git-bot
Copy link
Contributor

This PR has the approved label and has been created more than 5 days ago. It should therefore be ready to merge by a maintainer (or a PSC member if the concerned addon has no declared maintainer). 🤖

@dreispt
Copy link
Member

dreispt commented Mar 9, 2024

/ocabot merge nobump

@OCA-git-bot
Copy link
Contributor

Hey, thanks for contributing! Proceeding to merge this for you.
Prepared branch 15.0-ocabot-merge-pr-1467-by-dreispt-bump-nobump, awaiting test results.

OCA-git-bot added a commit that referenced this pull request Mar 9, 2024
Signed-off-by dreispt
@OCA-git-bot
Copy link
Contributor

It looks like something changed on 15.0 in the meantime.
Let me try again (no action is required from you).
Prepared branch 15.0-ocabot-merge-pr-1467-by-dreispt-bump-nobump, awaiting test results.

OCA-git-bot added a commit that referenced this pull request Mar 9, 2024
Signed-off-by dreispt
@OCA-git-bot
Copy link
Contributor

It looks like something changed on 15.0 in the meantime.
Let me try again (no action is required from you).
Prepared branch 15.0-ocabot-merge-pr-1467-by-dreispt-bump-nobump, awaiting test results.

@OCA-git-bot OCA-git-bot merged commit 5e39665 into OCA:15.0 Mar 9, 2024
6 of 7 checks passed
@OCA-git-bot
Copy link
Contributor

Congratulations, your PR was merged at e073289. Thanks a lot for contributing to OCA. ❤️

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.