@zgfe/modules-settings 2.0.0-zhongyuan.11 → 2.0.0-zhongyuan.13
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/es/constants/api.d.ts +2 -0
- package/es/constants/api.js +2 -0
- package/es/modules/companySetting/application/index.d.ts +11 -0
- package/es/modules/companySetting/application/index.js +242 -82
- package/es/modules/companySetting/application/index.less +166 -126
- package/es/modules/personalSetting/info/index.js +1 -1
- package/package.json +2 -2
package/es/constants/api.d.ts
CHANGED
package/es/constants/api.js
CHANGED
|
@@ -16,6 +16,8 @@ var apis = {
|
|
|
16
16
|
editVirtualSourceApp: '/user/editSourceApp.jsp' // 修改虚拟应用的来源应用配置
|
|
17
17
|
},
|
|
18
18
|
setting: {
|
|
19
|
+
queryRealTimeData: 'zg/web/v2/newapp/delay',
|
|
20
|
+
updateStatus: 'zg/web/v2/list/status',
|
|
19
21
|
updateCompanyName: '/company/v2updateInfo.jsp',
|
|
20
22
|
updateLicense: apiPrefix + '/system/license',
|
|
21
23
|
groupInfos: '/auth/groupInfos.jsp',
|
|
@@ -7,6 +7,17 @@ export interface ApplicationItem {
|
|
|
7
7
|
appVersion: number;
|
|
8
8
|
appVersionName: string;
|
|
9
9
|
platform: number[];
|
|
10
|
+
children?: ApplicationListChildren[];
|
|
11
|
+
status?: number;
|
|
12
|
+
joinDatabaseDelay: string;
|
|
13
|
+
realTimeDelay: string;
|
|
14
|
+
}
|
|
15
|
+
export interface ApplicationListChildren {
|
|
16
|
+
label: string;
|
|
17
|
+
key: 'appVersionName' | 'name' | 'platform' | 'status' | 'realTimeDelay' | 'joinDatabaseDelay';
|
|
18
|
+
type: string;
|
|
19
|
+
style?: any;
|
|
20
|
+
list?: number[];
|
|
10
21
|
}
|
|
11
22
|
declare const Application: React.FC<{
|
|
12
23
|
companyId: number;
|
|
@@ -17,7 +17,6 @@ import React, { useEffect, useState, useRef, useContext } from 'react';
|
|
|
17
17
|
import request from '../../../utils/ajax';
|
|
18
18
|
import apis from '../../../constants/api';
|
|
19
19
|
import { notification, Tooltip, Modal, Row, Col, Drawer, Button, Divider, message } from 'antd';
|
|
20
|
-
import Card from '../../../components/card';
|
|
21
20
|
import { BizGlobalDataContext, BizLoading, IconFont } from '@zgfe/business-lib';
|
|
22
21
|
import ApplicationForm from './applicationForm';
|
|
23
22
|
import './index.less';
|
|
@@ -65,7 +64,7 @@ var Application = function Application(_ref) {
|
|
|
65
64
|
var settingRef = useRef();
|
|
66
65
|
var handleQueryList = /*#__PURE__*/function () {
|
|
67
66
|
var _ref2 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
|
|
68
|
-
var _res$data, _res$data2, _res$
|
|
67
|
+
var _res$data, _res$data2, _res$data5, _res$data6, res, _res$data3, _res$data4;
|
|
69
68
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
70
69
|
while (1) switch (_context.prev = _context.next) {
|
|
71
70
|
case 0:
|
|
@@ -92,26 +91,63 @@ var Application = function Application(_ref) {
|
|
|
92
91
|
item.platform = item.platform.reverse();
|
|
93
92
|
}
|
|
94
93
|
});
|
|
94
|
+
//添加列表数据
|
|
95
|
+
res === null || res === void 0 ? void 0 : (_res$data4 = res.data) === null || _res$data4 === void 0 ? void 0 : _res$data4.list.forEach(function (item) {
|
|
96
|
+
item.children = [{
|
|
97
|
+
label: '',
|
|
98
|
+
key: 'name',
|
|
99
|
+
type: 'text',
|
|
100
|
+
style: {
|
|
101
|
+
fontWeight: 'bold',
|
|
102
|
+
fontSize: '14px',
|
|
103
|
+
color: '#000000',
|
|
104
|
+
'min-width': '100px'
|
|
105
|
+
}
|
|
106
|
+
}, {
|
|
107
|
+
label: '实时数据延迟',
|
|
108
|
+
key: 'realTimeDelay',
|
|
109
|
+
type: 'text'
|
|
110
|
+
}, {
|
|
111
|
+
label: '入库数据延迟',
|
|
112
|
+
key: 'joinDatabaseDelay',
|
|
113
|
+
type: 'text'
|
|
114
|
+
}, {
|
|
115
|
+
label: '接入平台',
|
|
116
|
+
key: 'platform',
|
|
117
|
+
type: 'icon',
|
|
118
|
+
list: item.platform
|
|
119
|
+
}, {
|
|
120
|
+
label: '版本',
|
|
121
|
+
key: 'appVersionName',
|
|
122
|
+
type: 'text'
|
|
123
|
+
}, {
|
|
124
|
+
label: '状态',
|
|
125
|
+
key: 'status',
|
|
126
|
+
type: 'status'
|
|
127
|
+
}];
|
|
128
|
+
});
|
|
95
129
|
}
|
|
96
|
-
setList((res === null || res === void 0 ? void 0 : (_res$
|
|
130
|
+
setList((res === null || res === void 0 ? void 0 : (_res$data5 = res.data) === null || _res$data5 === void 0 ? void 0 : _res$data5.list) || []);
|
|
97
131
|
// 如果无应用,自定展示新建应用弹窗
|
|
98
|
-
if (!(res === null || res === void 0 ? void 0 : (_res$
|
|
132
|
+
if (!(res === null || res === void 0 ? void 0 : (_res$data6 = res.data) === null || _res$data6 === void 0 ? void 0 : _res$data6.list)) {
|
|
99
133
|
handleAddClick();
|
|
100
134
|
}
|
|
101
|
-
|
|
135
|
+
//对实时渲染数据进行处理
|
|
136
|
+
getRealTimeData();
|
|
137
|
+
_context.next = 18;
|
|
102
138
|
break;
|
|
103
|
-
case
|
|
104
|
-
_context.prev =
|
|
139
|
+
case 14:
|
|
140
|
+
_context.prev = 14;
|
|
105
141
|
_context.t0 = _context["catch"](1);
|
|
106
142
|
setLoading(false);
|
|
107
143
|
notification.error({
|
|
108
144
|
message: _context.t0
|
|
109
145
|
});
|
|
110
|
-
case
|
|
146
|
+
case 18:
|
|
111
147
|
case "end":
|
|
112
148
|
return _context.stop();
|
|
113
149
|
}
|
|
114
|
-
}, _callee, null, [[1,
|
|
150
|
+
}, _callee, null, [[1, 14]]);
|
|
115
151
|
}));
|
|
116
152
|
return function handleQueryList() {
|
|
117
153
|
return _ref2.apply(this, arguments);
|
|
@@ -120,52 +156,6 @@ var Application = function Application(_ref) {
|
|
|
120
156
|
useEffect(function () {
|
|
121
157
|
handleQueryList();
|
|
122
158
|
}, []);
|
|
123
|
-
var btnNodes = function btnNodes() {
|
|
124
|
-
var array = [{
|
|
125
|
-
Element: function Element(props) {
|
|
126
|
-
return /*#__PURE__*/React.createElement(Tooltip, {
|
|
127
|
-
title: "\u7F16\u8F91",
|
|
128
|
-
placement: "top"
|
|
129
|
-
}, /*#__PURE__*/React.createElement("span", _objectSpread({}, props)));
|
|
130
|
-
},
|
|
131
|
-
options: {
|
|
132
|
-
className: "zhuge icon-bianji2 ".concat(!authority[1716284360] ? classPrefix + '-disabled' : ''),
|
|
133
|
-
onClick: function onClick(props) {
|
|
134
|
-
return authority[1716284360] && handleEditClick(props);
|
|
135
|
-
}
|
|
136
|
-
}
|
|
137
|
-
}, {
|
|
138
|
-
Element: function Element(props) {
|
|
139
|
-
return /*#__PURE__*/React.createElement(Tooltip, {
|
|
140
|
-
title: "\u5220\u9664",
|
|
141
|
-
placement: "top"
|
|
142
|
-
}, /*#__PURE__*/React.createElement("span", _objectSpread({}, props)));
|
|
143
|
-
},
|
|
144
|
-
options: {
|
|
145
|
-
className: "zhuge icon-shanchu ".concat(!authority[10101] ? classPrefix + '-disabled' : ''),
|
|
146
|
-
onClick: function onClick(props) {
|
|
147
|
-
return authority[10101] && handleDeleteClick(props);
|
|
148
|
-
}
|
|
149
|
-
}
|
|
150
|
-
}];
|
|
151
|
-
if (!isOpen) {
|
|
152
|
-
return [{
|
|
153
|
-
Element: function Element(props) {
|
|
154
|
-
return /*#__PURE__*/React.createElement(Tooltip, {
|
|
155
|
-
title: "\u8BBE\u7F6E",
|
|
156
|
-
placement: "top"
|
|
157
|
-
}, /*#__PURE__*/React.createElement("span", _objectSpread({}, props)));
|
|
158
|
-
},
|
|
159
|
-
options: {
|
|
160
|
-
className: "zhuge icon-shezhi ".concat(!authority[1716285396] ? classPrefix + '-disabled' : ''),
|
|
161
|
-
onClick: function onClick(props) {
|
|
162
|
-
return authority[1716285396] && handleSettingClick(props);
|
|
163
|
-
}
|
|
164
|
-
}
|
|
165
|
-
}].concat(array);
|
|
166
|
-
}
|
|
167
|
-
return array;
|
|
168
|
-
};
|
|
169
159
|
var handleAddClick = /*#__PURE__*/function () {
|
|
170
160
|
var _ref3 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee3() {
|
|
171
161
|
return _regeneratorRuntime().wrap(function _callee3$(_context3) {
|
|
@@ -177,7 +167,7 @@ var Application = function Application(_ref) {
|
|
|
177
167
|
onCancel: function onCancel() {},
|
|
178
168
|
onOk: function () {
|
|
179
169
|
var _onOk = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee2() {
|
|
180
|
-
var _formRef$current, _formRef$current2, _res$
|
|
170
|
+
var _formRef$current, _formRef$current2, _res$data7, data, res;
|
|
181
171
|
return _regeneratorRuntime().wrap(function _callee2$(_context2) {
|
|
182
172
|
while (1) switch (_context2.prev = _context2.next) {
|
|
183
173
|
case 0:
|
|
@@ -207,7 +197,7 @@ var Application = function Application(_ref) {
|
|
|
207
197
|
message.success('创建成功');
|
|
208
198
|
handleQueryList();
|
|
209
199
|
settingCallback && settingCallback('settingAddApplicationCallback', {
|
|
210
|
-
id: res === null || res === void 0 ? void 0 : (_res$
|
|
200
|
+
id: res === null || res === void 0 ? void 0 : (_res$data7 = res.data) === null || _res$data7 === void 0 ? void 0 : _res$data7.appId
|
|
211
201
|
});
|
|
212
202
|
_context2.next = 19;
|
|
213
203
|
break;
|
|
@@ -248,7 +238,7 @@ var Application = function Application(_ref) {
|
|
|
248
238
|
while (1) switch (_context5.prev = _context5.next) {
|
|
249
239
|
case 0:
|
|
250
240
|
Modal.confirm(_objectSpread(_objectSpread({}, modalConfig), {}, {
|
|
251
|
-
title: '
|
|
241
|
+
title: '修改名称',
|
|
252
242
|
icon: null,
|
|
253
243
|
onCancel: function onCancel() {},
|
|
254
244
|
onOk: function () {
|
|
@@ -319,8 +309,8 @@ var Application = function Application(_ref) {
|
|
|
319
309
|
// 主体开关关闭时,设置的是默认主体
|
|
320
310
|
var handleSettingClick = /*#__PURE__*/function () {
|
|
321
311
|
var _ref5 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee6(record) {
|
|
322
|
-
var _res$
|
|
323
|
-
var res, _res$
|
|
312
|
+
var _res$data8, _res$data9, _res$data9$results;
|
|
313
|
+
var res, _res$data10, mainPart;
|
|
324
314
|
return _regeneratorRuntime().wrap(function _callee6$(_context6) {
|
|
325
315
|
while (1) switch (_context6.prev = _context6.next) {
|
|
326
316
|
case 0:
|
|
@@ -334,8 +324,8 @@ var Application = function Application(_ref) {
|
|
|
334
324
|
});
|
|
335
325
|
case 2:
|
|
336
326
|
res = _context6.sent;
|
|
337
|
-
if ((res === null || res === void 0 ? void 0 : (_res$
|
|
338
|
-
mainPart = res === null || res === void 0 ? void 0 : (_res$
|
|
327
|
+
if ((res === null || res === void 0 ? void 0 : (_res$data8 = res.data) === null || _res$data8 === void 0 ? void 0 : _res$data8.results) && (res === null || res === void 0 ? void 0 : (_res$data9 = res.data) === null || _res$data9 === void 0 ? void 0 : (_res$data9$results = _res$data9.results) === null || _res$data9$results === void 0 ? void 0 : _res$data9$results.length) > 0) {
|
|
328
|
+
mainPart = res === null || res === void 0 ? void 0 : (_res$data10 = res.data) === null || _res$data10 === void 0 ? void 0 : _res$data10.results[0];
|
|
339
329
|
setProfile(mainPart);
|
|
340
330
|
setShowSetting(true);
|
|
341
331
|
}
|
|
@@ -484,6 +474,126 @@ var Application = function Application(_ref) {
|
|
|
484
474
|
return _ref7.apply(this, arguments);
|
|
485
475
|
};
|
|
486
476
|
}();
|
|
477
|
+
// 应用状态开关
|
|
478
|
+
// 0:关闭 1:开启
|
|
479
|
+
var landleStatusClick = /*#__PURE__*/function () {
|
|
480
|
+
var _ref8 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee11(props) {
|
|
481
|
+
return _regeneratorRuntime().wrap(function _callee11$(_context11) {
|
|
482
|
+
while (1) switch (_context11.prev = _context11.next) {
|
|
483
|
+
case 0:
|
|
484
|
+
Modal.confirm(_objectSpread(_objectSpread({}, modalConfig), {}, {
|
|
485
|
+
title: props.status ? '关闭应用' : '开启应用',
|
|
486
|
+
content: props.status ? '关闭应用后,应用将不再接收数据' : '开启应用后,应用将开始接收数据',
|
|
487
|
+
icon: null,
|
|
488
|
+
onCancel: function onCancel() {},
|
|
489
|
+
onOk: function () {
|
|
490
|
+
var _onOk4 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee10() {
|
|
491
|
+
var res;
|
|
492
|
+
return _regeneratorRuntime().wrap(function _callee10$(_context10) {
|
|
493
|
+
while (1) switch (_context10.prev = _context10.next) {
|
|
494
|
+
case 0:
|
|
495
|
+
_context10.prev = 0;
|
|
496
|
+
_context10.next = 3;
|
|
497
|
+
return request(apis.setting.updateStatus, {
|
|
498
|
+
method: 'post',
|
|
499
|
+
data: {
|
|
500
|
+
companyId: companyId,
|
|
501
|
+
projectId: props === null || props === void 0 ? void 0 : props.id,
|
|
502
|
+
status: props.status ? 0 : 1
|
|
503
|
+
},
|
|
504
|
+
intercept: false
|
|
505
|
+
});
|
|
506
|
+
case 3:
|
|
507
|
+
res = _context10.sent;
|
|
508
|
+
if (['101000', '100000'].includes(res === null || res === void 0 ? void 0 : res.code)) {
|
|
509
|
+
_context10.next = 7;
|
|
510
|
+
break;
|
|
511
|
+
}
|
|
512
|
+
message.error(res === null || res === void 0 ? void 0 : res.msg);
|
|
513
|
+
return _context10.abrupt("return", Promise.reject());
|
|
514
|
+
case 7:
|
|
515
|
+
message.success(props.status ? '关闭应用成功' : '开启应用成功');
|
|
516
|
+
handleQueryList();
|
|
517
|
+
_context10.next = 15;
|
|
518
|
+
break;
|
|
519
|
+
case 11:
|
|
520
|
+
_context10.prev = 11;
|
|
521
|
+
_context10.t0 = _context10["catch"](0);
|
|
522
|
+
console.log('catch', _context10.t0);
|
|
523
|
+
return _context10.abrupt("return", Promise.reject(_context10.t0));
|
|
524
|
+
case 15:
|
|
525
|
+
case "end":
|
|
526
|
+
return _context10.stop();
|
|
527
|
+
}
|
|
528
|
+
}, _callee10, null, [[0, 11]]);
|
|
529
|
+
}));
|
|
530
|
+
function onOk() {
|
|
531
|
+
return _onOk4.apply(this, arguments);
|
|
532
|
+
}
|
|
533
|
+
return onOk;
|
|
534
|
+
}()
|
|
535
|
+
}));
|
|
536
|
+
case 1:
|
|
537
|
+
case "end":
|
|
538
|
+
return _context11.stop();
|
|
539
|
+
}
|
|
540
|
+
}, _callee11);
|
|
541
|
+
}));
|
|
542
|
+
return function landleStatusClick(_x4) {
|
|
543
|
+
return _ref8.apply(this, arguments);
|
|
544
|
+
};
|
|
545
|
+
}();
|
|
546
|
+
// 获取实时渲染数据
|
|
547
|
+
var getRealTimeData = /*#__PURE__*/function () {
|
|
548
|
+
var _ref9 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee12() {
|
|
549
|
+
var res, intList;
|
|
550
|
+
return _regeneratorRuntime().wrap(function _callee12$(_context12) {
|
|
551
|
+
while (1) switch (_context12.prev = _context12.next) {
|
|
552
|
+
case 0:
|
|
553
|
+
_context12.prev = 0;
|
|
554
|
+
_context12.next = 3;
|
|
555
|
+
return request(apis.setting.queryRealTimeData, {
|
|
556
|
+
method: 'get',
|
|
557
|
+
data: {}
|
|
558
|
+
});
|
|
559
|
+
case 3:
|
|
560
|
+
res = _context12.sent;
|
|
561
|
+
if (['101000', '100000'].includes(res === null || res === void 0 ? void 0 : res.code)) {
|
|
562
|
+
_context12.next = 6;
|
|
563
|
+
break;
|
|
564
|
+
}
|
|
565
|
+
return _context12.abrupt("return", Promise.reject());
|
|
566
|
+
case 6:
|
|
567
|
+
if (res === null || res === void 0 ? void 0 : res.data) {
|
|
568
|
+
intList = list.map(function (item) {
|
|
569
|
+
var obj = item;
|
|
570
|
+
//对相关数据进行合并
|
|
571
|
+
res.data.forEach(function (resItem) {
|
|
572
|
+
if (item.id === resItem.id) {
|
|
573
|
+
obj = Object.assign(item, resItem);
|
|
574
|
+
return;
|
|
575
|
+
}
|
|
576
|
+
});
|
|
577
|
+
return obj;
|
|
578
|
+
});
|
|
579
|
+
setList(intList);
|
|
580
|
+
}
|
|
581
|
+
_context12.next = 12;
|
|
582
|
+
break;
|
|
583
|
+
case 9:
|
|
584
|
+
_context12.prev = 9;
|
|
585
|
+
_context12.t0 = _context12["catch"](0);
|
|
586
|
+
return _context12.abrupt("return", Promise.reject(_context12.t0));
|
|
587
|
+
case 12:
|
|
588
|
+
case "end":
|
|
589
|
+
return _context12.stop();
|
|
590
|
+
}
|
|
591
|
+
}, _callee12, null, [[0, 9]]);
|
|
592
|
+
}));
|
|
593
|
+
return function getRealTimeData() {
|
|
594
|
+
return _ref9.apply(this, arguments);
|
|
595
|
+
};
|
|
596
|
+
}();
|
|
487
597
|
return /*#__PURE__*/React.createElement("div", {
|
|
488
598
|
className: "".concat(classPrefix)
|
|
489
599
|
}, /*#__PURE__*/React.createElement("div", {
|
|
@@ -501,24 +611,78 @@ var Application = function Application(_ref) {
|
|
|
501
611
|
size: "small",
|
|
502
612
|
onClick: handleAddClick
|
|
503
613
|
}, "\u521B\u5EFA\u5E94\u7528")), /*#__PURE__*/React.createElement(Divider, null), /*#__PURE__*/React.createElement(Row, {
|
|
504
|
-
|
|
614
|
+
className: "".concat(classPrefix, "-rowContent"),
|
|
615
|
+
gutter: [0, 16]
|
|
505
616
|
}, list.length > 0 && (list === null || list === void 0 ? void 0 : list.map(function (item) {
|
|
506
|
-
var _item$platform2;
|
|
507
617
|
var content = /*#__PURE__*/React.createElement("div", {
|
|
508
|
-
className: "".concat(classPrefix, "-
|
|
509
|
-
},
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
|
|
514
|
-
|
|
515
|
-
|
|
618
|
+
className: "".concat(classPrefix, "-contentList")
|
|
619
|
+
}, item.children && item.children.length > 0 && item.children.map(function (child) {
|
|
620
|
+
var _child$list, _child$list2;
|
|
621
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
622
|
+
className: "".concat(classPrefix, "-contentList-item")
|
|
623
|
+
}, child.label && (/*#__PURE__*/React.createElement("div", {
|
|
624
|
+
className: "".concat(classPrefix, "-contentList-item-label")
|
|
625
|
+
}, child.label)), /*#__PURE__*/React.createElement("div", {
|
|
626
|
+
className: "".concat(classPrefix, "-contentList-item-value")
|
|
627
|
+
}, child.type === 'icon' && child.list && ((_child$list = child.list) === null || _child$list === void 0 ? void 0 : _child$list.length) > 0 && ((_child$list2 = child.list) === null || _child$list2 === void 0 ? void 0 : _child$list2.map(function (plat) {
|
|
628
|
+
return /*#__PURE__*/React.createElement(Tooltip, {
|
|
629
|
+
title: getPlatText(plat),
|
|
630
|
+
placement: "top"
|
|
631
|
+
}, /*#__PURE__*/React.createElement("span", {
|
|
632
|
+
key: plat,
|
|
633
|
+
className: "icon-".concat(getPlatIcon(plat))
|
|
634
|
+
}));
|
|
635
|
+
})), child.type === 'text' && (/*#__PURE__*/React.createElement(Tooltip, {
|
|
636
|
+
title: item[child.key],
|
|
516
637
|
placement: "top"
|
|
517
638
|
}, /*#__PURE__*/React.createElement("span", {
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
}))
|
|
521
|
-
|
|
639
|
+
className: "".concat(classPrefix, "-contentList-item-label-text"),
|
|
640
|
+
style: child.style
|
|
641
|
+
}, item[child.key]))), child.type === 'status' && (/*#__PURE__*/React.createElement("span", {
|
|
642
|
+
className: "".concat(classPrefix, "-contentList-item-status")
|
|
643
|
+
}, /*#__PURE__*/React.createElement("span", {
|
|
644
|
+
className: "".concat(classPrefix, "-contentList-item-status-icon").concat(item[child.key] || 0)
|
|
645
|
+
}), item[child.key] ? '运行中' : '关闭'))));
|
|
646
|
+
}), /*#__PURE__*/React.createElement("div", {
|
|
647
|
+
className: "".concat(classPrefix, "-contentList-btn")
|
|
648
|
+
}, /*#__PURE__*/React.createElement(Button, {
|
|
649
|
+
type: "link",
|
|
650
|
+
style: {
|
|
651
|
+
padding: '0 10px'
|
|
652
|
+
},
|
|
653
|
+
disabled: !authority[1716284934],
|
|
654
|
+
onClick: function onClick() {
|
|
655
|
+
return landleStatusClick && landleStatusClick(item);
|
|
656
|
+
}
|
|
657
|
+
}, item.status ? '关闭' : '开启'), /*#__PURE__*/React.createElement(Button, {
|
|
658
|
+
type: "link",
|
|
659
|
+
style: {
|
|
660
|
+
padding: '0 10px'
|
|
661
|
+
},
|
|
662
|
+
disabled: !authority[1716284360],
|
|
663
|
+
onClick: function onClick() {
|
|
664
|
+
return authority[1716284360] && handleEditClick(item);
|
|
665
|
+
}
|
|
666
|
+
}, "\u4FEE\u6539\u540D\u79F0"), /*#__PURE__*/React.createElement(Button, {
|
|
667
|
+
type: "link",
|
|
668
|
+
style: {
|
|
669
|
+
padding: '0 10px'
|
|
670
|
+
},
|
|
671
|
+
disabled: !authority[10101],
|
|
672
|
+
onClick: function onClick() {
|
|
673
|
+
return authority[10101] && handleDeleteClick(item);
|
|
674
|
+
}
|
|
675
|
+
}, "\u5220\u9664"), !isOpen && (/*#__PURE__*/React.createElement(Button, {
|
|
676
|
+
type: "link",
|
|
677
|
+
style: {
|
|
678
|
+
padding: '0 10px'
|
|
679
|
+
},
|
|
680
|
+
disabled: !authority[1716285396],
|
|
681
|
+
onClick: function onClick() {
|
|
682
|
+
return authority[1716285396] && handleSettingClick(item);
|
|
683
|
+
}
|
|
684
|
+
}, "\u8BBE\u7F6E")), isOpen && (/*#__PURE__*/React.createElement(Button, {
|
|
685
|
+
type: "link",
|
|
522
686
|
style: {
|
|
523
687
|
padding: '0 10px'
|
|
524
688
|
},
|
|
@@ -529,12 +693,8 @@ var Application = function Application(_ref) {
|
|
|
529
693
|
}, "\u4E3B\u4F53\u7BA1\u7406"))));
|
|
530
694
|
return /*#__PURE__*/React.createElement(Col, {
|
|
531
695
|
key: item.id,
|
|
532
|
-
span:
|
|
533
|
-
},
|
|
534
|
-
title: item.name,
|
|
535
|
-
btnNodes: btnNodes(),
|
|
536
|
-
content: content
|
|
537
|
-
})));
|
|
696
|
+
span: 24
|
|
697
|
+
}, content);
|
|
538
698
|
})), loading && /*#__PURE__*/React.createElement(BizLoading, null)), /*#__PURE__*/React.createElement(Drawer, {
|
|
539
699
|
className: "".concat(classPrefix, "-drawer"),
|
|
540
700
|
open: showSetting,
|
|
@@ -1,126 +1,166 @@
|
|
|
1
|
-
.application {
|
|
2
|
-
min-height: 400px;
|
|
3
|
-
overflow-x: hidden;
|
|
4
|
-
overflow-y: auto;
|
|
5
|
-
|
|
6
|
-
&-modal {
|
|
7
|
-
.ant-modal-body {
|
|
8
|
-
padding: 24px !important;
|
|
9
|
-
}
|
|
10
|
-
.ant-modal-confirm-body .ant-modal-confirm-title {
|
|
11
|
-
color: #000;
|
|
12
|
-
font-size: 24px;
|
|
13
|
-
line-height: 24px;
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
.ant-modal-confirm-body .ant-modal-confirm-content {
|
|
17
|
-
margin-top: 0;
|
|
18
|
-
padding-top: 24px;
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
.ant-modal-close {
|
|
22
|
-
padding-top: 8px;
|
|
23
|
-
padding-right: 6px;
|
|
24
|
-
|
|
25
|
-
&-x {
|
|
26
|
-
color: #021429;
|
|
27
|
-
font-size: 24px;
|
|
28
|
-
}
|
|
29
|
-
}
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
&-drawer {
|
|
33
|
-
.ant-drawer-header-title {
|
|
34
|
-
flex-direction: row-reverse;
|
|
35
|
-
}
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
.bsicon {
|
|
39
|
-
color: #9aa1a9;
|
|
40
|
-
font-size: 16px !important;
|
|
41
|
-
}
|
|
42
|
-
.bsicon:hover {
|
|
43
|
-
color: var(--io-i-, #165dff);
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
.bsicon.shanchu:hover {
|
|
47
|
-
color: #fb5547;
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
.zhuge.icon-shanchu:hover {
|
|
51
|
-
color: #fb5547;
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
&-alert-info {
|
|
55
|
-
background-color: #e6f7ff;
|
|
56
|
-
border: 1px solid #91d5ff;
|
|
57
|
-
border-radius: 2px;
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
&-form {
|
|
61
|
-
display: flex;
|
|
62
|
-
align-items: center;
|
|
63
|
-
justify-content: space-between;
|
|
64
|
-
|
|
65
|
-
&-item {
|
|
66
|
-
display: flex;
|
|
67
|
-
gap: 8px;
|
|
68
|
-
align-items: center;
|
|
69
|
-
|
|
70
|
-
.bsicon {
|
|
71
|
-
color: #fd9f41;
|
|
72
|
-
}
|
|
73
|
-
|
|
74
|
-
.bsicon:hover {
|
|
75
|
-
color: var(--io-i-, #fd9f41);
|
|
76
|
-
}
|
|
77
|
-
}
|
|
78
|
-
|
|
79
|
-
.ant-btn-sm {
|
|
80
|
-
height: 32px;
|
|
81
|
-
padding: 4px 16px;
|
|
82
|
-
}
|
|
83
|
-
}
|
|
84
|
-
|
|
85
|
-
.ant-divider-horizontal {
|
|
86
|
-
margin: 14px 0;
|
|
87
|
-
}
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
}
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
1
|
+
.application {
|
|
2
|
+
min-height: 400px;
|
|
3
|
+
overflow-x: hidden;
|
|
4
|
+
overflow-y: auto;
|
|
5
|
+
|
|
6
|
+
&-modal {
|
|
7
|
+
.ant-modal-body {
|
|
8
|
+
padding: 24px !important;
|
|
9
|
+
}
|
|
10
|
+
.ant-modal-confirm-body .ant-modal-confirm-title {
|
|
11
|
+
color: #000;
|
|
12
|
+
font-size: 24px;
|
|
13
|
+
line-height: 24px;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
.ant-modal-confirm-body .ant-modal-confirm-content {
|
|
17
|
+
margin-top: 0;
|
|
18
|
+
padding-top: 24px;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
.ant-modal-close {
|
|
22
|
+
padding-top: 8px;
|
|
23
|
+
padding-right: 6px;
|
|
24
|
+
|
|
25
|
+
&-x {
|
|
26
|
+
color: #021429;
|
|
27
|
+
font-size: 24px;
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
&-drawer {
|
|
33
|
+
.ant-drawer-header-title {
|
|
34
|
+
flex-direction: row-reverse;
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
.bsicon {
|
|
39
|
+
color: #9aa1a9;
|
|
40
|
+
font-size: 16px !important;
|
|
41
|
+
}
|
|
42
|
+
.bsicon:hover {
|
|
43
|
+
color: var(--io-i-, #165dff);
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
.bsicon.shanchu:hover {
|
|
47
|
+
color: #fb5547;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
.zhuge.icon-shanchu:hover {
|
|
51
|
+
color: #fb5547;
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
&-alert-info {
|
|
55
|
+
background-color: #e6f7ff;
|
|
56
|
+
border: 1px solid #91d5ff;
|
|
57
|
+
border-radius: 2px;
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
&-form {
|
|
61
|
+
display: flex;
|
|
62
|
+
align-items: center;
|
|
63
|
+
justify-content: space-between;
|
|
64
|
+
|
|
65
|
+
&-item {
|
|
66
|
+
display: flex;
|
|
67
|
+
gap: 8px;
|
|
68
|
+
align-items: center;
|
|
69
|
+
|
|
70
|
+
.bsicon {
|
|
71
|
+
color: #fd9f41;
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
.bsicon:hover {
|
|
75
|
+
color: var(--io-i-, #fd9f41);
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
.ant-btn-sm {
|
|
80
|
+
height: 32px;
|
|
81
|
+
padding: 4px 16px;
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
.ant-divider-horizontal {
|
|
86
|
+
margin: 14px 0;
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
.biz-loading-container.loading {
|
|
90
|
+
margin-top: 100px;
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
&-disabled,
|
|
94
|
+
&-disabled:hover,
|
|
95
|
+
&-disabled:focus {
|
|
96
|
+
cursor: not-allowed !important;
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
.ant-btn-primary[disabled],
|
|
100
|
+
.ant-btn-primary[disabled]:hover,
|
|
101
|
+
.ant-btn-primary[disabled]:focus,
|
|
102
|
+
.ant-btn-primary[disabled]:active {
|
|
103
|
+
color: #fff;
|
|
104
|
+
background: var(--io-i2-, #d0dfff);
|
|
105
|
+
border: 1px solid #d0dfff;
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
.settings-card {
|
|
109
|
+
gap: 6px;
|
|
110
|
+
height: 120px;
|
|
111
|
+
}
|
|
112
|
+
&-rowContent {
|
|
113
|
+
overflow: auto;
|
|
114
|
+
}
|
|
115
|
+
&-contentList {
|
|
116
|
+
display: grid;
|
|
117
|
+
grid-template-columns: 240px repeat(5, minmax(95px, 1fr)) 260px;
|
|
118
|
+
align-items: center;
|
|
119
|
+
&-item {
|
|
120
|
+
flex: 1;
|
|
121
|
+
color: var(--io-N6-, #67727f);
|
|
122
|
+
text-align: center;
|
|
123
|
+
&-label {
|
|
124
|
+
font-size: 14px;
|
|
125
|
+
}
|
|
126
|
+
&-value {
|
|
127
|
+
display: flex;
|
|
128
|
+
grid-gap: 4px;
|
|
129
|
+
gap: 4px;
|
|
130
|
+
align-items: center;
|
|
131
|
+
justify-content: center;
|
|
132
|
+
white-space: nowrap;
|
|
133
|
+
}
|
|
134
|
+
&-label-text {
|
|
135
|
+
overflow: hidden;
|
|
136
|
+
white-space: nowrap;
|
|
137
|
+
text-overflow: ellipsis;
|
|
138
|
+
}
|
|
139
|
+
&-status-icon0,
|
|
140
|
+
&-status-icon1 {
|
|
141
|
+
display: inline-block;
|
|
142
|
+
width: 6px;
|
|
143
|
+
height: 6px;
|
|
144
|
+
margin-right: 3px;
|
|
145
|
+
border-radius: 50%;
|
|
146
|
+
transform: translateY(-1px);
|
|
147
|
+
}
|
|
148
|
+
&-status-icon0 {
|
|
149
|
+
background: #67727f;
|
|
150
|
+
}
|
|
151
|
+
&-status-icon1 {
|
|
152
|
+
background: #165dff;
|
|
153
|
+
}
|
|
154
|
+
}
|
|
155
|
+
&-btn {
|
|
156
|
+
position: sticky;
|
|
157
|
+
top: 0;
|
|
158
|
+
right: 0;
|
|
159
|
+
display: flex;
|
|
160
|
+
align-items: center;
|
|
161
|
+
height: 100%;
|
|
162
|
+
background-color: #fff;
|
|
163
|
+
box-shadow: -12px 0px 8px -8px #0505050f;
|
|
164
|
+
}
|
|
165
|
+
}
|
|
166
|
+
}
|
|
@@ -134,7 +134,7 @@ var PersonalInfo = function PersonalInfo(_ref) {
|
|
|
134
134
|
type: "primary",
|
|
135
135
|
htmlType: "submit",
|
|
136
136
|
loading: loading,
|
|
137
|
-
disabled: isDemo || !(form.isFieldTouched('username') || form.isFieldTouched('emailNote')
|
|
137
|
+
disabled: isDemo || !(form.isFieldTouched('username') || form.isFieldTouched('emailNote') || form.isFieldTouched('telphone')) || !!form.getFieldsError().filter(function (_ref2) {
|
|
138
138
|
var errors = _ref2.errors;
|
|
139
139
|
return errors.length;
|
|
140
140
|
}).length || JSON.stringify(initialValues) === JSON.stringify(form.getFieldsValue())
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@zgfe/modules-settings",
|
|
3
|
-
"version": "2.0.0-zhongyuan.
|
|
3
|
+
"version": "2.0.0-zhongyuan.13",
|
|
4
4
|
"private": false,
|
|
5
5
|
"module": "es/index.js",
|
|
6
6
|
"typings": "es/index.d.ts",
|
|
@@ -67,7 +67,7 @@
|
|
|
67
67
|
"publishConfig": {
|
|
68
68
|
"access": "public"
|
|
69
69
|
},
|
|
70
|
-
"gitHead": "
|
|
70
|
+
"gitHead": "98b123e9526464b5e41ea5ce970e03456df20642",
|
|
71
71
|
"gitHooks": {
|
|
72
72
|
"pre-commit": "lint-staged"
|
|
73
73
|
}
|