diff options
| author | Denis Ledoux <dle@odoo.com> | 2016-04-20 10:05:09 +0200 |
|---|---|---|
| committer | Denis Ledoux <dle@odoo.com> | 2016-04-20 10:12:45 +0200 |
| commit | 21ccf2fe1c9ed2f6e16ded5f0e5751eebfc082e2 (patch) | |
| tree | 73a53330198799c2aace39002b7ebe3d796569bc | |
| parent | bdfc75e613b45afcc5e9ada58f2d6c3d42b7732a (diff) | |
[FIX] stock: remove spaces surrounding the `/` in locations complete name
The location name get is computed as:
`parent.name + '/' + child.name`
While, the complete was computed as:
`parent.name + ' / ' + child.name`
This leaded to an obvious inconsistency.
Besides, this prevented to use the `location`
filter in the search of the products list to
know the quantity available of products for
a specifc location, as the domain used
to retrieve the locations is set as
`[('complete_name','ilike',context['location'])]`
`context['location']` containing the content of the `name_get`
(No spaces surrounding `/`)
and
`complete_name` surrounding `/` with spaces.
opw-674378
| -rw-r--r-- | addons/stock/stock.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/addons/stock/stock.py b/addons/stock/stock.py index 96937d3463d..dab4f6a3c16 100644 --- a/addons/stock/stock.py +++ b/addons/stock/stock.py @@ -61,7 +61,7 @@ class stock_location(osv.osv): res[m.id] = m.name parent = m.location_id while parent: - res[m.id] = parent.name + ' / ' + res[m.id] + res[m.id] = parent.name + '/' + res[m.id] parent = parent.location_id return res |
