def all(self): result = sqliteClient.execute_select(''' select nome,login,pwd,admin,id from users; ''') return self.fill(result)
def all(self): result = sqliteClient.execute_select(''' select id,env,user from envs; ''') return self.fill(result)
def all(self): result = sqliteClient.execute_select(''' SELECT id FROM envs; ''') return self.fill(result)
def filter(self, filter=None): condition = "" for i in filter.keys(): condition += i + "=" + filter[i] if i != filter.keys()[-1]: condition += " and " result = sqliteClient.execute_select(''' select nome,login,pwd,admin,id from users where ''' + condition + '''; ''') return self.fill(result)
def filter(self, filter): condition = "" for i in filter.keys(): condition += i + "=" + filter[i] if i != filter.keys()[-1]: condition += " and " result = sqliteClient.execute_select(''' select id,env,user from envs where ''' + condition + '''; ''') return self.fill(result)
def filter(self, filter=None): if not filter: return None condition = "" for i in filter.keys(): condition += i + "=" + filter[i] if i != filter.keys()[-1]: condition += " and " results = sqliteClient.execute_select(''' SELECT id FROM envs WHERE ''' + condition + ''' ; ''') return self.fill(results)