← Back to team overview

openerp-india team mailing list archive

[Bug 1197467] Re: OpenERP Enterprise Edition Bugfix: duplicate inventory lines produce wrong posted inventories

 

Le 12/07/2013 07:26, Rifakat Haradwala (rha) a écrit :
>
> Hi Lionel,
>
> In your case you might have using your date with timestamp 00:00:00, 
> but what about other users?
> Normally no one would ever enter date with timestamp 00:00:00, (...)
>
The mandatory yearly inventory is part of the accounting/fiscal year 
closing procedure: it MUST happen at the end of the period, so in all 
logic it should be dated right after the last day, at 00:00:00 (local time).
Will all due respect, I think everyone should do it this way.
It's good practice and OpenERP supports it out of the box: it's a good 
design except for this bug.
>
> (...)if I create constraint considering this date field then I have an 
> impression that the constraint will never get executed as date 
> normally will not match.
>
Yes of course: constraints only catch errors!

Anyway, it's would only be a workaround.
Now I think it's better to fix the bug than work around it. Stock Moves 
should be created correctly when several inventory lines have the same 
date+product+lot+location.
Maybe the problem just to that the Stock Moves dated at the exact same 
date of the inventory are excluded from the computation?

> Do you suggest any generic possible solution which can work for any 
> user? This looks more like your specific requirement and I can provide 
> a patch for you.
>
It's not specific, I use only standard features in a way supported by 
the standard: multiple concurrent inventories with precise dates.
Let's call it a corner case.

Sorry I kept you waiting so long. I hope this helps you progress towards 
a solution. Thanks for your support.

Lionel.

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

Title:
  duplicate inventory lines produce wrong posted inventories

Status in OpenERP Addons (modules):
  New

Bug description:
  When you enter an inventory with several lines containing the same (product,location,prodlot) tuple, the posted inventory is not consistent : all lines are processes independently of each others, but they all relate to the same initial quantity.
  As a consequence, differences are found even when the total of all the "duplicate" lines is right. Please see the attached screencast for an illustration of the problem, where I can make the stock wrong twice even though I entered correct quantities, split in 2 lines.

  The simplest solution would be to forbid "duplicate" inventory lines
  with the same (product,location,prodlot) tuple.

  Another possible solution would be to let users insert duplicates, but
  sum them up before computing the difference with the initial stock.
  This would be interesting as it would allow users to enter products
  one by one (possibly with a barcode scanner).

  Lionel Sausin.

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