[Zope3-checkins] CVS: Zope3/lib/python/Zope/App/Forms/Views/Browser - Widget.py:1.12
Jim Fulton
jim@zope.com
Wed, 4 Dec 2002 04:58:47 -0500
Update of /cvs-repository/Zope3/lib/python/Zope/App/Forms/Views/Browser
In directory cvs.zope.org:/tmp/cvs-serv13281/Views/Browser
Modified Files:
Widget.py
Log Message:
Fixed a bug in handling of conversions when getting data to be
inserted into forms.
=== Zope3/lib/python/Zope/App/Forms/Views/Browser/Widget.py 1.11 => 1.12 ===
--- Zope3/lib/python/Zope/App/Forms/Views/Browser/Widget.py:1.11 Mon Nov 11 15:43:32 2002
+++ Zope3/lib/python/Zope/App/Forms/Views/Browser/Widget.py Wed Dec 4 04:58:46 2002
@@ -54,7 +54,7 @@
# No user input
if field.required:
raise MissingInputError(field.__name__)
- return self.field.default
+ return field.default
try:
value = self._convert(value)
@@ -87,9 +87,9 @@
if (self._data is None) and self.haveData():
data = self.getData()
else:
- data = self._unconvert(self._data)
+ data = self._data
- return data
+ return self._unconvert(data)
def __call__(self):
'See Zope.App.Forms.Views.Browser.IBrowserWidget.IBrowserWidget'