69 self.w(OWL_OPENING_ROOT % {'appid': self._cw.vreg.schema.name}) |
69 self.w(OWL_OPENING_ROOT % {'appid': self._cw.vreg.schema.name}) |
70 self.visit_schema(skiptypes=skipmeta and schema.SKIP_TYPES or ()) |
70 self.visit_schema(skiptypes=skipmeta and schema.SKIP_TYPES or ()) |
71 if writeprefix: |
71 if writeprefix: |
72 self.w(OWL_CLOSING_ROOT) |
72 self.w(OWL_CLOSING_ROOT) |
73 |
73 |
74 <<<<<<< /home/syt/src/fcubicweb/cubicweb/web/views/owl.py |
|
75 def should_display_rschema(self, rschema): |
|
76 return not rschema in self.skiptypes and ( |
|
77 rschema.has_local_role('read') or |
|
78 rschema.has_perm(self._cw, 'read')) |
|
79 ======= |
|
80 def should_display_rschema(self, eschema, rschema, tschemas, role): |
74 def should_display_rschema(self, eschema, rschema, tschemas, role): |
81 return rschema.may_have_permissions('read', self.req, eschema, role) |
75 return not rschema in self.skiptypes and ( |
82 >>>>>>> /tmp/owl.py~other.-maWGS |
76 rschema.may_have_permissions('read', self._cw, eschema, role)) |
83 |
77 |
84 def visit_schema(self, skiptypes): |
78 def visit_schema(self, skiptypes): |
85 """get a layout for a whole schema""" |
79 """get a layout for a whole schema""" |
86 self.skiptypes = skiptypes |
80 self.skiptypes = skiptypes |
87 entities = sorted(eschema for eschema in self._cw.vreg.schema.entities() |
81 entities = sorted(eschema for eschema in self._cw.vreg.schema.entities() |