瀏覽代碼

[#85] The update method of the LeDataSourceSQL class returns the number of updated rows

Roland Haroutiounian 9 年之前
父節點
當前提交
dca5d2d1ca
共有 1 個文件被更改,包括 2 次插入2 次删除
  1. 2
    2
      leapi/datasources/ledatasourcesql.py

+ 2
- 2
leapi/datasources/ledatasourcesql.py 查看文件

@@ -127,8 +127,8 @@ class LeDataSourceSQL(DummyDatasource):
127 127
             prep_rel_filters = self._prepare_rel_filters(rel_filters)
128 128
         query = update(table=query_table_name, where=where_filters, set=set_data)
129 129
         with self.connection as cur:
130
-            cur.execute(query)
131
-        return True
130
+            result = cur.execute(query)
131
+        return result
132 132
 
133 133
     ## @brief inserts a new lodel editorial component
134 134
     # @param target_cls LeCrud(class) : The component class concerned by the insert (a LeCrud child class (not instance !) )

Loading…
取消
儲存