mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-09-18 22:33:33 +00:00
ifc4x3 support for adding IfcQuantityCount #4776
In IFC4X3 IfcQuantityCount is now more strict and requires only interger values. Error for a reference: TypeError: attribute 'CountValue' for entity 'IFC4X3.IfcQuantityCount' is expecting value of type 'INT', got 'float'.
This commit is contained in:
@@ -185,7 +185,7 @@ class Csv2Ifc:
|
||||
"cost.add_cost_item_quantity", self.file, cost_item=cost_item["ifc"], ifc_class=quantity_class
|
||||
)
|
||||
# 3 IfcPhysicalSimpleQuantity Value
|
||||
quantity[3] = cost_item["Quantity"]
|
||||
quantity[3] = int(cost_item["Quantity"]) if quantity_class == "IfcQuantityCount" else cost_item["Quantity"]
|
||||
if prop_name:
|
||||
quantity.Name = prop_name
|
||||
|
||||
|
||||
Reference in New Issue
Block a user