web/views/editcontroller.py
changeset 4045 f4a52abb6f4f
parent 4007 91d11fda4aa0
child 4053 7cc66b1d9183
--- a/web/views/editcontroller.py	Tue Dec 08 16:46:56 2009 +0100
+++ b/web/views/editcontroller.py	Tue Dec 08 16:50:36 2009 +0100
@@ -178,7 +178,7 @@
                     or
                     (field.role == 'object' and eschema.has_object_relation(field.name))):
                     continue
-                rschema = self._cw.schema.rschema(field.name)
+                rschema = self._cw.vreg.schema.rschema(field.name)
                 if rschema.is_final():
                     rqlquery.kwargs[attr] = value
                     rqlquery.edited.append('X %s %%(%s)s' % (attr, attr))
@@ -246,7 +246,7 @@
         if values is None or values == origvalues:
             return # not edited / not modified / to do later
         etype = entity.e_schema
-        rschema = self._cw.schema.rschema(field.name)
+        rschema = self._cw.vreg.schema.rschema(field.name)
         if field.role == 'subject':
             desttype = rschema.objects(etype)[0]
             card = rschema.rproperty(etype, desttype, 'cardinality')[0]