[FEM] update bodyHeatSource

- to the state of the other constraints

(this constraint is currently completely broken by the way)
This commit is contained in:
Uwe
2022-07-26 01:47:09 +02:00
parent c9b709d814
commit 22c64ef8be

View File

@@ -39,10 +39,17 @@ class ConstraintBodyHeatSource(base_fempythonobject.BaseFemPythonObject):
def __init__(self, obj):
super(ConstraintBodyHeatSource, self).__init__(obj)
self.add_properties(obj)
obj.addProperty(
"App::PropertyFloat",
"HeatSource",
"Base",
"Body heat source"
)
def onDocumentRestored(self, obj):
self.add_properties(obj)
def add_properties(self, obj):
if not hasattr(obj, "HeatSource"):
obj.addProperty(
"App::PropertyFloat",
"HeatSource",
"Base",
"Body heat source"
)
obj.HeatSource = 0.0