FIX 7862 Strict equality check on previously selected item in the TreeDropdownField

This commit is contained in:
jean 2012-09-13 09:27:09 +12:00
parent 2939632778
commit d1a3c80a9d

View File

@ -161,7 +161,7 @@
.jstree(self.getTreeConfig()) .jstree(self.getTreeConfig())
.bind('select_node.jstree', function(e, data) { .bind('select_node.jstree', function(e, data) {
var node = data.rslt.obj, id = $(node).data('id'); var node = data.rslt.obj, id = $(node).data('id');
if(!firstLoad && !self.getValue() == id) { if(!firstLoad && !self.getValue() === id) {
// Value is already selected, unselect it (for lack of a better UI to do this) // Value is already selected, unselect it (for lack of a better UI to do this)
self.data('metadata', null); self.data('metadata', null);
self.setTitle(null); self.setTitle(null);