96 req.set_message(req._("You have no access to this view or it's not applyable to current data")) |
96 req.set_message(req._("You have no access to this view or it's not applyable to current data")) |
97 self.warning("the view %s can not be applied to this query", vid) |
97 self.warning("the view %s can not be applied to this query", vid) |
98 vid = vid_from_rset(req, rset, self.schema) |
98 vid = vid_from_rset(req, rset, self.schema) |
99 view = self.vreg.select_view(vid, req, rset) |
99 view = self.vreg.select_view(vid, req, rset) |
100 return view, rset |
100 return view, rset |
101 |
|
102 def process_rql(self, rql): |
|
103 """execute rql if specified""" |
|
104 if rql: |
|
105 self.ensure_ro_rql(rql) |
|
106 if not isinstance(rql, unicode): |
|
107 rql = unicode(rql, self.req.encoding) |
|
108 pp = self.vreg.select_component('magicsearch', self.req) |
|
109 self.rset = pp.process_query(rql, self.req) |
|
110 return self.rset |
|
111 return None |
|
112 |
101 |
113 def add_to_breadcrumbs(self, view): |
102 def add_to_breadcrumbs(self, view): |
114 # update breadcrumps **before** validating cache, unless the view |
103 # update breadcrumps **before** validating cache, unless the view |
115 # specifies explicitly it should not be added to breadcrumb or the |
104 # specifies explicitly it should not be added to breadcrumb or the |
116 # view is a binary view |
105 # view is a binary view |