def update_api(self, data_map): ''' api信息更新 ''' pg_update.update("api", data_map, where=" api = '%s' " % data_map['api'])
def update_business(self, data_map): ''' 编辑和删除业务 ''' pg_update.update("business", data_map, where=" id = %s " % data_map['id'])
def update_user(self): ''' 用户信息更新 ''' pg_update.update("user_info", self.user_map, where=" account = '%s' " % self.data_map['account'])
def update_user(data_map): ''' 用户信息更新 ''' pg_update.update("user_info", data_map, where=" account = '%s' " % data_map['account'])
def update_user(self): ''' 用户信息更新 ''' pg_update.update("user_info", self.user_map, where=" account = '%s' " % self.data_map['account'])
def update_api(self, data_map): ''' api信息更新 ''' pg_update.update("api", data_map, where=" api = '%s' " % data_map['api'])
def delete_role_business_by_business_code(self, business_code): ''' 删除某业务对应的角色业务 ''' pg_update.update("business", {'status': 1}, where=" business_code = '%s' " % business_code)
def update_business(self, data_map): ''' 编辑和删除业务 ''' pg_update.update("business", data_map, where=" id = %s " % data_map['id'])
def update_role(data_map): ''' 编辑和删除角色 ''' pg_update.update("role", data_map, where=" id = %s " % data_map['id'])
def update_session(self, session): pg_update.update("session", {'invalid_time': str(datetime.datetime.now() + datetime.timedelta(seconds=600))[:19]}, where=" session = '%s' " % session)
def clear_session(self, session): data = {} data['invalid_time'] = str(datetime.datetime.now())[:19] data['status'] = 1 pg_update.update("session", data, where=" session = '%s'" % session)
def delete_role_business_by_business_code(self, business_code): ''' 删除某业务对应的角色业务 ''' pg_update.update("business", {'status': 1}, where=" business_code = '%s' " % business_code)
def update_role(data_map): ''' 编辑和删除角色 ''' pg_update.update("role", data_map, where=" id = %s " % data_map['id'])
def update_session(self, session): pg_update.update("session", { 'invalid_time': str(datetime.datetime.now() + datetime.timedelta(seconds=600))[:19] }, where=" session = '%s' " % session)
def clear_session(self, session): data = {} data['invalid_time'] = str(datetime.datetime.now())[:19] data['status'] = 1 pg_update.update("session", data, where=" session = '%s'" % session)