mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-09-21 14:23:53 +00:00
add starting server if no server is running during export to web
This commit is contained in:
@@ -254,7 +254,10 @@ class ExportIfcCsv(bpy.types.Operator):
|
|||||||
schedule_creator = scheduler.Scheduler()
|
schedule_creator = scheduler.Scheduler()
|
||||||
schedule_creator.schedule(self.filepath, tool.Drawing.get_path_with_ext(self.filepath, "svg"))
|
schedule_creator.schedule(self.filepath, tool.Drawing.get_path_with_ext(self.filepath, "svg"))
|
||||||
if props.format == "web":
|
if props.format == "web":
|
||||||
|
if not context.scene.WebProperties.is_running:
|
||||||
|
bpy.ops.bim.connect_websocket_server()
|
||||||
tool.Web.send_webui_data(data=ifc_csv.dataframe.to_csv(index=False), data_key="csv_data", event="csv_data")
|
tool.Web.send_webui_data(data=ifc_csv.dataframe.to_csv(index=False), data_key="csv_data", event="csv_data")
|
||||||
|
|
||||||
self.report({"INFO"}, f"Data is exported to {props.format.upper()}.")
|
self.report({"INFO"}, f"Data is exported to {props.format.upper()}.")
|
||||||
return {"FINISHED"}
|
return {"FINISHED"}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user