Contributors mailing list archives

contributors@odoo-community.org

Browse archives

Avatar

Re: Sale Order packaging without specify products

by
Francesco Ballerini
- 13/12/2023 12:28:27
Update 2

From what I can understand the management of carrier deliveries with packages is super complex either from a functional and developing point of view as the delivery package definition is a bit clunky by itself.

I finally understood that you still need to you need to define a "delivery package" associated with carrier, because dimension and weight data cannot be not taken from package directly. They are taken instead from each "delivery package" linked with a picking "package".. but you still have to define both package and delivery package to access packaging data because picking structure will be like 

picking > multiple packages (stock.quant.packages) > every package has packaging_id (product.packaging) (which is designed to be product specific unless you define it as a "delivery packages", aka a "product.packaging" object without product id 😵‍💫 )

If this is correct and someone has taken the trouble to read until this point, maybe you could also confirm that it is possible to speed up (a lot) the whole process by generating multiple "packaging" objects from a sale order and automatically recreate the structure

> picking > packages > delivery packages 

by automatically generating 

- 1 package containing all products and 
- n° fake packages (containing no products, or a dummy product..) 
-  link every package to one of previously defined delivery packages (this workflow can be activated, for example, by clicking put in pack if a custom option is selected on picking.. to avoid conflicts with normal workflows)

Of course this is possible only if you manage the whole delivery in a single picking, like we do.
Seems like it's going to be more challenging than I thought but it seems like it can be done, unfortunately I don't think that we already have designed a workflow for this situation.

Francesco Ballerini

Il giorno mar 12 dic 2023 alle ore 20:29 Francesco Ballerini <francescobl.lavoro@gmail.com> ha scritto:
Update: 

Forgive me I have mistaken "packaging" and "package" business logic.

I think that if I want to provide this feature and keep a decent level of scalability/extensibility I need to:

1 - make possible for backend user to generate n° stock.quant.package objects from a sale order (simply adding a one2many relation with stock.quant.package, in Sale Order)

2 - use stock_quant_package_dimension to allow setting dimensions and automatic volume calculation from the Sale Order as well

3 - when the outgoing picking is generated by confirming order (as I previously said we have a really simplified picking process but this part will still probably be a bit tricky in case of picking and/or order cancel)
   3a) all sale order packages will be automatically attached to the outgoing picking by setting them on "picking.package_ids"
   3b) all the products will automatically be put in a single pack, the other packs will be "fake packs" in the sense that they will not store any products but still has dimensions

This will not provide huge advantages by itself, but definitely better than having separate model to manage "shipping packs" delivery rate and tracking. Tracking will not be really accurate as it doesn't target products, but the rate we need to get is always based on taxable weight, so it should be a decent solution. I'm still not sure if it's worth to manage "package_id" on stock.quant.package, if I am not wrong that's needed in order to print shipping label.

If you have any kind of suggestions that comes from experience in developing similar workflows (TLDR generating packages from sale order without having to specify the pack content) it will be helpful for sure.

Thanks,

Francesco Ballerini


Privo di virus.www.avast.com

Il giorno dom 10 dic 2023 alle ore 23:27 Francesco Ballerini <francescobl.lavoro@gmail.com> ha scritto:
Hello, 

TLTR 

I am searching (for Odoo v14) a module which add a one2many on sale order, linking SO with multiple product packaging objects.

More details

Long time ago I've been asked to make implementations for a workflow when we need to define product packaging objects in a Sale Order so that we can store packaging dimensions, compute the proper rate and send some info to the carrier. 

We don't want to define any package on sale order line, or link specific products to a packaging: we just need to define an X number of packaging objects related to the sale order. 
Also, we want to do it from sale order because we adjust product lines accordingly to the "on hand quantity" directly on sale order, before picking generation, plus we don't manage backorder in the classic Odoo way, so picking is basically only "validate" for us.

I already have developed the workflow, but it's not properly integrated with some Odoo modules/models so I want to make some refactors and possibly integrate it with some OCA modules like product_packaging_dimension to use already implemented features when possible.

But I did not find anything covering this, possibly did I miss it?

Thanks

Francesco Ballerini

Privo di virus.www.avast.com

Reference