def getMatchesByPhrase(self, aFragment): """Return matches for aFragment at start of phrases.""" matches = gmDateTime.str2fuzzy_timestamp_matches(aFragment.strip()) if len(matches) == 0: return (False, []) items = [] for match in matches: items.append ({ 'data': match['data'], 'field_label': match['label'], 'list_label': match['label'] }) return (True, items)