bim.calculate_resource_quantity #5744

Added operator to calculate resource quantity based on the output products and the quantity Name.
See video demo - https://imgchest.com/p/9rydjlbmnyk
This commit is contained in:
Andrej730
2024-11-14 16:18:09 +05:00
parent 6c26403b9c
commit 9f49cbe0c9
6 changed files with 27 additions and 0 deletions
@@ -101,6 +101,7 @@ def calculate_cost_item_resource_value(file: ifcopenshell.file, cost_item: ifcop
for resource in resources:
cost, unit = ifcopenshell.util.resource.get_cost(resource)
# TODO: cost is never None because get_cost always returns a float.
if cost is None:
# Concept to standardise - Not defined in schema, but this makes manual scheduling of resources 10x faster and less duplicate data.
parent_cost = ifcopenshell.util.resource.get_parent_cost(resource)