References for adding external svgs to the sheets

It works exactly the same as schedules - you add some .svg file, path to it stored in ifc and you can attach it to the sheet.

UI - https://i.imgur.com/tGbCGBb.png

Still need to add some tests for references
This commit is contained in:
Andrej730
2023-06-01 21:41:06 +05:00
parent 3c9f09f246
commit 0fd94d291b
11 changed files with 275 additions and 60 deletions
@@ -182,7 +182,7 @@ class SheetBuilder:
layout_tree.write(layout_path)
def add_schedule(self, reference, schedule, sheet):
def add_document(self, reference, schedule, sheet):
view_path = tool.Drawing.get_path_with_ext(tool.Drawing.get_document_uri(schedule), "svg")
if not os.path.exists(view_path):
tool.Drawing.create_svg_schedule(schedule)