@zgfe/modules-dm 1.0.57-alpha.0 → 1.0.57-zhongyuan.10
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 -1
- package/es/constants/api.js +3 -2
- package/es/index.d.ts +2 -2
- package/es/index.js +2 -2
- package/es/modules/{clear-rule → clearRule}/addRule.js +18 -22
- package/es/modules/{clear-rule → clearRule}/index.js +35 -9
- package/es/modules/dataManage/components/panelList.js +1 -1
- package/es/modules/{formulate-rule → formulateRule}/addFormulate.d.ts +1 -1
- package/es/modules/{formulate-rule → formulateRule}/addFormulate.js +8 -6
- package/es/modules/{formulate-rule → formulateRule}/addRule.d.ts +1 -1
- package/es/modules/{formulate-rule → formulateRule}/addRule.js +1 -1
- package/es/modules/{formulate-rule → formulateRule}/index.d.ts +1 -1
- package/es/modules/{formulate-rule → formulateRule}/index.js +6 -4
- package/package.json +2 -2
- /package/es/modules/{clear-rule → clearRule}/addRule.d.ts +0 -0
- /package/es/modules/{clear-rule → clearRule}/css/index.css +0 -0
- /package/es/modules/{clear-rule → clearRule}/css/index.less +0 -0
- /package/es/modules/{clear-rule → clearRule}/demo/index.d.ts +0 -0
- /package/es/modules/{clear-rule → clearRule}/demo/index.js +0 -0
- /package/es/modules/{clear-rule → clearRule}/importMetaDialog/demo/index.d.ts +0 -0
- /package/es/modules/{clear-rule → clearRule}/importMetaDialog/demo/index.js +0 -0
- /package/es/modules/{clear-rule → clearRule}/importMetaDialog/index.d.ts +0 -0
- /package/es/modules/{clear-rule → clearRule}/importMetaDialog/index.js +0 -0
- /package/es/modules/{clear-rule → clearRule}/importMetaDialog/styles/index.less +0 -0
- /package/es/modules/{clear-rule → clearRule}/index.d.ts +0 -0
- /package/es/modules/{formulate-rule → formulateRule}/data.d.ts +0 -0
- /package/es/modules/{formulate-rule → formulateRule}/data.js +0 -0
- /package/es/modules/{formulate-rule → formulateRule}/demo/index.d.ts +0 -0
- /package/es/modules/{formulate-rule → formulateRule}/demo/index.js +0 -0
package/es/constants/api.d.ts
CHANGED
|
@@ -88,6 +88,7 @@ declare let apis: {
|
|
|
88
88
|
exportFile: string;
|
|
89
89
|
downloadTemple: string;
|
|
90
90
|
allOpenStatus: string;
|
|
91
|
+
checkStatus: string;
|
|
91
92
|
};
|
|
92
93
|
clearRule: {
|
|
93
94
|
getList: string;
|
|
@@ -95,7 +96,7 @@ declare let apis: {
|
|
|
95
96
|
checkRule: string;
|
|
96
97
|
getDetail: string;
|
|
97
98
|
modifyRule: string;
|
|
98
|
-
|
|
99
|
+
checkStatus: string;
|
|
99
100
|
selectStatus: string;
|
|
100
101
|
deleteRule: string;
|
|
101
102
|
exportFile: string;
|
package/es/constants/api.js
CHANGED
|
@@ -151,7 +151,8 @@ var apis = {
|
|
|
151
151
|
downloadRule: '/zg/web/v2/verify/exportVerify',
|
|
152
152
|
exportFile: '/zg/web/v2/verify/report/export',
|
|
153
153
|
downloadTemple: '/zg/web/v2/verify/downloadMould',
|
|
154
|
-
allOpenStatus: '/zg/web/v2/verify/statusMain'
|
|
154
|
+
allOpenStatus: '/zg/web/v2/verify/statusMain',
|
|
155
|
+
checkStatus: '/zg/web/v2/verify/statusBefore'
|
|
155
156
|
},
|
|
156
157
|
clearRule: {
|
|
157
158
|
getList: '/zg/web/v2/rinseShiftRule/queryRinseShiftRuleList',
|
|
@@ -159,7 +160,7 @@ var apis = {
|
|
|
159
160
|
checkRule: '/zg/web/v2/rinseShiftRule/updateRinseShiftRuleCheck',
|
|
160
161
|
getDetail: '/zg/web/v2/rinseShiftRule/detail',
|
|
161
162
|
modifyRule: '/zg/web/v2/rinseShiftRule/updateRinseShiftRule',
|
|
162
|
-
|
|
163
|
+
checkStatus: '/zg/web/v2/rinseShiftRule/statusBefore',
|
|
163
164
|
selectStatus: '/zg/web/v2/rinseShiftRule/status',
|
|
164
165
|
deleteRule: '/zg/web/v2/rinseShiftRule/deleteRule',
|
|
165
166
|
exportFile: '/zg/web/v2/rinseShiftRule/exportReport',
|
package/es/index.d.ts
CHANGED
|
@@ -3,6 +3,6 @@ import DataManage from './modules/dataManage';
|
|
|
3
3
|
import PlanList from './modules/dataPlan';
|
|
4
4
|
import DataRealView from './modules/dataReal/index1';
|
|
5
5
|
import DataMapView from './modules/dataMap';
|
|
6
|
-
import ClearRule from './modules/
|
|
7
|
-
import FormulateRule from './modules/
|
|
6
|
+
import ClearRule from './modules/clearRule';
|
|
7
|
+
import FormulateRule from './modules/formulateRule';
|
|
8
8
|
export { PlanList, DataManage, DataRealView, DataMapView, ClearRule, FormulateRule };
|
package/es/index.js
CHANGED
|
@@ -3,6 +3,6 @@ import DataManage from './modules/dataManage';
|
|
|
3
3
|
import PlanList from './modules/dataPlan';
|
|
4
4
|
import DataRealView from './modules/dataReal/index1';
|
|
5
5
|
import DataMapView from './modules/dataMap';
|
|
6
|
-
import ClearRule from './modules/
|
|
7
|
-
import FormulateRule from './modules/
|
|
6
|
+
import ClearRule from './modules/clearRule';
|
|
7
|
+
import FormulateRule from './modules/formulateRule';
|
|
8
8
|
export { PlanList, DataManage, DataRealView, DataMapView, ClearRule, FormulateRule };
|
|
@@ -109,7 +109,7 @@ var AddRule = function AddRule(_ref) {
|
|
|
109
109
|
// 刷新列表
|
|
110
110
|
getList();
|
|
111
111
|
} else {
|
|
112
|
-
message.error(
|
|
112
|
+
message.error(res.msg);
|
|
113
113
|
}
|
|
114
114
|
});
|
|
115
115
|
return;
|
|
@@ -142,7 +142,7 @@ var AddRule = function AddRule(_ref) {
|
|
|
142
142
|
// 刷新列表
|
|
143
143
|
getList();
|
|
144
144
|
} else {
|
|
145
|
-
message.error(
|
|
145
|
+
message.error(res.msg);
|
|
146
146
|
}
|
|
147
147
|
});
|
|
148
148
|
};
|
|
@@ -265,15 +265,9 @@ var AddRule = function AddRule(_ref) {
|
|
|
265
265
|
setBizAttributeSelectorValue(undefined);
|
|
266
266
|
} else {
|
|
267
267
|
var _value = attr.propCategory === 'eventProp' ? attr.id : attr.name;
|
|
268
|
-
setBizAttributeSelectorValue({
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
value: _value,
|
|
272
|
-
id: attr.id,
|
|
273
|
-
label: attr === null || attr === void 0 ? void 0 : attr.label,
|
|
274
|
-
name: attr === null || attr === void 0 ? void 0 : attr.name,
|
|
275
|
-
type: attr.type
|
|
276
|
-
});
|
|
268
|
+
setBizAttributeSelectorValue(_objectSpread(_objectSpread({}, attr), {}, {
|
|
269
|
+
value: _value
|
|
270
|
+
}));
|
|
277
271
|
// 初始化属性基础类型
|
|
278
272
|
if (currentRule.includes(1)) {
|
|
279
273
|
var newArr = optionsRule;
|
|
@@ -313,10 +307,6 @@ var AddRule = function AddRule(_ref) {
|
|
|
313
307
|
if (o.ruleType == j.ruleType) {
|
|
314
308
|
o.content = j.content;
|
|
315
309
|
}
|
|
316
|
-
// 这个为模拟的区间数据
|
|
317
|
-
if (o.ruleType == 3) {
|
|
318
|
-
o.content = '(4,8]';
|
|
319
|
-
}
|
|
320
310
|
});
|
|
321
311
|
});
|
|
322
312
|
var currentTypeArr = currentRuleDetail.verifyDetailVo.map(function (o) {
|
|
@@ -359,7 +349,7 @@ var AddRule = function AddRule(_ref) {
|
|
|
359
349
|
initialValues: {
|
|
360
350
|
name: '',
|
|
361
351
|
desctiption: '',
|
|
362
|
-
ruleobj:
|
|
352
|
+
ruleobj: {}
|
|
363
353
|
},
|
|
364
354
|
onFinish: onFinish,
|
|
365
355
|
labelAlign: "left"
|
|
@@ -386,7 +376,7 @@ var AddRule = function AddRule(_ref) {
|
|
|
386
376
|
name: "ruleobj",
|
|
387
377
|
rules: [{
|
|
388
378
|
required: true,
|
|
389
|
-
message: '
|
|
379
|
+
message: '请选择校验对象'
|
|
390
380
|
}]
|
|
391
381
|
}, /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Radio.Group, {
|
|
392
382
|
onChange: onSelectType,
|
|
@@ -395,7 +385,7 @@ var AddRule = function AddRule(_ref) {
|
|
|
395
385
|
value: 'eventProp'
|
|
396
386
|
}, "\u4E8B\u4EF6\u5C5E\u6027\u6821\u9A8C"), /*#__PURE__*/React.createElement(Radio, {
|
|
397
387
|
value: 'user'
|
|
398
|
-
}, "\
|
|
388
|
+
}, "\u89D2\u8272\u5C5E\u6027\u6821\u9A8C")), /*#__PURE__*/React.createElement("br", null), /*#__PURE__*/React.createElement("div", {
|
|
399
389
|
className: "selectVent"
|
|
400
390
|
}, selectType == 'eventProp' && (/*#__PURE__*/React.createElement(BizEventSelector, {
|
|
401
391
|
showAllEvent: true,
|
|
@@ -415,7 +405,7 @@ var AddRule = function AddRule(_ref) {
|
|
|
415
405
|
enableEnvProp: true,
|
|
416
406
|
eventIdList: [event === null || event === void 0 ? void 0 : event.id],
|
|
417
407
|
value: bizAttributeSelectorValue,
|
|
418
|
-
enableDelete:
|
|
408
|
+
enableDelete: false,
|
|
419
409
|
onChange: onChangeAttr,
|
|
420
410
|
onDelete: function onDelete() {
|
|
421
411
|
onChangeAttr(undefined);
|
|
@@ -503,7 +493,7 @@ var TypeComponent = function TypeComponent(_ref2) {
|
|
|
503
493
|
setMinNum(val.firstNumber);
|
|
504
494
|
setMaxNum(val.secondNumber);
|
|
505
495
|
setIncludedMinState(val.leftSymbol == '(' ? false : true);
|
|
506
|
-
setIncludedMaxState(val.rightSymbol == '
|
|
496
|
+
setIncludedMaxState(val.rightSymbol == ')' ? false : true);
|
|
507
497
|
}
|
|
508
498
|
}
|
|
509
499
|
}, []);
|
|
@@ -548,8 +538,11 @@ var TypeComponent = function TypeComponent(_ref2) {
|
|
|
548
538
|
Component = /*#__PURE__*/React.createElement("div", {
|
|
549
539
|
className: "attrValue-list-right"
|
|
550
540
|
}, /*#__PURE__*/React.createElement(Tooltip, {
|
|
551
|
-
title: "\u70B9\u51FB\u5207\u6362[\u5F00
|
|
541
|
+
title: "\u70B9\u51FB\u5207\u6362[\u5F00/\u95ED]\u533A\u95F4"
|
|
552
542
|
}, /*#__PURE__*/React.createElement("div", {
|
|
543
|
+
style: {
|
|
544
|
+
cursor: 'pointer'
|
|
545
|
+
},
|
|
553
546
|
onClick: function onClick() {
|
|
554
547
|
setIncludedMinState(function (pre) {
|
|
555
548
|
optionsValue.filter(function (r) {
|
|
@@ -579,8 +572,11 @@ var TypeComponent = function TypeComponent(_ref2) {
|
|
|
579
572
|
})[0].content = "".concat(includedMinState ? '[' : '(').concat(minNum, ",").concat(value).concat(includedMaxState ? ']' : ')');
|
|
580
573
|
}
|
|
581
574
|
}), /*#__PURE__*/React.createElement(Tooltip, {
|
|
582
|
-
title: "\u70B9\u51FB\u5207\u6362[\u5F00
|
|
575
|
+
title: "\u70B9\u51FB\u5207\u6362[\u5F00/\u95ED]\u533A\u95F4"
|
|
583
576
|
}, /*#__PURE__*/React.createElement("div", {
|
|
577
|
+
style: {
|
|
578
|
+
cursor: 'pointer'
|
|
579
|
+
},
|
|
584
580
|
onClick: function onClick() {
|
|
585
581
|
setIncludedMaxState(function (pre) {
|
|
586
582
|
optionsValue.filter(function (r) {
|
|
@@ -177,7 +177,6 @@ var ClearRule = function ClearRule() {
|
|
|
177
177
|
downloadDate = _useState14[0],
|
|
178
178
|
setDownloadDate = _useState14[1];
|
|
179
179
|
var handleSelectDate = function handleSelectDate(date) {
|
|
180
|
-
console.log(date);
|
|
181
180
|
setDownloadDate(date);
|
|
182
181
|
};
|
|
183
182
|
var handleOk = function handleOk() {
|
|
@@ -214,6 +213,8 @@ var ClearRule = function ClearRule() {
|
|
|
214
213
|
setOpenImportModal(false);
|
|
215
214
|
setOpenImportModalResult(false);
|
|
216
215
|
setErrorRule(undefined);
|
|
216
|
+
// 刷新列表
|
|
217
|
+
_getList(ruleSearchName);
|
|
217
218
|
};
|
|
218
219
|
// 导出规则
|
|
219
220
|
var handleDownLoadRuleFile = function handleDownLoadRuleFile() {
|
|
@@ -240,6 +241,7 @@ var ClearRule = function ClearRule() {
|
|
|
240
241
|
var searchChange = function searchChange(e) {
|
|
241
242
|
var _value = e.currentTarget.value;
|
|
242
243
|
setRuleSearchName(_value);
|
|
244
|
+
_getList(_value);
|
|
243
245
|
};
|
|
244
246
|
var handleSearch = function handleSearch() {
|
|
245
247
|
_getList(ruleSearchName);
|
|
@@ -311,16 +313,40 @@ var ClearRule = function ClearRule() {
|
|
|
311
313
|
}
|
|
312
314
|
});
|
|
313
315
|
};
|
|
314
|
-
var
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
316
|
+
var statusCheck = function statusCheck(ruleRow) {
|
|
317
|
+
// 可直接关闭
|
|
318
|
+
if (ruleRow.status == 1) {
|
|
319
|
+
handleOpenRuleStatus(ruleRow);
|
|
320
|
+
return;
|
|
321
|
+
}
|
|
322
|
+
request(apis.rule.checkStatus, {
|
|
323
|
+
method: 'post',
|
|
324
|
+
data: {
|
|
325
|
+
appId: currentApp === null || currentApp === void 0 ? void 0 : currentApp.appId,
|
|
326
|
+
ruleId: ruleRow.ruleId,
|
|
327
|
+
status: ruleRow.status ? 0 : 1
|
|
328
|
+
}
|
|
329
|
+
}).then(function (res) {
|
|
330
|
+
if (!res) return;
|
|
331
|
+
if ((res === null || res === void 0 ? void 0 : res.code) == '100000') {
|
|
332
|
+
if (res.data.data == 0) {
|
|
333
|
+
UseModal({
|
|
334
|
+
onOk: function onOk() {
|
|
335
|
+
return handleOpenRuleStatus(ruleRow);
|
|
336
|
+
},
|
|
337
|
+
okText: "\u4ECD\u7136\u5F00\u542F",
|
|
338
|
+
title: '警告',
|
|
339
|
+
content: '该规则与已开启规则可能产生冲突,请确认是否继续开启'.concat(" ")
|
|
340
|
+
});
|
|
341
|
+
}
|
|
342
|
+
} else {
|
|
343
|
+
message.error('查询列表失败!');
|
|
344
|
+
}
|
|
322
345
|
});
|
|
323
346
|
};
|
|
347
|
+
var _onChange = function _onChange(value, ruleRow) {
|
|
348
|
+
statusCheck(ruleRow);
|
|
349
|
+
};
|
|
324
350
|
var handleOpenRuleStatus = function handleOpenRuleStatus(ruleRow) {
|
|
325
351
|
request(apis.rule.openRuleStatus, {
|
|
326
352
|
method: 'post',
|
|
@@ -12,7 +12,7 @@ import { Drawer, Input, Button, Space, Form, Table, Select, message } from 'antd
|
|
|
12
12
|
import { CloseOutlined, PlusOutlined } from '@ant-design/icons';
|
|
13
13
|
import React, { useState, useEffect, useContext } from 'react';
|
|
14
14
|
import { BizGlobalDataContext } from '@zgfe/business-lib';
|
|
15
|
-
import '../
|
|
15
|
+
import '../clearRule/css/index.less';
|
|
16
16
|
import AddRule from './addRule';
|
|
17
17
|
import request from '../../utils/ajax';
|
|
18
18
|
import apis from '../../constants/api';
|
|
@@ -199,13 +199,15 @@ var AddFormulate = function AddFormulate(_ref) {
|
|
|
199
199
|
// 回显
|
|
200
200
|
useEffect(function () {
|
|
201
201
|
if (detailData) {
|
|
202
|
+
var _detailData$rinseObje, _detailData$rinseShif;
|
|
202
203
|
ruleForm.setFieldsValue({
|
|
203
204
|
name: detailData.ruleName,
|
|
204
|
-
description: detailData.ruleDescription,
|
|
205
|
-
target: detailData.rinseObjects[0],
|
|
206
|
-
ruleArr: detailData.rinseShiftRuleDetails
|
|
205
|
+
description: detailData === null || detailData === void 0 ? void 0 : detailData.ruleDescription,
|
|
206
|
+
target: detailData === null || detailData === void 0 ? void 0 : (_detailData$rinseObje = detailData.rinseObjects) === null || _detailData$rinseObje === void 0 ? void 0 : _detailData$rinseObje[0],
|
|
207
|
+
ruleArr: detailData === null || detailData === void 0 ? void 0 : detailData.rinseShiftRuleDetails
|
|
207
208
|
});
|
|
208
|
-
var arr =
|
|
209
|
+
var arr = [];
|
|
210
|
+
arr = (detailData === null || detailData === void 0 ? void 0 : detailData.rinseShiftRuleDetails) && (detailData === null || detailData === void 0 ? void 0 : (_detailData$rinseShif = detailData.rinseShiftRuleDetails) === null || _detailData$rinseShif === void 0 ? void 0 : _detailData$rinseShif.map(function (o) {
|
|
209
211
|
return {
|
|
210
212
|
currentType: o.ruleType,
|
|
211
213
|
currentTypeName: typeArr.filter(function (j) {
|
|
@@ -215,7 +217,7 @@ var AddFormulate = function AddFormulate(_ref) {
|
|
|
215
217
|
targetValue: o.targetValue,
|
|
216
218
|
key: o.id
|
|
217
219
|
};
|
|
218
|
-
});
|
|
220
|
+
}));
|
|
219
221
|
setDataSoure(arr);
|
|
220
222
|
}
|
|
221
223
|
}, []);
|
|
@@ -17,7 +17,7 @@ function _arrayWithHoles(r) { if (Array.isArray(r)) return r; }
|
|
|
17
17
|
import { Drawer, Input, Button, Space, Form, Table, Select } from 'antd';
|
|
18
18
|
import { CloseOutlined, PlusOutlined } from '@ant-design/icons';
|
|
19
19
|
import React, { useEffect, useState } from 'react';
|
|
20
|
-
import '../
|
|
20
|
+
import '../clearRule/css/index.less';
|
|
21
21
|
import { typeArr, dateArr, tianchongArr, shuzhiArr } from './data';
|
|
22
22
|
var AddRule = function AddRule(_ref) {
|
|
23
23
|
var addruleShow = _ref.addruleShow,
|
|
@@ -18,7 +18,7 @@ import UseModal from '../CutsModal';
|
|
|
18
18
|
import AddFormulate from './addFormulate';
|
|
19
19
|
import request from '../../utils/ajax';
|
|
20
20
|
import apis from '../../constants/api';
|
|
21
|
-
import '../
|
|
21
|
+
import '../clearRule/css/index.less';
|
|
22
22
|
import moment from 'moment';
|
|
23
23
|
var Text = Typography.Text;
|
|
24
24
|
var RangePicker = DatePicker.RangePicker;
|
|
@@ -96,7 +96,7 @@ var FormulateRule = function FormulateRule() {
|
|
|
96
96
|
openAddDraw = _useState2[0],
|
|
97
97
|
setOpenAddDraw = _useState2[1];
|
|
98
98
|
var handleOpenStatus = function handleOpenStatus(ruleObj) {
|
|
99
|
-
request(apis.clearRule.
|
|
99
|
+
request(apis.clearRule.checkStatus, {
|
|
100
100
|
method: 'post',
|
|
101
101
|
data: {
|
|
102
102
|
ruleId: ruleObj.ruleId,
|
|
@@ -182,8 +182,10 @@ var FormulateRule = function FormulateRule() {
|
|
|
182
182
|
if ((res === null || res === void 0 ? void 0 : res.code) == '100000') {
|
|
183
183
|
if (res.data == 1) {
|
|
184
184
|
UseModal({
|
|
185
|
-
onOk: function onOk() {
|
|
186
|
-
|
|
185
|
+
onOk: function onOk() {
|
|
186
|
+
getDetail(ruleId);
|
|
187
|
+
},
|
|
188
|
+
okText: '去修改',
|
|
187
189
|
title: '校验对象已被删除',
|
|
188
190
|
content: "\u6821\u9A8C\u5BF9\u8C61\u5DF2\u88AB\u5220\u9664\uFF0C\u5C06\u4E0D\u4F1A\u8FDB\u884C\u4F7F\u7528\uFF0C\u8BF7\u8FDB\u884C\u4FEE\u6539"
|
|
189
191
|
});
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@zgfe/modules-dm",
|
|
3
|
-
"version": "1.0.57-
|
|
3
|
+
"version": "1.0.57-zhongyuan.10",
|
|
4
4
|
"license": "ISC",
|
|
5
5
|
"module": "es/index.js",
|
|
6
6
|
"typings": "es/index.d.ts",
|
|
@@ -57,7 +57,7 @@
|
|
|
57
57
|
"umi-request": "^1.4.0",
|
|
58
58
|
"yorkie": "^2.0.0"
|
|
59
59
|
},
|
|
60
|
-
"gitHead": "
|
|
60
|
+
"gitHead": "46311c056ac9e09a0b2296223d81d9f60b21258f",
|
|
61
61
|
"gitHooks": {
|
|
62
62
|
"pre-commit": "lint-staged"
|
|
63
63
|
}
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|