Document information is now always assigned to the project by default.

This commit is contained in:
Dion Moult
2022-03-14 20:39:11 +11:00
parent bc9e403a58
commit e343494ab4
3 changed files with 56 additions and 3 deletions
@@ -41,7 +41,13 @@ class DocumentData:
@classmethod
def total_information(cls):
return len(tool.Ifc.get().by_type("IfcDocumentInformation"))
return len(
[
rel
for rel in tool.Ifc.get().by_type("IfcProject")[0].HasAssociations or []
if rel.is_a("IfcRelAssociatesDocument") and rel.RelatingDocument.is_a("IfcDocumentInformation")
]
)
@classmethod
def total_references(cls):