Improved reordering rules
stock_reord_rule · OCA/stock-logistics-warehouse
-
Security25/25No findings
-
Activity0/25Last human commit 50 months ago
-
Required by5/250 modules depend on it
-
Maturity25/25In 4 Odoo series since 7.0
Heuristic over the facts below, not an audit · How it's computed
Migration considerations
product_product— Class 'product_product' declares `_columns` as a plain dict: old-style field/default declarations, replace with `fields.X(...)` class attributes and `default=`. migration-old-style-fields · sourcestock_warehouse_orderpoint— Class 'stock_warehouse_orderpoint' still inherits from the old-style `orm.Model` API: rewrite it against `models.Model`/`models.TransientModel`/`models.AbstractModel` - the old `osv`/`orm` API was removed entirely in modern Odoo. (2 occurrences in this file) migration-old-api-base · sourceupdate_reordering_quantity_cron— Migrating to 18.0: `ir.cron` lost `numbercall`/`doall`: remove them from the record, data loading fails on unknown fields. migration-cron-numbercall · source- Since 10.0: the `openerp` namespace was renamed to `odoo`; only a deprecated `openerp.addons` alias remained. (`openerp.osv`) migration-openerp-import · source
Migration review checklist, not a compatibility verdict. "Migrating to X.0" applies once you upgrade to that version; "Since X.0" means this version already ignores or rejects that code. Methodology
Description
This module allows to improve reordering rules of stock module.
It works forecasting the stock needed per product for n days of sales, with the following formula:
(( Qty sold in days_stats * (1+forecast_gap)) / days_stats * days_warehouse)
where:
- days_stats = days on wich calculate sales stats;
- forecast_gap = forecast of increase/decrease on sales (%);
- days_warehouse = days of stock to keep in the warehouse.
Usage:
insert days_stats, forecast_gap and days_warehouse vars in product form and create a reordering rule for the same product, without inserting nothing (neither maximum or minimum quantity are required). The cron job will be executed daily and will update the maximum quantity in the reordering rule (you can force it to start changing the date and hour of execution).
This module doesn't need purchase module to work, but it's useful with that module.
Dependencies
Code analysis
Extracted from the source by best-effort static analysis (no code is executed); details may be incomplete.
Views touched 1
| XML ID | Name | Model | Type | Status |
|---|---|---|---|---|
product_normal_form_view_procurement_by_days |
product.normal.form_procurement_by_days | product.product | form | Inherits product.product_normal_form_view |
HTTP endpoints 0
No HTTP endpoints found for this module.
Models touched 2
No new fields.
Public methods (0)No public methods.
No new fields.
Public methods (0)No public methods.
Loading…
Loading…
Loading…