@kmkf-fe-packages/services-components 1.19.4-beta.1 → 1.19.4
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/esm/components/BS/BsSystemOrder/index.js +22 -93
- package/dist/esm/components/Common/index.js +2 -188
- package/dist/esm/components/CommonHeaderGood/index.js +0 -161
- package/dist/esm/components/Picture/index.d.ts +5 -5
- package/dist/esm/components/Picture/index.js +20 -20
- package/dist/esm/factory.d.ts +2 -2
- package/dist/esm/factory.js +1 -4
- package/dist/esm/index.d.ts +0 -1
- package/dist/esm/index.js +0 -1
- package/package.json +4 -4
- package/dist/esm/components/BsE3/BsGoods/index.d.ts +0 -33
- package/dist/esm/components/BsE3/BsGoods/index.js +0 -123
|
@@ -20,104 +20,27 @@ var typeMap = {
|
|
|
20
20
|
BS_SYSTEM_ORDER: {
|
|
21
21
|
key: 'bsSystemShowOrder',
|
|
22
22
|
name: 'bs',
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
dataIndex: "billType",
|
|
27
|
-
width: 150
|
|
28
|
-
}, {
|
|
29
|
-
title: "系统订单号",
|
|
30
|
-
dataIndex: "billNo",
|
|
31
|
-
width: 150
|
|
32
|
-
}, {
|
|
33
|
-
title: "标签",
|
|
34
|
-
dataIndex: "billTag",
|
|
35
|
-
width: 150
|
|
36
|
-
}]
|
|
23
|
+
typeName: '单据类型',
|
|
24
|
+
tagName: '标签',
|
|
25
|
+
selectId: 'bsSystemSelectIds'
|
|
37
26
|
},
|
|
38
27
|
WLN_SYSTEM_ORDER: {
|
|
39
28
|
key: 'wlnSystemShowOrder',
|
|
40
29
|
name: '万里牛',
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
dataIndex: "billType",
|
|
45
|
-
width: 150
|
|
46
|
-
}, {
|
|
47
|
-
title: "系统订单号",
|
|
48
|
-
dataIndex: "billNo",
|
|
49
|
-
width: 150
|
|
50
|
-
}, {
|
|
51
|
-
title: "标记",
|
|
52
|
-
dataIndex: "billTag",
|
|
53
|
-
width: 150
|
|
54
|
-
}]
|
|
30
|
+
typeName: '订单类型',
|
|
31
|
+
tagName: '标记',
|
|
32
|
+
selectId: 'wlnSystemSelectIds'
|
|
55
33
|
},
|
|
56
34
|
WDT_SYSTEM_ORDER: {
|
|
57
35
|
key: "wdtSystemShowOrder",
|
|
58
36
|
name: "旺店通",
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
dataIndex: "billType",
|
|
63
|
-
width: 150
|
|
64
|
-
}, {
|
|
65
|
-
title: "系统订单号",
|
|
66
|
-
dataIndex: "billNo",
|
|
67
|
-
width: 150
|
|
68
|
-
}, {
|
|
69
|
-
title: "订单标签",
|
|
70
|
-
dataIndex: "billTag",
|
|
71
|
-
width: 150
|
|
72
|
-
}]
|
|
73
|
-
},
|
|
74
|
-
BS_E3_SYSTEM_ORDER: {
|
|
75
|
-
key: "bsE3SystemShowOrder",
|
|
76
|
-
name: "百胜",
|
|
77
|
-
selectId: "bsE3SystemSelectIds",
|
|
78
|
-
columns: [{
|
|
79
|
-
title: "系统订单号",
|
|
80
|
-
dataIndex: "orderSn",
|
|
81
|
-
width: 150
|
|
82
|
-
}, {
|
|
83
|
-
title: "订单状态",
|
|
84
|
-
dataIndex: "orderStatus",
|
|
85
|
-
width: 100
|
|
86
|
-
}, {
|
|
87
|
-
title: "是否被拆分",
|
|
88
|
-
dataIndex: "isSplit",
|
|
89
|
-
width: 100
|
|
90
|
-
}, {
|
|
91
|
-
title: "是否拆分子单",
|
|
92
|
-
dataIndex: "isSplitNew",
|
|
93
|
-
width: 100
|
|
94
|
-
}, {
|
|
95
|
-
title: "是否被合并",
|
|
96
|
-
dataIndex: "isCombine",
|
|
97
|
-
width: 100
|
|
98
|
-
}, {
|
|
99
|
-
title: "是否合并新单",
|
|
100
|
-
dataIndex: "isCombineNew",
|
|
101
|
-
width: 100
|
|
102
|
-
}, {
|
|
103
|
-
title: "是否复制单",
|
|
104
|
-
dataIndex: "isCopy",
|
|
105
|
-
width: 100
|
|
106
|
-
}, {
|
|
107
|
-
title: "是否换货单",
|
|
108
|
-
dataIndex: "isExchangeOrder",
|
|
109
|
-
width: 100
|
|
110
|
-
}, {
|
|
111
|
-
title: "订单备注",
|
|
112
|
-
dataIndex: "orderMsg",
|
|
113
|
-
width: 150
|
|
114
|
-
}]
|
|
37
|
+
typeName: "订单类型",
|
|
38
|
+
tagName: "订单标签",
|
|
39
|
+
selectId: "wdtSystemSelectIds"
|
|
115
40
|
}
|
|
116
41
|
};
|
|
117
42
|
var BsSystemOrder = /*#__PURE__*/_createClass(function BsSystemOrder(options) {
|
|
118
43
|
var _this = this,
|
|
119
|
-
_typeMap$options$type,
|
|
120
|
-
_typeMap$options$type2,
|
|
121
44
|
_this$componentConfig3;
|
|
122
45
|
_classCallCheck(this, BsSystemOrder);
|
|
123
46
|
_defineProperty(this, "name", void 0);
|
|
@@ -199,13 +122,19 @@ var BsSystemOrder = /*#__PURE__*/_createClass(function BsSystemOrder(options) {
|
|
|
199
122
|
this.effects = options === null || options === void 0 ? void 0 : options.effects;
|
|
200
123
|
this.isCombinationComponent = true;
|
|
201
124
|
this.canSort = false;
|
|
202
|
-
this.children =
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
125
|
+
this.children = [new BsHeaderChild(_objectSpread(_objectSpread({}, options), {}, {
|
|
126
|
+
name: typeMap[options.type].typeName,
|
|
127
|
+
id: "".concat(options.id, "_").concat(typeMap[options.type].key, "_billType"),
|
|
128
|
+
width: 150
|
|
129
|
+
})), new BsHeaderChild(_objectSpread(_objectSpread({}, options), {}, {
|
|
130
|
+
name: '系统订单号',
|
|
131
|
+
id: "".concat(options.id, "_").concat(typeMap[options.type].key, "_billNo"),
|
|
132
|
+
width: 150
|
|
133
|
+
})), new BsHeaderChild(_objectSpread(_objectSpread({}, options), {}, {
|
|
134
|
+
name: typeMap[options.type].tagName,
|
|
135
|
+
id: "".concat(options.id, "_").concat(typeMap[options.type].key, "_billTag"),
|
|
136
|
+
width: 150
|
|
137
|
+
}))];
|
|
209
138
|
this.componentConfig = options === null || options === void 0 ? void 0 : options.componentConfig;
|
|
210
139
|
this.rules = this !== null && this !== void 0 && (_this$componentConfig3 = this.componentConfig) !== null && _this$componentConfig3 !== void 0 && _this$componentConfig3.required ? [{
|
|
211
140
|
required: true,
|
|
@@ -749,149 +749,6 @@ export var BsGoodsTable = function BsGoodsTable(_ref11) {
|
|
|
749
749
|
}];
|
|
750
750
|
}
|
|
751
751
|
break;
|
|
752
|
-
case 'BS_E3_GOODS':
|
|
753
|
-
{
|
|
754
|
-
columns = [{
|
|
755
|
-
dataIndex: 'sku',
|
|
756
|
-
title: "SKU",
|
|
757
|
-
align: 'center',
|
|
758
|
-
ellipsis: true,
|
|
759
|
-
width: 150
|
|
760
|
-
}, {
|
|
761
|
-
dataIndex: 'skuId',
|
|
762
|
-
title: "SKU ID",
|
|
763
|
-
align: 'center',
|
|
764
|
-
ellipsis: true,
|
|
765
|
-
width: 150
|
|
766
|
-
}, {
|
|
767
|
-
dataIndex: 'goodsName',
|
|
768
|
-
title: "\u5546\u54C1\u540D\u79F0",
|
|
769
|
-
align: 'center',
|
|
770
|
-
ellipsis: true,
|
|
771
|
-
width: 150
|
|
772
|
-
}, {
|
|
773
|
-
dataIndex: 'goodsShortName',
|
|
774
|
-
title: "\u5546\u54C1\u7B80\u79F0",
|
|
775
|
-
align: 'center',
|
|
776
|
-
ellipsis: true,
|
|
777
|
-
width: 100
|
|
778
|
-
}, {
|
|
779
|
-
dataIndex: 'picPath',
|
|
780
|
-
title: "\u5546\u54C1\u56FE\u7247",
|
|
781
|
-
align: 'center',
|
|
782
|
-
ellipsis: true,
|
|
783
|
-
width: 100,
|
|
784
|
-
render: function render(val) {
|
|
785
|
-
return /*#__PURE__*/React.createElement(Image, {
|
|
786
|
-
width: 60,
|
|
787
|
-
src: val
|
|
788
|
-
});
|
|
789
|
-
}
|
|
790
|
-
}, {
|
|
791
|
-
dataIndex: 'goodsSn',
|
|
792
|
-
title: "\u8D27\u53F7",
|
|
793
|
-
align: 'center',
|
|
794
|
-
ellipsis: true,
|
|
795
|
-
width: 150
|
|
796
|
-
}, {
|
|
797
|
-
dataIndex: 'goodsId',
|
|
798
|
-
title: "\u8D27\u53F7ID",
|
|
799
|
-
align: 'center',
|
|
800
|
-
ellipsis: true,
|
|
801
|
-
width: 150
|
|
802
|
-
}, {
|
|
803
|
-
dataIndex: 'colorName',
|
|
804
|
-
title: "\u989C\u8272\u540D\u79F0",
|
|
805
|
-
align: 'center',
|
|
806
|
-
ellipsis: true,
|
|
807
|
-
width: 100
|
|
808
|
-
}, {
|
|
809
|
-
dataIndex: 'colorCode',
|
|
810
|
-
title: "\u989C\u8272\u4EE3\u7801",
|
|
811
|
-
align: 'center',
|
|
812
|
-
ellipsis: true,
|
|
813
|
-
width: 150
|
|
814
|
-
}, {
|
|
815
|
-
dataIndex: 'sizeName',
|
|
816
|
-
title: "\u5C3A\u7801\u540D\u79F0",
|
|
817
|
-
align: 'center',
|
|
818
|
-
ellipsis: true,
|
|
819
|
-
width: 100
|
|
820
|
-
}, {
|
|
821
|
-
dataIndex: 'sizeCode',
|
|
822
|
-
title: "\u5C3A\u7801\u4EE3\u7801",
|
|
823
|
-
align: 'center',
|
|
824
|
-
ellipsis: true,
|
|
825
|
-
width: 100
|
|
826
|
-
}, {
|
|
827
|
-
dataIndex: 'brandName',
|
|
828
|
-
title: "\u54C1\u724C\u540D\u79F0",
|
|
829
|
-
align: 'center',
|
|
830
|
-
ellipsis: true,
|
|
831
|
-
width: 150
|
|
832
|
-
}, {
|
|
833
|
-
dataIndex: 'goodsNumber',
|
|
834
|
-
title: "\u5546\u54C1\u6570\u91CF",
|
|
835
|
-
align: 'center',
|
|
836
|
-
ellipsis: true,
|
|
837
|
-
width: 100
|
|
838
|
-
}, {
|
|
839
|
-
dataIndex: 'goodsPrice',
|
|
840
|
-
title: "\u5546\u54C1\u5355\u4EF7",
|
|
841
|
-
align: 'center',
|
|
842
|
-
ellipsis: true,
|
|
843
|
-
width: 120
|
|
844
|
-
}, {
|
|
845
|
-
dataIndex: 'shopPrice',
|
|
846
|
-
title: "\u5546\u54C1\u7F51\u5E97\u552E\u4EF7",
|
|
847
|
-
align: 'center',
|
|
848
|
-
ellipsis: true,
|
|
849
|
-
width: 120
|
|
850
|
-
}, {
|
|
851
|
-
dataIndex: 'sharePrice',
|
|
852
|
-
title: "\u5206\u644A\u4EF7",
|
|
853
|
-
align: 'center',
|
|
854
|
-
ellipsis: true,
|
|
855
|
-
width: 120
|
|
856
|
-
}, {
|
|
857
|
-
dataIndex: 'sharePayment',
|
|
858
|
-
title: "\u5206\u644A\u5B9E\u4ED8\u91D1\u989D",
|
|
859
|
-
align: 'center',
|
|
860
|
-
ellipsis: true,
|
|
861
|
-
width: 120
|
|
862
|
-
}, {
|
|
863
|
-
dataIndex: 'payment',
|
|
864
|
-
title: "\u5B9E\u4ED8\u91D1\u989D",
|
|
865
|
-
align: 'center',
|
|
866
|
-
ellipsis: true,
|
|
867
|
-
width: 120
|
|
868
|
-
}, {
|
|
869
|
-
dataIndex: 'tcSku',
|
|
870
|
-
title: "\u5957\u9910SKU",
|
|
871
|
-
align: 'center',
|
|
872
|
-
ellipsis: true,
|
|
873
|
-
width: 150
|
|
874
|
-
}, {
|
|
875
|
-
dataIndex: 'tcGoodsNumber',
|
|
876
|
-
title: "\u5957\u9910\u5957\u6570",
|
|
877
|
-
align: 'center',
|
|
878
|
-
ellipsis: true,
|
|
879
|
-
width: 100
|
|
880
|
-
}, {
|
|
881
|
-
dataIndex: 'taoCanSingleSl',
|
|
882
|
-
title: "\u5355\u4E2A\u5957\u9910\u6570\u91CF",
|
|
883
|
-
align: 'center',
|
|
884
|
-
ellipsis: true,
|
|
885
|
-
width: 100
|
|
886
|
-
}, {
|
|
887
|
-
dataIndex: 'isGift',
|
|
888
|
-
title: "\u662F\u5426\u8D60\u54C1",
|
|
889
|
-
align: 'center',
|
|
890
|
-
ellipsis: true,
|
|
891
|
-
width: 100
|
|
892
|
-
}];
|
|
893
|
-
}
|
|
894
|
-
break;
|
|
895
752
|
default:
|
|
896
753
|
columns = [{
|
|
897
754
|
dataIndex: 'mark',
|
|
@@ -1149,55 +1006,12 @@ export var BsSystemOrderTable = function BsSystemOrderTable(_ref13) {
|
|
|
1149
1006
|
}, {
|
|
1150
1007
|
dataIndex: 'billTag',
|
|
1151
1008
|
title: '订单标签'
|
|
1152
|
-
}],
|
|
1153
|
-
BS_E3_SYSTEM_ORDER: [{
|
|
1154
|
-
title: "系统订单号",
|
|
1155
|
-
dataIndex: "orderSn",
|
|
1156
|
-
width: 150
|
|
1157
|
-
}, {
|
|
1158
|
-
title: "订单状态",
|
|
1159
|
-
dataIndex: "orderStatus",
|
|
1160
|
-
width: 100
|
|
1161
|
-
}, {
|
|
1162
|
-
title: "是否被拆分",
|
|
1163
|
-
dataIndex: "isSplit",
|
|
1164
|
-
width: 100
|
|
1165
|
-
}, {
|
|
1166
|
-
title: "是否拆分子单",
|
|
1167
|
-
dataIndex: "isSplitNew",
|
|
1168
|
-
width: 100
|
|
1169
|
-
}, {
|
|
1170
|
-
title: "是否被合并",
|
|
1171
|
-
dataIndex: "isCombine",
|
|
1172
|
-
width: 100
|
|
1173
|
-
}, {
|
|
1174
|
-
title: "是否合并新单",
|
|
1175
|
-
dataIndex: "isCombineNew",
|
|
1176
|
-
width: 100
|
|
1177
|
-
}, {
|
|
1178
|
-
title: "是否复制单",
|
|
1179
|
-
dataIndex: "isCopy",
|
|
1180
|
-
width: 100
|
|
1181
|
-
}, {
|
|
1182
|
-
title: "是否换货单",
|
|
1183
|
-
dataIndex: "isExchangeOrder",
|
|
1184
|
-
width: 100
|
|
1185
|
-
}, {
|
|
1186
|
-
title: "订单备注",
|
|
1187
|
-
dataIndex: "orderMsg",
|
|
1188
|
-
width: 150
|
|
1189
1009
|
}]
|
|
1190
1010
|
};
|
|
1191
|
-
var rowKeyMap = {
|
|
1192
|
-
BS_SYSTEM_ORDER: 'billNo',
|
|
1193
|
-
WLN_SYSTEM_ORDER: 'billNo',
|
|
1194
|
-
WDT_SYSTEM_ORDER: 'billNo',
|
|
1195
|
-
BS_E3_SYSTEM_ORDER: 'orderSn'
|
|
1196
|
-
};
|
|
1197
1011
|
var rowSelection = {
|
|
1198
1012
|
selectedRowKeys: (value === null || value === void 0 ? void 0 : value.selectIds) || ((value === null || value === void 0 ? void 0 : value.showOrderInfo) || []).reduce(function (prv, next) {
|
|
1199
1013
|
if (next.select) {
|
|
1200
|
-
prv.push(next
|
|
1014
|
+
prv.push(next.billNo);
|
|
1201
1015
|
}
|
|
1202
1016
|
return prv;
|
|
1203
1017
|
}, []),
|
|
@@ -1213,7 +1027,7 @@ export var BsSystemOrderTable = function BsSystemOrderTable(_ref13) {
|
|
|
1213
1027
|
dataSource: (value === null || value === void 0 ? void 0 : value.showOrderInfo) || [],
|
|
1214
1028
|
columns: columnMap[type] || [],
|
|
1215
1029
|
rowSelection: rowSelection,
|
|
1216
|
-
rowKey:
|
|
1030
|
+
rowKey: 'billNo',
|
|
1217
1031
|
size: "small",
|
|
1218
1032
|
pagination: false,
|
|
1219
1033
|
scroll: {
|
|
@@ -286,167 +286,6 @@ var GoodHeaderMap = {
|
|
|
286
286
|
giftType: "赠品方式"
|
|
287
287
|
},
|
|
288
288
|
moneyKey: "exchangePrice"
|
|
289
|
-
},
|
|
290
|
-
"BS_E3_GOODS": {
|
|
291
|
-
headerMap: {
|
|
292
|
-
sku: {
|
|
293
|
-
component: BsHeaderChild,
|
|
294
|
-
name: "SKU",
|
|
295
|
-
key: "sku",
|
|
296
|
-
width: 140
|
|
297
|
-
},
|
|
298
|
-
skuId: {
|
|
299
|
-
component: BsHeaderChild,
|
|
300
|
-
name: "SKU ID",
|
|
301
|
-
key: "skuId",
|
|
302
|
-
width: 140
|
|
303
|
-
},
|
|
304
|
-
goodsName: {
|
|
305
|
-
component: BsHeaderChild,
|
|
306
|
-
name: "商品名称",
|
|
307
|
-
key: "goodsName",
|
|
308
|
-
width: 100
|
|
309
|
-
},
|
|
310
|
-
goodsShortName: {
|
|
311
|
-
component: BsHeaderChild,
|
|
312
|
-
name: "商品简称",
|
|
313
|
-
key: "goodsShortName",
|
|
314
|
-
width: 70
|
|
315
|
-
},
|
|
316
|
-
picPath: {
|
|
317
|
-
component: BsHeaderPic,
|
|
318
|
-
name: "商品图片",
|
|
319
|
-
key: "picPath",
|
|
320
|
-
width: 80
|
|
321
|
-
},
|
|
322
|
-
goodsSn: {
|
|
323
|
-
component: BsHeaderChild,
|
|
324
|
-
name: "货号",
|
|
325
|
-
key: "goodsSn",
|
|
326
|
-
width: 140
|
|
327
|
-
},
|
|
328
|
-
goodsId: {
|
|
329
|
-
component: BsHeaderChild,
|
|
330
|
-
name: "货号ID",
|
|
331
|
-
key: "goodsId",
|
|
332
|
-
width: 100
|
|
333
|
-
},
|
|
334
|
-
colorName: {
|
|
335
|
-
component: BsHeaderChild,
|
|
336
|
-
name: "颜色名称",
|
|
337
|
-
key: "colorName",
|
|
338
|
-
width: 80
|
|
339
|
-
},
|
|
340
|
-
colorCode: {
|
|
341
|
-
component: BsHeaderChild,
|
|
342
|
-
name: "颜色代码",
|
|
343
|
-
key: "colorCode",
|
|
344
|
-
width: 80
|
|
345
|
-
},
|
|
346
|
-
sizeName: {
|
|
347
|
-
component: BsHeaderChild,
|
|
348
|
-
name: "尺码名称",
|
|
349
|
-
key: "sizeName",
|
|
350
|
-
width: 80
|
|
351
|
-
},
|
|
352
|
-
sizeCode: {
|
|
353
|
-
component: BsHeaderChild,
|
|
354
|
-
name: "尺码代码",
|
|
355
|
-
key: "sizeCode",
|
|
356
|
-
width: 80
|
|
357
|
-
},
|
|
358
|
-
brandName: {
|
|
359
|
-
component: BsHeaderChild,
|
|
360
|
-
name: "品牌名称",
|
|
361
|
-
key: "brandName",
|
|
362
|
-
width: 80
|
|
363
|
-
},
|
|
364
|
-
goodsNumber: {
|
|
365
|
-
component: BsHeaderChild,
|
|
366
|
-
name: "商品数量",
|
|
367
|
-
key: "goodsNumber",
|
|
368
|
-
width: 80
|
|
369
|
-
},
|
|
370
|
-
goodsPrice: {
|
|
371
|
-
component: BsHeaderChild,
|
|
372
|
-
name: "商品单价",
|
|
373
|
-
key: "goodsPrice",
|
|
374
|
-
width: 80
|
|
375
|
-
},
|
|
376
|
-
shopPrice: {
|
|
377
|
-
component: BsHeaderChild,
|
|
378
|
-
name: "商品网店售价",
|
|
379
|
-
key: "shopPrice",
|
|
380
|
-
width: 80
|
|
381
|
-
},
|
|
382
|
-
sharePrice: {
|
|
383
|
-
component: BsHeaderChild,
|
|
384
|
-
name: "分摊价",
|
|
385
|
-
key: "sharePrice",
|
|
386
|
-
width: 80
|
|
387
|
-
},
|
|
388
|
-
sharePayment: {
|
|
389
|
-
component: BsHeaderChild,
|
|
390
|
-
name: "分摊实付金额",
|
|
391
|
-
key: "sharePayment",
|
|
392
|
-
width: 80
|
|
393
|
-
},
|
|
394
|
-
payment: {
|
|
395
|
-
component: BsHeaderChild,
|
|
396
|
-
name: "实付金额",
|
|
397
|
-
key: "payment",
|
|
398
|
-
width: 80
|
|
399
|
-
},
|
|
400
|
-
tcSku: {
|
|
401
|
-
component: BsHeaderChild,
|
|
402
|
-
name: "套餐SKU",
|
|
403
|
-
key: "tcSku",
|
|
404
|
-
width: 120
|
|
405
|
-
},
|
|
406
|
-
tcGoodsNumber: {
|
|
407
|
-
component: BsHeaderChild,
|
|
408
|
-
name: "套餐套数",
|
|
409
|
-
key: "tcGoodsNumber",
|
|
410
|
-
width: 120
|
|
411
|
-
},
|
|
412
|
-
taoCanSingleSl: {
|
|
413
|
-
component: BsHeaderChild,
|
|
414
|
-
name: "单个套餐数量",
|
|
415
|
-
key: "taoCanSingleSl",
|
|
416
|
-
width: 80
|
|
417
|
-
},
|
|
418
|
-
isGift: {
|
|
419
|
-
component: BsHeaderChild,
|
|
420
|
-
name: "是否赠品",
|
|
421
|
-
key: "isGift",
|
|
422
|
-
width: 80
|
|
423
|
-
}
|
|
424
|
-
},
|
|
425
|
-
itemKey: {
|
|
426
|
-
sku: "SKU",
|
|
427
|
-
skuId: "SKU ID",
|
|
428
|
-
goodsName: "商品名称",
|
|
429
|
-
goodsShortName: "商品简称",
|
|
430
|
-
picPath: "商品图片",
|
|
431
|
-
goodsSn: "货号",
|
|
432
|
-
goodsId: "货号ID",
|
|
433
|
-
colorName: "颜色名称",
|
|
434
|
-
colorCode: "颜色代码",
|
|
435
|
-
sizeName: "尺码名称",
|
|
436
|
-
sizeCode: "尺码代码",
|
|
437
|
-
brandName: "品牌名称",
|
|
438
|
-
goodsNumber: "商品数量",
|
|
439
|
-
goodsPrice: "商品单价",
|
|
440
|
-
shopPrice: "商品网店售价",
|
|
441
|
-
sharePrice: "分摊价",
|
|
442
|
-
sharePayment: "分摊实付金额",
|
|
443
|
-
payment: "实付金额",
|
|
444
|
-
tcSku: "套餐SKU",
|
|
445
|
-
tcGoodsNumber: "套餐套数",
|
|
446
|
-
taoCanSingleSl: "单个套餐数量",
|
|
447
|
-
isGift: "是否赠品"
|
|
448
|
-
},
|
|
449
|
-
moneyKey: "payment"
|
|
450
289
|
}
|
|
451
290
|
};
|
|
452
291
|
GoodHeaderMap['WDT_REISSUE_GOODS'] = GoodHeaderMap['WDT_GOODS'];
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { ComponentInterface, PickOption, Record } from
|
|
2
|
-
import React from
|
|
1
|
+
import { ComponentInterface, PickOption, Record } from '../../type';
|
|
2
|
+
import React from 'react';
|
|
3
3
|
declare type Value = string[] | undefined;
|
|
4
4
|
declare class BasicPicture implements ComponentInterface {
|
|
5
5
|
name: string;
|
|
@@ -12,12 +12,12 @@ declare class BasicPicture implements ComponentInterface {
|
|
|
12
12
|
formField: string;
|
|
13
13
|
canSort: boolean;
|
|
14
14
|
children: ComponentInterface[];
|
|
15
|
-
dataType: ComponentInterface[
|
|
15
|
+
dataType: ComponentInterface['dataType'];
|
|
16
16
|
constructor(options: PickOption);
|
|
17
17
|
formatPictures: (pictures: string) => string[];
|
|
18
18
|
render: (value: Value) => React.JSX.Element | null;
|
|
19
|
-
renderPc: (value: any, record: Record) => React.JSX.Element;
|
|
20
|
-
renderLog: (r: Record) => React.JSX.Element | null;
|
|
19
|
+
renderPc: (value: any, record: Record) => React.JSX.Element | React.JSX.Element[];
|
|
20
|
+
renderLog: (r: Record) => React.JSX.Element | React.JSX.Element[] | null;
|
|
21
21
|
getComponentValue: (r: Record) => any;
|
|
22
22
|
renderClient: (record: any) => React.JSX.Element | null;
|
|
23
23
|
editRender: (p: any) => React.JSX.Element;
|
|
@@ -6,13 +6,13 @@ function _classCallCheck(instance, Constructor) { if (!(instance instanceof Cons
|
|
|
6
6
|
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
7
7
|
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
|
|
8
8
|
function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
9
|
-
import React from
|
|
10
|
-
import { Image } from
|
|
11
|
-
import { ApaasUploadAsync, ApaasUpload } from
|
|
12
|
-
import { imgResize } from
|
|
9
|
+
import React from 'react';
|
|
10
|
+
import { Image } from 'antd';
|
|
11
|
+
import { ApaasUploadAsync, ApaasUpload } from '@kmkf-fe-packages/basic-components';
|
|
12
|
+
import { imgResize } from '@kmkf-fe-packages/kmkf-utils';
|
|
13
13
|
import GetFormItem from "../GetFormItem";
|
|
14
14
|
import ItemView from "../../commonComponents/ItemView";
|
|
15
|
-
import { isNull } from
|
|
15
|
+
import { isNull } from '@kmkf-fe-packages/kmkf-utils';
|
|
16
16
|
var BasicPicture = /*#__PURE__*/_createClass(function BasicPicture(options) {
|
|
17
17
|
var _this = this;
|
|
18
18
|
_classCallCheck(this, BasicPicture);
|
|
@@ -28,28 +28,28 @@ var BasicPicture = /*#__PURE__*/_createClass(function BasicPicture(options) {
|
|
|
28
28
|
_defineProperty(this, "children", void 0);
|
|
29
29
|
_defineProperty(this, "dataType", void 0);
|
|
30
30
|
_defineProperty(this, "formatPictures", function (pictures) {
|
|
31
|
-
pictures = pictures.replace(/[\[\]]/g,
|
|
32
|
-
pictures = pictures.replace(/\s/g,
|
|
33
|
-
return pictures ? pictures.split(
|
|
31
|
+
pictures = pictures.replace(/[\[\]]/g, '');
|
|
32
|
+
pictures = pictures.replace(/\s/g, '');
|
|
33
|
+
return pictures ? pictures.split(',') : [];
|
|
34
34
|
});
|
|
35
35
|
_defineProperty(this, "render", function (value) {
|
|
36
36
|
if (!(value !== null && value !== void 0 && value.length)) {
|
|
37
37
|
return null;
|
|
38
38
|
}
|
|
39
|
-
return /*#__PURE__*/React.createElement("div", null,
|
|
39
|
+
return /*#__PURE__*/React.createElement("div", null, value === null || value === void 0 ? void 0 : value.map(function (pic) {
|
|
40
40
|
return /*#__PURE__*/React.createElement("div", {
|
|
41
41
|
style: {
|
|
42
|
-
marginRight:
|
|
43
|
-
display:
|
|
42
|
+
marginRight: '5px',
|
|
43
|
+
display: 'inline-block'
|
|
44
44
|
}
|
|
45
45
|
}, /*#__PURE__*/React.createElement(Image, {
|
|
46
46
|
width: 32,
|
|
47
|
-
src: imgResize(pic ||
|
|
47
|
+
src: imgResize(pic || ''),
|
|
48
48
|
preview: {
|
|
49
|
-
src: imgResize(pic ||
|
|
49
|
+
src: imgResize(pic || '', 0, 0)
|
|
50
50
|
}
|
|
51
51
|
}));
|
|
52
|
-
}))
|
|
52
|
+
}));
|
|
53
53
|
});
|
|
54
54
|
_defineProperty(this, "renderPc", function (value, record) {
|
|
55
55
|
if ((record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_picture")]) === undefined) {
|
|
@@ -58,11 +58,11 @@ var BasicPicture = /*#__PURE__*/_createClass(function BasicPicture(options) {
|
|
|
58
58
|
var finalPictures = _this.formatPictures(record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_picture")]).map(function (item) {
|
|
59
59
|
return "".concat(window.location.origin, "/").concat(item);
|
|
60
60
|
});
|
|
61
|
-
return
|
|
61
|
+
return finalPictures === null || finalPictures === void 0 ? void 0 : finalPictures.map(function (pic) {
|
|
62
62
|
return /*#__PURE__*/React.createElement("div", {
|
|
63
63
|
style: {
|
|
64
|
-
marginRight:
|
|
65
|
-
display:
|
|
64
|
+
marginRight: '5px',
|
|
65
|
+
display: 'inline-block'
|
|
66
66
|
},
|
|
67
67
|
onClick: function onClick(e) {
|
|
68
68
|
return e.stopPropagation();
|
|
@@ -74,7 +74,7 @@ var BasicPicture = /*#__PURE__*/_createClass(function BasicPicture(options) {
|
|
|
74
74
|
src: pic
|
|
75
75
|
}
|
|
76
76
|
}));
|
|
77
|
-
})
|
|
77
|
+
});
|
|
78
78
|
});
|
|
79
79
|
_defineProperty(this, "renderLog", function (r) {
|
|
80
80
|
if (isNull(r === null || r === void 0 ? void 0 : r["".concat(_this.id, "_picture")])) return null;
|
|
@@ -99,7 +99,7 @@ var BasicPicture = /*#__PURE__*/_createClass(function BasicPicture(options) {
|
|
|
99
99
|
hidden: p === null || p === void 0 ? void 0 : p.hidden,
|
|
100
100
|
display: p === null || p === void 0 ? void 0 : p.display,
|
|
101
101
|
required: (_this$componentConfig = (_this$componentConfig2 = _this.componentConfig) === null || _this$componentConfig2 === void 0 ? void 0 : _this$componentConfig2.required) !== null && _this$componentConfig !== void 0 ? _this$componentConfig : false,
|
|
102
|
-
tooltip: (_this$componentConfig3 = _this.componentConfig) !== null && _this$componentConfig3 !== void 0 && _this$componentConfig3.showTooltip ? (_this$componentConfig4 = _this.componentConfig) === null || _this$componentConfig4 === void 0 ? void 0 : _this$componentConfig4.tooltip :
|
|
102
|
+
tooltip: (_this$componentConfig3 = _this.componentConfig) !== null && _this$componentConfig3 !== void 0 && _this$componentConfig3.showTooltip ? (_this$componentConfig4 = _this.componentConfig) === null || _this$componentConfig4 === void 0 ? void 0 : _this$componentConfig4.tooltip : '',
|
|
103
103
|
component: (_this$componentConfig5 = _this.componentConfig) !== null && _this$componentConfig5 !== void 0 && _this$componentConfig5.isSingleShop ? /*#__PURE__*/React.createElement(ApaasUpload, _this.componentConfig) : /*#__PURE__*/React.createElement(ApaasUploadAsync, _extends({}, _this.componentConfig, {
|
|
104
104
|
uniqueKey: _this.id,
|
|
105
105
|
hostUrl: "https://kefu.kuaimai.com"
|
|
@@ -122,6 +122,6 @@ var BasicPicture = /*#__PURE__*/_createClass(function BasicPicture(options) {
|
|
|
122
122
|
this.isCombinationComponent = false;
|
|
123
123
|
this.canSort = true;
|
|
124
124
|
this.children = [];
|
|
125
|
-
this.dataType =
|
|
125
|
+
this.dataType = 'string';
|
|
126
126
|
});
|
|
127
127
|
export default BasicPicture;
|
package/dist/esm/factory.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { JstLogistics, JstItemSelect, JstSupply, JstSendGood, BasicInput, BasicAddress, BasicCascader, BasicCheckbox, BasicDataTime, BasicSelect, BasicRadio, BasicTextArea, BasicPicture, BasicMultSelect, BasicGrade, BasicRate, BasicFile, BasicPosting, SubForm, CommonDataTime, TradeId, ShopName, BuyerNick, ReceiverName, ReceiverMobile, ReceiverAddress, TradeDateTime, Logistics, ReturnLogistics, ActualPayment, ERemark, AliPay, ItemSelect, ItemId, ItemEnCode, SystemOrderNo, Ordinary, ThirdItemSelect, FlowStatusSelect, FlowMarkSelect, FlowTag, Payment, TemplateSelect, WorkOrderId, PlatForm, ShopInput, Submitter, PrevSubmitter, FlowCreator, Handler, CompletedUser, LogisticsInterception, LogisticsMoreInterception, LogisticsTrajectory, LogisticsMoreTrajectory, FlowWorkOrderId, BsGoods, BsExchange, BsReissue, BsReturn, BsSystemOrder, BsLogistics, StatusSelect, CommonSystemOrder, CommonMultiStatus, Calculation, NodeDeadLine, HandlerDeadLine, NodeStayDuration, WlnGoods, BsPosting, MsgStatus, NodeInput, FlowWorkOrderStatus, WdtGoods, WdtReturn, WdtExchange, CommonInput, PaymentVoucherCode, Label, WdtReissue, KmErpSendGood, AfterSalesOrderId
|
|
1
|
+
import { JstLogistics, JstItemSelect, JstSupply, JstSendGood, BasicInput, BasicAddress, BasicCascader, BasicCheckbox, BasicDataTime, BasicSelect, BasicRadio, BasicTextArea, BasicPicture, BasicMultSelect, BasicGrade, BasicRate, BasicFile, BasicPosting, SubForm, CommonDataTime, TradeId, ShopName, BuyerNick, ReceiverName, ReceiverMobile, ReceiverAddress, TradeDateTime, Logistics, ReturnLogistics, ActualPayment, ERemark, AliPay, ItemSelect, ItemId, ItemEnCode, SystemOrderNo, Ordinary, ThirdItemSelect, FlowStatusSelect, FlowMarkSelect, FlowTag, Payment, TemplateSelect, WorkOrderId, PlatForm, ShopInput, Submitter, PrevSubmitter, FlowCreator, Handler, CompletedUser, LogisticsInterception, LogisticsMoreInterception, LogisticsTrajectory, LogisticsMoreTrajectory, FlowWorkOrderId, BsGoods, BsExchange, BsReissue, BsReturn, BsSystemOrder, BsLogistics, StatusSelect, CommonSystemOrder, CommonMultiStatus, Calculation, NodeDeadLine, HandlerDeadLine, NodeStayDuration, WlnGoods, BsPosting, MsgStatus, NodeInput, FlowWorkOrderStatus, WdtGoods, WdtReturn, WdtExchange, CommonInput, PaymentVoucherCode, Label, WdtReissue, KmErpSendGood, AfterSalesOrderId } from "./index";
|
|
2
2
|
import { PickOption } from "./type";
|
|
3
|
-
export declare const factory: (type: string, options: PickOption) =>
|
|
3
|
+
export declare const factory: (type: string, options: PickOption) => BsSystemOrder | MsgStatus | BasicPicture | BasicInput | BasicAddress | BasicCascader | BasicCheckbox | BasicDataTime | BasicSelect | BasicRadio | BasicTextArea | BasicMultSelect | BasicGrade | BasicRate | BasicFile | BasicPosting | SubForm | CommonDataTime | TradeId | ShopName | BuyerNick | ReceiverName | ReceiverMobile | ReceiverAddress | TradeDateTime | Logistics | ReturnLogistics | ActualPayment | ERemark | AliPay | ItemSelect | ItemId | ItemEnCode | SystemOrderNo | Ordinary | ThirdItemSelect | Payment | JstLogistics | JstItemSelect | JstSendGood | JstSupply | BsGoods | BsExchange | BsReissue | BsReturn | BsLogistics | FlowStatusSelect | FlowMarkSelect | FlowTag | TemplateSelect | WorkOrderId | LogisticsInterception | LogisticsMoreInterception | LogisticsTrajectory | LogisticsMoreTrajectory | PlatForm | ShopInput | Submitter | PrevSubmitter | FlowCreator | Handler | CompletedUser | FlowWorkOrderId | StatusSelect | Calculation | CommonSystemOrder | CommonMultiStatus | NodeDeadLine | HandlerDeadLine | NodeStayDuration | WlnGoods | BsPosting | NodeInput | FlowWorkOrderStatus | WdtGoods | WdtReissue | WdtReturn | WdtExchange | CommonInput | PaymentVoucherCode | Label | KmErpSendGood | AfterSalesOrderId;
|
package/dist/esm/factory.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { JstLogistics, JstItemSelect, JstSupply, JstSendGood, BasicInput, BasicAddress, BasicCascader, BasicCheckbox, BasicDataTime, BasicSelect, BasicRadio, BasicTextArea, BasicPicture, BasicMultSelect, BasicGrade, BasicRate, BasicFile, BasicPosting, SubForm, CommonDataTime, TradeId, ShopName, ErpTradeId, BuyerNick, ReceiverName, ReceiverMobile, ReceiverAddress, TradeDateTime, Logistics, ReturnLogistics, ActualPayment, ERemark, AliPay, ItemSelect, ItemId, ItemEnCode, SystemOrderNo, Ordinary, ThirdItemSelect, FlowStatusSelect, FlowMarkSelect, FlowTag, Payment, TemplateSelect, WorkOrderId, PlatForm, ShopInput, Submitter, PrevSubmitter, FlowCreator, Handler, CompletedUser, LogisticsInterception, LogisticsMoreInterception, LogisticsTrajectory, LogisticsMoreTrajectory, FlowWorkOrderId, BsGoods, BsExchange, BsReissue, BsReturn, BsSystemOrder, BsLogistics, StatusSelect,
|
|
2
2
|
// CommonTradeId,
|
|
3
|
-
CommonSystemOrder, CommonMultiStatus, Calculation, NodeDeadLine, HandlerDeadLine, NodeStayDuration, WlnGoods, BsPosting, MsgStatus, NodeInput, FlowWorkOrderStatus, WdtGoods, WdtReturn, WdtExchange, CommonInput, PaymentVoucherCode, Label, WdtReissue, KmErpSendGood, AfterSalesOrderId
|
|
3
|
+
CommonSystemOrder, CommonMultiStatus, Calculation, NodeDeadLine, HandlerDeadLine, NodeStayDuration, WlnGoods, BsPosting, MsgStatus, NodeInput, FlowWorkOrderStatus, WdtGoods, WdtReturn, WdtExchange, CommonInput, PaymentVoucherCode, Label, WdtReissue, KmErpSendGood, AfterSalesOrderId } from "./index";
|
|
4
4
|
export var factory = function factory(type, options) {
|
|
5
5
|
var _options$componentCon;
|
|
6
6
|
switch (type) {
|
|
@@ -131,7 +131,6 @@ export var factory = function factory(type, options) {
|
|
|
131
131
|
case "BS_SYSTEM_ORDER":
|
|
132
132
|
case "WLN_SYSTEM_ORDER":
|
|
133
133
|
case "WDT_SYSTEM_ORDER":
|
|
134
|
-
case "BS_E3_SYSTEM_ORDER":
|
|
135
134
|
return new BsSystemOrder(options);
|
|
136
135
|
case "JST_SEND_GOOD":
|
|
137
136
|
case "BS_SEND_GOOD":
|
|
@@ -142,8 +141,6 @@ export var factory = function factory(type, options) {
|
|
|
142
141
|
return new BsPosting(options);
|
|
143
142
|
case "BS_GOODS":
|
|
144
143
|
return new BsGoods(options);
|
|
145
|
-
case "BS_E3_GOODS":
|
|
146
|
-
return new BsE3Goods(options);
|
|
147
144
|
case "BS_EXCHANGE_GOODS":
|
|
148
145
|
return new BsExchange(options);
|
|
149
146
|
case "WDT_EXCHANGE_GOODS":
|
package/dist/esm/index.d.ts
CHANGED
|
@@ -40,7 +40,6 @@ export { default as JstSendGood } from "./components/JST/JstSendGood";
|
|
|
40
40
|
export { default as JstSupply } from "./components/JST/JstSupply";
|
|
41
41
|
export { default as BsSystemOrder } from "./components/BS/BsSystemOrder";
|
|
42
42
|
export { default as BsGoods } from "./components/BS/BsGoods";
|
|
43
|
-
export { default as BsE3Goods } from "./components/BsE3/BsGoods";
|
|
44
43
|
export { default as BsExchange } from "./components/BS/BsExchange";
|
|
45
44
|
export { default as BsReissue } from "./components/BS/BsReissue";
|
|
46
45
|
export { default as BsReturn } from "./components/BS/BsReturn";
|
package/dist/esm/index.js
CHANGED
|
@@ -40,7 +40,6 @@ export { default as JstSendGood } from "./components/JST/JstSendGood";
|
|
|
40
40
|
export { default as JstSupply } from "./components/JST/JstSupply";
|
|
41
41
|
export { default as BsSystemOrder } from "./components/BS/BsSystemOrder";
|
|
42
42
|
export { default as BsGoods } from "./components/BS/BsGoods";
|
|
43
|
-
export { default as BsE3Goods } from "./components/BsE3/BsGoods";
|
|
44
43
|
export { default as BsExchange } from "./components/BS/BsExchange";
|
|
45
44
|
export { default as BsReissue } from "./components/BS/BsReissue";
|
|
46
45
|
export { default as BsReturn } from "./components/BS/BsReturn";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@kmkf-fe-packages/services-components",
|
|
3
|
-
"version": "1.19.4
|
|
3
|
+
"version": "1.19.4",
|
|
4
4
|
"module": "dist/esm/index.js",
|
|
5
5
|
"typings": "dist/esm/index.d.ts",
|
|
6
6
|
"files": [
|
|
@@ -21,8 +21,8 @@
|
|
|
21
21
|
]
|
|
22
22
|
},
|
|
23
23
|
"dependencies": {
|
|
24
|
-
"@kmkf-fe-packages/basic-components": "1.19.4
|
|
25
|
-
"@kmkf-fe-packages/kmkf-utils": "1.19.4
|
|
24
|
+
"@kmkf-fe-packages/basic-components": "1.19.4",
|
|
25
|
+
"@kmkf-fe-packages/kmkf-utils": "1.19.4",
|
|
26
26
|
"b64-to-blob": "^1.2.19",
|
|
27
27
|
"html2canvas": "^1.4.1",
|
|
28
28
|
"react-pdf-js": "^5.1.0"
|
|
@@ -41,7 +41,7 @@
|
|
|
41
41
|
"publishConfig": {
|
|
42
42
|
"access": "public"
|
|
43
43
|
},
|
|
44
|
-
"gitHead": "
|
|
44
|
+
"gitHead": "167a8b190ae6a8c52525e929e98fee86be390f4f",
|
|
45
45
|
"gitHooks": {
|
|
46
46
|
"pre-commit": "lint-staged"
|
|
47
47
|
}
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
import { ComponentInterface, PickOption, ColumnConfig, Record } from "../../../type";
|
|
2
|
-
import React from "react";
|
|
3
|
-
import CommonHeaderGoods from "../../CommonHeaderGood";
|
|
4
|
-
declare class BSE3Goods implements ComponentInterface {
|
|
5
|
-
name: string;
|
|
6
|
-
id: string;
|
|
7
|
-
sortField: string;
|
|
8
|
-
type: string;
|
|
9
|
-
rules: any[];
|
|
10
|
-
componentConfig: ComponentInterface["componentConfig"];
|
|
11
|
-
effects: ComponentInterface["effects"];
|
|
12
|
-
isCombinationComponent: boolean;
|
|
13
|
-
formField: string;
|
|
14
|
-
canSort: boolean;
|
|
15
|
-
children: ComponentInterface[];
|
|
16
|
-
dataType: ComponentInterface["dataType"];
|
|
17
|
-
bsE3Goods: CommonHeaderGoods;
|
|
18
|
-
constructor(options: PickOption);
|
|
19
|
-
renderClient: (record: any) => React.JSX.Element | null;
|
|
20
|
-
renderPc: () => null;
|
|
21
|
-
renderLog: (r: Record) => React.JSX.Element | null;
|
|
22
|
-
getComponentValue: (r: Record) => any;
|
|
23
|
-
renderExport: () => null;
|
|
24
|
-
editRender: (p: any) => React.JSX.Element;
|
|
25
|
-
filterConfig: (item: ColumnConfig) => {
|
|
26
|
-
searchDefaultConditions: "like";
|
|
27
|
-
type: string;
|
|
28
|
-
id: string;
|
|
29
|
-
name: string;
|
|
30
|
-
filterComponentType: "Input";
|
|
31
|
-
}[];
|
|
32
|
-
}
|
|
33
|
-
export default BSE3Goods;
|
|
@@ -1,123 +0,0 @@
|
|
|
1
|
-
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
2
|
-
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
3
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
4
|
-
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
5
|
-
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor); } }
|
|
6
|
-
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
7
|
-
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
8
|
-
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
9
|
-
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
|
|
10
|
-
function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
11
|
-
import React from "react";
|
|
12
|
-
import GetFormItem from "../../GetFormItem";
|
|
13
|
-
import { BsGoodsTable } from "../../Common";
|
|
14
|
-
import CommonHeaderGoods from "../../CommonHeaderGood";
|
|
15
|
-
import ItemView from "../../../commonComponents/ItemView";
|
|
16
|
-
import { isNull } from "@kmkf-fe-packages/kmkf-utils";
|
|
17
|
-
import { CommonGoods as Goods } from "@kmkf-fe-packages/basic-components";
|
|
18
|
-
import { SYMBOL } from "../../../constant";
|
|
19
|
-
var BSE3Goods = /*#__PURE__*/_createClass(function BSE3Goods(options) {
|
|
20
|
-
var _this = this,
|
|
21
|
-
_this$componentConfig6;
|
|
22
|
-
_classCallCheck(this, BSE3Goods);
|
|
23
|
-
_defineProperty(this, "name", void 0);
|
|
24
|
-
_defineProperty(this, "id", void 0);
|
|
25
|
-
_defineProperty(this, "sortField", void 0);
|
|
26
|
-
_defineProperty(this, "type", void 0);
|
|
27
|
-
_defineProperty(this, "rules", void 0);
|
|
28
|
-
_defineProperty(this, "componentConfig", void 0);
|
|
29
|
-
_defineProperty(this, "effects", void 0);
|
|
30
|
-
_defineProperty(this, "isCombinationComponent", void 0);
|
|
31
|
-
_defineProperty(this, "formField", void 0);
|
|
32
|
-
_defineProperty(this, "canSort", void 0);
|
|
33
|
-
_defineProperty(this, "children", void 0);
|
|
34
|
-
_defineProperty(this, "dataType", void 0);
|
|
35
|
-
_defineProperty(this, "bsE3Goods", void 0);
|
|
36
|
-
_defineProperty(this, "renderClient", function (record) {
|
|
37
|
-
var _record, _this$componentConfig;
|
|
38
|
-
return !isNull(record === null || record === void 0 ? void 0 : record["".concat(_this.id)]) ? /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(ItemView, {
|
|
39
|
-
id: _this.id,
|
|
40
|
-
label: _this.name,
|
|
41
|
-
value: /*#__PURE__*/React.createElement(BsGoodsTable, {
|
|
42
|
-
type: _this.type,
|
|
43
|
-
list: (record === null || record === void 0 ? void 0 : (_record = record["".concat(_this.id)]) === null || _record === void 0 ? void 0 : _record.bsE3Goods) || [],
|
|
44
|
-
showHeader: ((_this$componentConfig = _this.componentConfig) === null || _this$componentConfig === void 0 ? void 0 : _this$componentConfig.showHeader) || []
|
|
45
|
-
})
|
|
46
|
-
})) : null;
|
|
47
|
-
});
|
|
48
|
-
_defineProperty(this, "renderPc", function () {
|
|
49
|
-
return null;
|
|
50
|
-
});
|
|
51
|
-
_defineProperty(this, "renderLog", function (r) {
|
|
52
|
-
var _this$componentConfig2;
|
|
53
|
-
if (isNull(r === null || r === void 0 ? void 0 : r["".concat(_this.id, "_bsE3Goods")])) return null;
|
|
54
|
-
return /*#__PURE__*/React.createElement(BsGoodsTable, {
|
|
55
|
-
type: _this.type,
|
|
56
|
-
list: (r === null || r === void 0 ? void 0 : r["".concat(_this.id, "_bsE3Goods")]) || [],
|
|
57
|
-
showHeader: ((_this$componentConfig2 = _this.componentConfig) === null || _this$componentConfig2 === void 0 ? void 0 : _this$componentConfig2.showHeader) || []
|
|
58
|
-
});
|
|
59
|
-
});
|
|
60
|
-
_defineProperty(this, "getComponentValue", function (r) {
|
|
61
|
-
return r === null || r === void 0 ? void 0 : r["".concat(_this.id, "_bsE3Goods")];
|
|
62
|
-
});
|
|
63
|
-
_defineProperty(this, "renderExport", function () {
|
|
64
|
-
return null;
|
|
65
|
-
});
|
|
66
|
-
_defineProperty(this, "editRender", function (p) {
|
|
67
|
-
var _this$componentConfig3, _this$componentConfig4, _this$componentConfig5, _this$effects, _this$effects2, _this$effects3;
|
|
68
|
-
return /*#__PURE__*/React.createElement(GetFormItem, {
|
|
69
|
-
title: _this.name,
|
|
70
|
-
name: _this.id,
|
|
71
|
-
rules: _this.rules,
|
|
72
|
-
required: false,
|
|
73
|
-
hidden: p === null || p === void 0 ? void 0 : p.hidden,
|
|
74
|
-
display: p === null || p === void 0 ? void 0 : p.display,
|
|
75
|
-
tooltip: (_this$componentConfig3 = _this.componentConfig) !== null && _this$componentConfig3 !== void 0 && _this$componentConfig3.showTooltip ? (_this$componentConfig4 = _this.componentConfig) === null || _this$componentConfig4 === void 0 ? void 0 : _this$componentConfig4.tooltip : '',
|
|
76
|
-
component: /*#__PURE__*/React.createElement(Goods, _extends({}, _this.componentConfig, {
|
|
77
|
-
maxLength: ((_this$componentConfig5 = _this.componentConfig) === null || _this$componentConfig5 === void 0 ? void 0 : _this$componentConfig5.maxLength) || 20,
|
|
78
|
-
shopId: (_this$effects = _this.effects) === null || _this$effects === void 0 ? void 0 : _this$effects.shopId,
|
|
79
|
-
shopList: ((_this$effects2 = _this.effects) === null || _this$effects2 === void 0 ? void 0 : _this$effects2.shopList) || [],
|
|
80
|
-
companyKey: (_this$effects3 = _this.effects) === null || _this$effects3 === void 0 ? void 0 : _this$effects3.companyKey,
|
|
81
|
-
type: _this.type,
|
|
82
|
-
width: "90%"
|
|
83
|
-
}))
|
|
84
|
-
});
|
|
85
|
-
});
|
|
86
|
-
_defineProperty(this, "filterConfig", function (item) {
|
|
87
|
-
return [{
|
|
88
|
-
searchDefaultConditions: SYMBOL.like,
|
|
89
|
-
type: item.type,
|
|
90
|
-
id: "".concat(item.id, "_bsE3Goods"),
|
|
91
|
-
// 过滤组件id
|
|
92
|
-
name: item.name,
|
|
93
|
-
// 过滤组件名称
|
|
94
|
-
filterComponentType: "Input"
|
|
95
|
-
}];
|
|
96
|
-
});
|
|
97
|
-
this.name = options.name;
|
|
98
|
-
this.id = options.id;
|
|
99
|
-
this.sortField = "".concat(options.id, "_bsE3Goods");
|
|
100
|
-
this.formField = "".concat(options.id, "_bsE3Goods");
|
|
101
|
-
this.type = options.type;
|
|
102
|
-
this.effects = options === null || options === void 0 ? void 0 : options.effects;
|
|
103
|
-
this.isCombinationComponent = true;
|
|
104
|
-
this.canSort = false;
|
|
105
|
-
this.bsE3Goods = new CommonHeaderGoods(_objectSpread(_objectSpread({}, options), {}, {
|
|
106
|
-
id: "".concat(options.id, "_bsE3Goods"),
|
|
107
|
-
name: "商品信息"
|
|
108
|
-
}));
|
|
109
|
-
this.children = [this.bsE3Goods];
|
|
110
|
-
this.componentConfig = options === null || options === void 0 ? void 0 : options.componentConfig;
|
|
111
|
-
this.rules = this !== null && this !== void 0 && (_this$componentConfig6 = this.componentConfig) !== null && _this$componentConfig6 !== void 0 && _this$componentConfig6.required ? [{
|
|
112
|
-
required: true,
|
|
113
|
-
validator: function validator(_, value) {
|
|
114
|
-
var _value$bsE3Goods;
|
|
115
|
-
if (!value || !(value !== null && value !== void 0 && (_value$bsE3Goods = value.bsE3Goods) !== null && _value$bsE3Goods !== void 0 && _value$bsE3Goods.length)) {
|
|
116
|
-
return Promise.reject(new Error("请选择百胜E3商品"));
|
|
117
|
-
}
|
|
118
|
-
return Promise.resolve();
|
|
119
|
-
}
|
|
120
|
-
}] : [];
|
|
121
|
-
this.dataType = "object";
|
|
122
|
-
});
|
|
123
|
-
export default BSE3Goods;
|