openerp-india team mailing list archive
-
openerp-india team
-
Mailing list archive
-
Message #11888
[Bug 1004442] Re: [Trunk/6.1] stock: erroneous help message on product stock levels
Hello,
As per my "Opinion" the displayed qty is correct (Which is displayed the
our company's all warehouses 's stock location's total ), So we should
be improve the tooltip of this field.
Thanks!
** Summary changed:
- [6.1] stock: erroneous help message on product stock levels
+ [Trunk/6.1] stock: erroneous help message on product stock levels
** Changed in: openobject-addons
Importance: Undecided => Low
** Changed in: openobject-addons
Status: New => Confirmed
** Changed in: openobject-addons
Assignee: (unassigned) => OpenERP R&D Addons Team 2 (openerp-dev-addons2)
--
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/1004442
Title:
[Trunk/6.1] stock: erroneous help message on product stock levels
Status in OpenERP Addons (modules):
Confirmed
Bug description:
in the stock module, the help string for qty_available says:
"""
Current quantity of products.
In a context with a single Stock Location, this includes goods stored at this Location, or any of its children.
In a context with a single Warehouse, this includes goods stored in the Stock Location of this Warehouse, or any of its children.
In a context with a single Shop, this includes goods stored in the Stock Location of the Warehouse of this Shop, or any of its children.
Otherwise, this includes goods stored in any Stock Location typed as 'internal'
"""
The "Otherwise" part is wrong.
The code run in that case selects all stock locations of all
warehouses in the database:
else:
location_ids = []
wids = warehouse_obj.search(cr, uid, [], context=context)
for w in warehouse_obj.browse(cr, uid, wids, context=context):
location_ids.append(w.lot_stock_id.id)
I'm not sure what the fix for this should be : updating the code or
fixing the help string. I'm inclined to think that fixing the help
message is the least surprise path (although what I need in my
current project is what is described in that help tooltip...)
To reproduce the bug:
* on an instance create two warehouses
* on the first warehouse, set the stock location to an internal location
* on the second warehouse, set the stock location to something else than internal (eg inventory)
* add a third internal location, not linked to any warehouse
* add some stock level in all 3 locations for a product
* display the product view without any context: you should per the help see only the stock from location 1 and 3, yet you get the stock from location 1 and 2.
To manage notifications about this bug go to:
https://bugs.launchpad.net/openobject-addons/+bug/1004442/+subscriptions
References