fixed getDoIds (pass in getDo)
This commit is contained in:
parent
9bcd40db9b
commit
be255e6bbd
|
|
@ -97,7 +97,8 @@ class DoCollectionManager:
|
|||
for i in self.getDoIdList(parentId, zoneId, classType)]
|
||||
|
||||
def getDoIdList(self, parentId, zoneId=None, classType=None):
|
||||
return self._doHierarchy.getDoIds(parentId, zoneId, classType)
|
||||
return self._doHierarchy.getDoIds(self.getDo,
|
||||
parentId, zoneId, classType)
|
||||
|
||||
def getOwnerViewDoList(self, classType):
|
||||
assert self.hasOwnerView()
|
||||
|
|
|
|||
|
|
@ -24,7 +24,7 @@ class DoHierarchy:
|
|||
self._table = {}
|
||||
self._allDoIds = set()
|
||||
|
||||
def getDoIds(self, parentId, zoneId=None, classType=None):
|
||||
def getDoIds(self, getDo, parentId, zoneId=None, classType=None):
|
||||
"""
|
||||
Moved from DoCollectionManager
|
||||
==============================
|
||||
|
|
@ -52,7 +52,7 @@ class DoHierarchy:
|
|||
if classType is not None:
|
||||
a = []
|
||||
for doId in r:
|
||||
obj = self.getDo(doId)
|
||||
obj = getDo(doId)
|
||||
if isinstance(obj, classType):
|
||||
a.append(doId)
|
||||
r = a
|
||||
|
|
|
|||
Loading…
Reference in New Issue