Commit f0ffda3ffb040655e3cd01883dc784a8c373de5b

Authored by 王通
1 parent 93b27673

1.去除index.html等不受限的资源

src/main/resources/static/assets/js/template.js deleted 100644 → 0
1   -/*!art-template - Template Engine | http://aui.github.com/artTemplate/*/
2   -!function(){function a(a){return a.replace(t,"").replace(u,",").replace(v,"").replace(w,"").replace(x,"").split(y)}function b(a){return"'"+a.replace(/('|\\)/g,"\\$1").replace(/\r/g,"\\r").replace(/\n/g,"\\n")+"'"}function c(c,d){function e(a){return m+=a.split(/\n/).length-1,k&&(a=a.replace(/\s+/g," ").replace(/<!--[\w\W]*?-->/g,"")),a&&(a=s[1]+b(a)+s[2]+"\n"),a}function f(b){var c=m;if(j?b=j(b,d):g&&(b=b.replace(/\n/g,function(){return m++,"$line="+m+";"})),0===b.indexOf("=")){var e=l&&!/^=[=#]/.test(b);if(b=b.replace(/^=[=#]?|[\s;]*$/g,""),e){var f=b.replace(/\s*\([^\)]+\)/,"");n[f]||/^(include|print)$/.test(f)||(b="$escape("+b+")")}else b="$string("+b+")";b=s[1]+b+s[2]}return g&&(b="$line="+c+";"+b),r(a(b),function(a){if(a&&!p[a]){var b;b="print"===a?u:"include"===a?v:n[a]?"$utils."+a:o[a]?"$helpers."+a:"$data."+a,w+=a+"="+b+",",p[a]=!0}}),b+"\n"}var g=d.debug,h=d.openTag,i=d.closeTag,j=d.parser,k=d.compress,l=d.escape,m=1,p={$data:1,$filename:1,$utils:1,$helpers:1,$out:1,$line:1},q="".trim,s=q?["$out='';","$out+=",";","$out"]:["$out=[];","$out.push(",");","$out.join('')"],t=q?"$out+=text;return $out;":"$out.push(text);",u="function(){var text=''.concat.apply('',arguments);"+t+"}",v="function(filename,data){data=data||$data;var text=$utils.$include(filename,data,$filename);"+t+"}",w="'use strict';var $utils=this,$helpers=$utils.$helpers,"+(g?"$line=0,":""),x=s[0],y="return new String("+s[3]+");";r(c.split(h),function(a){a=a.split(i);var b=a[0],c=a[1];1===a.length?x+=e(b):(x+=f(b),c&&(x+=e(c)))});var z=w+x+y;g&&(z="try{"+z+"}catch(e){throw {filename:$filename,name:'Render Error',message:e.message,line:$line,source:"+b(c)+".split(/\\n/)[$line-1].replace(/^\\s+/,'')};}");try{var A=new Function("$data","$filename",z);return A.prototype=n,A}catch(B){throw B.temp="function anonymous($data,$filename) {"+z+"}",B}}var d=function(a,b){return"string"==typeof b?q(b,{filename:a}):g(a,b)};d.version="3.0.0",d.config=function(a,b){e[a]=b};var e=d.defaults={openTag:"<%",closeTag:"%>",escape:!0,cache:!0,compress:!1,parser:null},f=d.cache={};d.render=function(a,b){return q(a,b)};var g=d.renderFile=function(a,b){var c=d.get(a)||p({filename:a,name:"Render Error",message:"Template not found"});return b?c(b):c};d.get=function(a){var b;if(f[a])b=f[a];else if("object"==typeof document){var c=document.getElementById(a);if(c){var d=(c.value||c.innerHTML).replace(/^\s*|\s*$/g,"");b=q(d,{filename:a})}}return b};var h=function(a,b){return"string"!=typeof a&&(b=typeof a,"number"===b?a+="":a="function"===b?h(a.call(a)):""),a},i={"<":"&#60;",">":"&#62;",'"':"&#34;","'":"&#39;","&":"&#38;"},j=function(a){return i[a]},k=function(a){return h(a).replace(/&(?![\w#]+;)|[<>"']/g,j)},l=Array.isArray||function(a){return"[object Array]"==={}.toString.call(a)},m=function(a,b){var c,d;if(l(a))for(c=0,d=a.length;d>c;c++)b.call(a,a[c],c,a);else for(c in a)b.call(a,a[c],c)},n=d.utils={$helpers:{},$include:g,$string:h,$escape:k,$each:m};d.helper=function(a,b){o[a]=b};var o=d.helpers=n.$helpers;d.onerror=function(a){var b="Template Error\n\n";for(var c in a)b+="<"+c+">\n"+a[c]+"\n\n";"object"==typeof console&&console.error(b)};var p=function(a){return d.onerror(a),function(){return"{Template Error}"}},q=d.compile=function(a,b){function d(c){try{return new i(c,h)+""}catch(d){return b.debug?p(d)():(b.debug=!0,q(a,b)(c))}}b=b||{};for(var g in e)void 0===b[g]&&(b[g]=e[g]);var h=b.filename;try{var i=c(a,b)}catch(j){return j.filename=h||"anonymous",j.name="Syntax Error",p(j)}return d.prototype=i.prototype,d.toString=function(){return i.toString()},h&&b.cache&&(f[h]=d),d},r=n.$each,s="break,case,catch,continue,debugger,default,delete,do,else,false,finally,for,function,if,in,instanceof,new,null,return,switch,this,throw,true,try,typeof,var,void,while,with,abstract,boolean,byte,char,class,const,double,enum,export,extends,final,float,goto,implements,import,int,interface,long,native,package,private,protected,public,short,static,super,synchronized,throws,transient,volatile,arguments,let,yield,undefined",t=/\/\*[\w\W]*?\*\/|\/\/[^\n]*\n|\/\/[^\n]*$|"(?:[^"\\]|\\[\w\W])*"|'(?:[^'\\]|\\[\w\W])*'|\s*\.\s*[$\w\.]+/g,u=/[^\w$]+/g,v=new RegExp(["\\b"+s.replace(/,/g,"\\b|\\b")+"\\b"].join("|"),"g"),w=/^\d[^,]*|,\d[^,]*/g,x=/^,+|,+$/g,y=/^$|,+/;e.openTag="{{",e.closeTag="}}";var z=function(a,b){var c=b.split(":"),d=c.shift(),e=c.join(":")||"";return e&&(e=", "+e),"$helpers."+d+"("+a+e+")"};e.parser=function(a){a=a.replace(/^\s/,"");var b=a.split(" "),c=b.shift(),e=b.join(" ");switch(c){case"if":a="if("+e+"){";break;case"else":b="if"===b.shift()?" if("+b.join(" ")+")":"",a="}else"+b+"{";break;case"/if":a="}";break;case"each":var f=b[0]||"$data",g=b[1]||"as",h=b[2]||"$value",i=b[3]||"$index",j=h+","+i;"as"!==g&&(f="[]"),a="$each("+f+",function("+j+"){";break;case"/each":a="});";break;case"echo":a="print("+e+");";break;case"print":case"include":a=c+"("+b.join(",")+");";break;default:if(/^\s*\|\s*[\w\$]/.test(e)){var k=!0;0===a.indexOf("#")&&(a=a.substr(1),k=!1);for(var l=0,m=a.split("|"),n=m.length,o=m[l++];n>l;l++)o=z(o,m[l]);a=(k?"=":"=#")+o}else a=d.helpers[c]?"=#"+c+"("+b.join(",")+");":"="+a}return a},"function"==typeof define?define(function(){return d}):"undefined"!=typeof exports?module.exports=d:this.template=d}();
3 0 \ No newline at end of file
src/main/resources/static/bootstrap-switch/css/bootstrap3/bootstrap-switch.css deleted 100644 → 0
1   -/**
2   - * bootstrap-switch - Turn checkboxes and radio buttons into toggle switches.
3   - *
4   - * @version v3.3.4
5   - * @homepage https://bttstrp.github.io/bootstrap-switch
6   - * @author Mattia Larentis <mattia@larentis.eu> (http://larentis.eu)
7   - * @license Apache-2.0
8   - */
9   -.bootstrap-switch {
10   - display: inline-block;
11   - direction: ltr;
12   - cursor: pointer;
13   - border-radius: 4px;
14   - border: 1px solid;
15   - border-color: #ccc;
16   - position: relative;
17   - text-align: left;
18   - overflow: hidden;
19   - line-height: 8px;
20   - z-index: 0;
21   - -webkit-user-select: none;
22   - -moz-user-select: none;
23   - -ms-user-select: none;
24   - user-select: none;
25   - vertical-align: middle;
26   - -webkit-transition: border-color ease-in-out .15s, box-shadow
27   - ease-in-out .15s;
28   - -o-transition: border-color ease-in-out .15s, box-shadow ease-in-out
29   - .15s;
30   - transition: border-color ease-in-out .15s, box-shadow ease-in-out .15s;
31   -}
32   -
33   -.bootstrap-switch .bootstrap-switch-container {
34   - display: inline-block;
35   - top: 0;
36   - border-radius: 4px;
37   - -webkit-transform: translate3d(0, 0, 0);
38   - transform: translate3d(0, 0, 0);
39   -}
40   -
41   -.bootstrap-switch .bootstrap-switch-handle-on, .bootstrap-switch .bootstrap-switch-handle-off,
42   - .bootstrap-switch .bootstrap-switch-label {
43   - -webkit-box-sizing: border-box;
44   - -moz-box-sizing: border-box;
45   - box-sizing: border-box;
46   - cursor: pointer;
47   - display: table-cell;
48   - vertical-align: middle;
49   - padding: 6px 12px;
50   - font-size: 14px;
51   - line-height: 20px;
52   -}
53   -
54   -.bootstrap-switch .bootstrap-switch-handle-on, .bootstrap-switch .bootstrap-switch-handle-off
55   - {
56   - text-align: center;
57   - z-index: 1;
58   -}
59   -
60   -.bootstrap-switch .bootstrap-switch-handle-on.bootstrap-switch-primary,
61   - .bootstrap-switch .bootstrap-switch-handle-off.bootstrap-switch-primary
62   - {
63   - color: #fff;
64   - background: #337ab7;
65   -}
66   -
67   -.bootstrap-switch .bootstrap-switch-handle-on.bootstrap-switch-info,
68   - .bootstrap-switch .bootstrap-switch-handle-off.bootstrap-switch-info {
69   - color: #fff;
70   - background: #5bc0de;
71   -}
72   -
73   -.bootstrap-switch .bootstrap-switch-handle-on.bootstrap-switch-success,
74   - .bootstrap-switch .bootstrap-switch-handle-off.bootstrap-switch-success
75   - {
76   - color: #fff;
77   - background: #5cb85c;
78   -}
79   -
80   -.bootstrap-switch .bootstrap-switch-handle-on.bootstrap-switch-warning,
81   - .bootstrap-switch .bootstrap-switch-handle-off.bootstrap-switch-warning
82   - {
83   - background: #f0ad4e;
84   - color: #fff;
85   -}
86   -
87   -.bootstrap-switch .bootstrap-switch-handle-on.bootstrap-switch-danger,
88   - .bootstrap-switch .bootstrap-switch-handle-off.bootstrap-switch-danger
89   - {
90   - color: #fff;
91   - background: #d9534f;
92   -}
93   -
94   -.bootstrap-switch .bootstrap-switch-handle-on.bootstrap-switch-default,
95   - .bootstrap-switch .bootstrap-switch-handle-off.bootstrap-switch-default
96   - {
97   - color: #000;
98   - background: #eeeeee;
99   -}
100   -
101   -.bootstrap-switch .bootstrap-switch-label {
102   - text-align: center;
103   - margin-top: -1px;
104   - margin-bottom: -1px;
105   - z-index: 100;
106   - color: #333;
107   - background: #fff;
108   -}
109   -
110   -.bootstrap-switch span::before {
111   - content: "\200b";
112   -}
113   -
114   -.bootstrap-switch .bootstrap-switch-handle-on {
115   - border-bottom-left-radius: 3px;
116   - border-top-left-radius: 3px;
117   -}
118   -
119   -.bootstrap-switch .bootstrap-switch-handle-off {
120   - border-bottom-right-radius: 3px;
121   - border-top-right-radius: 3px;
122   -}
123   -
124   -.bootstrap-switch input[type='radio'], .bootstrap-switch input[type='checkbox']
125   - {
126   - position: absolute !important;
127   - top: 0;
128   - left: 0;
129   - margin: 0;
130   - z-index: -1;
131   - opacity: 0;
132   - filter: alpha(opacity = 0);
133   - visibility: hidden;
134   -}
135   -
136   -.bootstrap-switch.bootstrap-switch-mini .bootstrap-switch-handle-on,
137   - .bootstrap-switch.bootstrap-switch-mini .bootstrap-switch-handle-off,
138   - .bootstrap-switch.bootstrap-switch-mini .bootstrap-switch-label {
139   - padding: 1px 5px;
140   - font-size: 12px;
141   - line-height: 1.5;
142   -}
143   -
144   -.bootstrap-switch.bootstrap-switch-small .bootstrap-switch-handle-on,
145   - .bootstrap-switch.bootstrap-switch-small .bootstrap-switch-handle-off,
146   - .bootstrap-switch.bootstrap-switch-small .bootstrap-switch-label {
147   - padding: 5px 10px;
148   - font-size: 12px;
149   - line-height: 1.5;
150   -}
151   -
152   -.bootstrap-switch.bootstrap-switch-large .bootstrap-switch-handle-on,
153   - .bootstrap-switch.bootstrap-switch-large .bootstrap-switch-handle-off,
154   - .bootstrap-switch.bootstrap-switch-large .bootstrap-switch-label {
155   - padding: 6px 16px;
156   - font-size: 18px;
157   - line-height: 1.3333333;
158   -}
159   -
160   -.bootstrap-switch.bootstrap-switch-disabled, .bootstrap-switch.bootstrap-switch-readonly,
161   - .bootstrap-switch.bootstrap-switch-indeterminate {
162   - cursor: default !important;
163   -}
164   -
165   -.bootstrap-switch.bootstrap-switch-disabled .bootstrap-switch-handle-on,
166   - .bootstrap-switch.bootstrap-switch-readonly .bootstrap-switch-handle-on,
167   - .bootstrap-switch.bootstrap-switch-indeterminate .bootstrap-switch-handle-on,
168   - .bootstrap-switch.bootstrap-switch-disabled .bootstrap-switch-handle-off,
169   - .bootstrap-switch.bootstrap-switch-readonly .bootstrap-switch-handle-off,
170   - .bootstrap-switch.bootstrap-switch-indeterminate .bootstrap-switch-handle-off,
171   - .bootstrap-switch.bootstrap-switch-disabled .bootstrap-switch-label,
172   - .bootstrap-switch.bootstrap-switch-readonly .bootstrap-switch-label,
173   - .bootstrap-switch.bootstrap-switch-indeterminate .bootstrap-switch-label
174   - {
175   - opacity: 0.5;
176   - filter: alpha(opacity = 50);
177   - cursor: default !important;
178   -}
179   -
180   -.bootstrap-switch.bootstrap-switch-animate .bootstrap-switch-container {
181   - -webkit-transition: margin-left 0.5s;
182   - -o-transition: margin-left 0.5s;
183   - transition: margin-left 0.5s;
184   -}
185   -
186   -.bootstrap-switch.bootstrap-switch-inverse .bootstrap-switch-handle-on {
187   - border-bottom-left-radius: 0;
188   - border-top-left-radius: 0;
189   - border-bottom-right-radius: 3px;
190   - border-top-right-radius: 3px;
191   -}
192   -
193   -.bootstrap-switch.bootstrap-switch-inverse .bootstrap-switch-handle-off
194   - {
195   - border-bottom-right-radius: 0;
196   - border-top-right-radius: 0;
197   - border-bottom-left-radius: 3px;
198   - border-top-left-radius: 3px;
199   -}
200   -
201   -.bootstrap-switch.bootstrap-switch-focused {
202   - border-color: #66afe9;
203   - outline: 0;
204   - -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075), 0 0 8px
205   - rgba(102, 175, 233, 0.6);
206   - box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075), 0 0 8px
207   - rgba(102, 175, 233, 0.6);
208   -}
209   -
210   -.bootstrap-switch.bootstrap-switch-on .bootstrap-switch-label,
211   - .bootstrap-switch.bootstrap-switch-inverse.bootstrap-switch-off .bootstrap-switch-label
212   - {
213   - border-bottom-right-radius: 3px;
214   - border-top-right-radius: 3px;
215   -}
216   -
217   -.bootstrap-switch.bootstrap-switch-off .bootstrap-switch-label,
218   - .bootstrap-switch.bootstrap-switch-inverse.bootstrap-switch-on .bootstrap-switch-label
219   - {
220   - border-bottom-left-radius: 3px;
221   - border-top-left-radius: 3px;
222   -}
223 0 \ No newline at end of file
src/main/resources/static/bootstrap-switch/css/bootstrap3/bootstrap-switch.min.css deleted 100644 → 0
1   -/**
2   - * bootstrap-switch - Turn checkboxes and radio buttons into toggle switches.
3   - *
4   - * @version v3.3.4
5   - * @homepage https://bttstrp.github.io/bootstrap-switch
6   - * @author Mattia Larentis <mattia@larentis.eu> (http://larentis.eu)
7   - * @license Apache-2.0
8   - */
9   -.bootstrap-switch {
10   - display: inline-block;
11   - direction: ltr;
12   - cursor: pointer;
13   - border-radius: 4px;
14   - border: 1px solid #ccc;
15   - position: relative;
16   - text-align: left;
17   - overflow: hidden;
18   - line-height: 8px;
19   - z-index: 0;
20   - -webkit-user-select: none;
21   - -moz-user-select: none;
22   - -ms-user-select: none;
23   - user-select: none;
24   - vertical-align: middle;
25   - -webkit-transition: border-color ease-in-out .15s, box-shadow
26   - ease-in-out .15s;
27   - -o-transition: border-color ease-in-out .15s, box-shadow ease-in-out
28   - .15s;
29   - transition: border-color ease-in-out .15s, box-shadow ease-in-out .15s
30   -}
31   -
32   -.bootstrap-switch .bootstrap-switch-container {
33   - display: inline-block;
34   - top: 0;
35   - border-radius: 4px;
36   - -webkit-transform: translate3d(0, 0, 0);
37   - transform: translate3d(0, 0, 0)
38   -}
39   -
40   -.bootstrap-switch .bootstrap-switch-handle-off, .bootstrap-switch .bootstrap-switch-handle-on,
41   - .bootstrap-switch .bootstrap-switch-label {
42   - -webkit-box-sizing: border-box;
43   - -moz-box-sizing: border-box;
44   - box-sizing: border-box;
45   - cursor: pointer;
46   - display: table-cell;
47   - vertical-align: middle;
48   - padding: 6px 12px;
49   - font-size: 14px;
50   - line-height: 20px
51   -}
52   -
53   -.bootstrap-switch .bootstrap-switch-handle-off, .bootstrap-switch .bootstrap-switch-handle-on
54   - {
55   - text-align: center;
56   - z-index: 1
57   -}
58   -
59   -.bootstrap-switch .bootstrap-switch-handle-off.bootstrap-switch-primary,
60   - .bootstrap-switch .bootstrap-switch-handle-on.bootstrap-switch-primary
61   - {
62   - color: #fff;
63   - background: #337ab7
64   -}
65   -
66   -.bootstrap-switch .bootstrap-switch-handle-off.bootstrap-switch-info,
67   - .bootstrap-switch .bootstrap-switch-handle-on.bootstrap-switch-info {
68   - color: #fff;
69   - background: #5bc0de
70   -}
71   -
72   -.bootstrap-switch .bootstrap-switch-handle-off.bootstrap-switch-success,
73   - .bootstrap-switch .bootstrap-switch-handle-on.bootstrap-switch-success
74   - {
75   - color: #fff;
76   - background: #5cb85c
77   -}
78   -
79   -.bootstrap-switch .bootstrap-switch-handle-off.bootstrap-switch-warning,
80   - .bootstrap-switch .bootstrap-switch-handle-on.bootstrap-switch-warning
81   - {
82   - background: #f0ad4e;
83   - color: #fff
84   -}
85   -
86   -.bootstrap-switch .bootstrap-switch-handle-off.bootstrap-switch-danger,
87   - .bootstrap-switch .bootstrap-switch-handle-on.bootstrap-switch-danger {
88   - color: #fff;
89   - background: #d9534f
90   -}
91   -
92   -.bootstrap-switch .bootstrap-switch-handle-off.bootstrap-switch-default,
93   - .bootstrap-switch .bootstrap-switch-handle-on.bootstrap-switch-default
94   - {
95   - color: #000;
96   - background: #eee
97   -}
98   -
99   -.bootstrap-switch .bootstrap-switch-label {
100   - text-align: center;
101   - margin-top: -1px;
102   - margin-bottom: -1px;
103   - z-index: 100;
104   - color: #333;
105   - background: #fff
106   -}
107   -
108   -.bootstrap-switch span::before {
109   - content: "\200b"
110   -}
111   -
112   -.bootstrap-switch .bootstrap-switch-handle-on {
113   - border-bottom-left-radius: 3px;
114   - border-top-left-radius: 3px
115   -}
116   -
117   -.bootstrap-switch .bootstrap-switch-handle-off {
118   - border-bottom-right-radius: 3px;
119   - border-top-right-radius: 3px
120   -}
121   -
122   -.bootstrap-switch input[type=radio], .bootstrap-switch input[type=checkbox]
123   - {
124   - position: absolute !important;
125   - top: 0;
126   - left: 0;
127   - margin: 0;
128   - z-index: -1;
129   - opacity: 0;
130   - filter: alpha(opacity = 0);
131   - visibility: hidden
132   -}
133   -
134   -.bootstrap-switch.bootstrap-switch-mini .bootstrap-switch-handle-off,
135   - .bootstrap-switch.bootstrap-switch-mini .bootstrap-switch-handle-on,
136   - .bootstrap-switch.bootstrap-switch-mini .bootstrap-switch-label {
137   - padding: 1px 5px;
138   - font-size: 12px;
139   - line-height: 1.5
140   -}
141   -
142   -.bootstrap-switch.bootstrap-switch-small .bootstrap-switch-handle-off,
143   - .bootstrap-switch.bootstrap-switch-small .bootstrap-switch-handle-on,
144   - .bootstrap-switch.bootstrap-switch-small .bootstrap-switch-label {
145   - padding: 5px 10px;
146   - font-size: 12px;
147   - line-height: 1.5
148   -}
149   -
150   -.bootstrap-switch.bootstrap-switch-large .bootstrap-switch-handle-off,
151   - .bootstrap-switch.bootstrap-switch-large .bootstrap-switch-handle-on,
152   - .bootstrap-switch.bootstrap-switch-large .bootstrap-switch-label {
153   - padding: 6px 16px;
154   - font-size: 18px;
155   - line-height: 1.3333333
156   -}
157   -
158   -.bootstrap-switch.bootstrap-switch-disabled, .bootstrap-switch.bootstrap-switch-indeterminate,
159   - .bootstrap-switch.bootstrap-switch-readonly {
160   - cursor: default !important
161   -}
162   -
163   -.bootstrap-switch.bootstrap-switch-disabled .bootstrap-switch-handle-off,
164   - .bootstrap-switch.bootstrap-switch-disabled .bootstrap-switch-handle-on,
165   - .bootstrap-switch.bootstrap-switch-disabled .bootstrap-switch-label,
166   - .bootstrap-switch.bootstrap-switch-indeterminate .bootstrap-switch-handle-off,
167   - .bootstrap-switch.bootstrap-switch-indeterminate .bootstrap-switch-handle-on,
168   - .bootstrap-switch.bootstrap-switch-indeterminate .bootstrap-switch-label,
169   - .bootstrap-switch.bootstrap-switch-readonly .bootstrap-switch-handle-off,
170   - .bootstrap-switch.bootstrap-switch-readonly .bootstrap-switch-handle-on,
171   - .bootstrap-switch.bootstrap-switch-readonly .bootstrap-switch-label {
172   - opacity: .5;
173   - filter: alpha(opacity = 50);
174   - cursor: default !important
175   -}
176   -
177   -.bootstrap-switch.bootstrap-switch-animate .bootstrap-switch-container {
178   - -webkit-transition: margin-left .5s;
179   - -o-transition: margin-left .5s;
180   - transition: margin-left .5s
181   -}
182   -
183   -.bootstrap-switch.bootstrap-switch-inverse .bootstrap-switch-handle-on {
184   - border-radius: 0 3px 3px 0
185   -}
186   -
187   -.bootstrap-switch.bootstrap-switch-inverse .bootstrap-switch-handle-off
188   - {
189   - border-radius: 3px 0 0 3px
190   -}
191   -
192   -.bootstrap-switch.bootstrap-switch-focused {
193   - border-color: #66afe9;
194   - outline: 0;
195   - -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075), 0 0 8px
196   - rgba(102, 175, 233, .6);
197   - box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075), 0 0 8px
198   - rgba(102, 175, 233, .6)
199   -}
200   -
201   -.bootstrap-switch.bootstrap-switch-inverse.bootstrap-switch-off .bootstrap-switch-label,
202   - .bootstrap-switch.bootstrap-switch-on .bootstrap-switch-label {
203   - border-bottom-right-radius: 3px;
204   - border-top-right-radius: 3px
205   -}
206   -
207   -.bootstrap-switch.bootstrap-switch-inverse.bootstrap-switch-on .bootstrap-switch-label,
208   - .bootstrap-switch.bootstrap-switch-off .bootstrap-switch-label {
209   - border-bottom-left-radius: 3px;
210   - border-top-left-radius: 3px
211   -}
212 0 \ No newline at end of file
src/main/resources/static/bootstrap-switch/js/bootstrap-switch.js deleted 100644 → 0
1   -/**
2   - * bootstrap-switch - Turn checkboxes and radio buttons into toggle switches.
3   - *
4   - * @version v3.3.4
5   - * @homepage https://bttstrp.github.io/bootstrap-switch
6   - * @author Mattia Larentis <mattia@larentis.eu> (http://larentis.eu)
7   - * @license Apache-2.0
8   - */
9   -
10   -(function (global, factory) {
11   - if (typeof define === "function" && define.amd) {
12   - define(['jquery'], factory);
13   - } else if (typeof exports !== "undefined") {
14   - factory(require('jquery'));
15   - } else {
16   - var mod = {
17   - exports: {}
18   - };
19   - factory(global.jquery);
20   - global.bootstrapSwitch = mod.exports;
21   - }
22   -})(this, function (_jquery) {
23   - 'use strict';
24   -
25   - var _jquery2 = _interopRequireDefault(_jquery);
26   -
27   - function _interopRequireDefault(obj) {
28   - return obj && obj.__esModule ? obj : {
29   - default: obj
30   - };
31   - }
32   -
33   - var _extends = Object.assign || function (target) {
34   - for (var i = 1; i < arguments.length; i++) {
35   - var source = arguments[i];
36   -
37   - for (var key in source) {
38   - if (Object.prototype.hasOwnProperty.call(source, key)) {
39   - target[key] = source[key];
40   - }
41   - }
42   - }
43   -
44   - return target;
45   - };
46   -
47   - function _classCallCheck(instance, Constructor) {
48   - if (!(instance instanceof Constructor)) {
49   - throw new TypeError("Cannot call a class as a function");
50   - }
51   - }
52   -
53   - var _createClass = function () {
54   - function defineProperties(target, props) {
55   - for (var i = 0; i < props.length; i++) {
56   - var descriptor = props[i];
57   - descriptor.enumerable = descriptor.enumerable || false;
58   - descriptor.configurable = true;
59   - if ("value" in descriptor) descriptor.writable = true;
60   - Object.defineProperty(target, descriptor.key, descriptor);
61   - }
62   - }
63   -
64   - return function (Constructor, protoProps, staticProps) {
65   - if (protoProps) defineProperties(Constructor.prototype, protoProps);
66   - if (staticProps) defineProperties(Constructor, staticProps);
67   - return Constructor;
68   - };
69   - }();
70   -
71   - var $ = _jquery2.default || window.jQuery || window.$;
72   -
73   - var BootstrapSwitch = function () {
74   - function BootstrapSwitch(element) {
75   - var _this = this;
76   -
77   - var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
78   -
79   - _classCallCheck(this, BootstrapSwitch);
80   -
81   - this.$element = $(element);
82   - this.options = $.extend({}, $.fn.bootstrapSwitch.defaults, this._getElementOptions(), options);
83   - this.prevOptions = {};
84   - this.$wrapper = $('<div>', {
85   - class: function _class() {
86   - var classes = [];
87   - classes.push(_this.options.state ? 'on' : 'off');
88   - if (_this.options.size) {
89   - classes.push(_this.options.size);
90   - }
91   - if (_this.options.disabled) {
92   - classes.push('disabled');
93   - }
94   - if (_this.options.readonly) {
95   - classes.push('readonly');
96   - }
97   - if (_this.options.indeterminate) {
98   - classes.push('indeterminate');
99   - }
100   - if (_this.options.inverse) {
101   - classes.push('inverse');
102   - }
103   - if (_this.$element.attr('id')) {
104   - classes.push('id-' + _this.$element.attr('id'));
105   - }
106   - return classes.map(_this._getClass.bind(_this)).concat([_this.options.baseClass], _this._getClasses(_this.options.wrapperClass)).join(' ');
107   - }
108   - });
109   - this.$container = $('<div>', { class: this._getClass('container') });
110   - this.$on = $('<span>', {
111   - html: this.options.onText,
112   - class: this._getClass('handle-on') + ' ' + this._getClass(this.options.onColor)
113   - });
114   - this.$off = $('<span>', {
115   - html: this.options.offText,
116   - class: this._getClass('handle-off') + ' ' + this._getClass(this.options.offColor)
117   - });
118   - this.$label = $('<span>', {
119   - html: this.options.labelText,
120   - class: this._getClass('label')
121   - });
122   -
123   - this.$element.on('init.bootstrapSwitch', this.options.onInit.bind(this, element));
124   - this.$element.on('switchChange.bootstrapSwitch', function () {
125   - for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) {
126   - args[_key] = arguments[_key];
127   - }
128   -
129   - if (_this.options.onSwitchChange.apply(element, args) === false) {
130   - if (_this.$element.is(':radio')) {
131   - $('[name="' + _this.$element.attr('name') + '"]').trigger('previousState.bootstrapSwitch', true);
132   - } else {
133   - _this.$element.trigger('previousState.bootstrapSwitch', true);
134   - }
135   - }
136   - });
137   -
138   - this.$container = this.$element.wrap(this.$container).parent();
139   - this.$wrapper = this.$container.wrap(this.$wrapper).parent();
140   - this.$element.before(this.options.inverse ? this.$off : this.$on).before(this.$label).before(this.options.inverse ? this.$on : this.$off);
141   -
142   - if (this.options.indeterminate) {
143   - this.$element.prop('indeterminate', true);
144   - }
145   -
146   - this._init();
147   - this._elementHandlers();
148   - this._handleHandlers();
149   - this._labelHandlers();
150   - this._formHandler();
151   - this._externalLabelHandler();
152   - this.$element.trigger('init.bootstrapSwitch', this.options.state);
153   - }
154   -
155   - _createClass(BootstrapSwitch, [{
156   - key: 'setPrevOptions',
157   - value: function setPrevOptions() {
158   - this.prevOptions = _extends({}, this.options);
159   - }
160   - }, {
161   - key: 'state',
162   - value: function state(value, skip) {
163   - if (typeof value === 'undefined') {
164   - return this.options.state;
165   - }
166   - if (this.options.disabled || this.options.readonly || this.options.state && !this.options.radioAllOff && this.$element.is(':radio')) {
167   - return this.$element;
168   - }
169   - if (this.$element.is(':radio')) {
170   - $('[name="' + this.$element.attr('name') + '"]').trigger('setPreviousOptions.bootstrapSwitch');
171   - } else {
172   - this.$element.trigger('setPreviousOptions.bootstrapSwitch');
173   - }
174   - if (this.options.indeterminate) {
175   - this.indeterminate(false);
176   - }
177   - this.$element.prop('checked', Boolean(value)).trigger('change.bootstrapSwitch', skip);
178   - return this.$element;
179   - }
180   - }, {
181   - key: 'toggleState',
182   - value: function toggleState(skip) {
183   - if (this.options.disabled || this.options.readonly) {
184   - return this.$element;
185   - }
186   - if (this.options.indeterminate) {
187   - this.indeterminate(false);
188   - return this.state(true);
189   - } else {
190   - return this.$element.prop('checked', !this.options.state).trigger('change.bootstrapSwitch', skip);
191   - }
192   - }
193   - }, {
194   - key: 'size',
195   - value: function size(value) {
196   - if (typeof value === 'undefined') {
197   - return this.options.size;
198   - }
199   - if (this.options.size != null) {
200   - this.$wrapper.removeClass(this._getClass(this.options.size));
201   - }
202   - if (value) {
203   - this.$wrapper.addClass(this._getClass(value));
204   - }
205   - this._width();
206   - this._containerPosition();
207   - this.options.size = value;
208   - return this.$element;
209   - }
210   - }, {
211   - key: 'animate',
212   - value: function animate(value) {
213   - if (typeof value === 'undefined') {
214   - return this.options.animate;
215   - }
216   - if (this.options.animate === Boolean(value)) {
217   - return this.$element;
218   - }
219   - return this.toggleAnimate();
220   - }
221   - }, {
222   - key: 'toggleAnimate',
223   - value: function toggleAnimate() {
224   - this.options.animate = !this.options.animate;
225   - this.$wrapper.toggleClass(this._getClass('animate'));
226   - return this.$element;
227   - }
228   - }, {
229   - key: 'disabled',
230   - value: function disabled(value) {
231   - if (typeof value === 'undefined') {
232   - return this.options.disabled;
233   - }
234   - if (this.options.disabled === Boolean(value)) {
235   - return this.$element;
236   - }
237   - return this.toggleDisabled();
238   - }
239   - }, {
240   - key: 'toggleDisabled',
241   - value: function toggleDisabled() {
242   - this.options.disabled = !this.options.disabled;
243   - this.$element.prop('disabled', this.options.disabled);
244   - this.$wrapper.toggleClass(this._getClass('disabled'));
245   - return this.$element;
246   - }
247   - }, {
248   - key: 'readonly',
249   - value: function readonly(value) {
250   - if (typeof value === 'undefined') {
251   - return this.options.readonly;
252   - }
253   - if (this.options.readonly === Boolean(value)) {
254   - return this.$element;
255   - }
256   - return this.toggleReadonly();
257   - }
258   - }, {
259   - key: 'toggleReadonly',
260   - value: function toggleReadonly() {
261   - this.options.readonly = !this.options.readonly;
262   - this.$element.prop('readonly', this.options.readonly);
263   - this.$wrapper.toggleClass(this._getClass('readonly'));
264   - return this.$element;
265   - }
266   - }, {
267   - key: 'indeterminate',
268   - value: function indeterminate(value) {
269   - if (typeof value === 'undefined') {
270   - return this.options.indeterminate;
271   - }
272   - if (this.options.indeterminate === Boolean(value)) {
273   - return this.$element;
274   - }
275   - return this.toggleIndeterminate();
276   - }
277   - }, {
278   - key: 'toggleIndeterminate',
279   - value: function toggleIndeterminate() {
280   - this.options.indeterminate = !this.options.indeterminate;
281   - this.$element.prop('indeterminate', this.options.indeterminate);
282   - this.$wrapper.toggleClass(this._getClass('indeterminate'));
283   - this._containerPosition();
284   - return this.$element;
285   - }
286   - }, {
287   - key: 'inverse',
288   - value: function inverse(value) {
289   - if (typeof value === 'undefined') {
290   - return this.options.inverse;
291   - }
292   - if (this.options.inverse === Boolean(value)) {
293   - return this.$element;
294   - }
295   - return this.toggleInverse();
296   - }
297   - }, {
298   - key: 'toggleInverse',
299   - value: function toggleInverse() {
300   - this.$wrapper.toggleClass(this._getClass('inverse'));
301   - var $on = this.$on.clone(true);
302   - var $off = this.$off.clone(true);
303   - this.$on.replaceWith($off);
304   - this.$off.replaceWith($on);
305   - this.$on = $off;
306   - this.$off = $on;
307   - this.options.inverse = !this.options.inverse;
308   - return this.$element;
309   - }
310   - }, {
311   - key: 'onColor',
312   - value: function onColor(value) {
313   - if (typeof value === 'undefined') {
314   - return this.options.onColor;
315   - }
316   - if (this.options.onColor) {
317   - this.$on.removeClass(this._getClass(this.options.onColor));
318   - }
319   - this.$on.addClass(this._getClass(value));
320   - this.options.onColor = value;
321   - return this.$element;
322   - }
323   - }, {
324   - key: 'offColor',
325   - value: function offColor(value) {
326   - if (typeof value === 'undefined') {
327   - return this.options.offColor;
328   - }
329   - if (this.options.offColor) {
330   - this.$off.removeClass(this._getClass(this.options.offColor));
331   - }
332   - this.$off.addClass(this._getClass(value));
333   - this.options.offColor = value;
334   - return this.$element;
335   - }
336   - }, {
337   - key: 'onText',
338   - value: function onText(value) {
339   - if (typeof value === 'undefined') {
340   - return this.options.onText;
341   - }
342   - this.$on.html(value);
343   - this._width();
344   - this._containerPosition();
345   - this.options.onText = value;
346   - return this.$element;
347   - }
348   - }, {
349   - key: 'offText',
350   - value: function offText(value) {
351   - if (typeof value === 'undefined') {
352   - return this.options.offText;
353   - }
354   - this.$off.html(value);
355   - this._width();
356   - this._containerPosition();
357   - this.options.offText = value;
358   - return this.$element;
359   - }
360   - }, {
361   - key: 'labelText',
362   - value: function labelText(value) {
363   - if (typeof value === 'undefined') {
364   - return this.options.labelText;
365   - }
366   - this.$label.html(value);
367   - this._width();
368   - this.options.labelText = value;
369   - return this.$element;
370   - }
371   - }, {
372   - key: 'handleWidth',
373   - value: function handleWidth(value) {
374   - if (typeof value === 'undefined') {
375   - return this.options.handleWidth;
376   - }
377   - this.options.handleWidth = value;
378   - this._width();
379   - this._containerPosition();
380   - return this.$element;
381   - }
382   - }, {
383   - key: 'labelWidth',
384   - value: function labelWidth(value) {
385   - if (typeof value === 'undefined') {
386   - return this.options.labelWidth;
387   - }
388   - this.options.labelWidth = value;
389   - this._width();
390   - this._containerPosition();
391   - return this.$element;
392   - }
393   - }, {
394   - key: 'baseClass',
395   - value: function baseClass(value) {
396   - return this.options.baseClass;
397   - }
398   - }, {
399   - key: 'wrapperClass',
400   - value: function wrapperClass(value) {
401   - if (typeof value === 'undefined') {
402   - return this.options.wrapperClass;
403   - }
404   - if (!value) {
405   - value = $.fn.bootstrapSwitch.defaults.wrapperClass;
406   - }
407   - this.$wrapper.removeClass(this._getClasses(this.options.wrapperClass).join(' '));
408   - this.$wrapper.addClass(this._getClasses(value).join(' '));
409   - this.options.wrapperClass = value;
410   - return this.$element;
411   - }
412   - }, {
413   - key: 'radioAllOff',
414   - value: function radioAllOff(value) {
415   - if (typeof value === 'undefined') {
416   - return this.options.radioAllOff;
417   - }
418   - var val = Boolean(value);
419   - if (this.options.radioAllOff === val) {
420   - return this.$element;
421   - }
422   - this.options.radioAllOff = val;
423   - return this.$element;
424   - }
425   - }, {
426   - key: 'onInit',
427   - value: function onInit(value) {
428   - if (typeof value === 'undefined') {
429   - return this.options.onInit;
430   - }
431   - if (!value) {
432   - value = $.fn.bootstrapSwitch.defaults.onInit;
433   - }
434   - this.options.onInit = value;
435   - return this.$element;
436   - }
437   - }, {
438   - key: 'onSwitchChange',
439   - value: function onSwitchChange(value) {
440   - if (typeof value === 'undefined') {
441   - return this.options.onSwitchChange;
442   - }
443   - if (!value) {
444   - value = $.fn.bootstrapSwitch.defaults.onSwitchChange;
445   - }
446   - this.options.onSwitchChange = value;
447   - return this.$element;
448   - }
449   - }, {
450   - key: 'destroy',
451   - value: function destroy() {
452   - var $form = this.$element.closest('form');
453   - if ($form.length) {
454   - $form.off('reset.bootstrapSwitch').removeData('bootstrap-switch');
455   - }
456   - this.$container.children().not(this.$element).remove();
457   - this.$element.unwrap().unwrap().off('.bootstrapSwitch').removeData('bootstrap-switch');
458   - return this.$element;
459   - }
460   - }, {
461   - key: '_getElementOptions',
462   - value: function _getElementOptions() {
463   - return {
464   - state: this.$element.is(':checked'),
465   - size: this.$element.data('size'),
466   - animate: this.$element.data('animate'),
467   - disabled: this.$element.is(':disabled'),
468   - readonly: this.$element.is('[readonly]'),
469   - indeterminate: this.$element.data('indeterminate'),
470   - inverse: this.$element.data('inverse'),
471   - radioAllOff: this.$element.data('radio-all-off'),
472   - onColor: this.$element.data('on-color'),
473   - offColor: this.$element.data('off-color'),
474   - onText: this.$element.data('on-text'),
475   - offText: this.$element.data('off-text'),
476   - labelText: this.$element.data('label-text'),
477   - handleWidth: this.$element.data('handle-width'),
478   - labelWidth: this.$element.data('label-width'),
479   - baseClass: this.$element.data('base-class'),
480   - wrapperClass: this.$element.data('wrapper-class')
481   - };
482   - }
483   - }, {
484   - key: '_width',
485   - value: function _width() {
486   - var _this2 = this;
487   -
488   - var $handles = this.$on.add(this.$off).add(this.$label).css('width', '');
489   - var handleWidth = this.options.handleWidth === 'auto' ? Math.round(Math.max(this.$on.width(), this.$off.width())) : this.options.handleWidth;
490   - $handles.width(handleWidth);
491   - this.$label.width(function (index, width) {
492   - if (_this2.options.labelWidth !== 'auto') {
493   - return _this2.options.labelWidth;
494   - }
495   - if (width < handleWidth) {
496   - return handleWidth;
497   - }
498   - return width;
499   - });
500   - this._handleWidth = this.$on.outerWidth();
501   - this._labelWidth = this.$label.outerWidth();
502   - this.$container.width(this._handleWidth * 2 + this._labelWidth);
503   - return this.$wrapper.width(this._handleWidth + this._labelWidth);
504   - }
505   - }, {
506   - key: '_containerPosition',
507   - value: function _containerPosition() {
508   - var _this3 = this;
509   -
510   - var state = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : this.options.state;
511   - var callback = arguments[1];
512   -
513   - this.$container.css('margin-left', function () {
514   - var values = [0, '-' + _this3._handleWidth + 'px'];
515   - if (_this3.options.indeterminate) {
516   - return '-' + _this3._handleWidth / 2 + 'px';
517   - }
518   - if (state) {
519   - if (_this3.options.inverse) {
520   - return values[1];
521   - } else {
522   - return values[0];
523   - }
524   - } else {
525   - if (_this3.options.inverse) {
526   - return values[0];
527   - } else {
528   - return values[1];
529   - }
530   - }
531   - });
532   - }
533   - }, {
534   - key: '_init',
535   - value: function _init() {
536   - var _this4 = this;
537   -
538   - var init = function init() {
539   - _this4.setPrevOptions();
540   - _this4._width();
541   - _this4._containerPosition();
542   - setTimeout(function () {
543   - if (_this4.options.animate) {
544   - return _this4.$wrapper.addClass(_this4._getClass('animate'));
545   - }
546   - }, 50);
547   - };
548   - if (this.$wrapper.is(':visible')) {
549   - init();
550   - return;
551   - }
552   - var initInterval = window.setInterval(function () {
553   - if (_this4.$wrapper.is(':visible')) {
554   - init();
555   - return window.clearInterval(initInterval);
556   - }
557   - }, 50);
558   - }
559   - }, {
560   - key: '_elementHandlers',
561   - value: function _elementHandlers() {
562   - var _this5 = this;
563   -
564   - return this.$element.on({
565   - 'setPreviousOptions.bootstrapSwitch': this.setPrevOptions.bind(this),
566   -
567   - 'previousState.bootstrapSwitch': function previousStateBootstrapSwitch() {
568   - _this5.options = _this5.prevOptions;
569   - if (_this5.options.indeterminate) {
570   - _this5.$wrapper.addClass(_this5._getClass('indeterminate'));
571   - }
572   - _this5.$element.prop('checked', _this5.options.state).trigger('change.bootstrapSwitch', true);
573   - },
574   -
575   - 'change.bootstrapSwitch': function changeBootstrapSwitch(event, skip) {
576   - event.preventDefault();
577   - event.stopImmediatePropagation();
578   - var state = _this5.$element.is(':checked');
579   - _this5._containerPosition(state);
580   - if (state === _this5.options.state) {
581   - return;
582   - }
583   - _this5.options.state = state;
584   - _this5.$wrapper.toggleClass(_this5._getClass('off')).toggleClass(_this5._getClass('on'));
585   - if (!skip) {
586   - if (_this5.$element.is(':radio')) {
587   - $('[name="' + _this5.$element.attr('name') + '"]').not(_this5.$element).prop('checked', false).trigger('change.bootstrapSwitch', true);
588   - }
589   - _this5.$element.trigger('switchChange.bootstrapSwitch', [state]);
590   - }
591   - },
592   -
593   - 'focus.bootstrapSwitch': function focusBootstrapSwitch(event) {
594   - event.preventDefault();
595   - _this5.$wrapper.addClass(_this5._getClass('focused'));
596   - },
597   -
598   - 'blur.bootstrapSwitch': function blurBootstrapSwitch(event) {
599   - event.preventDefault();
600   - _this5.$wrapper.removeClass(_this5._getClass('focused'));
601   - },
602   -
603   - 'keydown.bootstrapSwitch': function keydownBootstrapSwitch(event) {
604   - if (!event.which || _this5.options.disabled || _this5.options.readonly) {
605   - return;
606   - }
607   - if (event.which === 37 || event.which === 39) {
608   - event.preventDefault();
609   - event.stopImmediatePropagation();
610   - _this5.state(event.which === 39);
611   - }
612   - }
613   - });
614   - }
615   - }, {
616   - key: '_handleHandlers',
617   - value: function _handleHandlers() {
618   - var _this6 = this;
619   -
620   - this.$on.on('click.bootstrapSwitch', function (event) {
621   - event.preventDefault();
622   - event.stopPropagation();
623   - _this6.state(false);
624   - return _this6.$element.trigger('focus.bootstrapSwitch');
625   - });
626   - return this.$off.on('click.bootstrapSwitch', function (event) {
627   - event.preventDefault();
628   - event.stopPropagation();
629   - _this6.state(true);
630   - return _this6.$element.trigger('focus.bootstrapSwitch');
631   - });
632   - }
633   - }, {
634   - key: '_labelHandlers',
635   - value: function _labelHandlers() {
636   - var _this7 = this;
637   -
638   - var handlers = {
639   - click: function click(event) {
640   - event.stopPropagation();
641   - },
642   -
643   -
644   - 'mousedown.bootstrapSwitch touchstart.bootstrapSwitch': function mousedownBootstrapSwitchTouchstartBootstrapSwitch(event) {
645   - if (_this7._dragStart || _this7.options.disabled || _this7.options.readonly) {
646   - return;
647   - }
648   - event.preventDefault();
649   - event.stopPropagation();
650   - _this7._dragStart = (event.pageX || event.originalEvent.touches[0].pageX) - parseInt(_this7.$container.css('margin-left'), 10);
651   - if (_this7.options.animate) {
652   - _this7.$wrapper.removeClass(_this7._getClass('animate'));
653   - }
654   - _this7.$element.trigger('focus.bootstrapSwitch');
655   - },
656   -
657   - 'mousemove.bootstrapSwitch touchmove.bootstrapSwitch': function mousemoveBootstrapSwitchTouchmoveBootstrapSwitch(event) {
658   - if (_this7._dragStart == null) {
659   - return;
660   - }
661   - var difference = (event.pageX || event.originalEvent.touches[0].pageX) - _this7._dragStart;
662   - event.preventDefault();
663   - if (difference < -_this7._handleWidth || difference > 0) {
664   - return;
665   - }
666   - _this7._dragEnd = difference;
667   - _this7.$container.css('margin-left', _this7._dragEnd + 'px');
668   - },
669   -
670   - 'mouseup.bootstrapSwitch touchend.bootstrapSwitch': function mouseupBootstrapSwitchTouchendBootstrapSwitch(event) {
671   - if (!_this7._dragStart) {
672   - return;
673   - }
674   - event.preventDefault();
675   - if (_this7.options.animate) {
676   - _this7.$wrapper.addClass(_this7._getClass('animate'));
677   - }
678   - if (_this7._dragEnd) {
679   - var state = _this7._dragEnd > -(_this7._handleWidth / 2);
680   - _this7._dragEnd = false;
681   - _this7.state(_this7.options.inverse ? !state : state);
682   - } else {
683   - _this7.state(!_this7.options.state);
684   - }
685   - _this7._dragStart = false;
686   - },
687   -
688   - 'mouseleave.bootstrapSwitch': function mouseleaveBootstrapSwitch() {
689   - _this7.$label.trigger('mouseup.bootstrapSwitch');
690   - }
691   - };
692   - this.$label.on(handlers);
693   - }
694   - }, {
695   - key: '_externalLabelHandler',
696   - value: function _externalLabelHandler() {
697   - var _this8 = this;
698   -
699   - var $externalLabel = this.$element.closest('label');
700   - $externalLabel.on('click', function (event) {
701   - event.preventDefault();
702   - event.stopImmediatePropagation();
703   - if (event.target === $externalLabel[0]) {
704   - _this8.toggleState();
705   - }
706   - });
707   - }
708   - }, {
709   - key: '_formHandler',
710   - value: function _formHandler() {
711   - var $form = this.$element.closest('form');
712   - if ($form.data('bootstrap-switch')) {
713   - return;
714   - }
715   - $form.on('reset.bootstrapSwitch', function () {
716   - window.setTimeout(function () {
717   - $form.find('input').filter(function () {
718   - return $(this).data('bootstrap-switch');
719   - }).each(function () {
720   - return $(this).bootstrapSwitch('state', this.checked);
721   - });
722   - }, 1);
723   - }).data('bootstrap-switch', true);
724   - }
725   - }, {
726   - key: '_getClass',
727   - value: function _getClass(name) {
728   - return this.options.baseClass + '-' + name;
729   - }
730   - }, {
731   - key: '_getClasses',
732   - value: function _getClasses(classes) {
733   - if (!$.isArray(classes)) {
734   - return [this._getClass(classes)];
735   - }
736   - return classes.map(this._getClass.bind(this));
737   - }
738   - }]);
739   -
740   - return BootstrapSwitch;
741   - }();
742   -
743   - $.fn.bootstrapSwitch = function (option) {
744   - for (var _len2 = arguments.length, args = Array(_len2 > 1 ? _len2 - 1 : 0), _key2 = 1; _key2 < _len2; _key2++) {
745   - args[_key2 - 1] = arguments[_key2];
746   - }
747   -
748   - function reducer(ret, next) {
749   - var $this = $(next);
750   - var existingData = $this.data('bootstrap-switch');
751   - var data = existingData || new BootstrapSwitch(next, option);
752   - if (!existingData) {
753   - $this.data('bootstrap-switch', data);
754   - }
755   - if (typeof option === 'string') {
756   - return data[option].apply(data, args);
757   - }
758   - return ret;
759   - }
760   - return Array.prototype.reduce.call(this, reducer, this);
761   - };
762   - $.fn.bootstrapSwitch.Constructor = BootstrapSwitch;
763   - $.fn.bootstrapSwitch.defaults = {
764   - state: true,
765   - size: null,
766   - animate: true,
767   - disabled: false,
768   - readonly: false,
769   - indeterminate: false,
770   - inverse: false,
771   - radioAllOff: false,
772   - onColor: 'primary',
773   - offColor: 'default',
774   - onText: 'ON',
775   - offText: 'OFF',
776   - labelText: '&nbsp',
777   - handleWidth: 'auto',
778   - labelWidth: 'auto',
779   - baseClass: 'bootstrap-switch',
780   - wrapperClass: 'wrapper',
781   - onInit: function onInit() {},
782   - onSwitchChange: function onSwitchChange() {}
783   - };
784   -});
src/main/resources/static/bootstrap-switch/js/bootstrap-switch.min.js deleted 100644 → 0
1   -/**
2   - * bootstrap-switch - Turn checkboxes and radio buttons into toggle switches.
3   - *
4   - * @version v3.3.4
5   - * @homepage https://bttstrp.github.io/bootstrap-switch
6   - * @author Mattia Larentis <mattia@larentis.eu> (http://larentis.eu)
7   - * @license Apache-2.0
8   - */
9   -
10   -(function(a,b){if('function'==typeof define&&define.amd)define(['jquery'],b);else if('undefined'!=typeof exports)b(require('jquery'));else{b(a.jquery),a.bootstrapSwitch={exports:{}}.exports}})(this,function(a){'use strict';function c(j,k){if(!(j instanceof k))throw new TypeError('Cannot call a class as a function')}var d=function(j){return j&&j.__esModule?j:{default:j}}(a),e=Object.assign||function(j){for(var l,k=1;k<arguments.length;k++)for(var m in l=arguments[k],l)Object.prototype.hasOwnProperty.call(l,m)&&(j[m]=l[m]);return j},f=function(){function j(k,l){for(var n,m=0;m<l.length;m++)n=l[m],n.enumerable=n.enumerable||!1,n.configurable=!0,'value'in n&&(n.writable=!0),Object.defineProperty(k,n.key,n)}return function(k,l,m){return l&&j(k.prototype,l),m&&j(k,m),k}}(),g=d.default||window.jQuery||window.$,h=function(){function j(k){var l=this,m=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};c(this,j),this.$element=g(k),this.options=g.extend({},g.fn.bootstrapSwitch.defaults,this._getElementOptions(),m),this.prevOptions={},this.$wrapper=g('<div>',{class:function(){var o=[];return o.push(l.options.state?'on':'off'),l.options.size&&o.push(l.options.size),l.options.disabled&&o.push('disabled'),l.options.readonly&&o.push('readonly'),l.options.indeterminate&&o.push('indeterminate'),l.options.inverse&&o.push('inverse'),l.$element.attr('id')&&o.push('id-'+l.$element.attr('id')),o.map(l._getClass.bind(l)).concat([l.options.baseClass],l._getClasses(l.options.wrapperClass)).join(' ')}}),this.$container=g('<div>',{class:this._getClass('container')}),this.$on=g('<span>',{html:this.options.onText,class:this._getClass('handle-on')+' '+this._getClass(this.options.onColor)}),this.$off=g('<span>',{html:this.options.offText,class:this._getClass('handle-off')+' '+this._getClass(this.options.offColor)}),this.$label=g('<span>',{html:this.options.labelText,class:this._getClass('label')}),this.$element.on('init.bootstrapSwitch',this.options.onInit.bind(this,k)),this.$element.on('switchChange.bootstrapSwitch',function(){for(var n=arguments.length,o=Array(n),p=0;p<n;p++)o[p]=arguments[p];!1===l.options.onSwitchChange.apply(k,o)&&(l.$element.is(':radio')?g('[name="'+l.$element.attr('name')+'"]').trigger('previousState.bootstrapSwitch',!0):l.$element.trigger('previousState.bootstrapSwitch',!0))}),this.$container=this.$element.wrap(this.$container).parent(),this.$wrapper=this.$container.wrap(this.$wrapper).parent(),this.$element.before(this.options.inverse?this.$off:this.$on).before(this.$label).before(this.options.inverse?this.$on:this.$off),this.options.indeterminate&&this.$element.prop('indeterminate',!0),this._init(),this._elementHandlers(),this._handleHandlers(),this._labelHandlers(),this._formHandler(),this._externalLabelHandler(),this.$element.trigger('init.bootstrapSwitch',this.options.state)}return f(j,[{key:'setPrevOptions',value:function(){this.prevOptions=e({},this.options)}},{key:'state',value:function(l,m){return'undefined'==typeof l?this.options.state:this.options.disabled||this.options.readonly||this.options.state&&!this.options.radioAllOff&&this.$element.is(':radio')?this.$element:(this.$element.is(':radio')?g('[name="'+this.$element.attr('name')+'"]').trigger('setPreviousOptions.bootstrapSwitch'):this.$element.trigger('setPreviousOptions.bootstrapSwitch'),this.options.indeterminate&&this.indeterminate(!1),this.$element.prop('checked',!!l).trigger('change.bootstrapSwitch',m),this.$element)}},{key:'toggleState',value:function(l){return this.options.disabled||this.options.readonly?this.$element:this.options.indeterminate?(this.indeterminate(!1),this.state(!0)):this.$element.prop('checked',!this.options.state).trigger('change.bootstrapSwitch',l)}},{key:'size',value:function(l){return'undefined'==typeof l?this.options.size:(null!=this.options.size&&this.$wrapper.removeClass(this._getClass(this.options.size)),l&&this.$wrapper.addClass(this._getClass(l)),this._width(),this._containerPosition(),this.options.size=l,this.$element)}},{key:'animate',value:function(l){return'undefined'==typeof l?this.options.animate:this.options.animate===!!l?this.$element:this.toggleAnimate()}},{key:'toggleAnimate',value:function(){return this.options.animate=!this.options.animate,this.$wrapper.toggleClass(this._getClass('animate')),this.$element}},{key:'disabled',value:function(l){return'undefined'==typeof l?this.options.disabled:this.options.disabled===!!l?this.$element:this.toggleDisabled()}},{key:'toggleDisabled',value:function(){return this.options.disabled=!this.options.disabled,this.$element.prop('disabled',this.options.disabled),this.$wrapper.toggleClass(this._getClass('disabled')),this.$element}},{key:'readonly',value:function(l){return'undefined'==typeof l?this.options.readonly:this.options.readonly===!!l?this.$element:this.toggleReadonly()}},{key:'toggleReadonly',value:function(){return this.options.readonly=!this.options.readonly,this.$element.prop('readonly',this.options.readonly),this.$wrapper.toggleClass(this._getClass('readonly')),this.$element}},{key:'indeterminate',value:function(l){return'undefined'==typeof l?this.options.indeterminate:this.options.indeterminate===!!l?this.$element:this.toggleIndeterminate()}},{key:'toggleIndeterminate',value:function(){return this.options.indeterminate=!this.options.indeterminate,this.$element.prop('indeterminate',this.options.indeterminate),this.$wrapper.toggleClass(this._getClass('indeterminate')),this._containerPosition(),this.$element}},{key:'inverse',value:function(l){return'undefined'==typeof l?this.options.inverse:this.options.inverse===!!l?this.$element:this.toggleInverse()}},{key:'toggleInverse',value:function(){this.$wrapper.toggleClass(this._getClass('inverse'));var l=this.$on.clone(!0),m=this.$off.clone(!0);return this.$on.replaceWith(m),this.$off.replaceWith(l),this.$on=m,this.$off=l,this.options.inverse=!this.options.inverse,this.$element}},{key:'onColor',value:function(l){return'undefined'==typeof l?this.options.onColor:(this.options.onColor&&this.$on.removeClass(this._getClass(this.options.onColor)),this.$on.addClass(this._getClass(l)),this.options.onColor=l,this.$element)}},{key:'offColor',value:function(l){return'undefined'==typeof l?this.options.offColor:(this.options.offColor&&this.$off.removeClass(this._getClass(this.options.offColor)),this.$off.addClass(this._getClass(l)),this.options.offColor=l,this.$element)}},{key:'onText',value:function(l){return'undefined'==typeof l?this.options.onText:(this.$on.html(l),this._width(),this._containerPosition(),this.options.onText=l,this.$element)}},{key:'offText',value:function(l){return'undefined'==typeof l?this.options.offText:(this.$off.html(l),this._width(),this._containerPosition(),this.options.offText=l,this.$element)}},{key:'labelText',value:function(l){return'undefined'==typeof l?this.options.labelText:(this.$label.html(l),this._width(),this.options.labelText=l,this.$element)}},{key:'handleWidth',value:function(l){return'undefined'==typeof l?this.options.handleWidth:(this.options.handleWidth=l,this._width(),this._containerPosition(),this.$element)}},{key:'labelWidth',value:function(l){return'undefined'==typeof l?this.options.labelWidth:(this.options.labelWidth=l,this._width(),this._containerPosition(),this.$element)}},{key:'baseClass',value:function(){return this.options.baseClass}},{key:'wrapperClass',value:function(l){return'undefined'==typeof l?this.options.wrapperClass:(l||(l=g.fn.bootstrapSwitch.defaults.wrapperClass),this.$wrapper.removeClass(this._getClasses(this.options.wrapperClass).join(' ')),this.$wrapper.addClass(this._getClasses(l).join(' ')),this.options.wrapperClass=l,this.$element)}},{key:'radioAllOff',value:function(l){if('undefined'==typeof l)return this.options.radioAllOff;var m=!!l;return this.options.radioAllOff===m?this.$element:(this.options.radioAllOff=m,this.$element)}},{key:'onInit',value:function(l){return'undefined'==typeof l?this.options.onInit:(l||(l=g.fn.bootstrapSwitch.defaults.onInit),this.options.onInit=l,this.$element)}},{key:'onSwitchChange',value:function(l){return'undefined'==typeof l?this.options.onSwitchChange:(l||(l=g.fn.bootstrapSwitch.defaults.onSwitchChange),this.options.onSwitchChange=l,this.$element)}},{key:'destroy',value:function(){var l=this.$element.closest('form');return l.length&&l.off('reset.bootstrapSwitch').removeData('bootstrap-switch'),this.$container.children().not(this.$element).remove(),this.$element.unwrap().unwrap().off('.bootstrapSwitch').removeData('bootstrap-switch'),this.$element}},{key:'_getElementOptions',value:function(){return{state:this.$element.is(':checked'),size:this.$element.data('size'),animate:this.$element.data('animate'),disabled:this.$element.is(':disabled'),readonly:this.$element.is('[readonly]'),indeterminate:this.$element.data('indeterminate'),inverse:this.$element.data('inverse'),radioAllOff:this.$element.data('radio-all-off'),onColor:this.$element.data('on-color'),offColor:this.$element.data('off-color'),onText:this.$element.data('on-text'),offText:this.$element.data('off-text'),labelText:this.$element.data('label-text'),handleWidth:this.$element.data('handle-width'),labelWidth:this.$element.data('label-width'),baseClass:this.$element.data('base-class'),wrapperClass:this.$element.data('wrapper-class')}}},{key:'_width',value:function(){var l=this,m=this.$on.add(this.$off).add(this.$label).css('width',''),n='auto'===this.options.handleWidth?Math.round(Math.max(this.$on.width(),this.$off.width())):this.options.handleWidth;return m.width(n),this.$label.width(function(o,p){return'auto'===l.options.labelWidth?p<n?n:p:l.options.labelWidth}),this._handleWidth=this.$on.outerWidth(),this._labelWidth=this.$label.outerWidth(),this.$container.width(2*this._handleWidth+this._labelWidth),this.$wrapper.width(this._handleWidth+this._labelWidth)}},{key:'_containerPosition',value:function(){var l=this,m=0<arguments.length&&void 0!==arguments[0]?arguments[0]:this.options.state,n=arguments[1];this.$container.css('margin-left',function(){var o=[0,'-'+l._handleWidth+'px'];return l.options.indeterminate?'-'+l._handleWidth/2+'px':m?l.options.inverse?o[1]:o[0]:l.options.inverse?o[0]:o[1]})}},{key:'_init',value:function(){var l=this,m=function(){l.setPrevOptions(),l._width(),l._containerPosition(),setTimeout(function(){if(l.options.animate)return l.$wrapper.addClass(l._getClass('animate'))},50)};if(this.$wrapper.is(':visible'))return void m();var n=window.setInterval(function(){if(l.$wrapper.is(':visible'))return m(),window.clearInterval(n)},50)}},{key:'_elementHandlers',value:function(){var l=this;return this.$element.on({'setPreviousOptions.bootstrapSwitch':this.setPrevOptions.bind(this),'previousState.bootstrapSwitch':function(){l.options=l.prevOptions,l.options.indeterminate&&l.$wrapper.addClass(l._getClass('indeterminate')),l.$element.prop('checked',l.options.state).trigger('change.bootstrapSwitch',!0)},'change.bootstrapSwitch':function(n,o){n.preventDefault(),n.stopImmediatePropagation();var p=l.$element.is(':checked');l._containerPosition(p),p===l.options.state||(l.options.state=p,l.$wrapper.toggleClass(l._getClass('off')).toggleClass(l._getClass('on')),!o&&(l.$element.is(':radio')&&g('[name="'+l.$element.attr('name')+'"]').not(l.$element).prop('checked',!1).trigger('change.bootstrapSwitch',!0),l.$element.trigger('switchChange.bootstrapSwitch',[p])))},'focus.bootstrapSwitch':function(n){n.preventDefault(),l.$wrapper.addClass(l._getClass('focused'))},'blur.bootstrapSwitch':function(n){n.preventDefault(),l.$wrapper.removeClass(l._getClass('focused'))},'keydown.bootstrapSwitch':function(n){!n.which||l.options.disabled||l.options.readonly||(37===n.which||39===n.which)&&(n.preventDefault(),n.stopImmediatePropagation(),l.state(39===n.which))}})}},{key:'_handleHandlers',value:function(){var l=this;return this.$on.on('click.bootstrapSwitch',function(m){return m.preventDefault(),m.stopPropagation(),l.state(!1),l.$element.trigger('focus.bootstrapSwitch')}),this.$off.on('click.bootstrapSwitch',function(m){return m.preventDefault(),m.stopPropagation(),l.state(!0),l.$element.trigger('focus.bootstrapSwitch')})}},{key:'_labelHandlers',value:function(){var l=this;this.$label.on({click:function(o){o.stopPropagation()},'mousedown.bootstrapSwitch touchstart.bootstrapSwitch':function(o){l._dragStart||l.options.disabled||l.options.readonly||(o.preventDefault(),o.stopPropagation(),l._dragStart=(o.pageX||o.originalEvent.touches[0].pageX)-parseInt(l.$container.css('margin-left'),10),l.options.animate&&l.$wrapper.removeClass(l._getClass('animate')),l.$element.trigger('focus.bootstrapSwitch'))},'mousemove.bootstrapSwitch touchmove.bootstrapSwitch':function(o){if(null!=l._dragStart){var p=(o.pageX||o.originalEvent.touches[0].pageX)-l._dragStart;o.preventDefault(),p<-l._handleWidth||0<p||(l._dragEnd=p,l.$container.css('margin-left',l._dragEnd+'px'))}},'mouseup.bootstrapSwitch touchend.bootstrapSwitch':function(o){if(l._dragStart){if(o.preventDefault(),l.options.animate&&l.$wrapper.addClass(l._getClass('animate')),l._dragEnd){var p=l._dragEnd>-(l._handleWidth/2);l._dragEnd=!1,l.state(l.options.inverse?!p:p)}else l.state(!l.options.state);l._dragStart=!1}},'mouseleave.bootstrapSwitch':function(){l.$label.trigger('mouseup.bootstrapSwitch')}})}},{key:'_externalLabelHandler',value:function(){var l=this,m=this.$element.closest('label');m.on('click',function(n){n.preventDefault(),n.stopImmediatePropagation(),n.target===m[0]&&l.toggleState()})}},{key:'_formHandler',value:function(){var l=this.$element.closest('form');l.data('bootstrap-switch')||l.on('reset.bootstrapSwitch',function(){window.setTimeout(function(){l.find('input').filter(function(){return g(this).data('bootstrap-switch')}).each(function(){return g(this).bootstrapSwitch('state',this.checked)})},1)}).data('bootstrap-switch',!0)}},{key:'_getClass',value:function(l){return this.options.baseClass+'-'+l}},{key:'_getClasses',value:function(l){return g.isArray(l)?l.map(this._getClass.bind(this)):[this._getClass(l)]}}]),j}();g.fn.bootstrapSwitch=function(j){for(var l=arguments.length,m=Array(1<l?l-1:0),n=1;n<l;n++)m[n-1]=arguments[n];return Array.prototype.reduce.call(this,function(o,p){var q=g(p),r=q.data('bootstrap-switch'),s=r||new h(p,j);return r||q.data('bootstrap-switch',s),'string'==typeof j?s[j].apply(s,m):o},this)},g.fn.bootstrapSwitch.Constructor=h,g.fn.bootstrapSwitch.defaults={state:!0,size:null,animate:!0,disabled:!1,readonly:!1,indeterminate:!1,inverse:!1,radioAllOff:!1,onColor:'primary',offColor:'default',onText:'ON',offText:'OFF',labelText:'&nbsp',handleWidth:'auto',labelWidth:'auto',baseClass:'bootstrap-switch',wrapperClass:'wrapper',onInit:function(){},onSwitchChange:function(){}}});
src/main/resources/static/favicon.ico deleted 100644 → 0
No preview for this file type
src/main/resources/static/index.html deleted 100644 → 0
1   -<!DOCTYPE html>
2   -<html>
3   -<head>
4   -<title>调度系统营运数据接口</title>
5   -<meta charset="utf-8">
6   -<meta http-equiv="Expires" content="0">
7   -<meta http-equiv="Pragma" content="no-cache">
8   -<meta http-equiv="Cache-control" content="no-cache">
9   -<meta http-equiv="Cache" content="no-cache">
10   -<link rel="stylesheet"
11   - href="http://apps.bdimg.com/libs/bootstrap/3.2.0/css/bootstrap.min.css">
12   -<link rel="stylesheet" href="/simple_switch/simple.switch.three.css">
13   -<style>
14   -.table-wrap {
15   - height: 500px;
16   - overflow: auto;
17   -}
18   -
19   -#line2SysListTable .Switch_FlatRadius .SwitchLine:before {
20   - content: "老系统";
21   -}
22   -
23   -#line2SysListTable .Switch_FlatRadius .SwitchLine:after {
24   - content: "新系统";
25   -}
26   -
27   -#line2SysListTable .Switch_FlatRadius {
28   - width: 118px;
29   -}
30   -
31   -#line2SysListTable .Switch_FlatRadius .SwitchButton {
32   - width: 52px;
33   -}
34   -
35   -#line2SysListTable .Switch_FlatRadius .SwitchButton:before {
36   - left: 18px;
37   -}
38   -
39   -#line2SysListTable .Switch_FlatRadius .SwitchButton:after {
40   - left: 30px;
41   -}
42   -
43   -#line2SysListTable .Switch_FlatRadius.On .SwitchButton {
44   - left: 60px;
45   -}
46   -</style>
47   -</head>
48   -
49   -<body>
50   -
51   - <div class="row" style="margin: 15px;">
52   - <div class="col-md-12 well">
53   - <h4>
54   - Available SOAP services: <a href="/webservice" target="_blank">/webservice</a>
55   - </h4>
56   - <h4>
57   - WSDL: <a href="/webservice/CompanyService?wsdl" target="_blank">/webservice/CompanyService?wsdl</a>
58   - </h4>
59   - </div>
60   -
61   - <div class="col-lg-4 col-md-6 col-sm-12">
62   - <div class="bs-example"
63   - data-example-id="panel-without-body-with-table">
64   - <div class="panel panel-default">
65   - <!-- Default panel contents -->
66   - <div class="panel-heading">线路清单</div>
67   - <div class="panel-body">
68   - <p style="color: #ff2727;">屏蔽新老系统的底层数据差异,对外提供统一的数据输出</p>
69   - <p>1、使用员工号查询数据时,系统将参考 “线路人员配置” 以确定人员所在线路。</p>
70   - <p>2、使用公司编码查询数据时,系统将参考 “线路基础信息” 里的公司编码。</p>
71   - </div>
72   - <div class="table-wrap">
73   - <table class="table" id="line2SysListTable">
74   - <thead>
75   - <tr>
76   - <th>线路编码</th>
77   - <th>线路名称</th>
78   - <th>数据来源</th>
79   - </tr>
80   - </thead>
81   - <tbody>
82   - </tbody>
83   - </table>
84   - </div>
85   - </div>
86   - </div>
87   - </div>
88   -
89   - <div class="col-lg-8 col-md-6 col-sm-12">
90   - <div class="bs-example">
91   - <div class="panel panel-default">
92   - <div class="panel-heading">接口调试工具</div>
93   - <div style="padding: 15px; margin-top: 15px;">
94   - <form class="form-inline">
95   - <div class="form-group">
96   - <label>函数</label> <select class="form-control">
97   - <option value="returnCCInfo">returnCCInfo(获取出场班次信息)</option>
98   - <option value="returnJCInfo">returnJCInfo(获取进场班次信息)</option>
99   - </select>
100   - </div>
101   - &nbsp;
102   - <div class="form-group">
103   - <label>公司编码</label> <select class="form-control">
104   - <option value="55">55(上南)</option>
105   - <option value="22">22(金高)</option>
106   - <option value="05">05(杨高)</option>
107   - <option value="26">26(南汇)</option>
108   - </select>
109   - </div>
110   - &nbsp;
111   - <div class="form-group">
112   - <label>日期</label> <input type="date" class="form-control"
113   - style="width: 150px;" required>
114   - </div>
115   - <button type="submit" class="btn btn-primary">获取数据</button>
116   -
117   - <textarea class="form-control" rows="25"
118   - style="width: 100%; margin-top: 25px;"></textarea>
119   - </form>
120   -
121   - </div>
122   - </div>
123   - </div>
124   - </div>
125   - </div>
126   -
127   - <script id="line2sys-table-list-temp" type="text/html">
128   - {{each list as obj i}}
129   - <tr data-id="{{obj.lineCode}}" data-name="{{obj.lineName}}" {{if obj.new}}class="warning" {{/if}} >
130   - <td>{{obj.lineCode}}</td>
131   - <td>{{obj.lineName}}</td>
132   - <td>
133   - <input type="checkbox" {{if obj.new}}checked{{/if}} />
134   - </td>
135   - </tr>
136   - {{/each}}
137   -</script>
138   -
139   - <script src="http://apps.bdimg.com/libs/jquery/1.8.3/jquery.min.js"></script>
140   - <script
141   - src="http://apps.bdimg.com/libs/bootstrap/3.2.0/js/bootstrap.min.js"></script>
142   - <script src="/assets/js/template.js"></script>
143   - <script src="/simple_switch/simple.switch.min.js"></script>
144   -
145   - <script>
146   -
147   - //线路清单
148   - !function () {
149   - var f = arguments.callee;
150   -/* $.get('/line2System/all', function (list) {
151   - list.sort(function (a, b) {
152   - return b.new - a.new;
153   - });
154   - var htmlStr = template('line2sys-table-list-temp', {list: list});
155   - $('#line2SysListTable tbody').html(htmlStr);
156   -
157   - $('input[type=checkbox]').simpleSwitch({
158   - "theme": "FlatRadius"
159   - });
160   -
161   - $('input[type=checkbox]').on('change', function () {
162   - var $tr = $(this).parents('tr');
163   - var data = {
164   - lineCode: $tr.data('id'),
165   - lineName: $tr.data('name'),
166   - new: this.checked
167   - }
168   -
169   - $.post('/line2System/update', data, function (rs) {
170   - var $tr = $('#line2SysListTable tr[data-id=' + rs.lineCode + ']');
171   - $tr.attr('class', rs.new ? 'warning' : '');
172   - });
173   - });
174   - });*/
175   - }();
176   -
177   -</script>
178   -</body>
179   -</html>
180 0 \ No newline at end of file
src/main/resources/static/simple_switch/simple.switch.min.js deleted 100644 → 0
1   -/*!
2   - * Copyright 2015, Lu Kang
3   - * WeChat:lukangdaye
4   - * https://github.com/1029131145/Simple-Switch
5   - */
6   -
7   -(function($){var Switch_Num=0;$.extend($.fn,{simpleSwitch:function(ATTR){var _ATTR={"id":$.simpleSwitch.Id,"theme":$.simpleSwitch.Theme,"end":$.simpleSwitch.End};$.extend(_ATTR,ATTR);var _ALL=$(this),a=_ATTR,_NUM=Switch_Num,_ID=a["id"],_THEME=a["theme"];_ALL.each(function(){var _THIS=$(this);_THIS.hide();_THIS.attr("simpleSwitch",_NUM);_THIS.after('<div class="'+_ID+" "+_ID+"_"+_THEME+'" id="'+_ID+_NUM+'"><div class="SwitchLine"></div><span class="SwitchButton"></span></div>');var _CONTAINER=$("#"+_ID+_NUM);var _type=_THIS.attr("type");var _name=_THIS.attr("name");if(_type=="radio"){_CONTAINER.attr("type",_type+_name)}$.simpleSwitch.Init(this,_CONTAINER);_THIS.change(function(){$.simpleSwitch.Change(this,_CONTAINER,_type,_name)});_CONTAINER.click(function(){$.simpleSwitch.Click(this,_THIS)});_NUM++;a["end"](_THIS,_CONTAINER)});Switch_Num=_NUM}}),$.simpleSwitch=function(){return !0},$.extend($.simpleSwitch,{Id:"Switch",Theme:"Flat",Result:"Result",setTheme:function(theme){$.extend(this.Theme,theme)
8   -},setDisabled:function(o,i){if(i){$(o).attr("disabled","disabled");$(o).next(".Switch").addClass("Disabled")}else{$(o).removeAttr("disabled");$(o).next(".Switch").removeClass("Disabled")}},Click:function(t,input){input.click()},Change:function(t,cont,type,name){var $T=$(t);var $type=cont.attr("type");if(type){$("div[type='"+$type+"']").removeClass("On");$("input[type='"+type+"'][name='"+name+"']").attr(this.Result,"false")}var checked=$T.attr("checked");if(checked){cont.addClass("On");$T.attr(this.Result,"true")}else{cont.removeClass("On");$T.attr(this.Result,"false")}},Init:function(t,cont){var $T=$(t);var checked=$T.attr("checked");if(checked){cont.addClass("On");$T.attr(this.Result,"true")}else{cont.removeClass("On");$T.attr(this.Result,"false")}if($T.attr("disabled")){cont.addClass("Disabled")}},End:function(t,c){}})})(jQuery);
9 0 \ No newline at end of file
src/main/resources/static/simple_switch/simple.switch.three.css deleted 100644 → 0
1   -* {
2   - box-sizing: border-box !important;
3   -}
4   -
5   -.Switch, .Switch * {
6   - -webkit-transition-property: all;
7   - -moz-transition-property: all;
8   - -o-transition-property: all;
9   - transition-property: all;
10   - -webkit-transition-duration: 0.2s;
11   - -moz-transition-duration: 0.2s;
12   - -o-transition-duration: 0.2s;
13   - transition-duration: 0.2s;
14   - -webkit-transition-delay: 0s;
15   - -moz-transition-delay: 0s;
16   - -o-transition-delay: 0s;
17   - transition-delay: 0s;
18   -}
19   -
20   -/*
21   -Default
22   -*/
23   -.Switch_Default {
24   - position: relative;
25   - width: 64px;
26   - height: 32px;
27   - cursor: pointer;
28   - display: inline-block;
29   - vertical-align: middle;
30   -}
31   -
32   -.Switch_Default .SwitchLine {
33   - position: absolute;
34   - width: 60px;
35   - height: 4px;
36   - left: 2px;
37   - top: 14px;
38   - z-index: 1;
39   - background-color: #dadada;
40   -}
41   -
42   -.Switch_Default .SwitchButton {
43   - position: absolute;
44   - width: 32px;
45   - height: 32px;
46   - left: 0;
47   - top: 0;
48   - z-index: 2;
49   - background-color: #dadada;
50   - border-radius: 32px;
51   -}
52   -
53   -.Switch_Default.On .SwitchLine {
54   - background-color: #00c0ff;
55   -}
56   -
57   -.Switch_Default.On .SwitchButton {
58   - left: 32px;
59   - background-color: #00c0ff;
60   -}
61   -
62   -.Switch_Default.On .SwitchButton {
63   - left: 32px;
64   - background-color: #00c0ff;
65   -}
66   -
67   -.Switch_Default.Disabled {
68   - opacity: 0.3;
69   -}
70   -
71   -.Switch_Default.Disabled .SwitchButton {
72   - /*opacity:0.5;*/
73   -
74   -}
75   -
76   -.Switch_Default.On.Disabled .SwitchLine {
77   - /*opacity:0.5;*/
78   -
79   -}
80   -
81   -/* DefaultMin */
82   -.Switch_DefaultMin {
83   - position: relative;
84   - width: 48px;
85   - height: 24px;
86   - cursor: pointer;
87   - display: inline-block;
88   - vertical-align: middle;
89   -}
90   -
91   -.Switch_DefaultMin .SwitchLine {
92   - position: absolute;
93   - width: 44px;
94   - height: 2px;
95   - left: 2px;
96   - top: 11px;
97   - z-index: 1;
98   - background-color: #dadada;
99   -}
100   -
101   -.Switch_DefaultMin .SwitchButton {
102   - position: absolute;
103   - width: 24px;
104   - height: 24px;
105   - left: 0;
106   - top: 0;
107   - z-index: 2;
108   - background-color: #dadada;
109   - border-radius: 24px;
110   -}
111   -
112   -.Switch_DefaultMin.On .SwitchLine {
113   - background-color: #00c0ff;
114   -}
115   -
116   -.Switch_DefaultMin.On .SwitchButton {
117   - left: 24px;
118   - background-color: #00c0ff;
119   -}
120   -
121   -.Switch_DefaultMin.Disabled {
122   - opacity: 0.3;
123   -}
124   -
125   -.Switch_DefaultMin.Disabled .SwitchButton {
126   - /*opacity:0.5;*/
127   -
128   -}
129   -
130   -.Switch_DefaultMin.On.Disabled .SwitchLine {
131   - /*opacity:0.5;*/
132   -
133   -}
134   -
135   -/* Flat */
136   -.Switch_Flat {
137   - position: relative;
138   - width: 100px;
139   - height: 40px;
140   - cursor: pointer;
141   - display: inline-block;
142   - vertical-align: middle;
143   - background-color: #f5a5a6;
144   -}
145   -
146   -.Switch_Flat .SwitchLine:before {
147   - position: absolute;
148   - content: "OFF";
149   - color: #fff;
150   - left: 60px;
151   - top: 9px;
152   -}
153   -
154   -.Switch_Flat .SwitchLine:after {
155   - position: absolute;
156   - content: "ON";
157   - color: #fff;
158   - left: 15px;
159   - top: 9px;
160   -}
161   -
162   -.Switch_Flat .SwitchButton {
163   - position: absolute;
164   - width: 45px;
165   - height: 30px;
166   - left: 5px;
167   - top: 5px;
168   - z-index: 2;
169   - background-color: #fff;
170   -}
171   -
172   -.Switch_Flat .SwitchButton:before {
173   - position: absolute;
174   - content: "";
175   - width: 4px;
176   - height: 16px;
177   - left: 15px;
178   - top: 7px;
179   - background-color: #f5a5a6;
180   -}
181   -
182   -.Switch_Flat .SwitchButton:after {
183   - position: absolute;
184   - content: "";
185   - width: 4px;
186   - height: 16px;
187   - left: 26px;
188   - top: 7px;
189   - background-color: #f5a5a6;
190   -}
191   -
192   -.Switch_Flat.On {
193   - background-color: #a7cce9;
194   -}
195   -
196   -.Switch_Flat.On .SwitchLine {
197   -
198   -}
199   -
200   -.Switch_Flat.On .SwitchButton {
201   - left: 50px;
202   -}
203   -
204   -.Switch_Flat.On .SwitchButton:after, .Switch_Flat.On .SwitchButton:before
205   - {
206   - background-color: #a7cce9;
207   -}
208   -
209   -.Switch_Flat.Disabled {
210   - opacity: 0.3;
211   -}
212   -
213   -.Switch_Flat.Disabled .SwitchButton {
214   - /*opacity:0.5;*/
215   -
216   -}
217   -
218   -.Switch_Flat.On.Disabled .SwitchLine {
219   - /*opacity:0.5;*/
220   -
221   -}
222   -
223   -/* FlatRadius */
224   -.Switch_FlatRadius {
225   - position: relative;
226   - width: 100px;
227   - height: 40px;
228   - cursor: pointer;
229   - display: inline-block;
230   - vertical-align: middle;
231   - background-color: #f5a5a6;
232   - border-radius: 4px;
233   -}
234   -
235   -.Switch_FlatRadius .SwitchLine:before {
236   - position: absolute;
237   - content: "OFF";
238   - color: #fff;
239   - left: 60px;
240   - top: 9px;
241   -}
242   -
243   -.Switch_FlatRadius .SwitchLine:after {
244   - position: absolute;
245   - content: "ON";
246   - color: #fff;
247   - left: 15px;
248   - top: 9px;
249   -}
250   -
251   -.Switch_FlatRadius .SwitchButton {
252   - position: absolute;
253   - width: 45px;
254   - height: 30px;
255   - left: 5px;
256   - top: 5px;
257   - z-index: 2;
258   - background-color: #fff;
259   - border-radius: 4px;
260   -}
261   -
262   -.Switch_FlatRadius .SwitchButton:before {
263   - position: absolute;
264   - content: "";
265   - width: 4px;
266   - height: 16px;
267   - left: 15px;
268   - top: 7px;
269   - background-color: #f5a5a6;
270   -}
271   -
272   -.Switch_FlatRadius .SwitchButton:after {
273   - position: absolute;
274   - content: "";
275   - width: 4px;
276   - height: 16px;
277   - left: 26px;
278   - top: 7px;
279   - background-color: #f5a5a6;
280   -}
281   -
282   -.Switch_FlatRadius.On {
283   - background-color: #a7cce9;
284   -}
285   -
286   -.Switch_FlatRadius.On .SwitchLine {
287   -
288   -}
289   -
290   -.Switch_FlatRadius.On .SwitchButton {
291   - left: 50px;
292   -}
293   -
294   -.Switch_FlatRadius.On .SwitchButton:after, .Switch_FlatRadius.On .SwitchButton:before
295   - {
296   - background-color: #a7cce9;
297   -}
298   -
299   -.Switch_FlatRadius.Disabled {
300   - opacity: 0.3;
301   -}
302   -
303   -.Switch_FlatRadius.Disabled .SwitchButton {
304   - /*opacity:0.5;*/
305   -
306   -}
307   -
308   -.Switch_FlatRadius.On.Disabled .SwitchLine {
309   - /*opacity:0.5;*/
310   -
311   -}
312   -
313   -/* FlatCircular */
314   -.Switch_FlatCircular {
315   - position: relative;
316   - width: 100px;
317   - height: 40px;
318   - cursor: pointer;
319   - display: inline-block;
320   - vertical-align: middle;
321   - background-color: #f5a5a6;
322   - border-radius: 20px;
323   -}
324   -
325   -.Switch_FlatCircular .SwitchLine:before {
326   - position: absolute;
327   - content: "OFF";
328   - color: #fff;
329   - left: 60px;
330   - top: 9px;
331   -}
332   -
333   -.Switch_FlatCircular .SwitchLine:after {
334   - position: absolute;
335   - content: "ON";
336   - color: #fff;
337   - left: 15px;
338   - top: 9px;
339   -}
340   -
341   -.Switch_FlatCircular .SwitchButton {
342   - position: absolute;
343   - width: 46px;
344   - height: 46px;
345   - left: -3px;
346   - top: -3px;
347   - z-index: 2;
348   - background-color: #fff;
349   - border-radius: 45px;
350   - border: 1px solid #f5a5a6;
351   -}
352   -
353   -.Switch_FlatCircular.On {
354   - background-color: #a7cce9;
355   -}
356   -
357   -.Switch_FlatCircular.On .SwitchLine {
358   -
359   -}
360   -
361   -.Switch_FlatCircular.On .SwitchButton {
362   - border: 1px solid #a7cce9;
363   - left: 57px;
364   -}
365   -
366   -.Switch_FlatCircular.On .SwitchButton:after, .Switch_FlatCircular.On .SwitchButton:before
367   - {
368   - background-color: #a7cce9;
369   -}
370   -
371   -.Switch_FlatCircular.Disabled {
372   - opacity: 0.3;
373   -}
374   -
375   -.Switch_FlatCircular.Disabled .SwitchButton {
376   - /*opacity:0.5;*/
377   -
378   -}
379   -
380   -.Switch_FlatCircular.On.Disabled .SwitchLine {
381   - /*opacity:0.5;*/
382   -
383   -}
384   -
385   -/* Green */
386   -.Switch_Green {
387   - position: relative;
388   - width: 100px;
389   - height: 40px;
390   - cursor: pointer;
391   - display: inline-block;
392   - vertical-align: middle;
393   - background-color: #b4aa9f;
394   - border-radius: 20px;
395   -}
396   -
397   -.Switch_Green .SwitchLine:before {
398   - position: absolute;
399   - content: "\f00d";
400   - color: #fff3e3;
401   - left: 62px;
402   - top: 8px;
403   - /*font-awesome*/
404   - font: normal normal normal 14px/1 FontAwesome !important;
405   - font-size: 25px !important;
406   -}
407   -
408   -.Switch_Green .SwitchLine:after {
409   - position: absolute;
410   - content: "\f00c";
411   - color: #fff3e3;
412   - left: 15px;
413   - top: 8px;
414   - /*font-awesome*/
415   - font: normal normal normal 14px/1 FontAwesome !important;
416   - font-size: 25px !important;
417   -}
418   -
419   -.Switch_Green .SwitchButton {
420   - position: absolute;
421   - width: 46px;
422   - height: 46px;
423   - left: -3px;
424   - top: -3px;
425   - z-index: 2;
426   - background-color: #fff3e3;
427   - border-radius: 45px;
428   - border: 3px solid #b4aa9f;
429   -}
430   -
431   -.Switch_Green.On {
432   - background-color: #6ebf5f;
433   -}
434   -
435   -.Switch_Green.On .SwitchLine {
436   -
437   -}
438   -
439   -.Switch_Green.On .SwitchButton {
440   - border: 3px solid #6ebf5f;
441   - left: 57px;
442   -}
443   -
444   -.Switch_Green.On .SwitchButton:after, .Switch_Green.On .SwitchButton:before
445   - {
446   - background-color: #a7cce9;
447   -}
448   -
449   -.Switch_Green.Disabled {
450   - opacity: 0.3;
451   -}
452   -
453   -.Switch_Green.Disabled .SwitchButton {
454   - /*opacity:0.5;*/
455   -
456   -}
457   -
458   -.Switch_Green.On.Disabled .SwitchLine {
459   - /*opacity:0.5;*/
460   -
461   -}
462   -
463   -/* Icon */
464   -.Switch_Icon {
465   - position: relative;
466   - width: 90px;
467   - height: 50px;
468   - cursor: pointer;
469   - display: inline-block;
470   - vertical-align: middle;
471   - border-radius: 30px;
472   - border: 6px solid #fff;
473   - margin: 0 38px;
474   -}
475   -
476   -.Switch_Icon .SwitchLine:before {
477   - position: absolute;
478   - content: "\f1e3";
479   - color: #1b5a95;
480   - left: 96px;
481   - top: 8px;
482   - /*font-awesome*/
483   - font: normal normal normal 14px/1 FontAwesome !important;
484   - font-size: 25px !important;
485   -}
486   -
487   -.Switch_Icon .SwitchLine:after {
488   - position: absolute;
489   - content: "\f1db";
490   - color: #fff;
491   - left: -42px;
492   - top: 8px;
493   - /*font-awesome*/
494   - font: normal normal normal 14px/1 FontAwesome !important;
495   - font-size: 25px !important;
496   -}
497   -
498   -.Switch_Icon .SwitchButton {
499   - position: absolute;
500   - width: 26px;
501   - height: 26px;
502   - left: 6px;
503   - top: 6px;
504   - z-index: 2;
505   - background-color: #fff;
506   - border-radius: 26px;
507   -}
508   -
509   -.Switch_Icon.On {
510   -
511   -}
512   -
513   -.Switch_Icon.On .SwitchLine {
514   -
515   -}
516   -
517   -.Switch_Icon.On .SwitchButton {
518   - left: 48px;
519   -}
520   -
521   -.Switch_Icon.On .SwitchLine:after {
522   - color: #1b5a95;
523   -}
524   -
525   -.Switch_Icon.On .SwitchLine:before {
526   - color: #fff;
527   -}
528   -
529   -.Switch_Icon.Disabled {
530   - opacity: 0.3;
531   -}
532   -
533   -.Switch_Icon.Disabled .SwitchButton {
534   - /*opacity:0.5;*/
535   -
536   -}
537   -
538   -.Switch_Icon.On.Disabled .SwitchLine {
539   - /*opacity:0.5;*/
540   -
541   -}
542 0 \ No newline at end of file