wl-design-mobile 0.8.13 → 0.8.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +6 -6
- package/api/doc.js +25 -25
- package/api/x1.js +56 -56
- package/btn/components/lambo-info-btn.vue +123 -123
- package/btn/components/lambo-primary-btn.vue +117 -117
- package/btn/components/lambo-text-btn.vue +116 -116
- package/btn/lambo-btn-divide.vue +35 -35
- package/btn/lambo-btn-group.vue +46 -46
- package/btn/lambo-btn-split-line.vue +41 -41
- package/btn/lambo-btn.vue +68 -68
- package/btn/lambo-extend-btn.vue +121 -121
- package/btn/lambo-icon-btn.vue +82 -82
- package/card-item/card-row-icon.vue +71 -71
- package/card-item/filtrate-row.vue +73 -73
- package/card-item/lambo-card-footer.vue +40 -40
- package/card-item/lambo-card-head.vue +66 -66
- package/card-item/lambo-card-row.vue +59 -59
- package/collapse/lambo-collapse.vue +93 -93
- package/config/config.js +14 -14
- package/detail/lambo-detail-grid.vue +58 -58
- package/detail/lambo-detail-row.vue +59 -59
- package/doc/file/compoents/lambo-file-list.vue +42 -42
- package/doc/file/compoents/lambo-file-row.vue +77 -77
- package/doc/file/lambo-file-upload-collapse.vue +107 -107
- package/doc/file-type/file-type.js +286 -286
- package/doc/img/comonents/lambo-img-grid.vue +109 -109
- package/doc/img/lambo-img-upload-collapse.vue +107 -109
- package/doc/img/styles/css/index.css +3 -3
- package/edit/list/Lambo-edit-list.vue +87 -87
- package/edit/list/lambo-edit-card-group.vue +100 -100
- package/edit/list/styles/css/index.css +39 -39
- package/edit/select/lambo-edit-date-range.vue +147 -147
- package/edit/select/lambo-edit-date-time.vue +122 -122
- package/edit/select/lambo-edit-date.vue +120 -120
- package/edit/select/lambo-edit-input-textarea.vue +91 -91
- package/edit/select/lambo-edit-input.vue +91 -91
- package/edit/select/lambo-edit-multi-select.vue +168 -168
- package/edit/select/lambo-edit-search-single-select.vue +186 -186
- package/edit/select/lambo-edit-single-select.vue +162 -162
- package/edit/select/styles/css/index.css +133 -133
- package/flow/approval/flow-approval.vue +552 -552
- package/flow/comps/flow-attachment-list.vue +230 -230
- package/flow/comps/flow-attachment-modal.vue +194 -194
- package/flow/comps/flow-copy-users.vue +358 -358
- package/flow/comps/flow-node-card.vue +150 -150
- package/flow/comps/flow-node-header.vue +172 -172
- package/flow/comps/flow-util.js +156 -156
- package/flow/comps/icons/approved.svg +11 -11
- package/flow/comps/icons/canceled.svg +11 -11
- package/flow/comps/icons/rejected.svg +11 -11
- package/flow/comps/icons/underway.svg +11 -11
- package/flow/detail/flow-detail.vue +467 -467
- package/flow/index.js +51 -51
- package/flow/lambo-flow-detail.vue +912 -912
- package/flow/lambo-flow-edit.vue +15 -15
- package/flow/submit/flow-submit.vue +383 -383
- package/icon/lambo-required-red-star.vue +47 -47
- package/icon/lambo-vector-icon.vue +71 -71
- package/list/lambo-list.vue +412 -294
- package/nav/lambo-top-nav.vue +81 -81
- package/order/comps/icons/approved.svg +10 -10
- package/order/comps/icons/underway.svg +10 -10
- package/order/comps/order-attachment-list.vue +228 -228
- package/order/comps/order-attachment-modal.vue +194 -194
- package/order/comps/order-node-card.vue +126 -126
- package/order/comps/order-node-header.vue +133 -133
- package/order/comps/order-util.js +132 -132
- package/order/detail/order-detail.vue +432 -432
- package/order/handle/order-handle.vue +517 -517
- package/order/index.js +33 -33
- package/package.json +1 -1
- package/search/lambo-date-range-page.vue +196 -196
- package/search/lambo-date-range.vue +111 -111
- package/search/lambo-date.vue +105 -105
- package/search/lambo-input.vue +74 -74
- package/search/lambo-multi-select.vue +129 -129
- package/search/lambo-org-select-page.vue +109 -109
- package/search/lambo-search-box.vue +61 -61
- package/search/lambo-search-single-select.vue +152 -152
- package/search/lambo-single-select.vue +123 -123
- package/search/lambo-week-date-select.vue +521 -521
- package/search/styles/css/index.css +138 -138
- package/styles/base.less +77 -77
- package/styles/components/btn.less +7 -7
- package/styles/components/search.less +33 -33
- package/styles/components/tag.less +181 -181
- package/styles/index.less +4 -4
- package/table/lambo-ag-table.vue +228 -227
- package/tag/lambo-tag.vue +23 -23
- package/title/lambo-title1.vue +151 -151
- package/title/lambo-title2.vue +37 -37
- package/title/lambo-title3.vue +77 -77
- package/util/assist.js +43 -43
- package/util/axios/cacheconf.js +19 -19
- package/util/axios/index.js +11 -11
- package/util/axios/interceptors.js +101 -101
- package/util/bus.js +4 -4
- package/util/jssdk-sczy.js +104 -104
- package/util/jssdk.js +565 -565
- package/util/math.js +76 -76
- package/util/token.js +36 -36
package/util/math.js
CHANGED
|
@@ -1,76 +1,76 @@
|
|
|
1
|
-
let math = {};
|
|
2
|
-
//js除法计算
|
|
3
|
-
math.accDiv = function(arg1, arg2) {
|
|
4
|
-
let t1 = 0,
|
|
5
|
-
t2 = 0,
|
|
6
|
-
r1, r2;
|
|
7
|
-
try {
|
|
8
|
-
t1 = arg1.toString().split(".")[1].length
|
|
9
|
-
} catch (e) {
|
|
10
|
-
console.error('accDiv',e)
|
|
11
|
-
}
|
|
12
|
-
try {
|
|
13
|
-
t2 = arg2.toString().split(".")[1].length
|
|
14
|
-
} catch (e) {
|
|
15
|
-
console.error('accDiv',e)
|
|
16
|
-
}
|
|
17
|
-
r1 = Number(arg1.toString().replace(".", ""))
|
|
18
|
-
r2 = Number(arg2.toString().replace(".", ""))
|
|
19
|
-
return Number(((r1 / r2) * Math.pow(10, t2 - t1)));
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
//js乘法计算
|
|
23
|
-
math.accMul = function(arg1, arg2) {
|
|
24
|
-
let m = 0,
|
|
25
|
-
s1 = arg1.toString(),
|
|
26
|
-
s2 = arg2.toString();
|
|
27
|
-
try {
|
|
28
|
-
m += s1.split(".")[1].length
|
|
29
|
-
} catch (e) {
|
|
30
|
-
console.error('accMul',e)
|
|
31
|
-
}
|
|
32
|
-
try {
|
|
33
|
-
m += s2.split(".")[1].length
|
|
34
|
-
} catch (e) {
|
|
35
|
-
console.error('accMul',e)
|
|
36
|
-
}
|
|
37
|
-
return Number(math.accDiv(Number(s1.replace(".", "")) * Number(s2.replace(".", "")), Math.pow(10, m)));
|
|
38
|
-
}
|
|
39
|
-
|
|
40
|
-
//js加法计算
|
|
41
|
-
math.accAdd = function(arg1, arg2) {
|
|
42
|
-
const POW4 = 10000;
|
|
43
|
-
let r1, r2, m;
|
|
44
|
-
try {
|
|
45
|
-
arg1 = math.accDiv(Math.round(arg1 * POW4) , POW4);
|
|
46
|
-
r1 = arg1.toString().split(".")[1].length
|
|
47
|
-
} catch (e) {
|
|
48
|
-
r1 = 0
|
|
49
|
-
}
|
|
50
|
-
try {
|
|
51
|
-
arg2 = math.accDiv(Math.round(arg2 * POW4) , POW4);
|
|
52
|
-
r2 = arg2.toString().split(".")[1].length
|
|
53
|
-
} catch (e) {
|
|
54
|
-
r2 = 0
|
|
55
|
-
}
|
|
56
|
-
m = Math.pow(10, Math.max(r1, r2));
|
|
57
|
-
return Number(math.accDiv((math.accMul(arg1, m) + math.accMul(arg2, m)), m));
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
//js减法计算
|
|
61
|
-
math.accSub = function(arg1, arg2) {
|
|
62
|
-
let r1, r2, m;
|
|
63
|
-
try {
|
|
64
|
-
r1 = arg1.toString().split(".")[1].length
|
|
65
|
-
} catch (e) {
|
|
66
|
-
r1 = 0
|
|
67
|
-
}
|
|
68
|
-
try {
|
|
69
|
-
r2 = arg2.toString().split(".")[1].length
|
|
70
|
-
} catch (e) {
|
|
71
|
-
r2 = 0
|
|
72
|
-
}
|
|
73
|
-
m = Math.pow(10, Math.max(r1, r2));
|
|
74
|
-
return Number(math.accDiv((math.accMul(arg1, m) - math.accMul(arg2, m)), m));
|
|
75
|
-
}
|
|
76
|
-
export default math;
|
|
1
|
+
let math = {};
|
|
2
|
+
//js除法计算
|
|
3
|
+
math.accDiv = function(arg1, arg2) {
|
|
4
|
+
let t1 = 0,
|
|
5
|
+
t2 = 0,
|
|
6
|
+
r1, r2;
|
|
7
|
+
try {
|
|
8
|
+
t1 = arg1.toString().split(".")[1].length
|
|
9
|
+
} catch (e) {
|
|
10
|
+
console.error('accDiv',e)
|
|
11
|
+
}
|
|
12
|
+
try {
|
|
13
|
+
t2 = arg2.toString().split(".")[1].length
|
|
14
|
+
} catch (e) {
|
|
15
|
+
console.error('accDiv',e)
|
|
16
|
+
}
|
|
17
|
+
r1 = Number(arg1.toString().replace(".", ""))
|
|
18
|
+
r2 = Number(arg2.toString().replace(".", ""))
|
|
19
|
+
return Number(((r1 / r2) * Math.pow(10, t2 - t1)));
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
//js乘法计算
|
|
23
|
+
math.accMul = function(arg1, arg2) {
|
|
24
|
+
let m = 0,
|
|
25
|
+
s1 = arg1.toString(),
|
|
26
|
+
s2 = arg2.toString();
|
|
27
|
+
try {
|
|
28
|
+
m += s1.split(".")[1].length
|
|
29
|
+
} catch (e) {
|
|
30
|
+
console.error('accMul',e)
|
|
31
|
+
}
|
|
32
|
+
try {
|
|
33
|
+
m += s2.split(".")[1].length
|
|
34
|
+
} catch (e) {
|
|
35
|
+
console.error('accMul',e)
|
|
36
|
+
}
|
|
37
|
+
return Number(math.accDiv(Number(s1.replace(".", "")) * Number(s2.replace(".", "")), Math.pow(10, m)));
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
//js加法计算
|
|
41
|
+
math.accAdd = function(arg1, arg2) {
|
|
42
|
+
const POW4 = 10000;
|
|
43
|
+
let r1, r2, m;
|
|
44
|
+
try {
|
|
45
|
+
arg1 = math.accDiv(Math.round(arg1 * POW4) , POW4);
|
|
46
|
+
r1 = arg1.toString().split(".")[1].length
|
|
47
|
+
} catch (e) {
|
|
48
|
+
r1 = 0
|
|
49
|
+
}
|
|
50
|
+
try {
|
|
51
|
+
arg2 = math.accDiv(Math.round(arg2 * POW4) , POW4);
|
|
52
|
+
r2 = arg2.toString().split(".")[1].length
|
|
53
|
+
} catch (e) {
|
|
54
|
+
r2 = 0
|
|
55
|
+
}
|
|
56
|
+
m = Math.pow(10, Math.max(r1, r2));
|
|
57
|
+
return Number(math.accDiv((math.accMul(arg1, m) + math.accMul(arg2, m)), m));
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
//js减法计算
|
|
61
|
+
math.accSub = function(arg1, arg2) {
|
|
62
|
+
let r1, r2, m;
|
|
63
|
+
try {
|
|
64
|
+
r1 = arg1.toString().split(".")[1].length
|
|
65
|
+
} catch (e) {
|
|
66
|
+
r1 = 0
|
|
67
|
+
}
|
|
68
|
+
try {
|
|
69
|
+
r2 = arg2.toString().split(".")[1].length
|
|
70
|
+
} catch (e) {
|
|
71
|
+
r2 = 0
|
|
72
|
+
}
|
|
73
|
+
m = Math.pow(10, Math.max(r1, r2));
|
|
74
|
+
return Number(math.accDiv((math.accMul(arg1, m) - math.accMul(arg2, m)), m));
|
|
75
|
+
}
|
|
76
|
+
export default math;
|
package/util/token.js
CHANGED
|
@@ -1,36 +1,36 @@
|
|
|
1
|
-
export const TOKEN_KEY = 'lambo-token'
|
|
2
|
-
|
|
3
|
-
export const COOKIE_KEY = 'lambo-sso-key'
|
|
4
|
-
|
|
5
|
-
export const SSO_TOKEN_KEY = 'lambo-sso-token'
|
|
6
|
-
|
|
7
|
-
export const setToken = (token) => {
|
|
8
|
-
sessionStorage.setItem(TOKEN_KEY, token)
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
export const getToken = () => {
|
|
12
|
-
const token = sessionStorage.getItem(TOKEN_KEY)
|
|
13
|
-
if (token) return token
|
|
14
|
-
else return false
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
/**
|
|
18
|
-
* 获取浏览器地址url中的参数
|
|
19
|
-
* @param url
|
|
20
|
-
* @returns {Object}
|
|
21
|
-
*/
|
|
22
|
-
export const getUrlParams = (url) => {
|
|
23
|
-
if (!url) {
|
|
24
|
-
url = location.search;
|
|
25
|
-
}
|
|
26
|
-
//const url = location.search; //获取url中"?"符后的字串
|
|
27
|
-
const theRequest = {};
|
|
28
|
-
if (url.indexOf("?") !== -1) {
|
|
29
|
-
const str = url.substr(1);
|
|
30
|
-
let strs = str.split("&");
|
|
31
|
-
for (let i = 0; i < strs.length; i++) {
|
|
32
|
-
theRequest[strs[i].split("=")[0]] = unescape(strs[i].split("=")[1]);
|
|
33
|
-
}
|
|
34
|
-
}
|
|
35
|
-
return theRequest;
|
|
36
|
-
}
|
|
1
|
+
export const TOKEN_KEY = 'lambo-token'
|
|
2
|
+
|
|
3
|
+
export const COOKIE_KEY = 'lambo-sso-key'
|
|
4
|
+
|
|
5
|
+
export const SSO_TOKEN_KEY = 'lambo-sso-token'
|
|
6
|
+
|
|
7
|
+
export const setToken = (token) => {
|
|
8
|
+
sessionStorage.setItem(TOKEN_KEY, token)
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
export const getToken = () => {
|
|
12
|
+
const token = sessionStorage.getItem(TOKEN_KEY)
|
|
13
|
+
if (token) return token
|
|
14
|
+
else return false
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
/**
|
|
18
|
+
* 获取浏览器地址url中的参数
|
|
19
|
+
* @param url
|
|
20
|
+
* @returns {Object}
|
|
21
|
+
*/
|
|
22
|
+
export const getUrlParams = (url) => {
|
|
23
|
+
if (!url) {
|
|
24
|
+
url = location.search;
|
|
25
|
+
}
|
|
26
|
+
//const url = location.search; //获取url中"?"符后的字串
|
|
27
|
+
const theRequest = {};
|
|
28
|
+
if (url.indexOf("?") !== -1) {
|
|
29
|
+
const str = url.substr(1);
|
|
30
|
+
let strs = str.split("&");
|
|
31
|
+
for (let i = 0; i < strs.length; i++) {
|
|
32
|
+
theRequest[strs[i].split("=")[0]] = unescape(strs[i].split("=")[1]);
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
return theRequest;
|
|
36
|
+
}
|