Merge pull request #1099 from uniun/patch-4

Impossible to unselect TreeDropdownField
This commit is contained in:
Ingo Schommer 2013-01-15 03:06:02 -08:00
commit dc4b2a4479

View File

@ -148,7 +148,7 @@
.jstree(self.getTreeConfig())
.bind('select_node.jstree', function(e, data) {
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)
self.data('metadata', null);
self.setTitle(null);