[FIX] _constraints : Multiple constraints on the same field should be allowed
bzr revid: ach@tinyerp.com-20100511083601-ne9n2ftq5lbohvwg
This commit is contained in:
parent
d8672f0f3a
commit
ee6e52fac7
|
@ -253,7 +253,8 @@ class osv(osv_base, orm.orm):
|
|||
for c in cls.__dict__.get(s, []):
|
||||
exist = False
|
||||
for c2 in range(len(new)):
|
||||
if new[c2][2]==c[2]:
|
||||
#For _constraints, we should check field and methods as well
|
||||
if new[c2][2]==c[2] and new[c2][0]==c[0]:
|
||||
new[c2] = c
|
||||
exist = True
|
||||
break
|
||||
|
|
Loading…
Reference in New Issue