web/views/cwuser.py
changeset 5877 0c7b7b76a84f
parent 5556 9ab2b4c74baf
child 6325 38cfda1ab60f
--- a/web/views/cwuser.py	Fri Jul 02 19:14:48 2010 +0200
+++ b/web/views/cwuser.py	Mon Jul 05 12:04:32 2010 +0200
@@ -21,7 +21,7 @@
 
 from logilab.mtconverter import xml_escape
 
-from cubicweb.selectors import one_line_rset, implements, match_user_groups
+from cubicweb.selectors import one_line_rset, is_instance, match_user_groups
 from cubicweb.view import EntityView
 from cubicweb.web import action, uicfg
 from cubicweb.web.views import tabs
@@ -38,7 +38,7 @@
 
 class UserPreferencesEntityAction(action.Action):
     __regid__ = 'prefs'
-    __select__ = (one_line_rset() & implements('CWUser') &
+    __select__ = (one_line_rset() & is_instance('CWUser') &
                   match_user_groups('owners', 'managers'))
 
     title = _('preferences')
@@ -51,7 +51,7 @@
 
 class FoafView(EntityView):
     __regid__ = 'foaf'
-    __select__ = implements('CWUser')
+    __select__ = is_instance('CWUser')
 
     title = _('foaf')
     templatable = False
@@ -93,14 +93,14 @@
 
 
 class CWGroupPrimaryView(tabs.TabbedPrimaryView):
-    __select__ = implements('CWGroup')
+    __select__ = is_instance('CWGroup')
     tabs = [_('cwgroup-main'), _('cwgroup-permissions')]
     default_tab = 'cwgroup-main'
 
 
 class CWGroupMainTab(tabs.PrimaryTab):
     __regid__ = 'cwgroup-main'
-    __select__ = tabs.PrimaryTab.__select__ & implements('CWGroup')
+    __select__ = tabs.PrimaryTab.__select__ & is_instance('CWGroup')
 
     def render_entity_attributes(self, entity):
         rql = 'Any U, FN, LN, CD, LL ORDERBY L WHERE U in_group G, ' \
@@ -114,7 +114,7 @@
 
 class CWGroupPermTab(EntityView):
     __regid__ = 'cwgroup-permissions'
-    __select__ = implements('CWGroup')
+    __select__ = is_instance('CWGroup')
 
     def cell_call(self, row, col):
         self._cw.add_css(('cubicweb.schema.css','cubicweb.acl.css'))
@@ -140,7 +140,7 @@
 
 class CWGroupInContextView(EntityView):
     __regid__ = 'incontext'
-    __select__ = implements('CWGroup')
+    __select__ = is_instance('CWGroup')
 
     def cell_call(self, row, col):
         entity = self.cw_rset.complete_entity(row, col)