@kmkf-fe-packages/services-components 2.2.44-beta.31 → 2.2.44-beta.33
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.d.ts +7 -0
- package/dist/esm/components/BS/BsSystemOrder/index.js +25 -8
- package/dist/esm/components/Common/index.d.ts +1 -1
- package/dist/esm/components/Common/index.js +3 -2
- package/dist/esm/components/CommonMultiStatus/index.js +37 -35
- package/dist/esm/components/Public/Goods/index.d.ts +7 -0
- package/dist/esm/components/Public/Goods/index.js +15 -0
- package/dist/esm/factory.d.ts +1 -1
- package/package.json +4 -4
|
@@ -13,7 +13,14 @@ declare class BsSystemOrder implements ComponentInterface {
|
|
|
13
13
|
canSort: boolean;
|
|
14
14
|
dataType: ComponentInterface["dataType"];
|
|
15
15
|
children: ComponentInterface[];
|
|
16
|
+
sortChildField: {
|
|
17
|
+
name: string;
|
|
18
|
+
key: string;
|
|
19
|
+
dataType: string;
|
|
20
|
+
[key: string]: any;
|
|
21
|
+
}[];
|
|
16
22
|
constructor(options: PickOption);
|
|
23
|
+
getSortChildFields: () => any;
|
|
17
24
|
renderClient: (record: any) => React.JSX.Element | null;
|
|
18
25
|
renderPc: () => null;
|
|
19
26
|
renderLog: (r: Record) => React.JSX.Element | null;
|
|
@@ -34,7 +34,7 @@ var BsSystemOrder = /*#__PURE__*/_createClass(function BsSystemOrder(options) {
|
|
|
34
34
|
_getSystemShowHead,
|
|
35
35
|
_typeMap$options$type,
|
|
36
36
|
_options$componentCon,
|
|
37
|
-
_this$
|
|
37
|
+
_this$componentConfig6;
|
|
38
38
|
_classCallCheck(this, BsSystemOrder);
|
|
39
39
|
_defineProperty(this, "name", void 0);
|
|
40
40
|
_defineProperty(this, "id", void 0);
|
|
@@ -48,15 +48,31 @@ var BsSystemOrder = /*#__PURE__*/_createClass(function BsSystemOrder(options) {
|
|
|
48
48
|
_defineProperty(this, "canSort", void 0);
|
|
49
49
|
_defineProperty(this, "dataType", void 0);
|
|
50
50
|
_defineProperty(this, "children", void 0);
|
|
51
|
+
_defineProperty(this, "sortChildField", void 0);
|
|
52
|
+
_defineProperty(this, "getSortChildFields", function () {
|
|
53
|
+
var _typeMap$_this$type, _this$componentConfig;
|
|
54
|
+
return getSystemShowHead({
|
|
55
|
+
columns: ((_typeMap$_this$type = typeMap[_this.type]) === null || _typeMap$_this$type === void 0 ? void 0 : _typeMap$_this$type.columns) || [],
|
|
56
|
+
showHeader: (_this === null || _this === void 0 ? void 0 : (_this$componentConfig = _this.componentConfig) === null || _this$componentConfig === void 0 ? void 0 : _this$componentConfig.showHeader) || []
|
|
57
|
+
}).filter(function (item) {
|
|
58
|
+
return !["picUrl"].includes(item.dataIndex);
|
|
59
|
+
}).map(function (item) {
|
|
60
|
+
return {
|
|
61
|
+
name: item.title,
|
|
62
|
+
key: "".concat(_this.id, "_").concat(item.dataIndex),
|
|
63
|
+
dataType: "arrayObject"
|
|
64
|
+
};
|
|
65
|
+
});
|
|
66
|
+
});
|
|
51
67
|
_defineProperty(this, "renderClient", function (record) {
|
|
52
|
-
var _this$
|
|
68
|
+
var _this$componentConfig2;
|
|
53
69
|
return !isNull(record === null || record === void 0 ? void 0 : record["".concat(_this.id)]) ? /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(ItemView, {
|
|
54
70
|
id: _this.id,
|
|
55
71
|
label: _this.name,
|
|
56
72
|
value: /*#__PURE__*/React.createElement(BsSystemOrderTable, {
|
|
57
73
|
value: record === null || record === void 0 ? void 0 : record["".concat(_this.id)],
|
|
58
74
|
type: _this.type,
|
|
59
|
-
showHeader: ((_this$
|
|
75
|
+
showHeader: ((_this$componentConfig2 = _this.componentConfig) === null || _this$componentConfig2 === void 0 ? void 0 : _this$componentConfig2.showHeader) || []
|
|
60
76
|
})
|
|
61
77
|
})) : null;
|
|
62
78
|
});
|
|
@@ -64,7 +80,7 @@ var BsSystemOrder = /*#__PURE__*/_createClass(function BsSystemOrder(options) {
|
|
|
64
80
|
return null;
|
|
65
81
|
});
|
|
66
82
|
_defineProperty(this, "renderLog", function (r) {
|
|
67
|
-
var _this$
|
|
83
|
+
var _this$componentConfig3;
|
|
68
84
|
if (isNull(r === null || r === void 0 ? void 0 : r["".concat(_this.id, "_").concat(typeMap[_this.type].key)])) return null;
|
|
69
85
|
return /*#__PURE__*/React.createElement(BsSystemOrderTable, {
|
|
70
86
|
value: {
|
|
@@ -72,7 +88,7 @@ var BsSystemOrder = /*#__PURE__*/_createClass(function BsSystemOrder(options) {
|
|
|
72
88
|
selectIds: r === null || r === void 0 ? void 0 : r["".concat(_this.id, "_").concat(typeMap[_this.type].selectId)]
|
|
73
89
|
},
|
|
74
90
|
type: _this.type,
|
|
75
|
-
showHeader: ((_this$
|
|
91
|
+
showHeader: ((_this$componentConfig3 = _this.componentConfig) === null || _this$componentConfig3 === void 0 ? void 0 : _this$componentConfig3.showHeader) || []
|
|
76
92
|
});
|
|
77
93
|
});
|
|
78
94
|
_defineProperty(this, "getComponentValue", function (r) {
|
|
@@ -82,7 +98,7 @@ var BsSystemOrder = /*#__PURE__*/_createClass(function BsSystemOrder(options) {
|
|
|
82
98
|
return null;
|
|
83
99
|
});
|
|
84
100
|
_defineProperty(this, "editRender", function (p) {
|
|
85
|
-
var _this$
|
|
101
|
+
var _this$componentConfig4, _this$componentConfig5;
|
|
86
102
|
return /*#__PURE__*/React.createElement(GetFormItem, {
|
|
87
103
|
title: _this.name,
|
|
88
104
|
name: _this.id,
|
|
@@ -90,7 +106,7 @@ var BsSystemOrder = /*#__PURE__*/_createClass(function BsSystemOrder(options) {
|
|
|
90
106
|
required: false,
|
|
91
107
|
hidden: p === null || p === void 0 ? void 0 : p.hidden,
|
|
92
108
|
display: p === null || p === void 0 ? void 0 : p.display,
|
|
93
|
-
tooltip: (_this$
|
|
109
|
+
tooltip: (_this$componentConfig4 = _this.componentConfig) !== null && _this$componentConfig4 !== void 0 && _this$componentConfig4.showTooltip ? (_this$componentConfig5 = _this.componentConfig) === null || _this$componentConfig5 === void 0 ? void 0 : _this$componentConfig5.tooltip : "",
|
|
94
110
|
component: /*#__PURE__*/React.createElement(SystemOrder, _extends({}, _this.componentConfig, {
|
|
95
111
|
onChange: p === null || p === void 0 ? void 0 : p.onChange,
|
|
96
112
|
type: _this.type
|
|
@@ -132,7 +148,7 @@ var BsSystemOrder = /*#__PURE__*/_createClass(function BsSystemOrder(options) {
|
|
|
132
148
|
}));
|
|
133
149
|
})) || [];
|
|
134
150
|
this.componentConfig = options === null || options === void 0 ? void 0 : options.componentConfig;
|
|
135
|
-
this.rules = this !== null && this !== void 0 && (_this$
|
|
151
|
+
this.rules = this !== null && this !== void 0 && (_this$componentConfig6 = this.componentConfig) !== null && _this$componentConfig6 !== void 0 && _this$componentConfig6.required ? [{
|
|
136
152
|
required: true,
|
|
137
153
|
validator: function validator(_, value) {
|
|
138
154
|
var _value$selectIds;
|
|
@@ -143,5 +159,6 @@ var BsSystemOrder = /*#__PURE__*/_createClass(function BsSystemOrder(options) {
|
|
|
143
159
|
}
|
|
144
160
|
}] : [];
|
|
145
161
|
this.dataType = "object";
|
|
162
|
+
this.sortChildField = this.getSortChildFields();
|
|
146
163
|
});
|
|
147
164
|
export default BsSystemOrder;
|
|
@@ -25,7 +25,7 @@ export declare const ShowTotalImage: ({ total, allImage, type, showHeader, }: {
|
|
|
25
25
|
export declare const GoodImage: ({ list, type, showHeader }: any) => React.JSX.Element | null;
|
|
26
26
|
export declare const JstGoodImage: ({ list, type, platformType, logisticsCompanyFormType, }: any) => any;
|
|
27
27
|
export declare const BsExpressRender: ({ list, showField, platformType, logisticsCompanyFormType, }: any) => any;
|
|
28
|
-
export declare const CommonOrderContent: ({ list, valueKey: initValueKey, failValue, options, isShowPopover, }: any) => any;
|
|
28
|
+
export declare const CommonOrderContent: ({ list, valueKey: initValueKey, failValue, options, isShowPopover, idKey, }: any) => any;
|
|
29
29
|
export declare const BsGoodImage: ({ item, index }: {
|
|
30
30
|
item: any;
|
|
31
31
|
index: number;
|
|
@@ -333,7 +333,8 @@ export var CommonOrderContent = function CommonOrderContent(_ref8) {
|
|
|
333
333
|
_ref8$options = _ref8.options,
|
|
334
334
|
options = _ref8$options === void 0 ? [] : _ref8$options,
|
|
335
335
|
_ref8$isShowPopover = _ref8.isShowPopover,
|
|
336
|
-
isShowPopover = _ref8$isShowPopover === void 0 ? true : _ref8$isShowPopover
|
|
336
|
+
isShowPopover = _ref8$isShowPopover === void 0 ? true : _ref8$isShowPopover,
|
|
337
|
+
idKey = _ref8.idKey;
|
|
337
338
|
var getContentData = function getContentData(item, index) {
|
|
338
339
|
if (item.platformId) return {
|
|
339
340
|
text: "平台售后单号",
|
|
@@ -345,7 +346,7 @@ export var CommonOrderContent = function CommonOrderContent(_ref8) {
|
|
|
345
346
|
};
|
|
346
347
|
return {
|
|
347
348
|
text: "\u7CFB\u7EDF\u8BA2\u5355\u53F7".concat(index + 1),
|
|
348
|
-
id: item.systemOrderId || item.systemOrderNo
|
|
349
|
+
id: item.systemOrderId || item.systemOrderNo || (item === null || item === void 0 ? void 0 : item[idKey])
|
|
349
350
|
};
|
|
350
351
|
};
|
|
351
352
|
var orderContent = function orderContent(item, index) {
|
|
@@ -164,8 +164,8 @@ var typeMap = {
|
|
|
164
164
|
code: "jkyInStockStatusList",
|
|
165
165
|
name: "商品入库状态(勿填)",
|
|
166
166
|
type: 2,
|
|
167
|
-
valueKey: "
|
|
168
|
-
idKey: "
|
|
167
|
+
valueKey: "receiveStatus",
|
|
168
|
+
idKey: "sourceTradeNo",
|
|
169
169
|
failValue: "失败",
|
|
170
170
|
dataType: "array_object"
|
|
171
171
|
}
|
|
@@ -193,7 +193,7 @@ var CommonMultiStatus = /*#__PURE__*/_createClass(function CommonMultiStatus(opt
|
|
|
193
193
|
_defineProperty(this, "dataType", void 0);
|
|
194
194
|
_defineProperty(this, "isSingleValue", void 0);
|
|
195
195
|
_defineProperty(this, "renderClient", function (record) {
|
|
196
|
-
var _typeMap$_this$type, _typeMap$_this$type2, _typeMap$_this$type3;
|
|
196
|
+
var _typeMap$_this$type, _typeMap$_this$type2, _typeMap$_this$type3, _typeMap$_this$type4;
|
|
197
197
|
var isShow = Array.isArray(record === null || record === void 0 ? void 0 : record[_this.id]) ? some(record === null || record === void 0 ? void 0 : record[_this.id], function (item) {
|
|
198
198
|
return !isNull(item);
|
|
199
199
|
}) : false;
|
|
@@ -202,16 +202,17 @@ var CommonMultiStatus = /*#__PURE__*/_createClass(function CommonMultiStatus(opt
|
|
|
202
202
|
label: _this.name,
|
|
203
203
|
value: /*#__PURE__*/React.createElement(CommonOrderContent, {
|
|
204
204
|
list: record === null || record === void 0 ? void 0 : record[_this.id],
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
205
|
+
idKey: (_typeMap$_this$type = typeMap[_this.type]) === null || _typeMap$_this$type === void 0 ? void 0 : _typeMap$_this$type.idKey,
|
|
206
|
+
valueKey: (_typeMap$_this$type2 = typeMap[_this.type]) === null || _typeMap$_this$type2 === void 0 ? void 0 : _typeMap$_this$type2.valueKey,
|
|
207
|
+
failValue: (_typeMap$_this$type3 = typeMap[_this.type]) === null || _typeMap$_this$type3 === void 0 ? void 0 : _typeMap$_this$type3.failValue,
|
|
208
|
+
options: (_typeMap$_this$type4 = typeMap[_this.type]) === null || _typeMap$_this$type4 === void 0 ? void 0 : _typeMap$_this$type4.options,
|
|
208
209
|
isShowPopover: !_this.isSingleValue
|
|
209
210
|
})
|
|
210
211
|
}) : null;
|
|
211
212
|
});
|
|
212
213
|
_defineProperty(this, "renderPc", function (value, record) {
|
|
213
|
-
var _typeMap$_this$
|
|
214
|
-
var list = record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_").concat((_typeMap$_this$
|
|
214
|
+
var _typeMap$_this$type5, _typeMap$_this$type6, _typeMap$_this$type7, _typeMap$_this$type8, _typeMap$_this$type9;
|
|
215
|
+
var list = record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_").concat((_typeMap$_this$type5 = typeMap[_this.type]) === null || _typeMap$_this$type5 === void 0 ? void 0 : _typeMap$_this$type5.key)];
|
|
215
216
|
//兼容多个商品
|
|
216
217
|
return /*#__PURE__*/React.createElement("span", {
|
|
217
218
|
onClick: function onClick(e) {
|
|
@@ -219,40 +220,41 @@ var CommonMultiStatus = /*#__PURE__*/_createClass(function CommonMultiStatus(opt
|
|
|
219
220
|
}
|
|
220
221
|
}, /*#__PURE__*/React.createElement(CommonOrderContent, {
|
|
221
222
|
list: list,
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
223
|
+
idKey: (_typeMap$_this$type6 = typeMap[_this.type]) === null || _typeMap$_this$type6 === void 0 ? void 0 : _typeMap$_this$type6.idKey,
|
|
224
|
+
valueKey: (_typeMap$_this$type7 = typeMap[_this.type]) === null || _typeMap$_this$type7 === void 0 ? void 0 : _typeMap$_this$type7.valueKey,
|
|
225
|
+
failValue: (_typeMap$_this$type8 = typeMap[_this.type]) === null || _typeMap$_this$type8 === void 0 ? void 0 : _typeMap$_this$type8.failValue,
|
|
226
|
+
options: (_typeMap$_this$type9 = typeMap[_this.type]) === null || _typeMap$_this$type9 === void 0 ? void 0 : _typeMap$_this$type9.options,
|
|
225
227
|
isShowPopover: !_this.isSingleValue
|
|
226
228
|
}));
|
|
227
229
|
});
|
|
228
230
|
_defineProperty(this, "renderLog", function (r) {
|
|
229
|
-
var _typeMap$_this$
|
|
230
|
-
var list = r === null || r === void 0 ? void 0 : r["".concat(_this.id, "_").concat((_typeMap$_this$
|
|
231
|
+
var _typeMap$_this$type10;
|
|
232
|
+
var list = r === null || r === void 0 ? void 0 : r["".concat(_this.id, "_").concat((_typeMap$_this$type10 = typeMap[_this.type]) === null || _typeMap$_this$type10 === void 0 ? void 0 : _typeMap$_this$type10.key)];
|
|
231
233
|
if (isNull(list)) return null;
|
|
232
234
|
return _this.renderPc(undefined, r);
|
|
233
235
|
});
|
|
234
236
|
_defineProperty(this, "getComponentValue", function (r) {
|
|
235
|
-
var _typeMap$_this$
|
|
236
|
-
return r === null || r === void 0 ? void 0 : r["".concat(_this.id, "_").concat((_typeMap$_this$
|
|
237
|
+
var _typeMap$_this$type11;
|
|
238
|
+
return r === null || r === void 0 ? void 0 : r["".concat(_this.id, "_").concat((_typeMap$_this$type11 = typeMap[_this.type]) === null || _typeMap$_this$type11 === void 0 ? void 0 : _typeMap$_this$type11.key)];
|
|
237
239
|
});
|
|
238
240
|
_defineProperty(this, "renderExport", function (value, record) {
|
|
239
|
-
var _typeMap$_this$
|
|
240
|
-
var list = record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_").concat((_typeMap$_this$
|
|
241
|
+
var _typeMap$_this$type12;
|
|
242
|
+
var list = record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_").concat((_typeMap$_this$type12 = typeMap[_this.type]) === null || _typeMap$_this$type12 === void 0 ? void 0 : _typeMap$_this$type12.key)];
|
|
241
243
|
return (list || []).map(function (item) {
|
|
242
|
-
var _typeMap$_this$
|
|
243
|
-
var currentOption = (_typeMap$_this$
|
|
244
|
-
var _typeMap$_this$
|
|
245
|
-
return item[(_typeMap$_this$
|
|
244
|
+
var _typeMap$_this$type13, _typeMap$_this$type14, _typeMap$_this$type15, _typeMap$_this$type18, _typeMap$_this$type19;
|
|
245
|
+
var currentOption = (_typeMap$_this$type13 = typeMap[_this.type]) === null || _typeMap$_this$type13 === void 0 ? void 0 : (_typeMap$_this$type14 = _typeMap$_this$type13.options) === null || _typeMap$_this$type14 === void 0 ? void 0 : (_typeMap$_this$type15 = _typeMap$_this$type14.find) === null || _typeMap$_this$type15 === void 0 ? void 0 : _typeMap$_this$type15.call(_typeMap$_this$type14, function (option) {
|
|
246
|
+
var _typeMap$_this$type16;
|
|
247
|
+
return item[(_typeMap$_this$type16 = typeMap[_this.type]) === null || _typeMap$_this$type16 === void 0 ? void 0 : _typeMap$_this$type16.valueKey] === option.value;
|
|
246
248
|
});
|
|
247
249
|
if (_this.isSingleValue) {
|
|
248
|
-
var _typeMap$_this$
|
|
249
|
-
return currentOption ? (currentOption === null || currentOption === void 0 ? void 0 : currentOption.label) || "" : (item === null || item === void 0 ? void 0 : item[(_typeMap$_this$
|
|
250
|
+
var _typeMap$_this$type17;
|
|
251
|
+
return currentOption ? (currentOption === null || currentOption === void 0 ? void 0 : currentOption.label) || "" : (item === null || item === void 0 ? void 0 : item[(_typeMap$_this$type17 = typeMap[_this.type]) === null || _typeMap$_this$type17 === void 0 ? void 0 : _typeMap$_this$type17.valueKey]) || "";
|
|
250
252
|
}
|
|
251
|
-
return "".concat(item === null || item === void 0 ? void 0 : item[(_typeMap$_this$
|
|
253
|
+
return "".concat(item === null || item === void 0 ? void 0 : item[(_typeMap$_this$type18 = typeMap[_this.type]) === null || _typeMap$_this$type18 === void 0 ? void 0 : _typeMap$_this$type18.idKey], ":").concat(currentOption ? (currentOption === null || currentOption === void 0 ? void 0 : currentOption.label) || "" : (item === null || item === void 0 ? void 0 : item[(_typeMap$_this$type19 = typeMap[_this.type]) === null || _typeMap$_this$type19 === void 0 ? void 0 : _typeMap$_this$type19.valueKey]) || "");
|
|
252
254
|
}).join(",");
|
|
253
255
|
});
|
|
254
256
|
_defineProperty(this, "editRender", function (p) {
|
|
255
|
-
var _this$componentConfig, _this$componentConfig2, _this$componentConfig3, _this$componentConfig4, _typeMap$_this$
|
|
257
|
+
var _this$componentConfig, _this$componentConfig2, _this$componentConfig3, _this$componentConfig4, _typeMap$_this$type20;
|
|
256
258
|
return /*#__PURE__*/React.createElement(GetFormItem, {
|
|
257
259
|
title: _this.name,
|
|
258
260
|
name: _this.id,
|
|
@@ -262,17 +264,17 @@ var CommonMultiStatus = /*#__PURE__*/_createClass(function CommonMultiStatus(opt
|
|
|
262
264
|
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,
|
|
263
265
|
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 : "",
|
|
264
266
|
component: /*#__PURE__*/React.createElement(Status, _extends({}, _this.componentConfig, {
|
|
265
|
-
type: (_typeMap$_this$
|
|
267
|
+
type: (_typeMap$_this$type20 = typeMap[_this.type]) === null || _typeMap$_this$type20 === void 0 ? void 0 : _typeMap$_this$type20.type,
|
|
266
268
|
failValue: typeMap[_this.type].failValue
|
|
267
269
|
}))
|
|
268
270
|
});
|
|
269
271
|
});
|
|
270
272
|
_defineProperty(this, "filterConfig", function (item) {
|
|
271
|
-
var _typeMap$_this$
|
|
273
|
+
var _typeMap$_this$type21, _item$templateConfig;
|
|
272
274
|
return {
|
|
273
275
|
searchDefaultConditions: ["BS_E3_WAREHOUSING_STATUS", "WAREHOUSING_STATUS", "WDT_WAREHOUSING_STATUS", "JKY_WAREHOUSING_STATUS"].includes(_this.type) ? SYMBOL.in : SYMBOL.like,
|
|
274
276
|
type: item.type,
|
|
275
|
-
id: "".concat(item.id, "_").concat((_typeMap$_this$
|
|
277
|
+
id: "".concat(item.id, "_").concat((_typeMap$_this$type21 = typeMap[_this.type]) === null || _typeMap$_this$type21 === void 0 ? void 0 : _typeMap$_this$type21.code),
|
|
276
278
|
name: "".concat(_this.name),
|
|
277
279
|
filterComponentType: ["BS_E3_WAREHOUSING_STATUS", "WAREHOUSING_STATUS", "WDT_WAREHOUSING_STATUS", "JKY_WAREHOUSING_STATUS"].includes(_this.type) ? "MultipleSelect" : "SelectInput",
|
|
278
280
|
props: {
|
|
@@ -285,8 +287,8 @@ var CommonMultiStatus = /*#__PURE__*/_createClass(function CommonMultiStatus(opt
|
|
|
285
287
|
},
|
|
286
288
|
filterFn: function filterFn(value) {
|
|
287
289
|
return function (i) {
|
|
288
|
-
var _typeMap$_this$
|
|
289
|
-
return _filterFn.filterSplitComma(_filterFn.filterTableListItemColumnValue(i, item.id, (_typeMap$_this$
|
|
290
|
+
var _typeMap$_this$type22;
|
|
291
|
+
return _filterFn.filterSplitComma(_filterFn.filterTableListItemColumnValue(i, item.id, (_typeMap$_this$type22 = typeMap[_this.type]) === null || _typeMap$_this$type22 === void 0 ? void 0 : _typeMap$_this$type22.code), value);
|
|
290
292
|
};
|
|
291
293
|
},
|
|
292
294
|
formatFilterValue: ["BS_E3_WAREHOUSING_STATUS", "WAREHOUSING_STATUS", "WDT_WAREHOUSING_STATUS", "JKY_WAREHOUSING_STATUS"].includes(_this.type) ? null : function (value) {
|
|
@@ -314,17 +316,17 @@ var CommonMultiStatus = /*#__PURE__*/_createClass(function CommonMultiStatus(opt
|
|
|
314
316
|
required: true,
|
|
315
317
|
validator: function validator(_, value) {
|
|
316
318
|
var hasNo = (value || []).some(function (item) {
|
|
317
|
-
var _typeMap$_this$
|
|
318
|
-
return item[(_typeMap$_this$
|
|
319
|
+
var _typeMap$_this$type23;
|
|
320
|
+
return item[(_typeMap$_this$type23 = typeMap[_this.type]) === null || _typeMap$_this$type23 === void 0 ? void 0 : _typeMap$_this$type23.valueKey];
|
|
319
321
|
});
|
|
320
322
|
if (!hasNo) {
|
|
321
|
-
var _typeMap$_this$
|
|
322
|
-
return Promise.reject(new Error("\u81F3\u5C11\u586B\u5199\u4E00\u4E2A\u5B8C\u6574\u7684".concat((_typeMap$_this$
|
|
323
|
+
var _typeMap$_this$type24;
|
|
324
|
+
return Promise.reject(new Error("\u81F3\u5C11\u586B\u5199\u4E00\u4E2A\u5B8C\u6574\u7684".concat((_typeMap$_this$type24 = typeMap[_this.type]) === null || _typeMap$_this$type24 === void 0 ? void 0 : _typeMap$_this$type24.name)));
|
|
323
325
|
}
|
|
324
326
|
return Promise.resolve();
|
|
325
327
|
}
|
|
326
328
|
}] : [];
|
|
327
329
|
this.align = "left";
|
|
328
|
-
this.isSingleValue = ((_this$componentConfig6 = this.componentConfig) === null || _this$componentConfig6 === void 0 ? void 0 : _this$componentConfig6.belongType) === "wdt" || this.type === "BS_E3_WAREHOUSING_STATUS" || this.type === "WDT_WAREHOUSING_STATUS";
|
|
330
|
+
this.isSingleValue = ((_this$componentConfig6 = this.componentConfig) === null || _this$componentConfig6 === void 0 ? void 0 : _this$componentConfig6.belongType) === "wdt" || this.type === "BS_E3_WAREHOUSING_STATUS" || this.type === "WDT_WAREHOUSING_STATUS" || this.type === "JKY_WAREHOUSING_STATUS";
|
|
329
331
|
});
|
|
330
332
|
export default CommonMultiStatus;
|
|
@@ -16,7 +16,14 @@ declare class PublicGoods implements ComponentInterface {
|
|
|
16
16
|
children: ComponentInterface[];
|
|
17
17
|
dataType: ComponentInterface["dataType"];
|
|
18
18
|
headers: CommonHeaderGoods;
|
|
19
|
+
sortChildField: {
|
|
20
|
+
name: string;
|
|
21
|
+
key: string;
|
|
22
|
+
dataType: string;
|
|
23
|
+
[key: string]: any;
|
|
24
|
+
}[];
|
|
19
25
|
constructor(options: PickOption);
|
|
26
|
+
getSortChildFields: () => any;
|
|
20
27
|
renderClient: (record: any) => React.JSX.Element | null;
|
|
21
28
|
renderPc: () => null;
|
|
22
29
|
renderLog: (r: Record) => React.JSX.Element | null;
|
|
@@ -15,6 +15,7 @@ import CommonHeaderGoods from "../../CommonHeaderGood";
|
|
|
15
15
|
import ItemView from "../../../commonComponents/ItemView";
|
|
16
16
|
import { isNull } from "@kmkf-fe-packages/kmkf-utils";
|
|
17
17
|
import { CommonGoods as Goods } from "@kmkf-fe-packages/basic-components";
|
|
18
|
+
import { getColumnsMap } from "../../Common/constants/columnsBaseInfoMap";
|
|
18
19
|
import { SYMBOL } from "../../../constant";
|
|
19
20
|
var CONFIG_MAP = {
|
|
20
21
|
JST_GOODS: {
|
|
@@ -60,6 +61,19 @@ var PublicGoods = /*#__PURE__*/_createClass(function PublicGoods(options) {
|
|
|
60
61
|
_defineProperty(this, "children", void 0);
|
|
61
62
|
_defineProperty(this, "dataType", void 0);
|
|
62
63
|
_defineProperty(this, "headers", void 0);
|
|
64
|
+
_defineProperty(this, "sortChildField", void 0);
|
|
65
|
+
_defineProperty(this, "getSortChildFields", function () {
|
|
66
|
+
var Columns = getColumnsMap();
|
|
67
|
+
return Columns[_this.type].filter(function (item) {
|
|
68
|
+
return !["picUrl"].includes(item.dataIndex);
|
|
69
|
+
}).map(function (item) {
|
|
70
|
+
return {
|
|
71
|
+
name: item.title,
|
|
72
|
+
key: "".concat(_this.id, "_").concat(item.dataIndex),
|
|
73
|
+
dataType: "arrayObject"
|
|
74
|
+
};
|
|
75
|
+
});
|
|
76
|
+
});
|
|
63
77
|
_defineProperty(this, "renderClient", function (record) {
|
|
64
78
|
var _record, _CONFIG_MAP$_this$typ, _this$componentConfig;
|
|
65
79
|
return !isNull(record === null || record === void 0 ? void 0 : record["".concat(_this.id)]) ? /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(ItemView, {
|
|
@@ -150,5 +164,6 @@ var PublicGoods = /*#__PURE__*/_createClass(function PublicGoods(options) {
|
|
|
150
164
|
}
|
|
151
165
|
}] : [];
|
|
152
166
|
this.dataType = "object";
|
|
167
|
+
this.sortChildField = this.getSortChildFields();
|
|
153
168
|
});
|
|
154
169
|
export default PublicGoods;
|
package/dist/esm/factory.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { ReissueLogistics, JstItemSelect, JstSupply, JstSendGood, BasicInput, BasicAddress, BasicCascader, BasicCheckbox, BasicDataTime, BasicSelect, BasicRadio, BasicTextArea, BasicPicture, BasicPicturePro, 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, GyReissue, AfterSalesOrderId, BsE3Goods, PublicGoods, PublicReissueGoods, PublicExchange, GyGoods, BsE3Reissue, MemberLevel, GyReturn, AsyncSelect, WdtShopSelect, KmVideo, BasicTypeInput, SkxIdInputSelect, SkxGoods, BasicSelectOption, OrderSubForm, FlowOverallStatusSelect } from "./index";
|
|
2
2
|
import { PickOption } from "./type";
|
|
3
|
-
export declare const factory: (type: string, options: PickOption) => CommonMultiStatus | JstSendGood | MsgStatus |
|
|
3
|
+
export declare const factory: (type: string, options: PickOption) => BsLogistics | BsSystemOrder | CommonInput | CommonMultiStatus | BasicInput | JstSendGood | LogisticsMoreInterception | MsgStatus | OrderSubForm | PublicGoods | StatusSelect | SubForm | BasicTypeInput | BasicAddress | BasicCascader | BasicCheckbox | BasicDataTime | BasicSelect | BasicSelectOption | BasicRadio | BasicTextArea | BasicPicture | BasicPicturePro | BasicMultSelect | BasicGrade | BasicRate | BasicFile | BasicPosting | CommonDataTime | TradeId | ShopName | BuyerNick | ReceiverName | ReceiverMobile | ReceiverAddress | TradeDateTime | Logistics | ReturnLogistics | ActualPayment | ERemark | AliPay | ItemSelect | ItemId | ItemEnCode | SystemOrderNo | Ordinary | ThirdItemSelect | Payment | ReissueLogistics | JstItemSelect | JstSupply | BsGoods | BsE3Goods | PublicReissueGoods | PublicExchange | BsE3Reissue | BsExchange | BsReissue | BsReturn | FlowStatusSelect | FlowMarkSelect | FlowTag | TemplateSelect | WorkOrderId | LogisticsInterception | LogisticsTrajectory | LogisticsMoreTrajectory | PlatForm | ShopInput | Submitter | PrevSubmitter | FlowCreator | Handler | CompletedUser | FlowWorkOrderId | Calculation | CommonSystemOrder | NodeDeadLine | HandlerDeadLine | NodeStayDuration | WlnGoods | BsPosting | NodeInput | FlowWorkOrderStatus | WdtGoods | WdtReissue | WdtReturn | WdtExchange | WdtShopSelect | KmVideo | PaymentVoucherCode | Label | MemberLevel | AfterSalesOrderId | GyGoods | GyReissue | GyReturn | AsyncSelect | SkxIdInputSelect | SkxGoods | FlowOverallStatusSelect;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@kmkf-fe-packages/services-components",
|
|
3
|
-
"version": "2.2.44-beta.
|
|
3
|
+
"version": "2.2.44-beta.33",
|
|
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": "2.2.44-beta.
|
|
25
|
-
"@kmkf-fe-packages/kmkf-utils": "2.2.44-beta.
|
|
24
|
+
"@kmkf-fe-packages/basic-components": "2.2.44-beta.32",
|
|
25
|
+
"@kmkf-fe-packages/kmkf-utils": "2.2.44-beta.32",
|
|
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": "6da7ef5d28cb99736057d4921096f372ba83c260",
|
|
45
45
|
"gitHooks": {
|
|
46
46
|
"pre-commit": "lint-staged"
|
|
47
47
|
}
|