diff --git a/leobject/datasources/dummy.py b/leobject/datasources/dummy.py index 734ed0b..042280f 100644 --- a/leobject/datasources/dummy.py +++ b/leobject/datasources/dummy.py @@ -15,9 +15,8 @@ class DummyDatasource(object): ## @brief update an existing LeObject # @param lodel_id (int) : list of lodel_id # @param checked_data dict - # @param datasource_filters (string) - def update(self, lodel_id, checked_data, datasource_filters): - print ("DummyDatasource.update: ", lodel_id, checked_data, datasource_filters) + def update(self, lodel_id, checked_data): + print ("DummyDatasource.update: ", lodel_id, checked_data) return True ## @brief create a new LeObject @@ -31,10 +30,9 @@ class DummyDatasource(object): ## @brief delete an existing LeObject # @param lodel_id int | (int): lodel_id of the object(s) to delete - # @param delete_filters string | (string): list of string of delete filters # @return okay bool: True on success, it will raise on failure - def delete(self, lodel_id, delete_filters=None): - print("DummyDatasource.delete: ", lodel_id, delete_filters) + def delete(self, lodel_id): + print("DummyDatasource.delete: ", lodel_id) return True ## @brief search for a collection of objects diff --git a/leobject/datasources/ledatasourcesql.py b/leobject/datasources/ledatasourcesql.py index 4301eff..c613e33 100644 --- a/leobject/datasources/ledatasourcesql.py +++ b/leobject/datasources/ledatasourcesql.py @@ -21,6 +21,7 @@ class LeDataSourceSQL(DummyDatasource): def get(self, emclass, emtype, field_list, filters, relational_filters): tablename = emclass.name where_filters = self._prepare_filters(filters) + rel_filters = self._prepare_filters(relational_filters) query = select(tablename, where=where_filters, select=field_list) self.db.execute(query) return all_to_dicts(self.db)