From 330c045b2ed4d73de0b4baca4cde63879f1a984f Mon Sep 17 00:00:00 2001 From: felmer <franz-josef.elmer@id.ethz.ch> Date: Sat, 25 Feb 2023 08:58:34 +0100 Subject: [PATCH] SSDM-12929: bug fixed when refreshing view in SFTP client --- .../eln-lims/1/dss/file-system-plugins/eln-tree/script.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/ui-eln-lims/src/core-plugins/eln-lims/1/dss/file-system-plugins/eln-tree/script.py b/ui-eln-lims/src/core-plugins/eln-lims/1/dss/file-system-plugins/eln-tree/script.py index 1bfc219846f..e530f7af482 100644 --- a/ui-eln-lims/src/core-plugins/eln-lims/1/dss/file-system-plugins/eln-tree/script.py +++ b/ui-eln-lims/src/core-plugins/eln-lims/1/dss/file-system-plugins/eln-tree/script.py @@ -260,13 +260,11 @@ def getNode(subPath, acceptor, context): nodeType = parentNode.getType() entityType = parentNode.getEntityType() permId = parentNode.getPermId() - print(">>>>>>>>>> GET NODE: %s, %s, %s" % (path, nodeType, parentNode.permIds)) if nodeType == "EXPERIMENT": addExperimentChildNodes(parentPathString, permId, entityType, None, acceptor, context) elif nodeType == "SAMPLE": addSampleChildNodes(parentPathString, permId, entityType, None, acceptor, context) elif nodeType == "DATASET": - print("====== GET DATASET NODE: %s, %s" % (path, parentNode.permIds)) dataSetCode, contentNode, _ = getContentNode(parentNode.getPermId(), context) addDataSetFileNodes(parentPathString, dataSetCode, contentNode, None, acceptor, context) else: @@ -342,7 +340,7 @@ def addDataSetFileNodes(path, dataSetCode, contentNode, response, acceptor, cont filePath = "%s/%s" % (path, nodeName) filePermId = "%s::%s" % (dataSetCode, childNode.getRelativePath()) cachedNode = context.getCache().getNode(filePath) - if cachedNode is not None: + if cachedNode is not None and filePermId not in cachedNode.permIds: cachedNode.addPermId(filePermId) else: context.getCache().putNode(NodeWithEntityType("DATASET", filePermId, None), filePath) -- GitLab