[Checkins] SVN: z3c.form/branches/icemac-dm-query/src/z3c/form/form.py The change in http://svn.zope.org/?rev=112225&view=rev requires each value to exist in a dictionary, so it would be nice to query the old value as it m
Michael Howitz
mh at gocept.com
Sat Jul 10 13:40:41 EDT 2010
Log message for revision 114527:
The change in http://svn.zope.org/?rev=112225&view=rev requires each value to exist in a dictionary, so it would be nice to query the old value as it m
ight not exist which then breaks applyChanges with an AttributeError.
Changed:
U z3c.form/branches/icemac-dm-query/src/z3c/form/form.py
-=-
Modified: z3c.form/branches/icemac-dm-query/src/z3c/form/form.py
===================================================================
--- z3c.form/branches/icemac-dm-query/src/z3c/form/form.py 2010-07-10 17:35:55 UTC (rev 114526)
+++ z3c.form/branches/icemac-dm-query/src/z3c/form/form.py 2010-07-10 17:40:40 UTC (rev 114527)
@@ -46,8 +46,8 @@
# Only update the data, if it is different
# Or we can not get the original value, in which case we can not check
# Or it is an Object, in case we'll never know
- if (not dm.canAccess() or
- dm.get() != data[name] or
+ if (not dm.canAccess() or
+ dm.query() != data[name] or
zope.schema.interfaces.IObject.providedBy(field.field)):
dm.set(data[name])
# Record the change using information required later
@@ -213,11 +213,11 @@
def __call__(self):
self.update()
-
+
# Don't render anything if we are doing a redirect
if self.request.response.getStatus() in (300, 301, 302, 303, 304, 305, 307,):
return u''
-
+
return self.render()
More information about the checkins
mailing list