Skip to content

Commit

Permalink
Arch: Fixed remaining bugs in Schedule - Fixes #3590
Browse files Browse the repository at this point in the history
  • Loading branch information
yorikvanhavre committed Dec 17, 2018
1 parent eb04b8e commit 175566d
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/Mod/Arch/ArchSchedule.py
Expand Up @@ -127,7 +127,7 @@ def execute(self,obj):
if objs:
objs = objs.split(";")
objs = [FreeCAD.ActiveDocument.getObject(o) for o in objs]
objs = [obj for obj in objs if obj != None]
objs = [o for o in objs if o != None]
else:
objs = FreeCAD.ActiveDocument.Objects
if len(objs) == 1:
Expand All @@ -136,6 +136,9 @@ def execute(self,obj):
objs = objs[0].Group
objs = Draft.getGroupContents(objs,walls=True,addgroups=True)
objs = Arch.pruneIncluded(objs,strict=True)
# remove the schedule object and its result from the list
objs = [o for o in objs if not o == obj]
objs = [o for o in objs if not o == obj.Result]
if obj.Filter[i]:
# apply filters
nobjs = []
Expand Down Expand Up @@ -231,6 +234,7 @@ def execute(self,obj):
obj.Result.set("B"+str(i+2),str(val))
if verbose:
print ("TOTAL:"+34*" "+str(val))
obj.Result.recompute()

def __getstate__(self):
return self.Type
Expand Down

0 comments on commit 175566d

Please sign in to comment.