30 Dec
2002
30 Dec
'02
11:46 a.m.
Luca Olivetti wrote:
No success because when the method gets called self is an instance of MyClass, so the method never returns None.
I would index the actual attribute, I'd index something called index_yourattributename. Then define a method called 'index_yourattributename' as follows: return getattr(context.aq_explicit,'yourattributename') ...and if you're really paranoid, make 'index_yourattributename' an external method: from Acquisition import aq_base def index_yourattributename(self): return getattr(aq_base(self),'yourattributename') cheers, Chris