|
mutator not called on empty value?: msg#00090web.zope.plone.archetypes.devel
Hi! It seems that mutators are not called if the value is None. Has this some reason? I am actually trying to do something like the file type and deriving the ID from the filename of the uploaded file. But in this case the id is empty and thus my mutator is not called and thus the id not set. Moreover I think it makes sense to pass all the fields to the mutator as in this case it's also dependant on these (now I fetch everything from the request). Maybe it makes sense to create some sort of data object which holds all the values and pass this to every mutator. Thes data object might then hold the right values already. In my case the requests now has a field "file_file" for my schema field "file". This might then be converted already. This change might need some different mutator attribute then in order to provide backwards compatibility. But mist important is the first question as I would change this then. So any objections? -- christian PS: referring to code in _processForm() in BaseObject.py -- COM.lounge http://comlounge.net/ communication & design info-WV3Fc3dYO6sqcZcGjlUOXw@xxxxxxxxxxxxxxxx ------------------------------------------------------- This SF.Net email is sponsored by: INetU Attention Web Developers & Consultants: Become An INetU Hosting Partner. Refer Dedicated Servers. We Manage Them. You Get 10% Monthly Commission! INetU Dedicated Managed Hosting http://www.inetu.net/partner/index.php |
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | References in set() ?: 00090, Christian Scholz |
|---|---|
| Next by Date: | Automatic migration for Archetypes schema changes: 00090, Geoff Davis |
| Previous by Thread: | References in set() ?i: 00090, Christian Scholz |
| Next by Thread: | Automatic migration for Archetypes schema changes: 00090, Geoff Davis |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
| News | FAQ | advertise |