You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

31 lines
1.1 KiB
Python

import logging
from yolanda.lib.base import *
log = logging.getLogger(__name__)
class SearchController(BaseController):
def results(self):
c.query = request.params['query']
# c.results dummy
c.results = [
{'title': 'foobar', 'id': '23' },
{'title': 'blablupp', 'id': '42'},
{'title': 'uiae nrdt', 'id': '555'},
{'title': 'uiaenrtd uiaenrtd uiaenrdt', 'id': '666666666'},
{'title': 'foobar', 'id': '23'},
{'title': 'blablupp', 'id': '42'},
{'title': 'James Bond drives a bulletproof Aston Martin !!!', 'id': '555'},
{'title': 'uiaenrtd uiaenrtd uiaenrdt uiaenrtd uiaenrtd', 'id': '666666666'},
{'title': 'foobar', 'id': '123'},
{'title': 'blablupp', 'id': '42'},
{'title': 'lolwtf hax !!!11', 'id': '9001'}
]
return render('/xhtml/results.mako')
# return request.params['query']
# return h.form(h.url(action='search'), method='get')