From b6672ffb6a720ac4f833b075208e1a23c1c456a0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C5=ABlija=20Ov=C4=8Di=C5=86=C5=86ikova?= Date: Wed, 27 Nov 2024 18:47:25 +0200 Subject: [PATCH] minor changes --- app/imports/client/custom/vq/js/transformations.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/app/imports/client/custom/vq/js/transformations.js b/app/imports/client/custom/vq/js/transformations.js index bc114b2c..42aa0cff 100644 --- a/app/imports/client/custom/vq/js/transformations.js +++ b/app/imports/client/custom/vq/js/transformations.js @@ -1510,8 +1510,9 @@ function setSchemaNamesForQuery(abstractQueryTable, schemaNamesTable, parentSche return schemaNamesTable; } -async function getSchemaNameForElement(){ - const selected_elem_id = Session.get("activeElement"); +async function getSchemaNameForElement(elem_id){ + let selected_elem_id = Session.get("activeElement"); + if(typeof elem_id !== "undefined" && elem_id !== null) selected_elem_id = elem_id; let tempSymbolTable = await generateSymbolTable(true); let sc = await dataShapes.schema.schema; let schemaNames = setSchemaNamesForQuery(tempSymbolTable["abstractQueryTable"], [], sc); @@ -1526,6 +1527,7 @@ async function getSchemaNameForElement(){ } } } + return schemaNameFromABS; }