@bit-sun/business-component 2.4.24 → 2.4.26-beta01
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/components/Business/BsLayouts/service.d.ts +1 -1
- package/dist/components/Business/BsSulaQueryTable/index.d.ts +0 -1
- package/dist/components/Business/BsSulaQueryTable/setting.d.ts +1 -1
- package/dist/components/Business/BsSulaQueryTable/utils.d.ts +0 -1
- package/dist/components/Business/columnSettingTable/columnSetting.d.ts +0 -1
- package/dist/components/Functional/ExportFunctions/ExportIcon/index.d.ts +1 -1
- package/dist/components/Functional/QueryMutipleInput/index.d.ts +1 -2
- package/dist/components/Solution/RuleComponent/services.d.ts +1 -1
- package/dist/index.esm.js +1185 -1739
- package/dist/index.js +1179 -1735
- package/dist/utils/TableUtils.d.ts +2 -93
- package/dist/utils/index.d.ts +4 -6
- package/dist/utils/utils.d.ts +0 -13
- package/package.json +4 -7
- package/src/assets/32.svg +27 -27
- package/src/assets/addIcon.svg +17 -17
- package/src/assets/allfunc.svg +27 -27
- package/src/assets/arrowRight.svg +24 -24
- package/src/assets/btn-delete.svg +29 -29
- package/src/assets/btn-edit.svg +19 -19
- package/src/assets/btn-more.svg +17 -17
- package/src/assets/btn-submit.svg +19 -19
- package/src/assets/close.svg +26 -26
- package/src/assets/drag.svg +17 -17
- package/src/assets/fixed-left.svg +15 -15
- package/src/assets/fixed-right.svg +15 -15
- package/src/assets/guanbi.svg +15 -15
- package/src/assets/icon-quanping.svg +15 -15
- package/src/assets/icon-shezhi.svg +17 -17
- package/src/assets/label_icon_bottom.svg +25 -25
- package/src/assets/list-no-img.svg +21 -21
- package/src/assets/morentouxiang-32.svg +23 -23
- package/src/assets/scanning.svg +24 -24
- package/src/assets/upExport.svg +22 -22
- package/src/common/ENUM.ts +41 -41
- package/src/components/Business/AddSelectBusiness/index.tsx +22 -40
- package/src/components/Business/BsLayouts/Components/AllFunc/index.less +153 -153
- package/src/components/Business/BsLayouts/Components/AllFunc/index.tsx +70 -70
- package/src/components/Business/BsLayouts/Components/CustomerMenu/MenuSetting/index.less +90 -90
- package/src/components/Business/BsLayouts/Components/CustomerMenu/MenuSetting/index.tsx +37 -37
- package/src/components/Business/BsLayouts/Components/CustomerMenu/MenuSetting/leftTree.tsx +242 -242
- package/src/components/Business/BsLayouts/Components/CustomerMenu/MenuSetting/rightTree.tsx +384 -384
- package/src/components/Business/BsLayouts/Components/CustomerMenu/globalMenu/customMenuHeader.tsx +74 -74
- package/src/components/Business/BsLayouts/Components/CustomerMenu/index.less +64 -64
- package/src/components/Business/BsLayouts/Components/CustomerMenu/index.tsx +153 -153
- package/src/components/Business/BsLayouts/Components/GlobalHeader/index.tsx +157 -163
- package/src/components/Business/BsLayouts/Components/RightContent/LoginModal.tsx +85 -85
- package/src/components/Business/BsLayouts/Components/RightContent/index.tsx +2 -19
- package/src/components/Business/BsLayouts/Components/SearchFunc/index.tsx +75 -75
- package/src/components/Business/BsLayouts/index.less +79 -79
- package/src/components/Business/BsLayouts/index.tsx +1484 -1494
- package/src/components/Business/BsLayouts/service.ts +2 -2
- package/src/components/Business/BsLayouts/utils.tsx +203 -203
- package/src/components/Business/BsSulaQueryTable/SearchItemSetting.tsx +9 -9
- package/src/components/Business/BsSulaQueryTable/index.less +221 -221
- package/src/components/Business/BsSulaQueryTable/index.tsx +175 -346
- package/src/components/Business/BsSulaQueryTable/setting.tsx +87 -125
- package/src/components/Business/BsSulaQueryTable/utils.tsx +34 -57
- package/src/components/Business/CommodityEntry/index.md +70 -70
- package/src/components/Business/CommodityEntry/index.tsx +81 -80
- package/src/components/Business/CommonGuideWrapper/index.less +112 -121
- package/src/components/Business/CommonGuideWrapper/index.md +39 -39
- package/src/components/Business/CommonGuideWrapper/index.tsx +84 -94
- package/src/components/Business/DetailPageWrapper/index.less +1 -9
- package/src/components/Business/DetailPageWrapper/index.tsx +110 -121
- package/src/components/Business/HomePageWrapper/index.md +45 -45
- package/src/components/Business/HomePageWrapper/index.tsx +162 -162
- package/src/components/Business/JsonQueryTable/configButton/index.js +20 -20
- package/src/components/Business/JsonQueryTable/configTree/component/compactArrayView.js +25 -25
- package/src/components/Business/JsonQueryTable/configTree/component/compactObjectView.js +30 -30
- package/src/components/Business/JsonQueryTable/configTree/index.js +82 -82
- package/src/components/Business/JsonQueryTable/configTree/index.less +44 -44
- package/src/components/Business/JsonQueryTable/configTree/parser/highlight.js +57 -57
- package/src/components/Business/JsonQueryTable/configTree/parser/index.js +124 -124
- package/src/components/Business/JsonQueryTable/configTree/render/iconRender.js +29 -29
- package/src/components/Business/JsonQueryTable/configTree/render/nameRender.js +22 -22
- package/src/components/Business/JsonQueryTable/configTree/treeNode.js +116 -116
- package/src/components/Business/JsonQueryTable/drawer/index.tsx +12 -12
- package/src/components/Business/JsonQueryTable/index.less +16 -16
- package/src/components/Business/JsonQueryTable/index.md +328 -328
- package/src/components/Business/JsonQueryTable/index.tsx +537 -535
- package/src/components/Business/JsonQueryTable/jsonEditor/index.js +346 -346
- package/src/components/Business/JsonQueryTable/jsonEditor/index.less +22 -22
- package/src/components/Business/JsonQueryTable/jsonEditor/lint/basicType.js +147 -147
- package/src/components/Business/JsonQueryTable/jsonEditor/lint/index.js +389 -389
- package/src/components/Business/JsonQueryTable/jsonEditor/suggestions/actions.js +118 -118
- package/src/components/Business/JsonQueryTable/jsonEditor/suggestions/dependency.js +22 -22
- package/src/components/Business/JsonQueryTable/jsonEditor/suggestions/index.js +21 -21
- package/src/components/Business/JsonQueryTable/jsonEditor/suggestions/request.js +65 -65
- package/src/components/Business/SearchSelect/utils.ts +3 -3
- package/src/components/Business/StateFlow/index.md +60 -60
- package/src/components/Business/StateFlow/index.tsx +29 -29
- package/src/components/Business/columnSettingTable/columnSetting.tsx +8 -10
- package/src/components/Business/columnSettingTable/index.less +247 -247
- package/src/components/Business/columnSettingTable/index.md +357 -357
- package/src/components/Business/columnSettingTable/utils.tsx +71 -71
- package/src/components/Business/moreTreeTable/FixedScrollBar.tsx +87 -87
- package/src/components/Business/moreTreeTable/hooks/useSticky.ts +21 -21
- package/src/components/Business/moreTreeTable/index.less +99 -99
- package/src/components/Business/moreTreeTable/index.tsx +387 -387
- package/src/components/Business/moreTreeTable/utils.ts +126 -126
- package/src/components/Functional/AddSelect/helps.ts +3 -4
- package/src/components/Functional/AddSelect/index.less +367 -367
- package/src/components/Functional/AddSelect/index.tsx +33 -79
- package/src/components/Functional/BillEntry/index.less +371 -371
- package/src/components/Functional/BillEntry/index.tsx +3 -3
- package/src/components/Functional/BsAntdSula/index.ts +2 -2
- package/src/components/Functional/DataImport/index.less +63 -63
- package/src/components/Functional/DataImport/index.tsx +3 -3
- package/src/components/Functional/DataValidation/index.less +63 -63
- package/src/components/Functional/DataValidation/index.tsx +3 -3
- package/src/components/Functional/EllipsisTooltip/index.d.ts +5 -5
- package/src/components/Functional/EllipsisTooltip/index.js +36 -36
- package/src/components/Functional/ExportFunctions/ExportIcon/index.tsx +5 -10
- package/src/components/Functional/QueryMutipleInput/index.less +37 -37
- package/src/components/Functional/QueryMutipleInput/index.tsx +1 -2
- package/src/components/Functional/SearchSelect/index.less +0 -6
- package/src/components/Functional/SearchSelect/index.tsx +45 -152
- package/src/components/Functional/SearchSelect/utils.ts +3 -3
- package/src/components/Functional/TreeSearchSelect/index.tsx +22 -24
- package/src/components/Solution/RuleComponent/Formula.tsx +335 -335
- package/src/components/Solution/RuleComponent/index.d.ts +29 -29
- package/src/components/Solution/RuleComponent/index.js +652 -7
- package/src/components/Solution/RuleComponent/index.less +230 -230
- package/src/components/Solution/RuleComponent/renderSpecificAction.js +99 -99
- package/src/components/Solution/RuleComponent/services.ts +13 -13
- package/src/plugin/TableColumnSetting/index.less +247 -247
- package/src/plugin/TableColumnSetting/index.md +50 -50
- package/src/plugin/TableColumnSetting/index.tsx +2 -2
- package/src/plugin/TableColumnSetting/utils.ts +19 -19
- package/src/utils/CheckOneUser/index.md +39 -39
- package/src/utils/CheckOneUser/index.ts +51 -51
- package/src/utils/LocalstorageUtils.ts +95 -95
- package/src/utils/TableUtils.tsx +18 -691
- package/src/utils/checkUtils.ts +39 -39
- package/src/utils/enumConfig.ts +11 -11
- package/src/utils/getFormMode.js +12 -12
- package/src/utils/index.ts +4 -6
- package/src/utils/requestUtils.ts +2 -29
- package/src/utils/serialize.js +7 -7
- package/src/utils/utils.ts +21 -64
- package/dist/components/Business/BsLayouts/Components/ChooseStore/index.d.ts +0 -3
- package/dist/components/Business/BsLayouts/Components/ChooseStore/services.d.ts +0 -1
- package/dist/components/Business/BsLayouts/Components/RightContent/i18n.d.ts +0 -9
- package/dist/components/Solution/RuleComponent/RenderCompItem.d.ts +0 -2
- package/dist/utils/businessUtils.d.ts +0 -27
- package/dist/utils/constant.d.ts +0 -37
- package/dist/utils/request.d.ts +0 -2
- package/src/assets/arrow_top.svg +0 -18
- package/src/components/Business/BsLayouts/Components/ChooseStore/index.less +0 -0
- package/src/components/Business/BsLayouts/Components/ChooseStore/index.tsx +0 -193
- package/src/components/Business/BsLayouts/Components/ChooseStore/services.ts +0 -10
- package/src/components/Business/BsLayouts/Components/RightContent/i18n.ts +0 -9
- package/src/components/Business/BsSulaQueryTable/bssulaquerytable.less +0 -5
- package/src/components/Solution/RuleComponent/RenderCompItem.tsx +0 -637
- package/src/utils/TableUtils.less +0 -52
- package/src/utils/businessUtils.ts +0 -441
- package/src/utils/constant.ts +0 -39
- package/src/utils/request.ts +0 -53
|
@@ -44,7 +44,6 @@ import {
|
|
|
44
44
|
import { request } from 'bssula';
|
|
45
45
|
import Formula from './Formula';
|
|
46
46
|
import RenderSpecificAction from './renderSpecificAction';
|
|
47
|
-
import RenderCompItem from './RenderCompItem';
|
|
48
47
|
import InnerSelect from './InnerSelect';
|
|
49
48
|
|
|
50
49
|
const { RangePicker } = DatePicker;
|
|
@@ -189,7 +188,6 @@ class RuleObjectComponent extends Component {
|
|
|
189
188
|
`${rootObjCode}.${parentKey}.${element.code}`
|
|
190
189
|
] = infoVo?.dictionaryCode;
|
|
191
190
|
} else if (element.choiceType === 10) {
|
|
192
|
-
// FIXME http://192.168.13.78/mep-fed-group/web/libs/business-component/-/merge_requests/45#note_115669
|
|
193
191
|
const list =
|
|
194
192
|
(Object.keys(infoVo).length &&
|
|
195
193
|
infoVo.enumeration &&
|
|
@@ -660,7 +658,7 @@ class RuleObjectComponent extends Component {
|
|
|
660
658
|
this.handleLogicalTypeChange(itemDetail, 'or');
|
|
661
659
|
}}
|
|
662
660
|
>
|
|
663
|
-
|
|
661
|
+
或者
|
|
664
662
|
</p>
|
|
665
663
|
<p
|
|
666
664
|
className={'choose_logical_type'}
|
|
@@ -668,7 +666,7 @@ class RuleObjectComponent extends Component {
|
|
|
668
666
|
this.handleLogicalTypeChange(itemDetail, 'and');
|
|
669
667
|
}}
|
|
670
668
|
>
|
|
671
|
-
|
|
669
|
+
并且
|
|
672
670
|
</p>
|
|
673
671
|
</div>
|
|
674
672
|
}
|
|
@@ -679,7 +677,7 @@ class RuleObjectComponent extends Component {
|
|
|
679
677
|
type="link"
|
|
680
678
|
className={'logical_item_btn'}
|
|
681
679
|
>
|
|
682
|
-
{itemDetail?.operationCode == 'or' ? '
|
|
680
|
+
{itemDetail?.operationCode == 'or' ? '或者' : '并且'}
|
|
683
681
|
<DownOutlined style={{ marginLeft: '6px' }} />
|
|
684
682
|
</Button>
|
|
685
683
|
</Popover>
|
|
@@ -700,7 +698,6 @@ class RuleObjectComponent extends Component {
|
|
|
700
698
|
})
|
|
701
699
|
) : (
|
|
702
700
|
<div style={{ display: 'flex', alignItems: 'center' }}>
|
|
703
|
-
{/* todo */}
|
|
704
701
|
<TreeSelect
|
|
705
702
|
value={itemDetail.propertyPath}
|
|
706
703
|
disabled={disabled}
|
|
@@ -793,6 +790,7 @@ class RuleObjectComponent extends Component {
|
|
|
793
790
|
}}
|
|
794
791
|
onChange={(value) => {
|
|
795
792
|
const { ruleClassData } = this.state;
|
|
793
|
+
console.log(itemDetail);
|
|
796
794
|
itemDetail.params = [(value && `{${value}}`) || ''];
|
|
797
795
|
const name = systemVariableList.find(
|
|
798
796
|
(i) => i.code == value,
|
|
@@ -982,6 +980,648 @@ class RuleObjectComponent extends Component {
|
|
|
982
980
|
);
|
|
983
981
|
};
|
|
984
982
|
|
|
983
|
+
renderCompItem = (ites, showValue, handleEdit,disabled) => {
|
|
984
|
+
const { regularDataList } = this.props;
|
|
985
|
+
let fieldListGroup = regularDataList.map((item) => {
|
|
986
|
+
const Item = {
|
|
987
|
+
id: item.id,
|
|
988
|
+
code: item.code,
|
|
989
|
+
name: item.name,
|
|
990
|
+
value: item.code,
|
|
991
|
+
};
|
|
992
|
+
if (item.propertyList) {
|
|
993
|
+
Item.propertyList = item.propertyList.map((field) => ({
|
|
994
|
+
id: field.id,
|
|
995
|
+
code: field.code,
|
|
996
|
+
name: field.name,
|
|
997
|
+
value: `${item.code}.${field.code}`,
|
|
998
|
+
valueText: `${item.name}.${field.name}`,
|
|
999
|
+
}));
|
|
1000
|
+
}
|
|
1001
|
+
return Item;
|
|
1002
|
+
});
|
|
1003
|
+
if (!ites) return;
|
|
1004
|
+
const styleCommon = {
|
|
1005
|
+
width: '200px',
|
|
1006
|
+
...(ites?.rightText ? { marginLeft: 10 } : {}),
|
|
1007
|
+
};
|
|
1008
|
+
const style2 = {
|
|
1009
|
+
width: '100px',
|
|
1010
|
+
};
|
|
1011
|
+
return (
|
|
1012
|
+
<>
|
|
1013
|
+
{/* 输入/字符串 */}
|
|
1014
|
+
{(ites?.inputType === 10 && ites?.valueType === 21 && (
|
|
1015
|
+
<Input
|
|
1016
|
+
disabled={disabled}
|
|
1017
|
+
allowClear={true}
|
|
1018
|
+
onClear={() => {
|
|
1019
|
+
handleEdit(ites.code, undefined);
|
|
1020
|
+
}}
|
|
1021
|
+
defaultValue={showValue(ites.code, 'input')}
|
|
1022
|
+
style={styleCommon}
|
|
1023
|
+
onBlur={(e) => {
|
|
1024
|
+
handleEdit(
|
|
1025
|
+
ites.code,
|
|
1026
|
+
String(e.target.value).trim() == ''
|
|
1027
|
+
? undefined
|
|
1028
|
+
: e.target.value,
|
|
1029
|
+
);
|
|
1030
|
+
}}
|
|
1031
|
+
/>
|
|
1032
|
+
)) ||
|
|
1033
|
+
null}
|
|
1034
|
+
{/* 输入 / 长整数23/小数22 */}
|
|
1035
|
+
{(ites?.inputType === 10 &&
|
|
1036
|
+
(ites?.valueType === 23 || ites?.valueType === 22) && (
|
|
1037
|
+
<InputNumber
|
|
1038
|
+
disabled={disabled}
|
|
1039
|
+
max={Number.MAX_SAFE_INTEGER}
|
|
1040
|
+
min={ites?.valueType === 23 ? 0 : Number.MIN_SAFE_INTEGER}
|
|
1041
|
+
precision={ites?.valueType === 23 ? 0 : 2}
|
|
1042
|
+
defaultValue={ites.defaultValue}
|
|
1043
|
+
style={style2}
|
|
1044
|
+
value={showValue(ites.code)}
|
|
1045
|
+
onChange={(value) => {
|
|
1046
|
+
handleEdit(ites.code, value);
|
|
1047
|
+
}}
|
|
1048
|
+
/>
|
|
1049
|
+
)) ||
|
|
1050
|
+
null}
|
|
1051
|
+
{/* 输入/日期 */}
|
|
1052
|
+
{(ites?.inputType === 10 && (ites?.valueType === 41 || ites?.valueType === 32) && (
|
|
1053
|
+
<DatePicker
|
|
1054
|
+
showTime={dataTypeCode == 32}
|
|
1055
|
+
format={dataTypeCode == 41 ? dateFormat : fullDateFormat}
|
|
1056
|
+
disabled={disabled}
|
|
1057
|
+
defaultValue={ites.defaultValue}
|
|
1058
|
+
style={style2}
|
|
1059
|
+
value={showValue(ites.code)}
|
|
1060
|
+
onChange={(value) => {
|
|
1061
|
+
handleEdit(ites.code, value);
|
|
1062
|
+
}}
|
|
1063
|
+
/>
|
|
1064
|
+
)) ||
|
|
1065
|
+
null}
|
|
1066
|
+
{/* 输入/时间 */}
|
|
1067
|
+
{(ites?.inputType === 10 && ites?.valueType === 40 && (
|
|
1068
|
+
<RangePicker
|
|
1069
|
+
showTime
|
|
1070
|
+
disabled={disabled}
|
|
1071
|
+
defaultValue={ites.defaultValue}
|
|
1072
|
+
style={style2}
|
|
1073
|
+
value={showValue(ites.code)}
|
|
1074
|
+
onChange={(value) => {
|
|
1075
|
+
handleEdit(ites.code, value);
|
|
1076
|
+
}}
|
|
1077
|
+
/>
|
|
1078
|
+
)) ||
|
|
1079
|
+
null}
|
|
1080
|
+
{/* 输入/布尔值 */}
|
|
1081
|
+
{(ites?.inputType === 10 && ites?.valueType === 24 && (
|
|
1082
|
+
<Switch
|
|
1083
|
+
disabled={disabled}
|
|
1084
|
+
defaultChecked={!!ites.defaultValue}
|
|
1085
|
+
style={style2}
|
|
1086
|
+
checked={showValue(ites.code)}
|
|
1087
|
+
onChange={(value) => {
|
|
1088
|
+
handleEdit(ites.code, value);
|
|
1089
|
+
}}
|
|
1090
|
+
/>
|
|
1091
|
+
)) ||
|
|
1092
|
+
null}
|
|
1093
|
+
{/* 单选/多选 自定义 */}
|
|
1094
|
+
{((ites?.inputType === 20 || ites?.inputType === 30) &&
|
|
1095
|
+
ites?.choiceType === 10 && (
|
|
1096
|
+
<Select
|
|
1097
|
+
disabled={disabled}
|
|
1098
|
+
allowClear
|
|
1099
|
+
showArrow
|
|
1100
|
+
{...(ites?.inputType === 30
|
|
1101
|
+
? {
|
|
1102
|
+
mode: 'multiple',
|
|
1103
|
+
}
|
|
1104
|
+
: {})}
|
|
1105
|
+
defaultValue={ites.defaultValue}
|
|
1106
|
+
style={styleCommon}
|
|
1107
|
+
value={showValue(ites.code)}
|
|
1108
|
+
onChange={(value) => {
|
|
1109
|
+
handleEdit(ites.code, value);
|
|
1110
|
+
}}
|
|
1111
|
+
>
|
|
1112
|
+
{Object.keys(ites.enumeration).map((it) => (
|
|
1113
|
+
<Select.Option key={it} value={it}>
|
|
1114
|
+
{ites.enumeration[it]}
|
|
1115
|
+
</Select.Option>
|
|
1116
|
+
))}
|
|
1117
|
+
</Select>
|
|
1118
|
+
)) ||
|
|
1119
|
+
null}
|
|
1120
|
+
{/* 单选/多选 数据字典 */}
|
|
1121
|
+
{((ites?.inputType === 20 || ites?.inputType === 30) &&
|
|
1122
|
+
ites?.choiceType === 20 && (
|
|
1123
|
+
<InnerSelect
|
|
1124
|
+
disabled={disabled}
|
|
1125
|
+
inputType={ites?.inputType}
|
|
1126
|
+
defaultValue={ites.defaultValue}
|
|
1127
|
+
styleCommon={styleCommon}
|
|
1128
|
+
value={showValue(ites.code)}
|
|
1129
|
+
onChange={(value) => {
|
|
1130
|
+
handleEdit(ites.code, value);
|
|
1131
|
+
}}
|
|
1132
|
+
dictionaryCode={ites.dictionaryCode}
|
|
1133
|
+
/>
|
|
1134
|
+
)) ||
|
|
1135
|
+
null}
|
|
1136
|
+
{/* 单选/多选 仓库选择器(物理仓) */}
|
|
1137
|
+
{((ites?.inputType === 20 || ites?.inputType === 30) &&
|
|
1138
|
+
ites?.choiceType === 110 && (
|
|
1139
|
+
<BusinessSearchSelect
|
|
1140
|
+
selectBusinessType="physicalWarehouse"
|
|
1141
|
+
selectProps={{
|
|
1142
|
+
style: styleCommon,
|
|
1143
|
+
placeholder: '请选择物理仓',
|
|
1144
|
+
...(ites?.inputType === 30
|
|
1145
|
+
? {
|
|
1146
|
+
mode: 'multiple',
|
|
1147
|
+
maxTagCount: 1,
|
|
1148
|
+
}
|
|
1149
|
+
: {}),
|
|
1150
|
+
}}
|
|
1151
|
+
disabled={disabled}
|
|
1152
|
+
labelInValue={true}
|
|
1153
|
+
value={showValue(ites.code)}
|
|
1154
|
+
requestConfig={{
|
|
1155
|
+
mappingValueField: 'physicalWarehouseCode',
|
|
1156
|
+
filterInit: 'qp-physicalWarehouseCode-in',
|
|
1157
|
+
}}
|
|
1158
|
+
onChange={(value) => {
|
|
1159
|
+
handleEdit(ites.code, value);
|
|
1160
|
+
}}
|
|
1161
|
+
getPopupContainer={() => document.body}
|
|
1162
|
+
/>
|
|
1163
|
+
)) ||
|
|
1164
|
+
null}
|
|
1165
|
+
{/* 单选/多选 仓库选择器(逻辑仓) */}
|
|
1166
|
+
{((ites?.inputType === 20 || ites?.inputType === 30) &&
|
|
1167
|
+
ites?.choiceType === 120 && (
|
|
1168
|
+
<BusinessSearchSelect
|
|
1169
|
+
selectBusinessType="realWarehouse"
|
|
1170
|
+
selectProps={{
|
|
1171
|
+
style: styleCommon,
|
|
1172
|
+
placeholder: '请选择逻辑仓',
|
|
1173
|
+
...(ites?.inputType === 30
|
|
1174
|
+
? {
|
|
1175
|
+
mode: 'multiple',
|
|
1176
|
+
maxTagCount: 1,
|
|
1177
|
+
}
|
|
1178
|
+
: {}),
|
|
1179
|
+
}}
|
|
1180
|
+
disabled={disabled}
|
|
1181
|
+
labelInValue={true}
|
|
1182
|
+
value={showValue(ites.code)}
|
|
1183
|
+
requestConfig={{
|
|
1184
|
+
mappingValueField: 'realWarehouseCode',
|
|
1185
|
+
filterInit: 'qp-realWarehouseCode-in',
|
|
1186
|
+
}}
|
|
1187
|
+
onChange={(value) => {
|
|
1188
|
+
handleEdit(ites.code, value);
|
|
1189
|
+
}}
|
|
1190
|
+
getPopupContainer={() => document.body}
|
|
1191
|
+
/>
|
|
1192
|
+
)) ||
|
|
1193
|
+
null}
|
|
1194
|
+
{/* 单选/多选 仓库选择器(虚拟仓) */}
|
|
1195
|
+
{((ites?.inputType === 20 || ites?.inputType === 30) &&
|
|
1196
|
+
ites?.choiceType === 130 && (
|
|
1197
|
+
<BusinessSearchSelect
|
|
1198
|
+
selectBusinessType="virtualWarehouse"
|
|
1199
|
+
selectProps={{
|
|
1200
|
+
style: styleCommon,
|
|
1201
|
+
placeholder: '请选择虚拟仓',
|
|
1202
|
+
...(ites?.inputType === 30
|
|
1203
|
+
? {
|
|
1204
|
+
mode: 'multiple',
|
|
1205
|
+
maxTagCount: 1,
|
|
1206
|
+
}
|
|
1207
|
+
: {}),
|
|
1208
|
+
}}
|
|
1209
|
+
disabled={disabled}
|
|
1210
|
+
labelInValue={true}
|
|
1211
|
+
value={showValue(ites.code)}
|
|
1212
|
+
requestConfig={{
|
|
1213
|
+
mappingValueField: 'virtualWarehouseCode',
|
|
1214
|
+
filterInit: 'qp-virtualWarehouseCode-in',
|
|
1215
|
+
}}
|
|
1216
|
+
onChange={(value) => {
|
|
1217
|
+
handleEdit(ites.code, value);
|
|
1218
|
+
}}
|
|
1219
|
+
getPopupContainer={() => document.body}
|
|
1220
|
+
/>
|
|
1221
|
+
)) ||
|
|
1222
|
+
null}
|
|
1223
|
+
{/* 单选/多选 仓库选择器(渠道仓) */}
|
|
1224
|
+
{((ites?.inputType === 20 || ites?.inputType === 30) &&
|
|
1225
|
+
ites?.choiceType === 140 && (
|
|
1226
|
+
<BusinessSearchSelect
|
|
1227
|
+
selectBusinessType="channelWarehouse"
|
|
1228
|
+
selectProps={{
|
|
1229
|
+
style: styleCommon,
|
|
1230
|
+
placeholder: '请选择渠道仓',
|
|
1231
|
+
...(ites?.inputType === 30
|
|
1232
|
+
? {
|
|
1233
|
+
mode: 'multiple',
|
|
1234
|
+
maxTagCount: 1,
|
|
1235
|
+
}
|
|
1236
|
+
: {}),
|
|
1237
|
+
}}
|
|
1238
|
+
disabled={disabled}
|
|
1239
|
+
labelInValue={true}
|
|
1240
|
+
value={showValue(ites.code)}
|
|
1241
|
+
requestConfig={{
|
|
1242
|
+
mappingValueField: 'channelWarehouseCode',
|
|
1243
|
+
filterInit: 'qp-channelWarehouseCode-in',
|
|
1244
|
+
}}
|
|
1245
|
+
onChange={(value) => {
|
|
1246
|
+
handleEdit(ites.code, value);
|
|
1247
|
+
}}
|
|
1248
|
+
getPopupContainer={() => document.body}
|
|
1249
|
+
/>
|
|
1250
|
+
)) ||
|
|
1251
|
+
null}
|
|
1252
|
+
{/* 单选/多选 商品SPU选择器 */}
|
|
1253
|
+
{((ites?.inputType === 20 || ites?.inputType === 30) &&
|
|
1254
|
+
ites?.choiceType === 150 && (
|
|
1255
|
+
<BusinessSearchSelect
|
|
1256
|
+
selectBusinessType="spuCommodity"
|
|
1257
|
+
selectProps={{
|
|
1258
|
+
style: styleCommon,
|
|
1259
|
+
placeholder: '请选择SPU',
|
|
1260
|
+
...(ites?.inputType === 30
|
|
1261
|
+
? {
|
|
1262
|
+
mode: 'multiple',
|
|
1263
|
+
maxTagCount: 1,
|
|
1264
|
+
}
|
|
1265
|
+
: {}),
|
|
1266
|
+
}}
|
|
1267
|
+
disabled={disabled}
|
|
1268
|
+
labelInValue={true}
|
|
1269
|
+
value={showValue(ites.code)}
|
|
1270
|
+
requestConfig={{
|
|
1271
|
+
filterInit: 'qp-itemCode-in',
|
|
1272
|
+
}}
|
|
1273
|
+
onChange={(value) => {
|
|
1274
|
+
handleEdit(ites.code, value);
|
|
1275
|
+
}}
|
|
1276
|
+
getPopupContainer={() => document.body}
|
|
1277
|
+
/>
|
|
1278
|
+
)) ||
|
|
1279
|
+
null}
|
|
1280
|
+
{/* 单选/多选 商品SKU选择器 */}
|
|
1281
|
+
{((ites?.inputType === 20 || ites?.inputType === 30) &&
|
|
1282
|
+
ites?.choiceType === 160 && (
|
|
1283
|
+
<BusinessSearchSelect
|
|
1284
|
+
selectBusinessType="skuCommodity"
|
|
1285
|
+
selectProps={{
|
|
1286
|
+
style: styleCommon,
|
|
1287
|
+
placeholder: '请选择商品',
|
|
1288
|
+
...(ites?.inputType === 30
|
|
1289
|
+
? {
|
|
1290
|
+
mode: 'multiple',
|
|
1291
|
+
maxTagCount: 1,
|
|
1292
|
+
}
|
|
1293
|
+
: {}),
|
|
1294
|
+
}}
|
|
1295
|
+
disabled={disabled}
|
|
1296
|
+
labelInValue={true}
|
|
1297
|
+
value={showValue(ites.code)}
|
|
1298
|
+
requestConfig={{
|
|
1299
|
+
filterInit: 'qp-skuCode-in',
|
|
1300
|
+
}}
|
|
1301
|
+
onChange={(value) => {
|
|
1302
|
+
handleEdit(ites.code, value);
|
|
1303
|
+
}}
|
|
1304
|
+
getPopupContainer={() => document.body}
|
|
1305
|
+
/>
|
|
1306
|
+
)) ||
|
|
1307
|
+
null}
|
|
1308
|
+
{/* 单选/多选 省市区 */}
|
|
1309
|
+
{((ites?.inputType === 20 || ites?.inputType === 30) &&
|
|
1310
|
+
ites?.choiceType === 190 && (
|
|
1311
|
+
<BsCascader
|
|
1312
|
+
disabled={disabled}
|
|
1313
|
+
isAll={true}
|
|
1314
|
+
needNameAndCode={true}
|
|
1315
|
+
notChangeOnSelect={true}
|
|
1316
|
+
initRequestSource={async () => {
|
|
1317
|
+
return await request({
|
|
1318
|
+
url: '/basic/bscArea/getBscAreaList?qp-level-eq=1&qp-pid-eq=100000',
|
|
1319
|
+
method: 'get',
|
|
1320
|
+
converter: ({ data }) => {
|
|
1321
|
+
const handleData =
|
|
1322
|
+
data && data[0]
|
|
1323
|
+
? data?.map((item) => {
|
|
1324
|
+
return {
|
|
1325
|
+
text: item.name,
|
|
1326
|
+
value: item.id,
|
|
1327
|
+
level: item.level,
|
|
1328
|
+
id: item.id,
|
|
1329
|
+
};
|
|
1330
|
+
})
|
|
1331
|
+
: [];
|
|
1332
|
+
return handleData;
|
|
1333
|
+
},
|
|
1334
|
+
});
|
|
1335
|
+
}}
|
|
1336
|
+
value={showValue(ites.code)}
|
|
1337
|
+
onChange={(value) => {
|
|
1338
|
+
handleEdit(ites.code, value);
|
|
1339
|
+
}}
|
|
1340
|
+
getPopupContainer={() => document.body}
|
|
1341
|
+
/>
|
|
1342
|
+
)) ||
|
|
1343
|
+
null}
|
|
1344
|
+
{/* 单选/多选 行政组织选择器 */}
|
|
1345
|
+
{((ites?.inputType === 20 || ites?.inputType === 30) &&
|
|
1346
|
+
ites?.choiceType === 210 && (
|
|
1347
|
+
<BusinessTreeSearchSelect
|
|
1348
|
+
disabled={disabled}
|
|
1349
|
+
treeCheckable={ites?.inputType === 30}
|
|
1350
|
+
businessType="department"
|
|
1351
|
+
labelInValue={true}
|
|
1352
|
+
value={showValue(ites.code)}
|
|
1353
|
+
style={styleCommon}
|
|
1354
|
+
onChange={(value) => {
|
|
1355
|
+
handleEdit(ites.code, value);
|
|
1356
|
+
}}
|
|
1357
|
+
getPopupContainer={() => document.body}
|
|
1358
|
+
/>
|
|
1359
|
+
)) ||
|
|
1360
|
+
null}
|
|
1361
|
+
{/* 单选/多选 采购组织选择器 */}
|
|
1362
|
+
{((ites?.inputType === 20 || ites?.inputType === 30) &&
|
|
1363
|
+
ites?.choiceType === 220 && (
|
|
1364
|
+
<BusinessTreeSearchSelect
|
|
1365
|
+
disabled={disabled}
|
|
1366
|
+
treeCheckable={ites?.inputType === 30}
|
|
1367
|
+
businessType="purchase-organization"
|
|
1368
|
+
labelInValue={true}
|
|
1369
|
+
value={showValue(ites.code)}
|
|
1370
|
+
style={styleCommon}
|
|
1371
|
+
onChange={(value) => {
|
|
1372
|
+
handleEdit(ites.code, value);
|
|
1373
|
+
}}
|
|
1374
|
+
getPopupContainer={() => document.body}
|
|
1375
|
+
/>
|
|
1376
|
+
)) ||
|
|
1377
|
+
null}
|
|
1378
|
+
{/* 单选/多选 销售组织选择器 */}
|
|
1379
|
+
{((ites?.inputType === 20 || ites?.inputType === 30) &&
|
|
1380
|
+
ites?.choiceType === 230 && (
|
|
1381
|
+
<BusinessTreeSearchSelect
|
|
1382
|
+
disabled={disabled}
|
|
1383
|
+
treeCheckable={ites?.inputType === 30}
|
|
1384
|
+
businessType="sales-organization"
|
|
1385
|
+
labelInValue={true}
|
|
1386
|
+
value={showValue(ites.code)}
|
|
1387
|
+
style={styleCommon}
|
|
1388
|
+
onChange={(value) => {
|
|
1389
|
+
handleEdit(ites.code, value);
|
|
1390
|
+
}}
|
|
1391
|
+
getPopupContainer={() => document.body}
|
|
1392
|
+
/>
|
|
1393
|
+
)) ||
|
|
1394
|
+
null}
|
|
1395
|
+
{/* 单选/多选 供应商选择器 */}
|
|
1396
|
+
{((ites?.inputType === 20 || ites?.inputType === 30) &&
|
|
1397
|
+
ites?.choiceType === 240 && (
|
|
1398
|
+
<BusinessSearchSelect
|
|
1399
|
+
selectBusinessType="supplier2"
|
|
1400
|
+
selectProps={{
|
|
1401
|
+
style: styleCommon,
|
|
1402
|
+
placeholder: '请选择供应商',
|
|
1403
|
+
...(ites?.inputType === 30
|
|
1404
|
+
? {
|
|
1405
|
+
mode: 'multiple',
|
|
1406
|
+
maxTagCount: 1,
|
|
1407
|
+
}
|
|
1408
|
+
: {}),
|
|
1409
|
+
}}
|
|
1410
|
+
disabled={disabled}
|
|
1411
|
+
labelInValue={true}
|
|
1412
|
+
value={showValue(ites.code)}
|
|
1413
|
+
requestConfig={{
|
|
1414
|
+
filterInit: 'qp-code-in',
|
|
1415
|
+
}}
|
|
1416
|
+
onChange={(value) => {
|
|
1417
|
+
handleEdit(ites.code, value);
|
|
1418
|
+
}}
|
|
1419
|
+
getPopupContainer={() => document.body}
|
|
1420
|
+
/>
|
|
1421
|
+
)) ||
|
|
1422
|
+
null}
|
|
1423
|
+
{/* 单选/多选 客户选择器 */}
|
|
1424
|
+
{((ites?.inputType === 20 || ites?.inputType === 30) &&
|
|
1425
|
+
ites?.choiceType === 250 && (
|
|
1426
|
+
<BusinessSearchSelect
|
|
1427
|
+
selectBusinessType="customer2"
|
|
1428
|
+
selectProps={{
|
|
1429
|
+
style: styleCommon,
|
|
1430
|
+
placeholder: '请选择客户',
|
|
1431
|
+
...(ites?.inputType === 30
|
|
1432
|
+
? {
|
|
1433
|
+
mode: 'multiple',
|
|
1434
|
+
maxTagCount: 1,
|
|
1435
|
+
}
|
|
1436
|
+
: {}),
|
|
1437
|
+
}}
|
|
1438
|
+
disabled={disabled}
|
|
1439
|
+
labelInValue={true}
|
|
1440
|
+
value={showValue(ites.code)}
|
|
1441
|
+
requestConfig={{
|
|
1442
|
+
filterInit: 'qp-code-in',
|
|
1443
|
+
}}
|
|
1444
|
+
onChange={(value) => {
|
|
1445
|
+
handleEdit(ites.code, value);
|
|
1446
|
+
}}
|
|
1447
|
+
getPopupContainer={() => document.body}
|
|
1448
|
+
/>
|
|
1449
|
+
)) ||
|
|
1450
|
+
null}
|
|
1451
|
+
{/* 单选/多选 店铺选择器 */}
|
|
1452
|
+
{((ites?.inputType === 20 || ites?.inputType === 30) &&
|
|
1453
|
+
ites?.choiceType === 260 && (
|
|
1454
|
+
<BusinessSearchSelect
|
|
1455
|
+
selectBusinessType="shopFile2"
|
|
1456
|
+
selectProps={{
|
|
1457
|
+
style: styleCommon,
|
|
1458
|
+
placeholder: '请选择店铺',
|
|
1459
|
+
...(ites?.inputType === 30
|
|
1460
|
+
? {
|
|
1461
|
+
mode: 'multiple',
|
|
1462
|
+
maxTagCount: 1,
|
|
1463
|
+
}
|
|
1464
|
+
: {}),
|
|
1465
|
+
}}
|
|
1466
|
+
disabled={disabled}
|
|
1467
|
+
labelInValue={true}
|
|
1468
|
+
value={showValue(ites.code)}
|
|
1469
|
+
requestConfig={{
|
|
1470
|
+
filterInit: 'qp-code-in',
|
|
1471
|
+
}}
|
|
1472
|
+
onChange={(value) => {
|
|
1473
|
+
handleEdit(ites.code, value);
|
|
1474
|
+
}}
|
|
1475
|
+
getPopupContainer={() => document.body}
|
|
1476
|
+
/>
|
|
1477
|
+
)) ||
|
|
1478
|
+
null}
|
|
1479
|
+
{/* 单选/多选 员工选择器 */}
|
|
1480
|
+
{((ites?.inputType === 20 || ites?.inputType === 30) &&
|
|
1481
|
+
ites?.choiceType === 270 && (
|
|
1482
|
+
<BusinessSearchSelect
|
|
1483
|
+
selectBusinessType="employee2"
|
|
1484
|
+
selectProps={{
|
|
1485
|
+
style: styleCommon,
|
|
1486
|
+
placeholder: '请选择员工',
|
|
1487
|
+
...(ites?.inputType === 30
|
|
1488
|
+
? {
|
|
1489
|
+
mode: 'multiple',
|
|
1490
|
+
maxTagCount: 1,
|
|
1491
|
+
}
|
|
1492
|
+
: {}),
|
|
1493
|
+
}}
|
|
1494
|
+
disabled={disabled}
|
|
1495
|
+
labelInValue={true}
|
|
1496
|
+
value={showValue(ites.code)}
|
|
1497
|
+
requestConfig={{
|
|
1498
|
+
filterInit: 'qp-id-in',
|
|
1499
|
+
}}
|
|
1500
|
+
onChange={(value) => {
|
|
1501
|
+
handleEdit(ites.code, value);
|
|
1502
|
+
}}
|
|
1503
|
+
getPopupContainer={() => document.body}
|
|
1504
|
+
/>
|
|
1505
|
+
)) ||
|
|
1506
|
+
null}
|
|
1507
|
+
{/* 单选/多选 库存组织选择器 */}
|
|
1508
|
+
{((ites?.inputType === 20 || ites?.inputType === 30) &&
|
|
1509
|
+
ites?.choiceType === 280 && (
|
|
1510
|
+
<BusinessTreeSearchSelect
|
|
1511
|
+
disabled={disabled}
|
|
1512
|
+
treeCheckable={ites?.inputType === 30}
|
|
1513
|
+
businessType="stock-organization"
|
|
1514
|
+
labelInValue={true}
|
|
1515
|
+
value={showValue(ites.code)}
|
|
1516
|
+
style={styleCommon}
|
|
1517
|
+
onChange={(value) => {
|
|
1518
|
+
handleEdit(ites.code, value);
|
|
1519
|
+
}}
|
|
1520
|
+
getPopupContainer={() => document.body}
|
|
1521
|
+
/>
|
|
1522
|
+
)) ||
|
|
1523
|
+
null}
|
|
1524
|
+
{/* 单选/多选 结算组织选择器 */}
|
|
1525
|
+
{((ites?.inputType === 20 || ites?.inputType === 30) &&
|
|
1526
|
+
ites?.choiceType === 290 && (
|
|
1527
|
+
<BusinessTreeSearchSelect
|
|
1528
|
+
disabled={disabled}
|
|
1529
|
+
treeCheckable={ites?.inputType === 30}
|
|
1530
|
+
businessType="settle-organization"
|
|
1531
|
+
labelInValue={true}
|
|
1532
|
+
value={showValue(ites.code)}
|
|
1533
|
+
style={styleCommon}
|
|
1534
|
+
onChange={(value) => {
|
|
1535
|
+
handleEdit(ites.code, value);
|
|
1536
|
+
}}
|
|
1537
|
+
getPopupContainer={() => document.body}
|
|
1538
|
+
/>
|
|
1539
|
+
)) ||
|
|
1540
|
+
null}
|
|
1541
|
+
{/* 单选/多选 配送方式选择器 */}
|
|
1542
|
+
{((ites?.inputType === 20 || ites?.inputType === 30) &&
|
|
1543
|
+
ites?.choiceType === 310 && (
|
|
1544
|
+
<BusinessSearchSelect
|
|
1545
|
+
selectBusinessType="deliveryMode"
|
|
1546
|
+
selectProps={{
|
|
1547
|
+
style: styleCommon,
|
|
1548
|
+
placeholder: '请选择配送方式',
|
|
1549
|
+
...(ites?.inputType === 30
|
|
1550
|
+
? {
|
|
1551
|
+
mode: 'multiple',
|
|
1552
|
+
maxTagCount: 1,
|
|
1553
|
+
}
|
|
1554
|
+
: {}),
|
|
1555
|
+
}}
|
|
1556
|
+
disabled={disabled}
|
|
1557
|
+
labelInValue={true}
|
|
1558
|
+
value={showValue(ites.code)}
|
|
1559
|
+
requestConfig={{
|
|
1560
|
+
filterInit: 'qp-code-in',
|
|
1561
|
+
}}
|
|
1562
|
+
onChange={(value) => {
|
|
1563
|
+
handleEdit(ites.code, value);
|
|
1564
|
+
}}
|
|
1565
|
+
getPopupContainer={() => document.body}
|
|
1566
|
+
/>
|
|
1567
|
+
)) ||
|
|
1568
|
+
null}
|
|
1569
|
+
{/* 单选/多选 角色选择器 */}
|
|
1570
|
+
{((ites?.inputType === 20 || ites?.inputType === 30) &&
|
|
1571
|
+
ites?.choiceType === 360 && (
|
|
1572
|
+
<BusinessSearchSelect
|
|
1573
|
+
selectBusinessType="role"
|
|
1574
|
+
selectProps={{
|
|
1575
|
+
style: styleCommon,
|
|
1576
|
+
placeholder: '请选择角色',
|
|
1577
|
+
...(ites?.inputType === 30
|
|
1578
|
+
? {
|
|
1579
|
+
mode: 'multiple',
|
|
1580
|
+
maxTagCount: 1,
|
|
1581
|
+
}
|
|
1582
|
+
: {}),
|
|
1583
|
+
}}
|
|
1584
|
+
disabled={disabled}
|
|
1585
|
+
labelInValue={true}
|
|
1586
|
+
value={showValue(ites.code)}
|
|
1587
|
+
requestConfig={{
|
|
1588
|
+
filterInit: 'qp-code-in',
|
|
1589
|
+
}}
|
|
1590
|
+
onChange={(value) => {
|
|
1591
|
+
handleEdit(ites.code, value);
|
|
1592
|
+
}}
|
|
1593
|
+
getPopupContainer={() => document.body}
|
|
1594
|
+
/>
|
|
1595
|
+
)) ||
|
|
1596
|
+
null}
|
|
1597
|
+
{/* 表达式 */}
|
|
1598
|
+
{ites?.inputType === 40 && (
|
|
1599
|
+
<div style={{ display: 'flex' }}>
|
|
1600
|
+
<Formula
|
|
1601
|
+
disabled={disabled}
|
|
1602
|
+
key={showValue(ites.code)}
|
|
1603
|
+
setValue={(val, formulaName) => {
|
|
1604
|
+
console.log(val, 'val');
|
|
1605
|
+
const value = val.map((item) => {
|
|
1606
|
+
return item.value.replace(
|
|
1607
|
+
/[a-zA-Z_]+\.\w+/g,
|
|
1608
|
+
(i) => '{' + i + '}',
|
|
1609
|
+
);
|
|
1610
|
+
});
|
|
1611
|
+
handleEdit(ites.code, value.join(''));
|
|
1612
|
+
handleEdit({
|
|
1613
|
+
inputType: 40,
|
|
1614
|
+
formulaName,
|
|
1615
|
+
});
|
|
1616
|
+
}}
|
|
1617
|
+
record={{ expression: showValue(ites.code) }}
|
|
1618
|
+
sourceData={fieldListGroup}
|
|
1619
|
+
/>
|
|
1620
|
+
</div>
|
|
1621
|
+
)}
|
|
1622
|
+
</>
|
|
1623
|
+
);
|
|
1624
|
+
};
|
|
985
1625
|
|
|
986
1626
|
renderFormCompItem = (
|
|
987
1627
|
config,
|
|
@@ -1007,7 +1647,12 @@ class RuleObjectComponent extends Component {
|
|
|
1007
1647
|
</div>
|
|
1008
1648
|
)) ||
|
|
1009
1649
|
null}
|
|
1010
|
-
|
|
1650
|
+
{this.renderCompItem(
|
|
1651
|
+
config,
|
|
1652
|
+
(a, b, c = parentItem, d = config) => showValue(a, b, c, d),
|
|
1653
|
+
(a, b, c = parentItem, d = config) => handleEdit(a, b, c, d),
|
|
1654
|
+
disabled
|
|
1655
|
+
)}
|
|
1011
1656
|
{(config?.rightText && (
|
|
1012
1657
|
<div style={{ flex: 'none', marginLeft: 10 }}>{config.rightText}</div>
|
|
1013
1658
|
)) ||
|