浏览代码

Bugfix on the recursive select

Roland Haroutiounian 8 年前
父节点
当前提交
8e4815c34f
共有 1 个文件被更改,包括 3 次插入2 次删除
  1. 3
    2
      plugins/mongodb_datasource/datasource.py

+ 3
- 2
plugins/mongodb_datasource/datasource.py 查看文件

@@ -90,12 +90,13 @@ class MongoDbDatasource(object):
90 90
     #@param instanciate bool : If true, the records are returned as instances, else they are returned as dict
91 91
     #@return list
92 92
     #@todo Implement the relations
93
-    def select(self, target, field_list, filters = None, rel_filters=None, order=None, group=None, limit=None, offset=0):
93
+    def select(self, target, field_list, filters = None, rel_filters=None, order=None, group=None, limit=None,
94
+               offset=0):
94 95
         results = list()
95 96
         if target.abstract:
96 97
             target_childs = target.child_classes()
97 98
             for target_child in target_childs:
98
-                results.append(self.select(target=target, field_list=field_list, filters=filters,
99
+                results.append(self.select(target=target_child, field_list=field_list, filters=filters,
99 100
                                            rel_filters=rel_filters, order=order, group=group, limit=limit,
100 101
                                            offset=offset))
101 102
         else:

正在加载...
取消
保存