@zgfe/modules-settings 2.1.0-zhongyuan.2 → 2.1.0-zhongyuan.21
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/components/importMetaDialog/index.d.ts +2 -0
- package/es/components/importMetaDialog/index.js +18 -3
- package/es/constants/api.d.ts +4 -0
- package/es/constants/api.js +12 -7
- package/es/modules/appSettings/dataAccessFilter/index.js +2 -1
- package/es/modules/companySetting/application/index.js +5 -6
- package/es/modules/companySetting/application/index.less +144 -144
- package/es/modules/companySetting/index.js +37 -33
- package/es/modules/companySetting/user/index.js +29 -24
- package/es/modules/companySetting/user/invite.js +3 -16
- package/es/modules/createDemand/demo/selectPoint.js +0 -1
- package/es/modules/createDemand/index.js +7 -6
- package/es/modules/createDemand/styles/index.less +403 -403
- package/es/modules/createDemand_bf/demo/index.js +0 -1
- package/es/modules/createDemand_bf/index.js +0 -1
- package/es/modules/dealDemand/demo/index.js +0 -1
- package/es/modules/dealDemand/index.js +0 -2
- package/es/modules/demandManage/styles/index.less +155 -155
- package/es/modules/pointMap/createMetaDrawer.js +78 -47
- package/es/modules/pointMap/pageInfo.js +28 -15
- package/es/modules/pointMap/styles/index.less +8 -0
- package/es/modules/pointMap/styles/tree.less +18 -0
- package/es/modules/pointMap/tree.js +191 -117
- package/es/modules/systemSetting/dictionaryItem/dictionaryManagement/create.js +26 -20
- package/es/modules/systemSetting/dictionaryItem/dictionaryManagement/css/index.less +3 -2
- package/es/modules/systemSetting/dictionaryItem/dictionaryManagement/index.js +10 -8
- package/es/modules/systemSetting/dictionaryItem/dictionaryManagement/type/index.d.ts +2 -2
- package/es/modules/systemSetting/dictionaryItem/eventTagManagement/create.js +7 -9
- package/es/modules/systemSetting/dictionaryItem/eventTagManagement/index.js +29 -16
- package/es/modules/systemSetting/dictionaryItem/eventTagManagement/type/index.d.ts +1 -1
- package/es/modules/systemSetting/document-setting/index.js +7 -6
- package/es/modules/systemSetting/index.js +13 -15
- package/package.json +3 -3
|
@@ -93,6 +93,7 @@
|
|
|
93
93
|
overflow: hidden;
|
|
94
94
|
.gengduocaozuo1 {
|
|
95
95
|
color: #354354;
|
|
96
|
+
transform: translateY(4px);
|
|
96
97
|
}
|
|
97
98
|
.gengduocaozuo1:hover {
|
|
98
99
|
color: #165dff;
|
|
@@ -135,6 +136,23 @@
|
|
|
135
136
|
margin-right: 10px;
|
|
136
137
|
}
|
|
137
138
|
}
|
|
139
|
+
&-iconList {
|
|
140
|
+
position: absolute;
|
|
141
|
+
top: 0;
|
|
142
|
+
right: 0;
|
|
143
|
+
bottom: 0;
|
|
144
|
+
display: none;
|
|
145
|
+
justify-content: space-around;
|
|
146
|
+
width: 85px;
|
|
147
|
+
font-size: 16px;
|
|
148
|
+
background: #ffffff;
|
|
149
|
+
.anticon:hover {
|
|
150
|
+
color: #165dff;
|
|
151
|
+
}
|
|
152
|
+
}
|
|
153
|
+
&:hover &-iconList {
|
|
154
|
+
display: flex;
|
|
155
|
+
}
|
|
138
156
|
}
|
|
139
157
|
.ant-tree-title {
|
|
140
158
|
display: block;
|
|
@@ -16,7 +16,7 @@ function _createForOfIteratorHelper(r, e) { var t = "undefined" != typeof Symbol
|
|
|
16
16
|
function _unsupportedIterableToArray(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }
|
|
17
17
|
function _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
|
|
18
18
|
import { Button, Dropdown, Empty, Input, message, Modal, Select, Tree, Popover, Spin, Tag, Checkbox } from 'antd';
|
|
19
|
-
import { QuestionCircleOutlined, EnvironmentOutlined } from '@ant-design/icons';
|
|
19
|
+
import { QuestionCircleOutlined, EnvironmentOutlined, PlusCircleOutlined, MinusCircleOutlined, EditOutlined } from '@ant-design/icons';
|
|
20
20
|
import React, { useContext, useEffect, useRef, useState } from 'react';
|
|
21
21
|
import './styles/tree.less';
|
|
22
22
|
import { BizDialog, BizGlobalDataContext, IconFont } from '@zgfe/business-lib';
|
|
@@ -58,7 +58,9 @@ var formatTreeArr = function formatTreeArr(list, arrTemp, parentName) {
|
|
|
58
58
|
arrTemp.push({
|
|
59
59
|
id: item.id,
|
|
60
60
|
name: parentName ? parentName + ' / ' + item.name : item.name,
|
|
61
|
-
tagJson:
|
|
61
|
+
tagJson: item.labels.map(function (res) {
|
|
62
|
+
return res.labelName;
|
|
63
|
+
}).join('')
|
|
62
64
|
});
|
|
63
65
|
if (item.children.length > 0) {
|
|
64
66
|
formatTreeArr(item.children, arrTemp, item.name);
|
|
@@ -98,7 +100,8 @@ var pointMap = function pointMap(props) {
|
|
|
98
100
|
var _useContext = useContext(BizGlobalDataContext),
|
|
99
101
|
currentApp = _useContext.currentApp,
|
|
100
102
|
route = _useContext.route,
|
|
101
|
-
authority = _useContext.authority
|
|
103
|
+
authority = _useContext.authority,
|
|
104
|
+
showProdDownload = _useContext.showProdDownload;
|
|
102
105
|
var _useState11 = useState([]),
|
|
103
106
|
_useState12 = _slicedToArray(_useState11, 2),
|
|
104
107
|
pointVersionList = _useState12[0],
|
|
@@ -143,12 +146,17 @@ var pointMap = function pointMap(props) {
|
|
|
143
146
|
_useState32 = _slicedToArray(_useState31, 2),
|
|
144
147
|
isShowDel = _useState32[0],
|
|
145
148
|
setIsShowDel = _useState32[1];
|
|
146
|
-
var _useState33 = useState(
|
|
149
|
+
var _useState33 = useState([]),
|
|
147
150
|
_useState34 = _slicedToArray(_useState33, 2),
|
|
148
|
-
|
|
149
|
-
|
|
151
|
+
pointList = _useState34[0],
|
|
152
|
+
setPointList = _useState34[1];
|
|
153
|
+
var _useState35 = useState(!!props.pageStatusIsEdit),
|
|
154
|
+
_useState36 = _slicedToArray(_useState35, 2),
|
|
155
|
+
pageStatusIsEdit = _useState36[0],
|
|
156
|
+
setPageStatusIsEdit = _useState36[1];
|
|
150
157
|
useEffect(function () {
|
|
151
158
|
pointGetVersion();
|
|
159
|
+
getPointList();
|
|
152
160
|
}, []);
|
|
153
161
|
useEffect(function () {
|
|
154
162
|
setPageStatusIsEdit(!!props.pageStatusIsEdit);
|
|
@@ -186,6 +194,7 @@ var pointMap = function pointMap(props) {
|
|
|
186
194
|
});
|
|
187
195
|
};
|
|
188
196
|
var getPointTree = function getPointTree() {
|
|
197
|
+
var fn = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : function () {};
|
|
189
198
|
request(apis.getPointTree, {
|
|
190
199
|
method: 'post',
|
|
191
200
|
data: {
|
|
@@ -194,7 +203,7 @@ var pointMap = function pointMap(props) {
|
|
|
194
203
|
}
|
|
195
204
|
}).then(function (res) {
|
|
196
205
|
if (res && res.code === '100000') {
|
|
197
|
-
pageNum = res === null || res === void 0 ? void 0 : res.data.length;
|
|
206
|
+
pageNum = ((res === null || res === void 0 ? void 0 : res.data.length) || 0) + 1;
|
|
198
207
|
setTreeData(formatTreeData((res === null || res === void 0 ? void 0 : res.data) || []));
|
|
199
208
|
setTreeArr(formatTreeArr((res === null || res === void 0 ? void 0 : res.data) || [], [], '') || []);
|
|
200
209
|
if (!selectedKeys) {
|
|
@@ -206,11 +215,32 @@ var pointMap = function pointMap(props) {
|
|
|
206
215
|
// props.onChangePage(res?.data ? { ...res?.data[0], currentPointVersion } : undefined);
|
|
207
216
|
}
|
|
208
217
|
setChangeNameId(undefined);
|
|
218
|
+
fn();
|
|
209
219
|
}
|
|
210
220
|
}).catch(function (err) {
|
|
211
221
|
console.log(err);
|
|
212
222
|
});
|
|
213
223
|
};
|
|
224
|
+
//查询位置标签
|
|
225
|
+
var getPointList = function getPointList() {
|
|
226
|
+
request(apis.dict.getTagList, {
|
|
227
|
+
method: 'post',
|
|
228
|
+
data: {
|
|
229
|
+
labelType: 1,
|
|
230
|
+
appId: currentApp === null || currentApp === void 0 ? void 0 : currentApp.appId
|
|
231
|
+
}
|
|
232
|
+
}).then(function (res) {
|
|
233
|
+
if (res && res.code == 100000) {
|
|
234
|
+
setPointList(res.data.map(function (res) {
|
|
235
|
+
return {
|
|
236
|
+
label: res.labelName,
|
|
237
|
+
value: res.id,
|
|
238
|
+
labelType: 1
|
|
239
|
+
};
|
|
240
|
+
}));
|
|
241
|
+
}
|
|
242
|
+
});
|
|
243
|
+
};
|
|
214
244
|
var addPage = function addPage(operationType, parentId, targetPageId) {
|
|
215
245
|
request(apis.createPage, {
|
|
216
246
|
method: 'post',
|
|
@@ -341,8 +371,7 @@ var pointMap = function pointMap(props) {
|
|
|
341
371
|
}
|
|
342
372
|
};
|
|
343
373
|
var titleRender = function titleRender(nodeData) {
|
|
344
|
-
var onItemClick = function onItemClick(
|
|
345
|
-
var key = _ref.key;
|
|
374
|
+
var onItemClick = function onItemClick(key) {
|
|
346
375
|
switch (key) {
|
|
347
376
|
case '0':
|
|
348
377
|
if (nodeData.storey >= 20) {
|
|
@@ -374,18 +403,84 @@ var pointMap = function pointMap(props) {
|
|
|
374
403
|
// message.info(`Click on item ${key}`);
|
|
375
404
|
};
|
|
376
405
|
//位置标签list
|
|
377
|
-
var
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
}
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
406
|
+
var color = ['magenta', 'red', 'volcano', 'orange', 'gold', 'lime', 'green', 'cyan', 'blue', 'geekblue', 'purple'];
|
|
407
|
+
var pointContent = /*#__PURE__*/React.createElement(React.Fragment, null, nodeData.labels && nodeData.labels.map(function (res, index) {
|
|
408
|
+
return /*#__PURE__*/React.createElement(Tag, {
|
|
409
|
+
key: index,
|
|
410
|
+
color: color[index]
|
|
411
|
+
}, res.labelName);
|
|
412
|
+
}));
|
|
413
|
+
var pointIds = nodeData.labels && nodeData.labels.map(function (res) {
|
|
414
|
+
return res.id;
|
|
415
|
+
}) || [];
|
|
416
|
+
var menu = {
|
|
417
|
+
items: [{
|
|
418
|
+
label: '添加子页面',
|
|
419
|
+
icon: /*#__PURE__*/React.createElement(IconFont, {
|
|
420
|
+
type: "tianjia3"
|
|
421
|
+
}),
|
|
422
|
+
key: '0'
|
|
423
|
+
}, {
|
|
424
|
+
label: '上方添加页面',
|
|
425
|
+
icon: /*#__PURE__*/React.createElement(IconFont, {
|
|
426
|
+
type: "shangfangtianjia"
|
|
427
|
+
}),
|
|
428
|
+
key: '1'
|
|
429
|
+
}, {
|
|
430
|
+
label: '下方添加页面',
|
|
431
|
+
icon: /*#__PURE__*/React.createElement(IconFont, {
|
|
432
|
+
type: "xiafangtianjia"
|
|
433
|
+
}),
|
|
434
|
+
key: '2'
|
|
435
|
+
}, {
|
|
436
|
+
label: '选择位置标签',
|
|
437
|
+
icon: /*#__PURE__*/React.createElement(EnvironmentOutlined, null),
|
|
438
|
+
key: '5',
|
|
439
|
+
children: pointList.map(function (res) {
|
|
440
|
+
return {
|
|
441
|
+
key: '5' + res.value,
|
|
442
|
+
label: (/*#__PURE__*/React.createElement(Checkbox, {
|
|
443
|
+
defaultChecked: pointIds.indexOf(res.value) != -1,
|
|
444
|
+
onChange: function onChange(e) {
|
|
445
|
+
onChangeTag(e, nodeData, res);
|
|
446
|
+
},
|
|
447
|
+
onClick: function onClick(e) {
|
|
448
|
+
e.stopPropagation();
|
|
449
|
+
}
|
|
450
|
+
}, res.label)),
|
|
451
|
+
disabled: true
|
|
452
|
+
};
|
|
453
|
+
})
|
|
454
|
+
}, {
|
|
455
|
+
type: 'divider'
|
|
456
|
+
}, {
|
|
457
|
+
label: '重命名',
|
|
458
|
+
icon: /*#__PURE__*/React.createElement(IconFont, {
|
|
459
|
+
type: "bianji1"
|
|
460
|
+
}),
|
|
461
|
+
key: '3'
|
|
462
|
+
}, {
|
|
463
|
+
type: 'divider'
|
|
464
|
+
}, {
|
|
465
|
+
label: '删除',
|
|
466
|
+
icon: /*#__PURE__*/React.createElement(IconFont, {
|
|
467
|
+
type: "shanchu2"
|
|
468
|
+
}),
|
|
469
|
+
key: '4'
|
|
470
|
+
}],
|
|
471
|
+
onClick: function onClick(item) {
|
|
472
|
+
item.domEvent.stopPropagation();
|
|
473
|
+
onItemClick(item.key);
|
|
474
|
+
}
|
|
475
|
+
};
|
|
476
|
+
return /*#__PURE__*/React.createElement(Dropdown, {
|
|
477
|
+
disabled: !authority[1724922805],
|
|
478
|
+
menu: menu,
|
|
479
|
+
overlayStyle: {
|
|
480
|
+
width: 156
|
|
481
|
+
},
|
|
482
|
+
trigger: ['contextMenu']
|
|
483
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
389
484
|
className: "".concat(classPrefix, "-tree-item")
|
|
390
485
|
}, changeNameId === nodeData.id ? (/*#__PURE__*/React.createElement(Input, {
|
|
391
486
|
style: {
|
|
@@ -431,118 +526,95 @@ var pointMap = function pointMap(props) {
|
|
|
431
526
|
}
|
|
432
527
|
}, /*#__PURE__*/React.createElement("span", {
|
|
433
528
|
className: "".concat(classPrefix, "-tree-item-title-name")
|
|
434
|
-
}, nodeData.name, " (
|
|
529
|
+
}, nodeData.name, " (", nodeData.pointSum || 0, ")"), /*#__PURE__*/React.createElement(Popover, {
|
|
435
530
|
placement: "topLeft",
|
|
436
531
|
title: "\u4F4D\u7F6E\u6807\u7B7E",
|
|
437
532
|
content: pointContent
|
|
438
|
-
}, /*#__PURE__*/React.createElement(
|
|
439
|
-
|
|
440
|
-
},
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
533
|
+
}, pointContent)))), /*#__PURE__*/React.createElement("div", {
|
|
534
|
+
className: "".concat(classPrefix, "-tree-item-iconList")
|
|
535
|
+
}, /*#__PURE__*/React.createElement(EditOutlined, {
|
|
536
|
+
onClick: function onClick(e) {
|
|
537
|
+
e.stopPropagation();
|
|
538
|
+
onItemClick('3');
|
|
539
|
+
}
|
|
540
|
+
}), /*#__PURE__*/React.createElement(MinusCircleOutlined, {
|
|
541
|
+
onClick: function onClick(e) {
|
|
542
|
+
e.stopPropagation();
|
|
543
|
+
onItemClick('4');
|
|
544
|
+
}
|
|
545
|
+
}), /*#__PURE__*/React.createElement(PlusCircleOutlined, {
|
|
546
|
+
onClick: function onClick(e) {
|
|
547
|
+
e.stopPropagation();
|
|
548
|
+
onItemClick('2');
|
|
549
|
+
}
|
|
550
|
+
}), /*#__PURE__*/React.createElement(Dropdown, {
|
|
449
551
|
disabled: !authority[1724922805],
|
|
450
|
-
|
|
451
|
-
menu: {
|
|
452
|
-
items: [{
|
|
453
|
-
label: '添加子页面',
|
|
454
|
-
icon: /*#__PURE__*/React.createElement(IconFont, {
|
|
455
|
-
type: "tianjia3"
|
|
456
|
-
}),
|
|
457
|
-
key: '0'
|
|
458
|
-
}, {
|
|
459
|
-
label: '上方添加页面',
|
|
460
|
-
icon: /*#__PURE__*/React.createElement(IconFont, {
|
|
461
|
-
type: "shangfangtianjia"
|
|
462
|
-
}),
|
|
463
|
-
key: '1'
|
|
464
|
-
}, {
|
|
465
|
-
label: '下方添加页面',
|
|
466
|
-
icon: /*#__PURE__*/React.createElement(IconFont, {
|
|
467
|
-
type: "xiafangtianjia"
|
|
468
|
-
}),
|
|
469
|
-
key: '2'
|
|
470
|
-
}, {
|
|
471
|
-
label: '选择位置标签',
|
|
472
|
-
icon: /*#__PURE__*/React.createElement(EnvironmentOutlined, null),
|
|
473
|
-
key: '5',
|
|
474
|
-
children: [{
|
|
475
|
-
key: '3-1',
|
|
476
|
-
label: (/*#__PURE__*/React.createElement(Checkbox, {
|
|
477
|
-
onChange: function onChange(e) {
|
|
478
|
-
onChangeTag(e, 'key');
|
|
479
|
-
}
|
|
480
|
-
}, "\u6807\u7B7E1")),
|
|
481
|
-
disabled: true
|
|
482
|
-
}, {
|
|
483
|
-
key: '3-2',
|
|
484
|
-
label: (/*#__PURE__*/React.createElement(Checkbox, {
|
|
485
|
-
onChange: function onChange(e) {
|
|
486
|
-
onChangeTag(e, 'key');
|
|
487
|
-
}
|
|
488
|
-
}, "\u6807\u7B7E2")),
|
|
489
|
-
disabled: true
|
|
490
|
-
}]
|
|
491
|
-
}, {
|
|
492
|
-
type: 'divider'
|
|
493
|
-
}, {
|
|
494
|
-
label: '重命名',
|
|
495
|
-
icon: /*#__PURE__*/React.createElement(IconFont, {
|
|
496
|
-
type: "bianji1"
|
|
497
|
-
}),
|
|
498
|
-
key: '3'
|
|
499
|
-
}, {
|
|
500
|
-
type: 'divider'
|
|
501
|
-
}, {
|
|
502
|
-
label: '删除',
|
|
503
|
-
icon: /*#__PURE__*/React.createElement(IconFont, {
|
|
504
|
-
type: "shanchu2"
|
|
505
|
-
}),
|
|
506
|
-
key: '4'
|
|
507
|
-
}],
|
|
508
|
-
onClick: onItemClick
|
|
509
|
-
},
|
|
552
|
+
menu: menu,
|
|
510
553
|
overlayStyle: {
|
|
511
554
|
width: 156
|
|
512
555
|
},
|
|
513
556
|
trigger: ['click']
|
|
514
557
|
}, /*#__PURE__*/React.createElement(IconFont, {
|
|
558
|
+
type: "gengduocaozuo1",
|
|
515
559
|
onClick: function onClick(e) {
|
|
516
560
|
e.stopPropagation();
|
|
517
|
-
}
|
|
518
|
-
|
|
519
|
-
})));
|
|
561
|
+
}
|
|
562
|
+
})))));
|
|
520
563
|
};
|
|
521
|
-
var onChangeTag = function onChangeTag(e,
|
|
522
|
-
|
|
564
|
+
var onChangeTag = function onChangeTag(e, node, option) {
|
|
565
|
+
labelRelation(e.target.checked, node, option);
|
|
523
566
|
};
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
567
|
+
//绑定和解绑标签
|
|
568
|
+
var labelRelation = function labelRelation(checked, node, option) {
|
|
569
|
+
request(checked ? apis.dict.addLabelRelation : apis.dict.delLabelRelation, {
|
|
570
|
+
method: 'post',
|
|
571
|
+
data: {
|
|
572
|
+
id: option.value,
|
|
573
|
+
appId: currentApp === null || currentApp === void 0 ? void 0 : currentApp.appId,
|
|
574
|
+
labelType: 1,
|
|
575
|
+
eventId: node.id
|
|
576
|
+
}
|
|
577
|
+
}).then(function (res) {
|
|
578
|
+
if ((res === null || res === void 0 ? void 0 : res.code) == '100000') {
|
|
579
|
+
getPointTree(function () {
|
|
580
|
+
var labels = node.labels;
|
|
581
|
+
if (checked) {
|
|
582
|
+
labels.push(option);
|
|
583
|
+
} else {
|
|
584
|
+
labels = labels.filter(function (res) {
|
|
585
|
+
return res.id != option.value;
|
|
586
|
+
});
|
|
587
|
+
}
|
|
588
|
+
node.labels = labels;
|
|
589
|
+
props.onChangePage(_objectSpread(_objectSpread({}, node), {}, {
|
|
590
|
+
currentPointVersion: currentPointVersion
|
|
591
|
+
}));
|
|
592
|
+
});
|
|
593
|
+
}
|
|
594
|
+
});
|
|
595
|
+
};
|
|
596
|
+
var _useState37 = useState(false),
|
|
597
|
+
_useState38 = _slicedToArray(_useState37, 2),
|
|
598
|
+
isOpen = _useState38[0],
|
|
599
|
+
setIsOpen = _useState38[1];
|
|
528
600
|
var downloadHelpFile = function downloadHelpFile() {
|
|
529
601
|
window.open("/\u63A8\u8350\u57CB\u70B9\u65B9\u6848.xlsx");
|
|
530
602
|
};
|
|
531
603
|
// 分享看板二维码
|
|
532
|
-
var
|
|
533
|
-
_useState38 = _slicedToArray(_useState37, 2),
|
|
534
|
-
qrCodeShare = _useState38[0],
|
|
535
|
-
setqrCodeShare = _useState38[1];
|
|
536
|
-
// 分享看板二维码-显示控制
|
|
537
|
-
var _useState39 = useState(false),
|
|
604
|
+
var _useState39 = useState(''),
|
|
538
605
|
_useState40 = _slicedToArray(_useState39, 2),
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
//
|
|
606
|
+
qrCodeShare = _useState40[0],
|
|
607
|
+
setqrCodeShare = _useState40[1];
|
|
608
|
+
// 分享看板二维码-显示控制
|
|
542
609
|
var _useState41 = useState(false),
|
|
543
610
|
_useState42 = _slicedToArray(_useState41, 2),
|
|
544
|
-
|
|
545
|
-
|
|
611
|
+
qrCodeShareShow = _useState42[0],
|
|
612
|
+
setqrCodeShareShow = _useState42[1];
|
|
613
|
+
// 二维码加载中
|
|
614
|
+
var _useState43 = useState(false),
|
|
615
|
+
_useState44 = _slicedToArray(_useState43, 2),
|
|
616
|
+
qrCodeLoading = _useState44[0],
|
|
617
|
+
setQrCodeLoading = _useState44[1];
|
|
546
618
|
var onOpenChangeShare = function onOpenChangeShare(open) {
|
|
547
619
|
setqrCodeShareShow(open);
|
|
548
620
|
if (qrCodeShare === '') {
|
|
@@ -580,8 +652,8 @@ var pointMap = function pointMap(props) {
|
|
|
580
652
|
key: item
|
|
581
653
|
};
|
|
582
654
|
}),
|
|
583
|
-
onClick: function onClick(
|
|
584
|
-
var key =
|
|
655
|
+
onClick: function onClick(_ref) {
|
|
656
|
+
var key = _ref.key;
|
|
585
657
|
setIsOpen(false);
|
|
586
658
|
setValue('');
|
|
587
659
|
setSelectedKeys(undefined);
|
|
@@ -620,7 +692,7 @@ var pointMap = function pointMap(props) {
|
|
|
620
692
|
})))), /*#__PURE__*/React.createElement("a", {
|
|
621
693
|
className: "".concat(classPrefix, "-select-box"),
|
|
622
694
|
onClick: downloadHelpFile
|
|
623
|
-
}, /*#__PURE__*/React.createElement(QuestionCircleOutlined, null), "\u5E2E\u52A9"), /*#__PURE__*/React.createElement("a", {
|
|
695
|
+
}, /*#__PURE__*/React.createElement(QuestionCircleOutlined, null), "\u5E2E\u52A9"), showProdDownload && (/*#__PURE__*/React.createElement("a", {
|
|
624
696
|
className: "".concat(classPrefix, "-select-box"),
|
|
625
697
|
onClick: function onClick() {
|
|
626
698
|
if (!authority[1724922774]) {
|
|
@@ -631,7 +703,7 @@ var pointMap = function pointMap(props) {
|
|
|
631
703
|
}
|
|
632
704
|
}, /*#__PURE__*/React.createElement(IconFont, {
|
|
633
705
|
type: "xiazai1"
|
|
634
|
-
}), "\u5BFC\u5165\u9875\u9762")), /*#__PURE__*/React.createElement("div", {
|
|
706
|
+
}), "\u5BFC\u5165\u9875\u9762"))), /*#__PURE__*/React.createElement("div", {
|
|
635
707
|
className: "".concat(classPrefix, "-search")
|
|
636
708
|
}, /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement(Select, {
|
|
637
709
|
className: "".concat(classPrefix, "-search-selectType"),
|
|
@@ -645,6 +717,7 @@ var pointMap = function pointMap(props) {
|
|
|
645
717
|
}],
|
|
646
718
|
onChange: function onChange(value) {
|
|
647
719
|
setSearchType(value);
|
|
720
|
+
setValue(undefined);
|
|
648
721
|
}
|
|
649
722
|
})), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement(Select, {
|
|
650
723
|
value: value,
|
|
@@ -661,6 +734,7 @@ var pointMap = function pointMap(props) {
|
|
|
661
734
|
value: 'id',
|
|
662
735
|
label: 'name'
|
|
663
736
|
},
|
|
737
|
+
allowClear: true,
|
|
664
738
|
options: treeArr,
|
|
665
739
|
popupClassName: "".concat(classPrefix, "-search-popup")
|
|
666
740
|
})), /*#__PURE__*/React.createElement("div", {
|
|
@@ -22,7 +22,8 @@ var clearDict = function clearDict(_ref) {
|
|
|
22
22
|
onSetclose = _ref.onSetclose,
|
|
23
23
|
currentDictDetail = _ref.currentDictDetail;
|
|
24
24
|
var _useContext = useContext(BizGlobalDataContext),
|
|
25
|
-
currentApp = _useContext.currentApp
|
|
25
|
+
currentApp = _useContext.currentApp,
|
|
26
|
+
showProdDownload = _useContext.showProdDownload;
|
|
26
27
|
var _useState = useState(addDictShow),
|
|
27
28
|
_useState2 = _slicedToArray(_useState, 2),
|
|
28
29
|
open = _useState2[0],
|
|
@@ -36,7 +37,7 @@ var clearDict = function clearDict(_ref) {
|
|
|
36
37
|
openImportModal = _useState6[0],
|
|
37
38
|
setOpenImportModal = _useState6[1];
|
|
38
39
|
var columns = [{
|
|
39
|
-
title: '
|
|
40
|
+
title: '属性值',
|
|
40
41
|
dataIndex: 'name',
|
|
41
42
|
key: 'name',
|
|
42
43
|
render: function render(text, record, index) {
|
|
@@ -80,12 +81,13 @@ var clearDict = function clearDict(_ref) {
|
|
|
80
81
|
request((currentDictDetail === null || currentDictDetail === void 0 ? void 0 : currentDictDetail.id) ? apis.dict.dictUpdate : apis.dict.dictSave, {
|
|
81
82
|
method: 'post',
|
|
82
83
|
data: {
|
|
84
|
+
id: (currentDictDetail === null || currentDictDetail === void 0 ? void 0 : currentDictDetail.id) || undefined,
|
|
83
85
|
appId: currentApp === null || currentApp === void 0 ? void 0 : currentApp.appId,
|
|
84
|
-
|
|
86
|
+
dictName: values.dictName,
|
|
85
87
|
remark: values.remark,
|
|
86
|
-
dictValue: dictList.map(function (res) {
|
|
88
|
+
dictValue: _toConsumableArray(new Set(dictList.map(function (res) {
|
|
87
89
|
return res.name;
|
|
88
|
-
})
|
|
90
|
+
})))
|
|
89
91
|
}
|
|
90
92
|
}).then(function (res) {
|
|
91
93
|
if (!res) return;
|
|
@@ -136,11 +138,12 @@ var clearDict = function clearDict(_ref) {
|
|
|
136
138
|
//初始请求初始化
|
|
137
139
|
useEffect(function () {
|
|
138
140
|
if (currentDictDetail) {
|
|
141
|
+
var _currentDictDetail$di;
|
|
139
142
|
dictForm.setFieldsValue({
|
|
140
|
-
|
|
143
|
+
dictName: currentDictDetail.dictName,
|
|
141
144
|
remark: currentDictDetail.remark
|
|
142
145
|
});
|
|
143
|
-
setDictList(currentDictDetail.dictValue.map(function (res) {
|
|
146
|
+
setDictList((_currentDictDetail$di = currentDictDetail.dictValue) === null || _currentDictDetail$di === void 0 ? void 0 : _currentDictDetail$di.split(',').map(function (res) {
|
|
144
147
|
return {
|
|
145
148
|
name: res,
|
|
146
149
|
key: Math.random() * 10000
|
|
@@ -155,10 +158,7 @@ var clearDict = function clearDict(_ref) {
|
|
|
155
158
|
title: /*#__PURE__*/React.createElement("div", null, currentDictDetail ? '修改' : '创建', "\u5C5E\u6027\u5B57\u5178", /*#__PURE__*/React.createElement("div", {
|
|
156
159
|
className: "clearDict-drawerCloseIcon",
|
|
157
160
|
onClick: onClose
|
|
158
|
-
}, /*#__PURE__*/React.createElement(CloseOutlined,
|
|
159
|
-
onPointerEnterCapture: undefined,
|
|
160
|
-
onPointerLeaveCapture: undefined
|
|
161
|
-
}))),
|
|
161
|
+
}, /*#__PURE__*/React.createElement(CloseOutlined, null))),
|
|
162
162
|
onClose: onClose,
|
|
163
163
|
closeIcon: false,
|
|
164
164
|
open: open,
|
|
@@ -179,22 +179,22 @@ var clearDict = function clearDict(_ref) {
|
|
|
179
179
|
span: 20
|
|
180
180
|
},
|
|
181
181
|
initialValues: {
|
|
182
|
-
|
|
182
|
+
dictName: '',
|
|
183
183
|
desctiption: ''
|
|
184
184
|
},
|
|
185
185
|
onFinish: onFinish,
|
|
186
186
|
labelAlign: "right"
|
|
187
187
|
}, /*#__PURE__*/React.createElement(Form.Item, {
|
|
188
|
-
label: "\u5C5E\u6027\
|
|
189
|
-
name: "
|
|
188
|
+
label: "\u5C5E\u6027\u5B57\u5178\u540D",
|
|
189
|
+
name: "dictName",
|
|
190
190
|
rules: [{
|
|
191
191
|
required: true,
|
|
192
|
-
message: '
|
|
192
|
+
message: '请输入属性字典名'
|
|
193
193
|
}]
|
|
194
194
|
}, /*#__PURE__*/React.createElement(Input, {
|
|
195
195
|
showCount: true,
|
|
196
196
|
maxLength: 50,
|
|
197
|
-
placeholder: "\u8BF7\u8F93\u5165\u5C5E\u6027\
|
|
197
|
+
placeholder: "\u8BF7\u8F93\u5165\u5C5E\u6027\u5B57\u5178\u540D"
|
|
198
198
|
})), /*#__PURE__*/React.createElement(Form.Item, {
|
|
199
199
|
label: "\u5907\u6CE8",
|
|
200
200
|
name: "remark"
|
|
@@ -214,17 +214,17 @@ var clearDict = function clearDict(_ref) {
|
|
|
214
214
|
columns: columns,
|
|
215
215
|
pagination: false,
|
|
216
216
|
scroll: {
|
|
217
|
-
y:
|
|
217
|
+
y: 'calc(100vh - 430px)'
|
|
218
218
|
}
|
|
219
219
|
})), /*#__PURE__*/React.createElement("div", {
|
|
220
220
|
className: "clearDict-addListBtn"
|
|
221
221
|
}, /*#__PURE__*/React.createElement(Button, {
|
|
222
222
|
type: "primary",
|
|
223
223
|
onClick: onHandlePush
|
|
224
|
-
}, /*#__PURE__*/React.createElement(PlusOutlined, null), "\u6DFB\u52A0\u503C"), /*#__PURE__*/React.createElement(Button, {
|
|
224
|
+
}, /*#__PURE__*/React.createElement(PlusOutlined, null), "\u6DFB\u52A0\u503C"), showProdDownload && (/*#__PURE__*/React.createElement(Button, {
|
|
225
225
|
type: "primary",
|
|
226
226
|
onClick: onHandleUploading
|
|
227
|
-
}, /*#__PURE__*/React.createElement(PlusOutlined, null), "\u4ECE\u6587\u4EF6\u6DFB\u52A0"))), openImportModal && (/*#__PURE__*/React.createElement(ImportMetaDialog, {
|
|
227
|
+
}, /*#__PURE__*/React.createElement(PlusOutlined, null), "\u4ECE\u6587\u4EF6\u6DFB\u52A0")))), openImportModal && (/*#__PURE__*/React.createElement(ImportMetaDialog, {
|
|
228
228
|
uploadFile: apis.dict.dictUpload,
|
|
229
229
|
downloadTempleUrl: apis.dict.dictTemplate,
|
|
230
230
|
fileName: "\u5C5E\u6027\u503C\u5BFC\u5165\u6A21\u677F",
|
|
@@ -232,7 +232,13 @@ var clearDict = function clearDict(_ref) {
|
|
|
232
232
|
setOpenImportModal(false);
|
|
233
233
|
},
|
|
234
234
|
onSuccess: function onSuccess(result) {
|
|
235
|
-
|
|
235
|
+
setDictList([].concat(_toConsumableArray(dictList), _toConsumableArray(result.map(function (res) {
|
|
236
|
+
return {
|
|
237
|
+
name: res,
|
|
238
|
+
key: Math.random() * 10000
|
|
239
|
+
};
|
|
240
|
+
}))));
|
|
241
|
+
setOpenImportModal(false);
|
|
236
242
|
}
|
|
237
243
|
})));
|
|
238
244
|
};
|
|
@@ -38,10 +38,11 @@
|
|
|
38
38
|
&-tableContainer {
|
|
39
39
|
margin-top: 10px;
|
|
40
40
|
.ant-table {
|
|
41
|
-
|
|
41
|
+
height: calc(100vh - 380px);
|
|
42
|
+
min-height: 410px !important; /* 设置表格最小高度 */
|
|
42
43
|
}
|
|
43
44
|
.ant-empty-normal {
|
|
44
|
-
height:
|
|
45
|
+
height: 260px; /* 设置表格最小高度 */
|
|
45
46
|
}
|
|
46
47
|
}
|
|
47
48
|
}
|
|
@@ -36,9 +36,9 @@ var DictionaryManagement = function DictionaryManagement() {
|
|
|
36
36
|
},
|
|
37
37
|
width: 80
|
|
38
38
|
}, {
|
|
39
|
-
title: '
|
|
40
|
-
dataIndex: '
|
|
41
|
-
key: '
|
|
39
|
+
title: '属性字典名',
|
|
40
|
+
dataIndex: 'dictName',
|
|
41
|
+
key: 'dictName',
|
|
42
42
|
render: function render(text) {
|
|
43
43
|
return /*#__PURE__*/React.createElement(Tooltip, {
|
|
44
44
|
title: text
|
|
@@ -53,8 +53,8 @@ var DictionaryManagement = function DictionaryManagement() {
|
|
|
53
53
|
}
|
|
54
54
|
}, {
|
|
55
55
|
title: '创建人',
|
|
56
|
-
dataIndex: '
|
|
57
|
-
key: '
|
|
56
|
+
dataIndex: 'creatorName',
|
|
57
|
+
key: 'creatorName',
|
|
58
58
|
width: 140
|
|
59
59
|
}, {
|
|
60
60
|
title: '备注',
|
|
@@ -98,6 +98,7 @@ var DictionaryManagement = function DictionaryManagement() {
|
|
|
98
98
|
setAddDictShow = _useState4[1];
|
|
99
99
|
var handleAddDict = function handleAddDict() {
|
|
100
100
|
setAddDictShow(true);
|
|
101
|
+
setDictDetail(undefined);
|
|
101
102
|
};
|
|
102
103
|
/**
|
|
103
104
|
* 字典列表, 搜索名称 删除字典
|
|
@@ -123,7 +124,7 @@ var DictionaryManagement = function DictionaryManagement() {
|
|
|
123
124
|
}, []);
|
|
124
125
|
//分页搜索
|
|
125
126
|
var getList = function getList() {
|
|
126
|
-
request(apis.dict.
|
|
127
|
+
request(apis.dict.getDictPage, {
|
|
127
128
|
method: 'post',
|
|
128
129
|
data: {
|
|
129
130
|
pageNo: tableParams.current,
|
|
@@ -133,7 +134,7 @@ var DictionaryManagement = function DictionaryManagement() {
|
|
|
133
134
|
}).then(function (res) {
|
|
134
135
|
if (!res) return;
|
|
135
136
|
if ((res === null || res === void 0 ? void 0 : res.code) == '100000') {
|
|
136
|
-
setDictList(res.data.
|
|
137
|
+
setDictList(res.data.dictList);
|
|
137
138
|
// 总页数
|
|
138
139
|
setTableParams(function (pre) {
|
|
139
140
|
return _objectSpread(_objectSpread({}, pre), {}, {
|
|
@@ -191,7 +192,8 @@ var DictionaryManagement = function DictionaryManagement() {
|
|
|
191
192
|
columns: columns,
|
|
192
193
|
onChange: handlePage,
|
|
193
194
|
scroll: {
|
|
194
|
-
x: 992
|
|
195
|
+
x: 992,
|
|
196
|
+
y: 390
|
|
195
197
|
}
|
|
196
198
|
}), addDictShow && (/*#__PURE__*/React.createElement(CreateDict, {
|
|
197
199
|
addDictShow: addDictShow,
|