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

[14.0] [ADD] delivery_roulier_picking_batch #904

Open
wants to merge 2 commits into
base: 14.0
Choose a base branch
from

Conversation

paradoxxxzero
Copy link

This module allows to generate a unique delivery label/tracking for a whole batch of
pickings.

The batch pickings operations will be grouped in a single delivery package if they are
not already in a delivery package. In case of a batch with multiple packages, a label
per package will be created.

This module is only compatible with delivery_roulier carriers.

@paradoxxxzero paradoxxxzero force-pushed the 14.0-add-delivery_roulier_picking_batch branch 2 times, most recently from 6813351 to 1c2e92d Compare November 18, 2024 11:12
Comment on lines +34 to +45
for package in packages:
package_pickings = (
self.env["stock.move.line"]
.search(
[
"|",
("result_package_id", "=", package.id),
("package_id", "=", package.id),
]
)
.mapped("picking_id")
)
Copy link
Member

Choose a reason for hiding this comment

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

We can make it simplier.
We should just check that all picking of the batch have the same delivery address

Copy link
Author

Choose a reason for hiding this comment

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

I'd rather work at package level since it's them that will be sent and you may want to send 2 packages from different pickings to different addresses.

Copy link
Member

Choose a reason for hiding this comment

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

In a functional point of view. When you use the batch delivery carrier you want to prepare all the picking for the same address, if user can mix, it will be a nightmare ;).
I am in favors of forcing to set a partner_id on the stock.picking.batch so it will be more understandable for the customer

@paradoxxxzero paradoxxxzero force-pushed the 14.0-add-delivery_roulier_picking_batch branch from 1c2e92d to 28dddcb Compare November 28, 2024 10:54
@sebastienbeau sebastienbeau force-pushed the 14.0-add-delivery_roulier_picking_batch branch from 0240730 to f9118c1 Compare November 28, 2024 22:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants