diff --git a/web_widget_boolean_switch/static/lib/bootstrap-switch/README.md b/web_widget_boolean_switch/static/lib/bootstrap-switch/README.md index e9e1d96f..8cd08298 100644 --- a/web_widget_boolean_switch/static/lib/bootstrap-switch/README.md +++ b/web_widget_boolean_switch/static/lib/bootstrap-switch/README.md @@ -7,3 +7,5 @@ from: https://github.com/nostalgiaz/bootstrap-switch directories at this [revision](https://github.com/nostalgiaz/bootstrap-switch/ tree/a39a1e9d6059822235bf4a9c0e7700a7e6a5ad19/dist) the september 30th 2015. +The default library doesn't allow to change value through javascript if +switcher is set `readonly` or `disabled`. diff --git a/web_widget_boolean_switch/static/lib/bootstrap-switch/bootstrap-switch.js b/web_widget_boolean_switch/static/lib/bootstrap-switch/bootstrap-switch.js index 826263a4..82c904ea 100644 --- a/web_widget_boolean_switch/static/lib/bootstrap-switch/bootstrap-switch.js +++ b/web_widget_boolean_switch/static/lib/bootstrap-switch/bootstrap-switch.js @@ -135,9 +135,6 @@ if (typeof value === "undefined") { return this.options.state; } - if (this.options.disabled || this.options.readonly) { - return this.$element; - } if (this.options.state && !this.options.radioAllOff && this.$element.is(":radio")) { return this.$element; }