Browse Source

Merge pull request #287 from cvsguimaraes/master

Form reset improvement
Emanuele 11 năm trước cách đây
mục cha
commit
ce3f45f1ac

+ 1 - 1
dist/js/bootstrap-switch.js

@@ -418,7 +418,7 @@
             return $form.find("input").filter(function() {
               return $(this).data("bootstrap-switch");
             }).each(function() {
-              return $(this).bootstrapSwitch("state", false);
+              return $(this).bootstrapSwitch("state", this.checked);
             });
           }, 1);
         }).data("bootstrap-switch", true);

Những thai đổi đã bị hủy bỏ vì nó quá lớn
+ 0 - 0
dist/js/bootstrap-switch.min.js


+ 1 - 1
src/coffee/bootstrap-switch.coffee

@@ -310,7 +310,7 @@ do ($ = window.jQuery, window) ->
           $form
           .find("input")
           .filter( -> $(@).data "bootstrap-switch")
-          .each -> $(@).bootstrapSwitch "state", false
+          .each -> $(@).bootstrapSwitch "state", @checked
         , 1
       .data "bootstrap-switch", true
 

Một số tệp đã không được hiển thị bởi vì quá nhiều tập tin thay đổi trong này khác