def GET(self, movieid): nocache() doc = search.do_query('id', movieid)[0] #recoms = search.do_query('indicators', movieid) recoms = [search.do_query('id', movieid)[0] for movieid in doc.bets] if hasattr(session, 'liked'): youlike = search.do_query('indicators', session.liked) else: youlike = [] return render.movie(doc, recoms, youlike)
def get(self, search_type, query): if not query: raise tornado.web.HTTPError(400) try: boxes = search.do_query(search_type, query) self.write(json.dumps(boxes)) except search.LiberSearchException, e: raise tornado.web.HTTPError(400)
def search(self, expr, *args, **kwargs): return search.do_query(expr, self.search_operators, *args, **kwargs)
def GET(self): nocache() ids = getattr(session, 'liked', []).split() return render.showlikes( [search.do_query('id', movieid)[0] for movieid in ids])
def GET(self): nocache() query = web.input().get('query') return render.search(search.do_query('title', query))
def GET(self): nocache() ids = getattr(session, 'liked', []).split() return render.showlikes([search.do_query('id', movieid)[0] for movieid in ids])
def searching(): self.result = search.do_query(search_item.text(), self.index, self.url_path) slm = QStringListModel() slm.setStringList(self.result) search_result.setModel(slm)