Fixed job removal for non-path base objects

This commit is contained in:
Markus Lampert
2017-09-12 13:03:25 -07:00
committed by wmayer
parent 82f9c2e090
commit a9652ea214

View File

@@ -235,14 +235,15 @@ class ObjectJob:
def allOperations(self):
ops = []
def collectBaseOps(op):
if op.TypeId == 'Path::FeaturePython':
ops.append(op)
if hasattr(op, 'Base'):
collectBaseOps(op.Base)
if op.TypeId == 'Path::FeatureCompoundPython':
ops.append(op)
for sub in op.Group:
collectBaseOps(sub)
if hasattr(op, 'TypeId'):
if op.TypeId == 'Path::FeaturePython':
ops.append(op)
if hasattr(op, 'Base'):
collectBaseOps(op.Base)
if op.TypeId == 'Path::FeatureCompoundPython':
ops.append(op)
for sub in op.Group:
collectBaseOps(sub)
for op in self.obj.Operations.Group:
collectBaseOps(op)
return ops