def dict_index(lletra): start = lletra.find('?') if start != -1: lletra = lletra[:start] search = Search(lletra) search.Index = True search.Duplicates = False View = IndexView(lletra) result = View.do(search) return result
def index_letter_api(lletra): search = Search(lletra) search.Index = True search.Duplicates = False return json_answer(search.get_json())