@kmkf-fe-packages/kmkf-utils 1.19.11 → 1.20.0
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.
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
export declare const BS_E3_BOOLEAN_STATUS_MAP: Record<number, string>;
|
|
2
2
|
export declare const BS_E3_ORDER_STATUS_MAP: Record<number, string>;
|
|
3
|
-
export declare const BS_E3_IS_GIFT_STATUS_MAP: Record<number, string>;
|
|
4
3
|
export declare const updateBsE3GoodsHandle: (orders?: any[]) => any;
|
|
5
4
|
export declare const bsE3OrderBackFormValues: (detail?: any, templateDetail?: any) => any;
|
|
6
5
|
export declare const bsE3OrderTransform: (detail: any, form: any) => {
|
|
@@ -10,6 +9,7 @@ export declare const bsE3OrderTransform: (detail: any, form: any) => {
|
|
|
10
9
|
selectIds: any;
|
|
11
10
|
showOrderInfo: any;
|
|
12
11
|
};
|
|
12
|
+
bsE3SystemOrderNo: any;
|
|
13
13
|
bsE3Goods: {
|
|
14
14
|
orders: any;
|
|
15
15
|
orderNo: any;
|
|
@@ -22,10 +22,6 @@ export var BS_E3_ORDER_STATUS_MAP = {
|
|
|
22
22
|
3: "已作废",
|
|
23
23
|
5: "已完成"
|
|
24
24
|
};
|
|
25
|
-
export var BS_E3_IS_GIFT_STATUS_MAP = {
|
|
26
|
-
0: "非赠品",
|
|
27
|
-
1: "赠品"
|
|
28
|
-
};
|
|
29
25
|
export var updateBsE3GoodsHandle = function updateBsE3GoodsHandle() {
|
|
30
26
|
var orders = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];
|
|
31
27
|
var list = orders.reduce(function (prv, next) {
|
|
@@ -33,7 +29,6 @@ export var updateBsE3GoodsHandle = function updateBsE3GoodsHandle() {
|
|
|
33
29
|
var goods = next === null || next === void 0 ? void 0 : (_next$orderDetailGets = next.orderDetailGets) === null || _next$orderDetailGets === void 0 ? void 0 : _next$orderDetailGets.map(function (item) {
|
|
34
30
|
return _objectSpread(_objectSpread({}, item), {}, {
|
|
35
31
|
mark: "是",
|
|
36
|
-
isGift: BS_E3_IS_GIFT_STATUS_MAP === null || BS_E3_IS_GIFT_STATUS_MAP === void 0 ? void 0 : BS_E3_IS_GIFT_STATUS_MAP[item.isGift],
|
|
37
32
|
canDelete: true,
|
|
38
33
|
uuid: uuid()
|
|
39
34
|
});
|
|
@@ -178,7 +173,11 @@ export var bsE3OrderBackFormValues = function bsE3OrderBackFormValues() {
|
|
|
178
173
|
// prv[uniqueKey] = detail?.bsExchangeGoods;
|
|
179
174
|
// break;
|
|
180
175
|
case "BS_E3_REISSUE_GOODS":
|
|
181
|
-
prv[uniqueKey] =
|
|
176
|
+
prv[uniqueKey] = {
|
|
177
|
+
bsE3SystemOrder: detail === null || detail === void 0 ? void 0 : detail.bsE3SystemOrder,
|
|
178
|
+
bsE3SystemOrderNo: detail === null || detail === void 0 ? void 0 : detail.bsE3SystemOrderNo,
|
|
179
|
+
bsE3ReissueGoods: []
|
|
180
|
+
};
|
|
182
181
|
break;
|
|
183
182
|
// case "BS_RETURN_GOODS":
|
|
184
183
|
// prv[uniqueKey] = detail?.bsReturnGoods;
|
|
@@ -258,7 +257,7 @@ export var bsE3OrderBackFormValues = function bsE3OrderBackFormValues() {
|
|
|
258
257
|
};
|
|
259
258
|
//bsE3订单信息转换
|
|
260
259
|
export var bsE3OrderTransform = function bsE3OrderTransform(detail, form) {
|
|
261
|
-
var _form$getFieldValue, _orderList$find, _orderList$find$call;
|
|
260
|
+
var _form$getFieldValue, _newOrderList$, _orderList$find, _orderList$find$call;
|
|
262
261
|
var orderNo = detail.orderNo,
|
|
263
262
|
_detail$orderList = detail.orderList,
|
|
264
263
|
orderList = _detail$orderList === void 0 ? [] : _detail$orderList,
|
|
@@ -268,32 +267,21 @@ export var bsE3OrderTransform = function bsE3OrderTransform(detail, form) {
|
|
|
268
267
|
});
|
|
269
268
|
var isStrict = bsE3GoodsCom ? (_form$getFieldValue = form.getFieldValue(bsE3GoodsCom.uniqueKey)) === null || _form$getFieldValue === void 0 ? void 0 : _form$getFieldValue.isStrict : false;
|
|
270
269
|
var newOrderList = orderList === null || orderList === void 0 ? void 0 : orderList.map(function (item) {
|
|
271
|
-
var isSplit = item.isSplit,
|
|
272
|
-
isSplitNew = item.isSplitNew,
|
|
273
|
-
isCopy = item.isCopy,
|
|
274
|
-
isExchangeOrder = item.isExchangeOrder,
|
|
275
|
-
isCombineNew = item.isCombineNew,
|
|
276
|
-
isCombine = item.isCombine,
|
|
277
|
-
orderStatus = item.orderStatus;
|
|
278
270
|
return _objectSpread(_objectSpread({}, item), {}, {
|
|
279
|
-
|
|
280
|
-
isSplit: BS_E3_BOOLEAN_STATUS_MAP[isSplit],
|
|
281
|
-
isSplitNew: BS_E3_BOOLEAN_STATUS_MAP[isSplitNew],
|
|
282
|
-
isExchangeOrder: BS_E3_BOOLEAN_STATUS_MAP[isExchangeOrder],
|
|
283
|
-
isCopy: BS_E3_BOOLEAN_STATUS_MAP[isCopy],
|
|
284
|
-
isCombineNew: BS_E3_BOOLEAN_STATUS_MAP[isCombineNew],
|
|
285
|
-
isCombine: BS_E3_BOOLEAN_STATUS_MAP[isCombine]
|
|
271
|
+
billNo: item.orderSn
|
|
286
272
|
});
|
|
287
273
|
});
|
|
288
274
|
return {
|
|
289
275
|
bsE3SystemOrder: {
|
|
290
276
|
orderNo: orderNo,
|
|
291
277
|
orders: newOrderList,
|
|
292
|
-
selectIds: (
|
|
278
|
+
selectIds: (newOrderList === null || newOrderList === void 0 ? void 0 : newOrderList.length) === 1 ? orderList.map(function (item) {
|
|
293
279
|
return item.orderSn;
|
|
294
280
|
}) : [],
|
|
295
281
|
showOrderInfo: newOrderList
|
|
296
282
|
},
|
|
283
|
+
// TODO: 当只有一条系统单时默认选中该系统单
|
|
284
|
+
bsE3SystemOrderNo: (newOrderList === null || newOrderList === void 0 ? void 0 : newOrderList.length) === 1 ? (_newOrderList$ = newOrderList[0]) === null || _newOrderList$ === void 0 ? void 0 : _newOrderList$.billNo : undefined,
|
|
297
285
|
bsE3Goods: {
|
|
298
286
|
// 订单反填,要清空orders,存的是当前系统订单号勾选上的 订单
|
|
299
287
|
orders: orderList || [],
|
|
@@ -7,7 +7,7 @@ export { default as getExpression } from "./getExpression";
|
|
|
7
7
|
export { default as formatDisplayConfig } from "./formatDisplayConfig";
|
|
8
8
|
export { default as orderBackFormValues } from "./orderBackFormValues";
|
|
9
9
|
export { bsOrderBackFormValues, bsOrderTransform, } from "./bsOrderBackFormValues";
|
|
10
|
-
export { bsE3OrderBackFormValues, bsE3OrderTransform, updateBsE3GoodsHandle, filterBsE3Orders, BS_E3_ORDER_STATUS_MAP, BS_E3_BOOLEAN_STATUS_MAP,
|
|
10
|
+
export { bsE3OrderBackFormValues, bsE3OrderTransform, updateBsE3GoodsHandle, filterBsE3Orders, BS_E3_ORDER_STATUS_MAP, BS_E3_BOOLEAN_STATUS_MAP, } from './bsE3OrderBackFormValues';
|
|
11
11
|
export { wlnOrderBackFormValues, wlnOrderTransform, } from "./wlnOrderBackFormValues";
|
|
12
12
|
export { wdtOrderBackFormValues, wdtOrderTransform, WDT_ORDER_TYPE_MAP, filterWdtOrders, updateWdtGoodsHandle, } from "./wdtOrderBackFormValues";
|
|
13
13
|
export { default as jstOrderBackFormValues } from "./jstOrderBackFormValues";
|
package/dist/esm/utils/index.js
CHANGED
|
@@ -7,7 +7,7 @@ export { default as getExpression } from "./getExpression";
|
|
|
7
7
|
export { default as formatDisplayConfig } from "./formatDisplayConfig";
|
|
8
8
|
export { default as orderBackFormValues } from "./orderBackFormValues";
|
|
9
9
|
export { bsOrderBackFormValues, bsOrderTransform } from "./bsOrderBackFormValues";
|
|
10
|
-
export { bsE3OrderBackFormValues, bsE3OrderTransform, updateBsE3GoodsHandle, filterBsE3Orders, BS_E3_ORDER_STATUS_MAP, BS_E3_BOOLEAN_STATUS_MAP
|
|
10
|
+
export { bsE3OrderBackFormValues, bsE3OrderTransform, updateBsE3GoodsHandle, filterBsE3Orders, BS_E3_ORDER_STATUS_MAP, BS_E3_BOOLEAN_STATUS_MAP } from "./bsE3OrderBackFormValues";
|
|
11
11
|
export { wlnOrderBackFormValues, wlnOrderTransform } from "./wlnOrderBackFormValues";
|
|
12
12
|
export { wdtOrderBackFormValues, wdtOrderTransform, WDT_ORDER_TYPE_MAP, filterWdtOrders, updateWdtGoodsHandle } from "./wdtOrderBackFormValues";
|
|
13
13
|
export { default as jstOrderBackFormValues } from "./jstOrderBackFormValues";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export default (function (key) {
|
|
2
|
-
return ["itemList", "itemId", "supplierName", "numIid", "aloneItemId", "aloneItemEncode", "jstItemList", "logisticsCompany", "logisticsCode", "supplyId", "supplyName", "sendId", "sendName", "dateTime", "basicMultSelect", "checkbox", "multSelect", "rate", "picture", "file", "wdtGoods", "wdtReissueType", "wdtSystemOrderNo", "wdtReissueGoods", "wdtSendGood", "wdtSendId", "wdtSendName", "wdtLogisticsCode", "wdtSystemShowOrder", "wdtSystemSelectIds", "wdtLogisticsCompany", "wdtLogisticsList", "wdtReturnGoods", "wdtReturnType", "wdtExchangeGoods", "bsSendGood", "bsSendId", "bsSendName", "bsGoods", "bsExchangeType", "bsExchangeReturnGoods", "bsExchangeSwapOutGoods", "bsExchangeGiftGoods", "bsReissueType", "bsReissueGoods", "bsReturnGoods", "bsReturnType", "bsLogisticsList", "bsLogisticsCompany", "bsLogisticsCode", "bsSystemShowOrder", "bsSystemSelectIds", "bsE3SystemOrderNo", "bsE3SystemShowOrder", "bsE3SystemSelectIds", "bsE3Goods", "reissueLogisticsList", "reissueLogisticsCompany", "reissueLogisticsCode", "deliveryNoList", "deliveryNoIds", "returnGoodsStatusList", "returnGoodsTradeIdList", "returnGoodsTradeItemList", "tradeIdList", "tradeItemList", "wlnLogisticsList", "wlnLogisticsCompany", "wlnLogisticsCode", "wlnSystemShowOrder", "wlnSystemSelectIds", "wlnGoods", "wlnSendGood", "wlnSendId", "wlnSendName", "exchangeReason", "flowTag", "returnGoodsStatusList", "returnGoodsStatusValue", "exchangeReason", "exchangeStatusValue", "inStockStatusItemList", "inStockStatusList", "reissueStatusValue", "reissueReason", "adjustWorkOrderStatusValue", "adjustWorkOrderReason", "msgStatusValues", "msgStatus4Search", "createStatusValue", "createReason", "invoiceStatusValue", "invoiceReason", "invoicingStatusValue", "invoicingReason", "trajectoryList", "trajectoryMoreCompany", "trajectoryMoreCode", "trajectoryMoreSnapshot", "logisticsInterceptList", "logisticsInterceptCompanyList", "logisticsInterceptCodeList", "logisticsInterceptTypeList", "logisticsInterceptStatusList", "logisticsInterceptApiStatusList", "interceptLogisticsApiStatus", "logisticsInterceptSnapshotList", "productList", "label", "kmSendGood", "kmSendId", "kmSendName"].reduce(function (cur, nxt) {
|
|
2
|
+
return ["itemList", "itemId", "supplierName", "numIid", "aloneItemId", "aloneItemEncode", "jstItemList", "logisticsCompany", "logisticsCode", "supplyId", "supplyName", "sendId", "sendName", "dateTime", "basicMultSelect", "checkbox", "multSelect", "rate", "picture", "file", "wdtGoods", "wdtReissueType", "wdtSystemOrderNo", "wdtReissueGoods", "wdtSendGood", "wdtSendId", "wdtSendName", "wdtLogisticsCode", "wdtSystemShowOrder", "wdtSystemSelectIds", "wdtLogisticsCompany", "wdtLogisticsList", "wdtReturnGoods", "wdtReturnType", "wdtExchangeGoods", "bsSendGood", "bsSendId", "bsSendName", "bsGoods", "bsExchangeType", "bsExchangeReturnGoods", "bsExchangeSwapOutGoods", "bsExchangeGiftGoods", "bsReissueType", "bsReissueGoods", "bsReturnGoods", "bsReturnType", "bsLogisticsList", "bsLogisticsCompany", "bsLogisticsCode", "bsSystemShowOrder", "bsSystemSelectIds", "bsE3SystemOrderNo", "bsE3SystemShowOrder", "bsE3SystemSelectIds", "bsE3Goods", "bsE3ReissueGoods", "bsE3ReissueType", "reissueLogisticsList", "reissueLogisticsCompany", "reissueLogisticsCode", "deliveryNoList", "deliveryNoIds", "returnGoodsStatusList", "returnGoodsTradeIdList", "returnGoodsTradeItemList", "tradeIdList", "tradeItemList", "wlnLogisticsList", "wlnLogisticsCompany", "wlnLogisticsCode", "wlnSystemShowOrder", "wlnSystemSelectIds", "wlnGoods", "wlnSendGood", "wlnSendId", "wlnSendName", "exchangeReason", "flowTag", "returnGoodsStatusList", "returnGoodsStatusValue", "exchangeReason", "exchangeStatusValue", "inStockStatusItemList", "inStockStatusList", "reissueStatusValue", "reissueReason", "adjustWorkOrderStatusValue", "adjustWorkOrderReason", "msgStatusValues", "msgStatus4Search", "createStatusValue", "createReason", "invoiceStatusValue", "invoiceReason", "invoicingStatusValue", "invoicingReason", "trajectoryList", "trajectoryMoreCompany", "trajectoryMoreCode", "trajectoryMoreSnapshot", "logisticsInterceptList", "logisticsInterceptCompanyList", "logisticsInterceptCodeList", "logisticsInterceptTypeList", "logisticsInterceptStatusList", "logisticsInterceptApiStatusList", "interceptLogisticsApiStatus", "logisticsInterceptSnapshotList", "productList", "label", "kmSendGood", "kmSendId", "kmSendName"].reduce(function (cur, nxt) {
|
|
3
3
|
return cur || (key === null || key === void 0 ? void 0 : key.includes(nxt));
|
|
4
4
|
}, false);
|
|
5
5
|
});
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@kmkf-fe-packages/kmkf-utils",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.20.0",
|
|
4
4
|
"module": "dist/esm/index.js",
|
|
5
5
|
"typings": "dist/esm/index.d.ts",
|
|
6
6
|
"files": [
|
|
@@ -41,7 +41,7 @@
|
|
|
41
41
|
"publishConfig": {
|
|
42
42
|
"access": "public"
|
|
43
43
|
},
|
|
44
|
-
"gitHead": "
|
|
44
|
+
"gitHead": "885c4ea232f39e0dde8083ffe34a8305dc616d26",
|
|
45
45
|
"gitHooks": {
|
|
46
46
|
"pre-commit": "lint-staged"
|
|
47
47
|
}
|