fields.related on many2many field always indicate (0)
Affects | Status | Importance | Assigned to | Milestone | ||
---|---|---|---|---|---|---|
Odoo Server (MOVED TO GITHUB) | Status tracked in Trunk | |||||
| 5.0 |
Won't Fix
|
Low
|
Unassigned | ||
| Trunk |
Confirmed
|
Wishlist
|
OpenERP's Framework R&D |
Bug Description
Server revno: 1755
Addons revno: 2267
Client revno: 949
On a new module, add fields.related to a many2many field.
Add this field on the tree view and a search form
the fields always indicate (0) all the times, thus there are a multi value on the original object.
See screenshot
Distribution: Ubuntu
Version: 8.10 (intrepid)
Python 2.5.2
Locale:
LANG=fr_FR.UTF-8
Related branches
Changed in openobject-server: | |
assignee: | nobody → jvo-openerp |
Fabien (Open ERP) (fp-tinyerp) wrote : | #3 |
related sields still does not support m2m.
Changed in openobject-server: | |
importance: | Undecided → Wishlist |
Hello, I changed the code in the /server/
this was the function I changed:
def _fnct_read(self, obj, cr, uid, ids, field_name, args, context=None):
if not ids: return {}
relation = obj._name
res = {}.fromkeys(ids, False)
objlst = obj.browse(cr, uid, ids)
for data in objlst:
if not data:
t_data = data
for i in range(len(
# Modificado por AMA para resolver o bug em que o one 2 many em related aparece apenas o ultimo valor
if field_detail[
if type(t_data) == type(objlst[0]) and field_detail[
else:
if field_detail[
if type(t_data) == type(objlst[0]):
if self._type=
ids = filter(None, res.values())
if ids:
ng = dict(obj.
for r in res:
return res
Setting the big as "Won't fix" for stable as it is really not a blocking point.
Thanks for your participation.
summary: |
- [5.0] fields.related on many2many field always indicate (0) + fields.related on many2many field always indicate (0) |
Need to investigate if its really fixed on trunk or not.
Hello Christophe,
Can you please send me your module?
I do not get the situation. My records are not saved even.
Thanks.