Clear tree before setting options to avoid duplicates

This commit is contained in:
nathan 2021-11-10 15:00:32 -07:00
parent 5dc17cfbc7
commit b0ef704c4b

View File

@ -375,6 +375,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);