@bit-sun/business-component 4.2.0-alpha.21 → 4.2.0-alpha.22
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/dist/index.esm.js +274 -11
- package/dist/index.js +274 -11
- package/package.json +1 -1
- package/src/components/Business/SearchSelect/BusinessUtils.tsx +60 -0
- package/src/components/Business/SearchSelect/index.md +2 -2
- package/src/components/Solution/RuleComponent/index.js +216 -8
- package/src/components/Solution/RuleComponent/ruleFiled.js +21 -5
package/dist/index.esm.js
CHANGED
|
@@ -10478,6 +10478,25 @@ function commonFun(type, prefixUrl, parentProps) {
|
|
|
10478
10478
|
field: {
|
|
10479
10479
|
type: 'proppertySelector'
|
|
10480
10480
|
}
|
|
10481
|
+
}, {
|
|
10482
|
+
name: 'qp-itemLabelId-in',
|
|
10483
|
+
type: 'select',
|
|
10484
|
+
label: '商品标签',
|
|
10485
|
+
field: {
|
|
10486
|
+
type: 'select',
|
|
10487
|
+
props: {
|
|
10488
|
+
mode: 'multiple',
|
|
10489
|
+
notFoundContent: '暂无数据',
|
|
10490
|
+
allowClear: true,
|
|
10491
|
+
showSearch: true,
|
|
10492
|
+
showArrow: true,
|
|
10493
|
+
maxTagCount: 1,
|
|
10494
|
+
optionFilterProp: 'children',
|
|
10495
|
+
filterOption: function filterOption(input, option) {
|
|
10496
|
+
return option.props.children.toLowerCase().indexOf(input.toLowerCase()) >= 0;
|
|
10497
|
+
}
|
|
10498
|
+
}
|
|
10499
|
+
}
|
|
10481
10500
|
}];
|
|
10482
10501
|
var defaultQSHL = [{
|
|
10483
10502
|
isOpen: true,
|
|
@@ -10495,9 +10514,14 @@ function commonFun(type, prefixUrl, parentProps) {
|
|
|
10495
10514
|
}, getQueryHeadersItem(_queryHeaderParams2, 'qp-brandId-in')), loadSelectSource$1("".concat(prefixUrl.formSelectFix, "/category/queryCategoryTree"), {
|
|
10496
10515
|
pageSize: 5000,
|
|
10497
10516
|
currentPage: 1
|
|
10498
|
-
}, getQueryHeadersItem(_queryHeaderParams2, 'qp-categoryId-in'))
|
|
10517
|
+
}, getQueryHeadersItem(_queryHeaderParams2, 'qp-categoryId-in')), loadSelectSource$1("".concat(prefixUrl.formSelectFix, "/label"), {
|
|
10518
|
+
pageSize: 500,
|
|
10519
|
+
currentPage: 1,
|
|
10520
|
+
'qp-labelType-eq': 1
|
|
10521
|
+
}, getQueryHeadersItem(_queryHeaderParams2, 'qp-itemLabelId-in'))]).then(function (x) {
|
|
10499
10522
|
formatSource(x, 0, 3, tableSearchForm, ['id', 'name']);
|
|
10500
10523
|
formatTreeDataSource(x, 1, 4, tableSearchForm);
|
|
10524
|
+
formatSource(x, 2, 6, tableSearchForm, ['id', 'name']);
|
|
10501
10525
|
});
|
|
10502
10526
|
modalTableProps = _objectSpread2({
|
|
10503
10527
|
modalTableTitle: '选择SKU',
|
|
@@ -10651,6 +10675,25 @@ function commonFun(type, prefixUrl, parentProps) {
|
|
|
10651
10675
|
}
|
|
10652
10676
|
}
|
|
10653
10677
|
}
|
|
10678
|
+
}, {
|
|
10679
|
+
name: 'qp-itemLabelId-in',
|
|
10680
|
+
type: 'select',
|
|
10681
|
+
label: '商品标签',
|
|
10682
|
+
field: {
|
|
10683
|
+
type: 'select',
|
|
10684
|
+
props: {
|
|
10685
|
+
mode: 'multiple',
|
|
10686
|
+
notFoundContent: '暂无数据',
|
|
10687
|
+
allowClear: true,
|
|
10688
|
+
showSearch: true,
|
|
10689
|
+
showArrow: true,
|
|
10690
|
+
maxTagCount: 1,
|
|
10691
|
+
optionFilterProp: 'children',
|
|
10692
|
+
filterOption: function filterOption(input, option) {
|
|
10693
|
+
return option.props.children.toLowerCase().indexOf(input.toLowerCase()) >= 0;
|
|
10694
|
+
}
|
|
10695
|
+
}
|
|
10696
|
+
}
|
|
10654
10697
|
}];
|
|
10655
10698
|
var _queryHeaderParams3 = getQueryHeadersList({
|
|
10656
10699
|
querySelectHeadersList: querySelectHeadersList,
|
|
@@ -10666,10 +10709,15 @@ function commonFun(type, prefixUrl, parentProps) {
|
|
|
10666
10709
|
}, getQueryHeadersItem(_queryHeaderParams3, 'qp-categoryId-in')), loadSelectSource$1("".concat(prefixUrl.formSelectFix, "/class/withProperty"), {
|
|
10667
10710
|
pageSize: 5000,
|
|
10668
10711
|
currentPage: 1
|
|
10669
|
-
}, getQueryHeadersItem(_queryHeaderParams3, 'qp-classId-in'))
|
|
10712
|
+
}, getQueryHeadersItem(_queryHeaderParams3, 'qp-classId-in')), loadSelectSource$1("".concat(prefixUrl.formSelectFix, "/label"), {
|
|
10713
|
+
pageSize: 500,
|
|
10714
|
+
currentPage: 1,
|
|
10715
|
+
'qp-labelType-eq': 1
|
|
10716
|
+
}, getQueryHeadersItem(_queryHeaderParams3, 'qp-itemLabelId-in'))]).then(function (x) {
|
|
10670
10717
|
formatSource(x, 0, 2, tableSearchForm, ['id', 'name']);
|
|
10671
10718
|
formatTreeDataSource(x, 1, 3, tableSearchForm);
|
|
10672
10719
|
formatSource(x, 2, 4, tableSearchForm, ['id', 'name']);
|
|
10720
|
+
formatSource(x, 3, 5, tableSearchForm, ['id', 'name']);
|
|
10673
10721
|
});
|
|
10674
10722
|
modalTableProps = _objectSpread2({
|
|
10675
10723
|
modalTableTitle: '选择商品(SPU) ',
|
|
@@ -10846,6 +10894,25 @@ function commonFun(type, prefixUrl, parentProps) {
|
|
|
10846
10894
|
mode: 'multiple'
|
|
10847
10895
|
}
|
|
10848
10896
|
}
|
|
10897
|
+
}, {
|
|
10898
|
+
name: 'qp-itemLabelId-in',
|
|
10899
|
+
type: 'select',
|
|
10900
|
+
label: '商品标签',
|
|
10901
|
+
field: {
|
|
10902
|
+
type: 'select',
|
|
10903
|
+
props: {
|
|
10904
|
+
mode: 'multiple',
|
|
10905
|
+
notFoundContent: '暂无数据',
|
|
10906
|
+
allowClear: true,
|
|
10907
|
+
showSearch: true,
|
|
10908
|
+
showArrow: true,
|
|
10909
|
+
maxTagCount: 1,
|
|
10910
|
+
optionFilterProp: 'children',
|
|
10911
|
+
filterOption: function filterOption(input, option) {
|
|
10912
|
+
return option.props.children.toLowerCase().indexOf(input.toLowerCase()) >= 0;
|
|
10913
|
+
}
|
|
10914
|
+
}
|
|
10915
|
+
}
|
|
10849
10916
|
}];
|
|
10850
10917
|
var _queryHeaderParams4 = getQueryHeadersList({
|
|
10851
10918
|
querySelectHeadersList: querySelectHeadersList,
|
|
@@ -10861,10 +10928,15 @@ function commonFun(type, prefixUrl, parentProps) {
|
|
|
10861
10928
|
}, getQueryHeadersItem(_queryHeaderParams4, 'qp-categoryId-in')), loadSelectSource$1("".concat(prefixUrl.formSelectFix, "/class/withProperty"), {
|
|
10862
10929
|
pageSize: 5000,
|
|
10863
10930
|
currentPage: 1
|
|
10864
|
-
}, getQueryHeadersItem(_queryHeaderParams4, 'qp-classId-in'))
|
|
10931
|
+
}, getQueryHeadersItem(_queryHeaderParams4, 'qp-classId-in')), loadSelectSource$1("".concat(prefixUrl.formSelectFix, "/label"), {
|
|
10932
|
+
pageSize: 500,
|
|
10933
|
+
currentPage: 1,
|
|
10934
|
+
'qp-labelType-eq': 1
|
|
10935
|
+
}, getQueryHeadersItem(_queryHeaderParams4, 'qp-itemLabelId-in'))]).then(function (x) {
|
|
10865
10936
|
formatSource(x, 0, 2, tableSearchForm, ['id', 'name']);
|
|
10866
10937
|
formatTreeDataSource(x, 1, 3, tableSearchForm);
|
|
10867
10938
|
formatSource(x, 2, 4, tableSearchForm, ['id', 'name']);
|
|
10939
|
+
formatSource(x, 3, 10, tableSearchForm, ['id', 'name']);
|
|
10868
10940
|
});
|
|
10869
10941
|
modalTableProps = _objectSpread2({
|
|
10870
10942
|
modalTableTitle: '选择SPU',
|
|
@@ -34562,11 +34634,24 @@ var RuleField = /*#__PURE__*/function (_Component) {
|
|
|
34562
34634
|
itemDetail = _this$props2$itemDeta === void 0 ? {} : _this$props2$itemDeta,
|
|
34563
34635
|
_this$props2$others = _this$props2.others,
|
|
34564
34636
|
others = _this$props2$others === void 0 ? {} : _this$props2$others,
|
|
34565
|
-
propertyCode = _this$props2.propertyCode
|
|
34637
|
+
propertyCode = _this$props2.propertyCode,
|
|
34638
|
+
isQueryParams = _this$props2.isQueryParams;
|
|
34566
34639
|
var thresholdList = _this.state.thresholdList;
|
|
34567
34640
|
var styleCommon = {
|
|
34568
34641
|
width: customerWidth || '180px'
|
|
34569
34642
|
};
|
|
34643
|
+
if (isQueryParams) {
|
|
34644
|
+
return /*#__PURE__*/React$1.createElement(Input, {
|
|
34645
|
+
defaultValue: values.join(','),
|
|
34646
|
+
disabled: disabled,
|
|
34647
|
+
style: styleCommon,
|
|
34648
|
+
onBlur: function onBlur(e) {
|
|
34649
|
+
values = e.target.value.split(',');
|
|
34650
|
+
valueNames = e.target.value.split(',');
|
|
34651
|
+
callback(values, valueNames);
|
|
34652
|
+
}
|
|
34653
|
+
});
|
|
34654
|
+
}
|
|
34570
34655
|
if (!selectOperation) return /*#__PURE__*/React$1.createElement(Input, {
|
|
34571
34656
|
disabled: true,
|
|
34572
34657
|
style: styleCommon
|
|
@@ -37092,7 +37177,8 @@ var RuleField = /*#__PURE__*/function (_Component) {
|
|
|
37092
37177
|
fieldValues: [],
|
|
37093
37178
|
thresholdQuery: {},
|
|
37094
37179
|
thresholdList: [],
|
|
37095
|
-
options: []
|
|
37180
|
+
options: [],
|
|
37181
|
+
isQueryParams: false
|
|
37096
37182
|
};
|
|
37097
37183
|
return _this;
|
|
37098
37184
|
}
|
|
@@ -37112,13 +37198,15 @@ var RuleField = /*#__PURE__*/function (_Component) {
|
|
|
37112
37198
|
initialThresholdQuery = _this$props3.initialThresholdQuery,
|
|
37113
37199
|
queryIdentify = _this$props3.queryIdentify,
|
|
37114
37200
|
propertyCode = _this$props3.propertyCode,
|
|
37115
|
-
queryIdentifyType = _this$props3.queryIdentifyType
|
|
37201
|
+
queryIdentifyType = _this$props3.queryIdentifyType,
|
|
37202
|
+
isQueryParams = _this$props3.isQueryParams;
|
|
37116
37203
|
this.setState({
|
|
37117
37204
|
selectOperation: selectOperation,
|
|
37118
37205
|
thresholdQuery: initialThresholdQuery ? _objectSpread2({}, initialThresholdQuery) : {},
|
|
37119
37206
|
dataTypeCode: dataTypeCode,
|
|
37120
37207
|
dataChoiceBusinessType: dataChoiceBusinessType,
|
|
37121
37208
|
dataInputBusinessType: dataInputBusinessType,
|
|
37209
|
+
isQueryParams: isQueryParams,
|
|
37122
37210
|
others: others,
|
|
37123
37211
|
fieldValues: _toConsumableArray(values),
|
|
37124
37212
|
options: options
|
|
@@ -38325,6 +38413,18 @@ function RenderCompItem(props) {
|
|
|
38325
38413
|
}
|
|
38326
38414
|
|
|
38327
38415
|
var RangePicker$2 = DatePicker.RangePicker;
|
|
38416
|
+
var FIXED_DATA_TYPES = {
|
|
38417
|
+
10: '字符串',
|
|
38418
|
+
20: '短整数',
|
|
38419
|
+
21: '长整数',
|
|
38420
|
+
22: '小数',
|
|
38421
|
+
40: '数组',
|
|
38422
|
+
41: '布尔值',
|
|
38423
|
+
12: '富文本',
|
|
38424
|
+
30: '日期',
|
|
38425
|
+
31: '时间',
|
|
38426
|
+
32: '日期时间'
|
|
38427
|
+
};
|
|
38328
38428
|
var RuleObjectComponent = /*#__PURE__*/function (_Component) {
|
|
38329
38429
|
function RuleObjectComponent(props) {
|
|
38330
38430
|
var _this;
|
|
@@ -38368,6 +38468,8 @@ var RuleObjectComponent = /*#__PURE__*/function (_Component) {
|
|
|
38368
38468
|
value: element.id,
|
|
38369
38469
|
id: element.id,
|
|
38370
38470
|
dataTypeCode: element.valueType,
|
|
38471
|
+
entityValueType: element.entityValueType,
|
|
38472
|
+
entityInputType: element.entityInputType,
|
|
38371
38473
|
dataChoiceBusinessType: element.choiceType,
|
|
38372
38474
|
dataInputBusinessType: element.inputType,
|
|
38373
38475
|
info: element.info,
|
|
@@ -38389,6 +38491,8 @@ var RuleObjectComponent = /*#__PURE__*/function (_Component) {
|
|
|
38389
38491
|
metaObjectCode: _this.props.metaObjectCode || item.code
|
|
38390
38492
|
}, item), {}, {
|
|
38391
38493
|
dataTypeCode: item.valueType,
|
|
38494
|
+
entityValueType: item.entityValueType,
|
|
38495
|
+
entityInputType: item.entityInputType,
|
|
38392
38496
|
dataChoiceBusinessType: item.choiceType,
|
|
38393
38497
|
dataInputBusinessType: item.inputType
|
|
38394
38498
|
}));
|
|
@@ -38422,6 +38526,8 @@ var RuleObjectComponent = /*#__PURE__*/function (_Component) {
|
|
|
38422
38526
|
value: element.id,
|
|
38423
38527
|
id: element.id,
|
|
38424
38528
|
dataTypeCode: element.valueType,
|
|
38529
|
+
entityValueType: element.entityValueType,
|
|
38530
|
+
entityInputType: element.entityInputType,
|
|
38425
38531
|
dataChoiceBusinessType: element.choiceType,
|
|
38426
38532
|
dataInputBusinessType: element.inputType,
|
|
38427
38533
|
info: element.info,
|
|
@@ -38783,7 +38889,7 @@ var RuleObjectComponent = /*#__PURE__*/function (_Component) {
|
|
|
38783
38889
|
});
|
|
38784
38890
|
};
|
|
38785
38891
|
_this.renderRuleItem = function (itemDetail, parentDetail, floorIndex, classDataIndex, relateDatas) {
|
|
38786
|
-
var _itemDetail$subExpres, _itemDetail$params, _itemDetail$params$, _itemDetail$params2;
|
|
38892
|
+
var _itemDetail$subExpres, _itemDetail$params, _itemDetail$params$, _itemDetail$params2, _itemDetail$reqCondit, _itemDetail$reqCondit2, _itemDetail$reqCondit3, _itemDetail$reqCondit4;
|
|
38787
38893
|
var ruleTreeData = _this.state.ruleTreeData;
|
|
38788
38894
|
var _this$props3 = _this.props,
|
|
38789
38895
|
callBack = _this$props3.callBack,
|
|
@@ -38791,7 +38897,8 @@ var RuleObjectComponent = /*#__PURE__*/function (_Component) {
|
|
|
38791
38897
|
initialThresholdQuery = _this$props3$initialT === void 0 ? {} : _this$props3$initialT,
|
|
38792
38898
|
disabled = _this$props3.disabled,
|
|
38793
38899
|
systemVariableList = _this$props3.systemVariableList,
|
|
38794
|
-
needShowInsertSQL = _this$props3.needShowInsertSQL
|
|
38900
|
+
needShowInsertSQL = _this$props3.needShowInsertSQL,
|
|
38901
|
+
needShowReqCondition = _this$props3.needShowReqCondition;
|
|
38795
38902
|
var thresholdQuery = _objectSpread2(_objectSpread2({}, initialThresholdQuery), relateDatas);
|
|
38796
38903
|
var finalIndex = floorIndex + 1;
|
|
38797
38904
|
var queryIdentify = '';
|
|
@@ -38882,6 +38989,8 @@ var RuleObjectComponent = /*#__PURE__*/function (_Component) {
|
|
|
38882
38989
|
itemDetail.elementId = nodeInfo.triggerNode.props.id;
|
|
38883
38990
|
itemDetail.elementName = nodeInfo.triggerNode.props.title;
|
|
38884
38991
|
itemDetail.dataTypeCode = nodeInfo.triggerNode.props.dataTypeCode;
|
|
38992
|
+
itemDetail.entityValueType = nodeInfo.triggerNode.props.entityValueType;
|
|
38993
|
+
itemDetail.entityInputType = nodeInfo.triggerNode.props.entityInputType;
|
|
38885
38994
|
itemDetail.metaObjectCode = nodeInfo.triggerNode.props.metaObjectCode;
|
|
38886
38995
|
itemDetail.isInsertParam = false;
|
|
38887
38996
|
if (needShowInsertSQL) {
|
|
@@ -39051,12 +39160,13 @@ var RuleObjectComponent = /*#__PURE__*/function (_Component) {
|
|
|
39051
39160
|
}
|
|
39052
39161
|
}, (itemDetail === null || itemDetail === void 0 ? void 0 : itemDetail.isInsertSQL) ? '取消插入SQL' : '插入SQL')), /*#__PURE__*/React$1.createElement("div", {
|
|
39053
39162
|
style: {
|
|
39054
|
-
display: itemDetail.operationType == 'logic' && !disabled ? 'block' : 'none'
|
|
39163
|
+
display: itemDetail.operationType == 'logic' && (!disabled || itemDetail.reqConditionData && itemDetail.reqConditionData.reqParamName && ((_itemDetail$reqCondit = itemDetail.reqConditionData.params) === null || _itemDetail$reqCondit === void 0 ? void 0 : _itemDetail$reqCondit.length)) ? 'block' : 'none'
|
|
39055
39164
|
}
|
|
39056
39165
|
}, /*#__PURE__*/React$1.createElement("span", {
|
|
39057
39166
|
style: {
|
|
39058
39167
|
color: '#008fe0',
|
|
39059
|
-
cursor: 'pointer'
|
|
39168
|
+
cursor: 'pointer',
|
|
39169
|
+
display: disabled ? 'none' : 'inline'
|
|
39060
39170
|
},
|
|
39061
39171
|
type: "link",
|
|
39062
39172
|
onClick: function onClick() {
|
|
@@ -39068,7 +39178,107 @@ var RuleObjectComponent = /*#__PURE__*/function (_Component) {
|
|
|
39068
39178
|
fontSize: '14px',
|
|
39069
39179
|
marginRight: '5px'
|
|
39070
39180
|
}
|
|
39071
|
-
}), "\u6DFB\u52A0\u6761\u4EF6")
|
|
39181
|
+
}), "\u6DFB\u52A0\u6761\u4EF6"), needShowReqCondition && /*#__PURE__*/React$1.createElement("span", {
|
|
39182
|
+
style: {
|
|
39183
|
+
marginLeft: 10,
|
|
39184
|
+
display: disabled ? 'none' : 'inline'
|
|
39185
|
+
}
|
|
39186
|
+
}, /*#__PURE__*/React$1.createElement(Button, {
|
|
39187
|
+
type: "link",
|
|
39188
|
+
disabled: disabled && (!itemDetail.reqConditionData || !itemDetail.reqConditionData.reqParamName || !((_itemDetail$reqCondit2 = itemDetail.reqConditionData.params) === null || _itemDetail$reqCondit2 === void 0 ? void 0 : _itemDetail$reqCondit2.length)),
|
|
39189
|
+
style: {
|
|
39190
|
+
padding: 0,
|
|
39191
|
+
height: 'auto'
|
|
39192
|
+
},
|
|
39193
|
+
onClick: function onClick() {
|
|
39194
|
+
return _this.handleReqConditionToggle(itemDetail);
|
|
39195
|
+
}
|
|
39196
|
+
}, itemDetail.isReqCondition ? '取消参数条件控制' : '参数条件控制')), (itemDetail.isReqCondition || disabled && itemDetail.reqConditionData && itemDetail.reqConditionData.reqParamName && ((_itemDetail$reqCondit3 = itemDetail.reqConditionData.params) === null || _itemDetail$reqCondit3 === void 0 ? void 0 : _itemDetail$reqCondit3.length)) && itemDetail.reqConditionData && /*#__PURE__*/React$1.createElement("div", {
|
|
39197
|
+
style: {
|
|
39198
|
+
marginTop: 10,
|
|
39199
|
+
display: disabled && (!itemDetail.reqConditionData.reqParamName || !((_itemDetail$reqCondit4 = itemDetail.reqConditionData.params) === null || _itemDetail$reqCondit4 === void 0 ? void 0 : _itemDetail$reqCondit4.length)) ? 'none' : 'flex',
|
|
39200
|
+
alignItems: 'center',
|
|
39201
|
+
background: '#f5f5f5',
|
|
39202
|
+
padding: '10px',
|
|
39203
|
+
borderRadius: '4px'
|
|
39204
|
+
}
|
|
39205
|
+
}, /*#__PURE__*/React$1.createElement("span", {
|
|
39206
|
+
style: {
|
|
39207
|
+
marginRight: 8,
|
|
39208
|
+
flexShrink: 0
|
|
39209
|
+
}
|
|
39210
|
+
}, "\u8BF7\u6C42\u53C2\u6570\u540D\u79F0:"), /*#__PURE__*/React$1.createElement(Input, {
|
|
39211
|
+
disabled: disabled,
|
|
39212
|
+
style: {
|
|
39213
|
+
width: 150,
|
|
39214
|
+
marginRight: 10
|
|
39215
|
+
},
|
|
39216
|
+
value: itemDetail.reqConditionData.reqParamName,
|
|
39217
|
+
onChange: function onChange(e) {
|
|
39218
|
+
return _this.handleReqDataChange(itemDetail, 'reqParamName', e.target.value);
|
|
39219
|
+
}
|
|
39220
|
+
}), /*#__PURE__*/React$1.createElement("span", {
|
|
39221
|
+
style: {
|
|
39222
|
+
marginRight: 8,
|
|
39223
|
+
flexShrink: 0
|
|
39224
|
+
}
|
|
39225
|
+
}, "\u7C7B\u578B:"), /*#__PURE__*/React$1.createElement(Select, {
|
|
39226
|
+
disabled: disabled,
|
|
39227
|
+
style: {
|
|
39228
|
+
width: 120,
|
|
39229
|
+
marginRight: 10
|
|
39230
|
+
},
|
|
39231
|
+
value: itemDetail.reqConditionData.dataTypeCode,
|
|
39232
|
+
onChange: function onChange(val) {
|
|
39233
|
+
return _this.handleReqDataChange(itemDetail, 'dataTypeCode', val);
|
|
39234
|
+
}
|
|
39235
|
+
}, Object.keys(FIXED_DATA_TYPES).map(function (code) {
|
|
39236
|
+
return /*#__PURE__*/React$1.createElement(Select.Option, {
|
|
39237
|
+
key: code,
|
|
39238
|
+
value: code
|
|
39239
|
+
}, FIXED_DATA_TYPES[code]);
|
|
39240
|
+
})), /*#__PURE__*/React$1.createElement(Select, {
|
|
39241
|
+
disabled: disabled,
|
|
39242
|
+
style: {
|
|
39243
|
+
width: 120,
|
|
39244
|
+
marginRight: 10
|
|
39245
|
+
},
|
|
39246
|
+
value: itemDetail.reqConditionData.operationCode,
|
|
39247
|
+
onChange: function onChange(val) {
|
|
39248
|
+
return _this.handleReqDataChange(itemDetail, 'operationCode', val);
|
|
39249
|
+
}
|
|
39250
|
+
}, [{
|
|
39251
|
+
'code': '1',
|
|
39252
|
+
'name': '在集合'
|
|
39253
|
+
}, {
|
|
39254
|
+
'code': '2',
|
|
39255
|
+
'name': '不等于'
|
|
39256
|
+
}, {
|
|
39257
|
+
code: '3',
|
|
39258
|
+
name: '小于'
|
|
39259
|
+
}, {
|
|
39260
|
+
code: '4',
|
|
39261
|
+
name: '大于'
|
|
39262
|
+
}, {
|
|
39263
|
+
code: '5',
|
|
39264
|
+
name: '等于'
|
|
39265
|
+
}].map(function (op) {
|
|
39266
|
+
return /*#__PURE__*/React$1.createElement(Select.Option, {
|
|
39267
|
+
key: op.code,
|
|
39268
|
+
value: op.code
|
|
39269
|
+
}, op.name);
|
|
39270
|
+
})), /*#__PURE__*/React$1.createElement(RuleField, {
|
|
39271
|
+
customerWidth: '180px',
|
|
39272
|
+
isQueryParams: true,
|
|
39273
|
+
selectOperation: itemDetail.reqConditionData.operationCode,
|
|
39274
|
+
dataTypeCode: itemDetail.reqConditionData.dataTypeCode,
|
|
39275
|
+
values: itemDetail.reqConditionData.params || [],
|
|
39276
|
+
valueNames: itemDetail.reqConditionData.paramNames || [],
|
|
39277
|
+
callback: function callback(newValues, newValueNames) {
|
|
39278
|
+
return _this.handleReqDataChange(itemDetail, 'params', newValues, newValueNames);
|
|
39279
|
+
},
|
|
39280
|
+
disabled: disabled
|
|
39281
|
+
})))));
|
|
39072
39282
|
};
|
|
39073
39283
|
_this.handleEditExtraInfoResponse = function (code, val, parentDetail, classDataIndex, key) {
|
|
39074
39284
|
var ruleClassData = _this.state.ruleClassData;
|
|
@@ -39384,6 +39594,8 @@ var RuleObjectComponent = /*#__PURE__*/function (_Component) {
|
|
|
39384
39594
|
delete itemDetail.params;
|
|
39385
39595
|
delete itemDetail.paramNames;
|
|
39386
39596
|
delete itemDetail.dataTypeCode;
|
|
39597
|
+
delete itemDetail.entityValueType;
|
|
39598
|
+
delete itemDetail.entityInputType;
|
|
39387
39599
|
delete itemDetail.elementId;
|
|
39388
39600
|
delete itemDetail.elementName;
|
|
39389
39601
|
delete itemDetail.metaObjectCode;
|
|
@@ -39434,6 +39646,8 @@ var RuleObjectComponent = /*#__PURE__*/function (_Component) {
|
|
|
39434
39646
|
parentDetail.elementId = parentDetail.subExpression[0].elementId;
|
|
39435
39647
|
parentDetail.elementName = parentDetail.subExpression[0].elementName;
|
|
39436
39648
|
parentDetail.dataTypeCode = parentDetail.subExpression[0].dataTypeCode;
|
|
39649
|
+
parentDetail.entityValueType = parentDetail.subExpression[0].entityValueType;
|
|
39650
|
+
parentDetail.entityInputType = parentDetail.subExpression[0].entityInputType;
|
|
39437
39651
|
delete parentDetail.subExpression;
|
|
39438
39652
|
}
|
|
39439
39653
|
}
|
|
@@ -39507,6 +39721,55 @@ var RuleObjectComponent = /*#__PURE__*/function (_Component) {
|
|
|
39507
39721
|
callBack(ruleClassData);
|
|
39508
39722
|
});
|
|
39509
39723
|
};
|
|
39724
|
+
_this.handleReqConditionToggle = function (itemDetail) {
|
|
39725
|
+
var ruleClassData = _this.state.ruleClassData;
|
|
39726
|
+
var callBack = _this.props.callBack;
|
|
39727
|
+
itemDetail.isReqCondition = !itemDetail.isReqCondition;
|
|
39728
|
+
if (itemDetail.isReqCondition && !itemDetail.reqConditionData) {
|
|
39729
|
+
itemDetail.reqConditionData = {
|
|
39730
|
+
operationType: 'relation',
|
|
39731
|
+
dataTypeCode: '10',
|
|
39732
|
+
entityInputType: '10',
|
|
39733
|
+
entityValueType: '10',
|
|
39734
|
+
operationCode: '',
|
|
39735
|
+
reqParamName: '',
|
|
39736
|
+
params: [],
|
|
39737
|
+
paramNames: []
|
|
39738
|
+
};
|
|
39739
|
+
}
|
|
39740
|
+
_this.setState({
|
|
39741
|
+
ruleClassData: ruleClassData
|
|
39742
|
+
}, function () {
|
|
39743
|
+
callBack(ruleClassData);
|
|
39744
|
+
});
|
|
39745
|
+
};
|
|
39746
|
+
_this.handleReqDataChange = function (itemDetail, field, value, valueNames) {
|
|
39747
|
+
var ruleClassData = _this.state.ruleClassData;
|
|
39748
|
+
var callBack = _this.props.callBack;
|
|
39749
|
+
if (!itemDetail.reqConditionData) return;
|
|
39750
|
+
if (field === 'dataTypeCode') {
|
|
39751
|
+
itemDetail.reqConditionData.dataTypeCode = value;
|
|
39752
|
+
itemDetail.reqConditionData.entityInputType = value;
|
|
39753
|
+
itemDetail.reqConditionData.entityValueType = value;
|
|
39754
|
+
itemDetail.reqConditionData.operationCode = '';
|
|
39755
|
+
itemDetail.reqConditionData.params = [];
|
|
39756
|
+
itemDetail.reqConditionData.paramNames = [];
|
|
39757
|
+
} else if (field === 'operationCode') {
|
|
39758
|
+
itemDetail.reqConditionData.operationCode = value;
|
|
39759
|
+
} else if (field === 'reqParamName') {
|
|
39760
|
+
itemDetail.reqConditionData.reqParamName = value;
|
|
39761
|
+
} else if (field === 'params') {
|
|
39762
|
+
itemDetail.reqConditionData.params = value;
|
|
39763
|
+
if (valueNames) {
|
|
39764
|
+
itemDetail.reqConditionData.paramNames = valueNames;
|
|
39765
|
+
}
|
|
39766
|
+
}
|
|
39767
|
+
_this.setState({
|
|
39768
|
+
ruleClassData: ruleClassData
|
|
39769
|
+
}, function () {
|
|
39770
|
+
callBack(ruleClassData);
|
|
39771
|
+
});
|
|
39772
|
+
};
|
|
39510
39773
|
_this.state = {
|
|
39511
39774
|
editNameIndex: 0,
|
|
39512
39775
|
isEdit: false,
|