diff --git a/js/bootstrap-select.js b/js/bootstrap-select.js index 060772528..a1ee4a86a 100644 --- a/js/bootstrap-select.js +++ b/js/bootstrap-select.js @@ -902,7 +902,8 @@ init: function () { var that = this, - id = this.$element.attr('id'); + id = this.$element.attr('id'), + form = this.$element[0].form; selectId++; this.selectId = 'bs-select-' + selectId; @@ -1005,6 +1006,14 @@ }); } + if (form) { + $(form).on('reset' + EVENT_KEY, function () { + requestAnimationFrame(function () { + that.render(); + }); + }); + } + setTimeout(function () { that.buildList(); that.$element.trigger('loaded' + EVENT_KEY);