Contributors mailing list archives

Browse archives


Inventory on a past date ?

Akretion, Clément Mombereau
- 18/11/2021 16:57:29
Hello contributors,

There is a few days delay between the moment the physical inventory is done at my client's warehouses and the moment he actually registers this inventory adjustment in Odoo.
So he would like to make inventory adjustments on a past date (only a few days ago mainly).

Anyone have an idea on how to achieve this ?

There is this accounting_date on stock.inventory but it looks like it only forces the account.move's date related to the inventory adjustment.

As far as I've understood the problem, when we click on Inventory's "action_start" it catches the  quants quantities... And a quant by definition can only shows the actual product quantity in stock.

So instead, it would mean to recalculate the past stock.moves for each products, a bit like what is done with the _compute_quantities when clicking on "Inventory at date" in the Inventory Report menu... (the big difference with this "_compute_quantities" being that we would have to group the moves calculation by location_id and lot_id because we need to make these distinctions)

Anyway, it does not look so easy at first glance. At least, would it be the good method to achieve this inventory on a past date?

Thank you very much for your opinion on this topic! 🙏