소스 검색

Added `setTextLabel` and `setIconLabel` methods

Francesco Pontillo 11 년 전
부모
커밋
220c9c30d7
2개의 변경된 파일3개의 추가작업 그리고 3개의 파일을 삭제
  1. 2 2
      static/js/bootstrap-switch.js
  2. 1 1
      static/js/bootstrap-switch.min.js

+ 2 - 2
static/js/bootstrap-switch.js

@@ -42,7 +42,7 @@
 
             $element.addClass('has-switch');
 
-            if ($element.data('on') !== undefined)
+            if ($element.data('on'))
               color = "switch-" + $element.data('on');
 
             if ($element.data('on-label') !== undefined)
@@ -64,7 +64,7 @@
               .html(onLabel);
 
             color = '';
-            if ($element.data('off') !== undefined)
+            if ($element.data('off'))
               color = "switch-" + $element.data('off');
 
             $switchRight = $('<span>')

파일 크기가 너무 크기때문에 변경 상태를 표시하지 않습니다.
+ 1 - 1
static/js/bootstrap-switch.min.js


이 변경점에서 너무 많은 파일들이 변경되어 몇몇 파일들은 표시되지 않았습니다.