def live_search(request): return live_search_results(request, FilmIdea, result_item_formatting=lambda post: { 'value': u'<div>%s</div>' % (post.summary), 'result': post.summary, })
def live_search(request): return live_search_results( request, Box, 'autocomplete_index', limit=3, redirect=True, query_converter=filter_published, result_item_formatting=lambda box: { 'value': u'<div>%s / <i>%s</i><img src="%s" class="float-right item-img" /></div>' % (box.title, box.instructor.name, box.language.image.url), 'result': box.title, })
def live_search(request): return live_search_results(request, FilmIdea, result_item_formatting=lambda post: {'value': u'<div>%s</div>' % (post.summary), 'result': post.summary, })
def live_search(request): return live_search_results( request, FilmIdea, result_item_formatting=lambda post: {"value": u"<div>%s</div>" % (post.summary), "result": post.summary}, )
def live_search_test(request): return live_search_results(request, X, 'index', chain_sort=(('idx =', 1), ('idx =', 2)))