def get_files_list(self, session): return [x[0] for x in db_query(session, models.File.id)]
def get_attachments_list(self, session): return [x[0] for x in db_query(session, models.InternalFile.filename)] + \ [x[0] for x in db_query(session, models.ReceiverFile.filename)] + \ [x[0] for x in db_query(session, models.WhistleblowerFile.filename)]
def db_get_languages(session, tid): return [ x[0] for x in db_query(session, models.EnabledLanguage.name, models.EnabledLanguage.tid == tid) ]