Delivery Estimated Package Quantity By Weight
delivery_estimated_package_quantity_by_weight · OCA/delivery-carrier
-
Security25/25No findings
-
Activity20/25Last human commit 11 months ago
-
Required by5/250 modules depend on it
-
Maturity18/25In 3 Odoo series since 16.0
Heuristic over the facts below, not an audit · How it's computed
Description
This module computes the amount of packages a picking out should have depending on the weight of the products and the limit fixed by the carrier. It's fully independent of the delivery_package_number module.
A warning is given if the number of packages for the picking out is above what is considered as the theoretical number of packages for this picking and the chosen carrier. The goal is to minimize the number of packages billed by the carrier.
The chosen strategy for the theoretical number of packages is as follow:
- Split the product_weights into as many items as we have
- Try to fit the heaviest product with the lightest. If it does not work then the heaviest should have a box for itself
- While the weight of products does not exceed the limit, continue adding products in the same package
Dependencies
Code analysis
Extracted from the source by best-effort static analysis (no code is executed); details may be incomplete.
Views touched 3
| XML ID | Name | Model | Type | Status |
|---|---|---|---|---|
delivery_carrier_form_view |
delivery.carrier.form (in delivery_number_package_theoretical) | delivery.carrier | form | Inherits delivery.view_delivery_carrier_form |
delivery_carrier_tree_view |
delivery.carrier.tree (in delivery_number_package_theoretical) | delivery.carrier | tree | Inherits delivery.view_delivery_carrier_tree |
stock_picking_form_view |
stock.picking.form (in delivery_number_package_theoretical) | stock.picking | form | Inherits stock.view_picking_form |
HTTP endpoints 0
No HTTP endpoints found for this module.
Models touched 2
-
maximum_weight_per_packageFloatstring='Maximum weight per package' -
weight_uom_nameCharcompute='_compute_weight_uom_name'string='Weight unit of measure label'
No public methods.
-
is_number_of_packages_outrangedBooleancompute='_compute_is_number_of_packages_outranged' args: 'Too many packages compared to the theoretical number' -
is_number_of_packages_visibleBooleancompute='_compute_is_number_of_packages_visible' args: 'Number of packages visible' -
number_of_packages_doneIntegercompute='_compute_number_of_packages_done' args: 'Number of packages in a picking out' -
theoretical_number_of_packagesIntegercompute='_compute_theoretical_number_of_packages' args: 'Theoretical number of packages in a picking out'
No public methods.
Loading…
Loading…
Loading…