Commit aa8e9a60 authored by Julien Muchembled's avatar Julien Muchembled

Fix getId/getTitle of broken objects

parent 0c1cc495
......@@ -28,6 +28,10 @@ class ERP5BaseBroken(Broken, ERP5Base):
d = dict(PersistentBroken.__dict__, **d)
for x in '__dict__', '__metaclass__', '__weakref__':
del d[x]
def get(*args):
return lambda self: self.__dict__['__Broken_state__'].get(*args)
for x in 'id', 'title':
d[x] = property(get(x, getattr(ERP5Base, x, None)))
return type(name, base, d)
def __getattr__(self, name):
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment