← Back to team overview

credativ team mailing list archive

[Bug 921866] Re: Scheduler created PO's affects virtual stock

 

Hello,

So it is as I suspected. You have the purchase orders generated by the
scheduler add to "Virtual stock" even though they are only quotation, as
a work around. This is because when the scheduler runs it uses as you
said, Virtual Stock to calculate what should be ordered.

This is bad practice. Companies using OpenERP and many modules depend on
virtual stock to accurately tell what stock they have, not real stock.
So, by adding to virtual stock, it makes it not possible for a company
to maintain accurate stock. (virtual stock shows what you have, what you
intend to sell (confirmed sales) and what you have ordered (confirmed
orders) This is core function. If I create a quotation order, or a
quotation purchase order it does not add to virtual stock or subtract.
This is the principal functionality.

Problem:
I have 20 pieces and the scheduler generates a purchase order for 120 pieces, well, now I think I have 140 pieces when really I only have 20 and I have not even ordered the extra product yet. It is only a quotation.

This effect completely ruins the stock management. Instead of this
current (bug),

The scheduler should maintain cached values of the previous orders that
were generated. Each time the scheduler runs before it creates a new
purchase order it should check against already created purchase orders.
Then create a new one. If a purchase order previously generated from the
scheduler is confirmed or deleted, then the rules are no longer
calculated. This cached value should be used on the purchase order
object. Roughly, when the min/max rules are calculated it takes the
purchase orders generated as a factor.

-- 
You received this bug notification because you are a member of OpenERP
Framework Experts, which is subscribed to OpenERP Addons.
https://bugs.launchpad.net/bugs/921866

Title:
  Scheduler created PO's affects virtual stock

Status in OpenERP Addons (modules):
  Incomplete

Bug description:
  I have min/max rules setup. When the scheduler runs nightly it auto-
  generates purchase orders. It generates them correctly. They are in
  quotation state.

  The problem is that they affect virtual stock. If I have 5 parts left
  in stock. A minimum rule of 10. It creates a purchase order for 5 in
  quotation. Now it says I have 10 in virtual stock, but this is not
  right. It should never ever effect virtual stock unless it is
  confirmed. A quotation has no value.

  Does it do this behavior intentionally to avoid creating the same
  purchase order again the next night? If so thats a bad work around.

To manage notifications about this bug go to:
https://bugs.launchpad.net/openobject-addons/+bug/921866/+subscriptions


References