From 52a2d4e9bbc5e31e4e2637b6ded4a02a2f19b618 Mon Sep 17 00:00:00 2001 From: nathan Date: Wed, 10 Nov 2021 15:00:32 -0700 Subject: [PATCH] Clear tree before setting options to avoid duplicates --- api/js/etemplate/et2_widget_tree.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/api/js/etemplate/et2_widget_tree.ts b/api/js/etemplate/et2_widget_tree.ts index 8db1b02d58..2d1e9bf9af 100644 --- a/api/js/etemplate/et2_widget_tree.ts +++ b/api/js/etemplate/et2_widget_tree.ts @@ -386,6 +386,7 @@ export class et2_tree extends et2_inputWidget f(data, f); options = data; } + this.input.deleteChildItems("0"); // if no options given, but autoloading url, use that to load initial nodes if (typeof options.id == 'undefined' && this.input.XMLsource) this.input.loadJSON(this.input.XMLsource);