mcrm-mobile 1.5.4 → 1.5.6
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 +42 -42
- package/es/data-process/ark.js +14 -14
- package/es/data-process/index.js +36 -36
- package/es/http/index.js +23 -19
- package/es/index.js +1 -1
- package/es/menu/index.js +10 -8
- package/es/menu-jump/index.js +399 -300
- package/es/nav-bar/index.less +97 -97
- package/es/style/theme.less +1189 -1189
- package/es/tab/index.less +25 -25
- package/es/tabs/index.less +277 -277
- package/es/utils/create-request-body/json.js +4 -4
- package/es/utils/filter/index.js +12 -1
- package/lib/data-process/ark.js +14 -14
- package/lib/data-process/index.js +36 -36
- package/lib/http/index.js +23 -19
- package/lib/index.js +1 -1
- package/lib/mcrm-mobile.js +497 -381
- package/lib/mcrm-mobile.min.js +1 -1
- package/lib/menu/index.js +10 -8
- package/lib/menu-jump/index.js +399 -298
- package/lib/nav-bar/index.less +97 -97
- package/lib/style/theme.less +1189 -1189
- package/lib/tab/index.less +25 -25
- package/lib/tabs/index.less +277 -277
- package/lib/utils/create-request-body/json.js +4 -4
- package/lib/utils/filter/index.js +12 -0
- package/package.json +158 -158
- package/types/data-process.d.ts +18 -18
- package/vetur/attributes.json +224 -224
- package/vetur/tags.json +61 -61
- package/vetur/web-types.json +542 -542
package/README.md
CHANGED
|
@@ -1,42 +1,42 @@
|
|
|
1
|
-
<div class="card">
|
|
2
|
-
<div class="van-doc-intro">
|
|
3
|
-
<h2 style="margin: 0; font-size: 36px; line-height: 60px;">McrmMobile</h2>
|
|
4
|
-
<p>生意宝专用组件库</p>
|
|
5
|
-
</div>
|
|
6
|
-
</div>
|
|
7
|
-
<p align="center">
|
|
8
|
-
🔥 <a href="http://20.26.39.174/downvue/mcrm-docs-new">文档网站</a>
|
|
9
|
-
</p>
|
|
10
|
-
|
|
11
|
-
### 特性
|
|
12
|
-
|
|
13
|
-
- 完善的文档和示例
|
|
14
|
-
- 支持按需引入
|
|
15
|
-
- 支持 TS
|
|
16
|
-
|
|
17
|
-
### 安装
|
|
18
|
-
|
|
19
|
-
```bash
|
|
20
|
-
# 通过 npm 安装
|
|
21
|
-
npm i mcrm-mobile -S
|
|
22
|
-
|
|
23
|
-
# 通过 yarn 安装
|
|
24
|
-
yarn add mcrm-mobile
|
|
25
|
-
```
|
|
26
|
-
|
|
27
|
-
### 快速上手
|
|
28
|
-
|
|
29
|
-
```js
|
|
30
|
-
import Vue from "vue";
|
|
31
|
-
import { Button } from "mcrm-mobile";
|
|
32
|
-
|
|
33
|
-
Vue.use(Button);
|
|
34
|
-
```
|
|
35
|
-
|
|
36
|
-
### 浏览器支持
|
|
37
|
-
|
|
38
|
-
现代浏览器以及 Android 4.0+, iOS 7+
|
|
39
|
-
|
|
40
|
-
### 开源协议
|
|
41
|
-
|
|
42
|
-
本项目基于 [MIT](https://zh.wikipedia.org/wiki/MIT%E8%A8%B1%E5%8F%AF%E8%AD%89) 协议,请自由地享受和参与开源
|
|
1
|
+
<div class="card">
|
|
2
|
+
<div class="van-doc-intro">
|
|
3
|
+
<h2 style="margin: 0; font-size: 36px; line-height: 60px;">McrmMobile</h2>
|
|
4
|
+
<p>生意宝专用组件库</p>
|
|
5
|
+
</div>
|
|
6
|
+
</div>
|
|
7
|
+
<p align="center">
|
|
8
|
+
🔥 <a href="http://20.26.39.174/downvue/mcrm-docs-new">文档网站</a>
|
|
9
|
+
</p>
|
|
10
|
+
|
|
11
|
+
### 特性
|
|
12
|
+
|
|
13
|
+
- 完善的文档和示例
|
|
14
|
+
- 支持按需引入
|
|
15
|
+
- 支持 TS
|
|
16
|
+
|
|
17
|
+
### 安装
|
|
18
|
+
|
|
19
|
+
```bash
|
|
20
|
+
# 通过 npm 安装
|
|
21
|
+
npm i mcrm-mobile -S
|
|
22
|
+
|
|
23
|
+
# 通过 yarn 安装
|
|
24
|
+
yarn add mcrm-mobile
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
### 快速上手
|
|
28
|
+
|
|
29
|
+
```js
|
|
30
|
+
import Vue from "vue";
|
|
31
|
+
import { Button } from "mcrm-mobile";
|
|
32
|
+
|
|
33
|
+
Vue.use(Button);
|
|
34
|
+
```
|
|
35
|
+
|
|
36
|
+
### 浏览器支持
|
|
37
|
+
|
|
38
|
+
现代浏览器以及 Android 4.0+, iOS 7+
|
|
39
|
+
|
|
40
|
+
### 开源协议
|
|
41
|
+
|
|
42
|
+
本项目基于 [MIT](https://zh.wikipedia.org/wiki/MIT%E8%A8%B1%E5%8F%AF%E8%AD%89) 协议,请自由地享受和参与开源
|
package/es/data-process/ark.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Base64加解密封装
|
|
1
|
+
/**
|
|
2
|
+
* Base64加解密封装
|
|
3
3
|
*/
|
|
4
4
|
function Base64() {
|
|
5
5
|
// private property
|
|
@@ -116,8 +116,8 @@ function Base64() {
|
|
|
116
116
|
return string;
|
|
117
117
|
};
|
|
118
118
|
}
|
|
119
|
-
/**
|
|
120
|
-
* 随机整数: [0, (n-1)]
|
|
119
|
+
/**
|
|
120
|
+
* 随机整数: [0, (n-1)]
|
|
121
121
|
*/
|
|
122
122
|
|
|
123
123
|
|
|
@@ -125,8 +125,8 @@ function rnd(n) {
|
|
|
125
125
|
var random = Math.floor(Math.random() * n);
|
|
126
126
|
return random;
|
|
127
127
|
}
|
|
128
|
-
/**-
|
|
129
|
-
* 简单解密
|
|
128
|
+
/**-
|
|
129
|
+
* 简单解密
|
|
130
130
|
*/
|
|
131
131
|
|
|
132
132
|
|
|
@@ -139,8 +139,8 @@ function decodeBase64ForSec(str) {
|
|
|
139
139
|
result = deleteChar(index2, result);
|
|
140
140
|
return base64.decode(result);
|
|
141
141
|
}
|
|
142
|
-
/**
|
|
143
|
-
* 简单加密
|
|
142
|
+
/**
|
|
143
|
+
* 简单加密
|
|
144
144
|
*/
|
|
145
145
|
|
|
146
146
|
|
|
@@ -153,8 +153,8 @@ function encodeBase64ForSec(str) {
|
|
|
153
153
|
result = insertChar(index2, getRandomForSec(), result);
|
|
154
154
|
return result.toString();
|
|
155
155
|
}
|
|
156
|
-
/**
|
|
157
|
-
* 插入字符
|
|
156
|
+
/**
|
|
157
|
+
* 插入字符
|
|
158
158
|
*/
|
|
159
159
|
|
|
160
160
|
|
|
@@ -162,8 +162,8 @@ function insertChar(n, c, str) {
|
|
|
162
162
|
var result = str.substring(0, n) + c + str.substring(n, str.length);
|
|
163
163
|
return result;
|
|
164
164
|
}
|
|
165
|
-
/**
|
|
166
|
-
* 删除字符
|
|
165
|
+
/**
|
|
166
|
+
* 删除字符
|
|
167
167
|
*/
|
|
168
168
|
|
|
169
169
|
|
|
@@ -171,8 +171,8 @@ function deleteChar(n, str) {
|
|
|
171
171
|
var result = str.substring(0, n) + str.substring(n + 1, str.length);
|
|
172
172
|
return result;
|
|
173
173
|
}
|
|
174
|
-
/**
|
|
175
|
-
* 加解密获取随机字符
|
|
174
|
+
/**
|
|
175
|
+
* 加解密获取随机字符
|
|
176
176
|
*/
|
|
177
177
|
|
|
178
178
|
|
package/es/data-process/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @author Wuner
|
|
3
|
-
* @date 2021/9/28
|
|
4
|
-
* @Description: 数据加解密
|
|
1
|
+
/**
|
|
2
|
+
* @author Wuner
|
|
3
|
+
* @date 2021/9/28
|
|
4
|
+
* @Description: 数据加解密
|
|
5
5
|
*/
|
|
6
6
|
import Vue from "vue";
|
|
7
7
|
import { strEnc, strDec } from "./des.js";
|
|
@@ -14,11 +14,11 @@ var CryptoJS = require("crypto-js");
|
|
|
14
14
|
|
|
15
15
|
var KEY = "TUNSTWQ1jcm1BQkNEIRUZHSA==";
|
|
16
16
|
var IV = "VGRtYlmdsalAxMWUxBcHJraw==";
|
|
17
|
-
/**
|
|
18
|
-
* AES加密
|
|
19
|
-
* @param content 需加密的文本
|
|
20
|
-
* @param key 密钥
|
|
21
|
-
* @param iv 偏移量
|
|
17
|
+
/**
|
|
18
|
+
* AES加密
|
|
19
|
+
* @param content 需加密的文本
|
|
20
|
+
* @param key 密钥
|
|
21
|
+
* @param iv 偏移量
|
|
22
22
|
*/
|
|
23
23
|
|
|
24
24
|
var aesEncrypt = function aesEncrypt(content, key, iv) {
|
|
@@ -34,11 +34,11 @@ var aesEncrypt = function aesEncrypt(content, key, iv) {
|
|
|
34
34
|
});
|
|
35
35
|
return encrypted.toString(); //返回的是base64格式的密文
|
|
36
36
|
};
|
|
37
|
-
/**
|
|
38
|
-
* AES解密
|
|
39
|
-
* @param content 密文
|
|
40
|
-
* @param key 密钥
|
|
41
|
-
* @param iv 偏移量
|
|
37
|
+
/**
|
|
38
|
+
* AES解密
|
|
39
|
+
* @param content 密文
|
|
40
|
+
* @param key 密钥
|
|
41
|
+
* @param iv 偏移量
|
|
42
42
|
*/
|
|
43
43
|
|
|
44
44
|
|
|
@@ -56,30 +56,30 @@ var aesDecrypt = function aesDecrypt(content, key, iv) {
|
|
|
56
56
|
});
|
|
57
57
|
return decrypted.toString(CryptoJS.enc.Utf8);
|
|
58
58
|
};
|
|
59
|
-
/**
|
|
60
|
-
* DES解密
|
|
61
|
-
* @param content 密文
|
|
62
|
-
* @param keys 密钥
|
|
59
|
+
/**
|
|
60
|
+
* DES解密
|
|
61
|
+
* @param content 密文
|
|
62
|
+
* @param keys 密钥
|
|
63
63
|
*/
|
|
64
64
|
|
|
65
65
|
|
|
66
66
|
var desDecrypt = function desDecrypt(content, keys) {
|
|
67
67
|
return strDec(content, keys[0], keys[1], keys[2]);
|
|
68
68
|
};
|
|
69
|
-
/**
|
|
70
|
-
* DES加密
|
|
71
|
-
* @param content 需加密的文本
|
|
72
|
-
* @param keys 密钥
|
|
69
|
+
/**
|
|
70
|
+
* DES加密
|
|
71
|
+
* @param content 需加密的文本
|
|
72
|
+
* @param keys 密钥
|
|
73
73
|
*/
|
|
74
74
|
|
|
75
75
|
|
|
76
76
|
var desEncrypt = function desEncrypt(content, keys) {
|
|
77
77
|
return strEnc(content, keys[0], keys[1], keys[2]);
|
|
78
78
|
};
|
|
79
|
-
/**
|
|
80
|
-
* base64加密
|
|
81
|
-
* @param content
|
|
82
|
-
* @returns {*}
|
|
79
|
+
/**
|
|
80
|
+
* base64加密
|
|
81
|
+
* @param content
|
|
82
|
+
* @returns {*}
|
|
83
83
|
*/
|
|
84
84
|
|
|
85
85
|
|
|
@@ -87,10 +87,10 @@ var base64Encrypt = function base64Encrypt(content) {
|
|
|
87
87
|
var words = CryptoJS.enc.Utf8.parse(content);
|
|
88
88
|
return CryptoJS.enc.Base64.stringify(words);
|
|
89
89
|
};
|
|
90
|
-
/**
|
|
91
|
-
* base64解密
|
|
92
|
-
* @param content
|
|
93
|
-
* @returns {*}
|
|
90
|
+
/**
|
|
91
|
+
* base64解密
|
|
92
|
+
* @param content
|
|
93
|
+
* @returns {*}
|
|
94
94
|
*/
|
|
95
95
|
|
|
96
96
|
|
|
@@ -98,18 +98,18 @@ var base64Decrypt = function base64Decrypt(content) {
|
|
|
98
98
|
var words = CryptoJS.enc.Base64.parse(content);
|
|
99
99
|
return CryptoJS.enc.Utf8.stringify(words);
|
|
100
100
|
};
|
|
101
|
-
/**
|
|
102
|
-
* 方舟加密
|
|
103
|
-
* @param content 需要加密对文本
|
|
101
|
+
/**
|
|
102
|
+
* 方舟加密
|
|
103
|
+
* @param content 需要加密对文本
|
|
104
104
|
*/
|
|
105
105
|
|
|
106
106
|
|
|
107
107
|
export var arkEncrypt = function arkEncrypt(content) {
|
|
108
108
|
return encodeBase64ForSec(content);
|
|
109
109
|
};
|
|
110
|
-
/**
|
|
111
|
-
* 方舟解密
|
|
112
|
-
* @param content 需要解密对文本
|
|
110
|
+
/**
|
|
111
|
+
* 方舟解密
|
|
112
|
+
* @param content 需要解密对文本
|
|
113
113
|
*/
|
|
114
114
|
|
|
115
115
|
var arkDecrypt = function arkDecrypt(content) {
|
package/es/http/index.js
CHANGED
|
@@ -375,7 +375,7 @@ var operationSaveLog = /*#__PURE__*/function () {
|
|
|
375
375
|
_ref10 = Session.get("mmExpInfo") || {}, SESSIONNEED = _ref10.SESSIONNEED, _ref10$mainAcct = _ref10.mainAcct, mainAcct = _ref10$mainAcct === void 0 ? "" : _ref10$mainAcct, _ref10$resAcct = _ref10.resAcct, resAcct = _ref10$resAcct === void 0 ? "" : _ref10$resAcct, _ref10$switchNames = _ref10.switchNames, switchNames = _ref10$switchNames === void 0 ? {} : _ref10$switchNames;
|
|
376
376
|
|
|
377
377
|
if (!switchNames.OPERATION_LOG_SWITCH) {
|
|
378
|
-
_context9.next =
|
|
378
|
+
_context9.next = 37;
|
|
379
379
|
break;
|
|
380
380
|
}
|
|
381
381
|
|
|
@@ -392,6 +392,8 @@ var operationSaveLog = /*#__PURE__*/function () {
|
|
|
392
392
|
});
|
|
393
393
|
|
|
394
394
|
case 6:
|
|
395
|
+
params.resourceCode = "sys_m_crm";
|
|
396
|
+
params.login4a = 0;
|
|
395
397
|
params.operationSessionId = SESSIONNEED;
|
|
396
398
|
params.operationTypeName = operationTypeName;
|
|
397
399
|
params.operationTypeCode = operationTypeCode;
|
|
@@ -401,36 +403,38 @@ var operationSaveLog = /*#__PURE__*/function () {
|
|
|
401
403
|
params.resourceSubAccount = resAcct;
|
|
402
404
|
params.operationResult = operationResult;
|
|
403
405
|
_context9.t0 = operationTypeCode;
|
|
404
|
-
_context9.next = _context9.t0 === "openMenu" ?
|
|
406
|
+
_context9.next = _context9.t0 === "openMenu" ? 19 : _context9.t0 === "logIn" ? 21 : _context9.t0 === "logOut" ? 23 : _context9.t0 === "query" ? 25 : _context9.t0 === "handle" ? 27 : 29;
|
|
405
407
|
break;
|
|
406
408
|
|
|
407
|
-
case 17:
|
|
408
|
-
params.operationContent = mainAcct + operationTypeName + moduleName;
|
|
409
|
-
return _context9.abrupt("break", 29);
|
|
410
|
-
|
|
411
409
|
case 19:
|
|
412
|
-
params.operationContent = mainAcct + operationTypeName;
|
|
413
|
-
return _context9.abrupt("break",
|
|
410
|
+
params.operationContent = mainAcct + operationTypeName + moduleName;
|
|
411
|
+
return _context9.abrupt("break", 31);
|
|
414
412
|
|
|
415
413
|
case 21:
|
|
416
414
|
params.operationContent = mainAcct + operationTypeName;
|
|
417
|
-
return _context9.abrupt("break",
|
|
415
|
+
return _context9.abrupt("break", 31);
|
|
418
416
|
|
|
419
417
|
case 23:
|
|
420
|
-
params.operationContent = mainAcct +
|
|
421
|
-
return _context9.abrupt("break",
|
|
418
|
+
params.operationContent = mainAcct + operationTypeName;
|
|
419
|
+
return _context9.abrupt("break", 31);
|
|
422
420
|
|
|
423
421
|
case 25:
|
|
424
|
-
params.operationContent = mainAcct + "
|
|
425
|
-
return _context9.abrupt("break",
|
|
422
|
+
params.operationContent = mainAcct + "查询了" + moduleName;
|
|
423
|
+
return _context9.abrupt("break", 31);
|
|
426
424
|
|
|
427
425
|
case 27:
|
|
428
|
-
params.operationContent = "";
|
|
429
|
-
return _context9.abrupt("break",
|
|
426
|
+
params.operationContent = mainAcct + "办理了" + moduleName;
|
|
427
|
+
return _context9.abrupt("break", 31);
|
|
430
428
|
|
|
431
429
|
case 29:
|
|
430
|
+
params.operationContent = "";
|
|
431
|
+
return _context9.abrupt("break", 31);
|
|
432
|
+
|
|
433
|
+
case 31:
|
|
432
434
|
if (window.secureOptLog) {
|
|
433
435
|
setLog = window.secureOptLog;
|
|
436
|
+
setLog.set("resourceCode", "sys_m_crm");
|
|
437
|
+
setLog.set("login4a", 0);
|
|
434
438
|
setLog.set("operationTypeName", operationTypeName);
|
|
435
439
|
setLog.set("operationSessionId", SESSIONNEED);
|
|
436
440
|
setLog.set("operationTypeCode", operationTypeCode);
|
|
@@ -441,18 +445,18 @@ var operationSaveLog = /*#__PURE__*/function () {
|
|
|
441
445
|
setLog.set("resourceSubAccount", resAcct);
|
|
442
446
|
setLog.set("clientIp", params.clientIp);
|
|
443
447
|
setLog.set("operationResult", operationResult);
|
|
444
|
-
window.secureOptLog && (params.invokeSessionId = window.secureOptLog.getAESData());
|
|
448
|
+
window.secureOptLog && (params.invokeSessionId = window.secureOptLog.getAESData(Session.get("defaultKeys")[3].log_key, Session.get("defaultKeys")[3].log_iv));
|
|
445
449
|
}
|
|
446
450
|
|
|
447
451
|
_context9.t1 = post;
|
|
448
|
-
_context9.next =
|
|
452
|
+
_context9.next = 35;
|
|
449
453
|
return json(params);
|
|
450
454
|
|
|
451
|
-
case
|
|
455
|
+
case 35:
|
|
452
456
|
_context9.t2 = _context9.sent;
|
|
453
457
|
return _context9.abrupt("return", (0, _context9.t1)("/expension/log/addMenuBuryingPoint", _context9.t2));
|
|
454
458
|
|
|
455
|
-
case
|
|
459
|
+
case 37:
|
|
456
460
|
case "end":
|
|
457
461
|
return _context9.stop();
|
|
458
462
|
}
|
package/es/index.js
CHANGED
|
@@ -91,7 +91,7 @@ import Tag from './tag';
|
|
|
91
91
|
import Toast from './toast';
|
|
92
92
|
import TreeSelect from './tree-select';
|
|
93
93
|
import Uploader from './uploader';
|
|
94
|
-
var version = '1.5.
|
|
94
|
+
var version = '1.5.6';
|
|
95
95
|
var components = [ActionSheet, AddressPicker, Api, Badge, Biz, Button, Calendar, Card, Cell, CellGroup, Checkbox, CheckboxGroup, Circle, Col, Collapse, CollapseItem, CommonUtils, CountDown, DataProcess, DatePicker, DatetimePicker, Dialog, Directive, Divider, Drag, DropdownItem, DropdownMenu, Empty, Field, GoodsAction, GoodsActionButton, GoodsActionIcon, Grid, GridItem, Http, Icon, Image, ImagePreview, IndexAnchor, IndexBar, Info, List, Loading, Local, Menu, MenuIcon, MenuJump, Menus, NavBar, NoticeBar, Notify, Overlay, Pagination, Panel, PasswordInput, Picker, Popover, Popup, Progress, PullRefresh, Radio, RadioGroup, Rank, Rate, Row, SafeKeyboard, Search, Session, ShareSheet, Sidebar, SidebarItem, Slider, Step, Stepper, Steps, Sticky, Swipe, SwipeCell, SwipeItem, Switch, SwitchCell, Tab, Tabbar, TabbarItem, Table, TableColumn, Tabs, Tag, Toast, TreeSelect, Uploader];
|
|
96
96
|
|
|
97
97
|
var install = function install(Vue) {
|
package/es/menu/index.js
CHANGED
|
@@ -127,13 +127,14 @@ export default create({
|
|
|
127
127
|
_this.$emit("click", menu);
|
|
128
128
|
} else {
|
|
129
129
|
if (isRoute) {
|
|
130
|
-
|
|
130
|
+
var _Http$operationSaveLo;
|
|
131
|
+
|
|
132
|
+
logMenusFilter(menuCode) && Http.operationSaveLog((_Http$operationSaveLo = {
|
|
131
133
|
operationTypeName: "打开菜单",
|
|
132
134
|
operationTypeCode: "openMenu",
|
|
133
135
|
operationResult: 0,
|
|
134
|
-
moduleNo: menuPageCode || ""
|
|
135
|
-
|
|
136
|
-
});
|
|
136
|
+
moduleNo: menuPageCode || ""
|
|
137
|
+
}, _Http$operationSaveLo["moduleNo"] = menu.funcId || menuPageCode || "", _Http$operationSaveLo));
|
|
137
138
|
|
|
138
139
|
_this.$router.push({
|
|
139
140
|
name: menuPageCode
|
|
@@ -146,14 +147,15 @@ export default create({
|
|
|
146
147
|
});
|
|
147
148
|
}
|
|
148
149
|
}, function (error) {
|
|
150
|
+
var _Http$operationSaveLo2;
|
|
151
|
+
|
|
149
152
|
Toast.clear();
|
|
150
|
-
logMenusFilter(menuCode) && Http.operationSaveLog({
|
|
153
|
+
logMenusFilter(menuCode) && Http.operationSaveLog((_Http$operationSaveLo2 = {
|
|
151
154
|
operationTypeName: "打开菜单",
|
|
152
155
|
operationTypeCode: "openMenu",
|
|
153
156
|
operationResult: 1,
|
|
154
|
-
moduleNo: menuPageCode || ""
|
|
155
|
-
|
|
156
|
-
});
|
|
157
|
+
moduleNo: menuPageCode || ""
|
|
158
|
+
}, _Http$operationSaveLo2["moduleNo"] = menu.funcId || menuPageCode || "", _Http$operationSaveLo2));
|
|
157
159
|
error && error.message && Toast(error.message);
|
|
158
160
|
|
|
159
161
|
_this.$emit("fail", {
|