@kmkf-fe-packages/kmkf-utils 2.2.4 → 2.2.5-beta.17
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/README.md +1 -0
- package/dist/esm/constants/constant.d.ts +143 -0
- package/dist/esm/constants/constant.js +215 -0
- package/dist/esm/constants/index.d.ts +2 -1
- package/dist/esm/constants/index.js +3 -2
- package/dist/esm/constants/msgTypeMapping.js +2 -1
- package/dist/esm/hooks/index.d.ts +1 -0
- package/dist/esm/hooks/index.js +1 -0
- package/dist/esm/hooks/useStatus.d.ts +1 -0
- package/dist/esm/hooks/useStatus.js +32 -0
- package/dist/esm/index.d.ts +1 -0
- package/dist/esm/index.js +1 -0
- package/dist/esm/request/index.js +25 -8
- package/dist/esm/servers/JY/index.d.ts +2 -0
- package/dist/esm/servers/JY/index.js +2 -0
- package/dist/esm/servers/JY/logisticsData.d.ts +6 -0
- package/dist/esm/servers/JY/logisticsData.js +42 -0
- package/dist/esm/servers/JY/warehouseData.d.ts +7 -0
- package/dist/esm/servers/JY/warehouseData.js +38 -0
- package/dist/esm/servers/SKX/index.d.ts +1 -0
- package/dist/esm/servers/SKX/index.js +1 -0
- package/dist/esm/servers/SKX/order.d.ts +12 -0
- package/dist/esm/servers/SKX/order.js +41 -0
- package/dist/esm/servers/index.d.ts +11 -0
- package/dist/esm/servers/index.js +40 -0
- package/dist/esm/servers/orderSubForm/index.d.ts +37 -0
- package/dist/esm/servers/orderSubForm/index.js +71 -0
- package/dist/esm/servers/utils.d.ts +6 -0
- package/dist/esm/servers/utils.js +32 -0
- package/dist/esm/servers/workOrder/index.d.ts +58 -0
- package/dist/esm/servers/workOrder/index.js +106 -0
- package/dist/esm/utils/SendData.js +4 -2
- package/dist/esm/utils/finalFormData.d.ts +8 -0
- package/dist/esm/utils/finalFormData.js +164 -0
- package/dist/esm/utils/getExpression.js +6 -6
- package/dist/esm/utils/index.d.ts +7 -1
- package/dist/esm/utils/index.js +8 -2
- package/dist/esm/utils/jyOrderBackFormValues.d.ts +36 -0
- package/dist/esm/utils/jyOrderBackFormValues.js +307 -0
- package/dist/esm/utils/kmOrderBackFormValues.js +6 -9
- package/dist/esm/utils/orderBackFormValues.js +11 -1
- package/dist/esm/utils/orderSubFormOrderBackFormValues.d.ts +8 -0
- package/dist/esm/utils/orderSubFormOrderBackFormValues.js +37 -0
- package/dist/esm/utils/skxOrderBackFormValues.d.ts +1 -0
- package/dist/esm/utils/skxOrderBackFormValues.js +10 -7
- package/dist/esm/utils/skxReturnOrderBackFormValues.d.ts +32 -0
- package/dist/esm/utils/skxReturnOrderBackFormValues.js +154 -0
- package/dist/esm/utils/transformList.d.ts +3 -0
- package/dist/esm/utils/transformList.js +347 -0
- package/dist/esm/utils/transformWorkOrderData.d.ts +15 -0
- package/dist/esm/utils/transformWorkOrderData.js +1327 -0
- package/dist/esm/utils/unTransField.js +1 -1
- package/package.json +2 -2
- package/dist/esm/utils/dist/gyOrderBackFormValues.js +0 -285
|
@@ -0,0 +1,1327 @@
|
|
|
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 _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; }
|
|
5
|
+
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
|
|
6
|
+
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); }
|
|
7
|
+
import every from "lodash/every";
|
|
8
|
+
import maxBy from "lodash/maxBy";
|
|
9
|
+
import isNull from "./isNull";
|
|
10
|
+
export var updateWorkTypeKeys = {
|
|
11
|
+
BASIC_GRADE: "basicGrade",
|
|
12
|
+
TRADE_ID_INPUT: "tradeId",
|
|
13
|
+
SHOP_NAME_INPUT: "shopName",
|
|
14
|
+
RECEIVER_NAME_INPUT: "receiveName",
|
|
15
|
+
//收件人姓名
|
|
16
|
+
RECEIVER_MOBILE_INPUT: "receiveMobile",
|
|
17
|
+
//收件人手机号
|
|
18
|
+
TRADE_CREATE_DATETIME: "tradeCreateDateTime",
|
|
19
|
+
//下单时间
|
|
20
|
+
TRADE_PAYMENT_DATETIME: "tradePaymentDateTime",
|
|
21
|
+
//付款时间
|
|
22
|
+
TRADE_DELIVERY_DATETIME: "tradeDeliveryDateTime",
|
|
23
|
+
//发货时间
|
|
24
|
+
TRADE_CLOSING_DATETIME: "tradeClosingDateTime",
|
|
25
|
+
//成交时间
|
|
26
|
+
TRADE_SIGNING_DATETIME: "tradeSigningDateTime",
|
|
27
|
+
// 签收时间
|
|
28
|
+
ACTUAL_PAYMENT: "actualPayment",
|
|
29
|
+
SYSTEM_ORDER_NO: "systemOrderNo",
|
|
30
|
+
BS_SIGNING_TIME: "bsSigningTime",
|
|
31
|
+
BS_SEND_TIME: "bsSendTime",
|
|
32
|
+
BS_TRADE_PAYMENT_TIME: "bsTradePaymentTime",
|
|
33
|
+
BS_NET_RECEIPTS: "bsNetReceipts",
|
|
34
|
+
BS_PACKAGE_WEIGHT: "bsPackageWeight",
|
|
35
|
+
BS_DEPOSIT: "bsDeposit",
|
|
36
|
+
NEW_PAYMENT_STATUS: "newPaymentStatus",
|
|
37
|
+
BUSINESS_ORDER_NO: "businessOrderNo",
|
|
38
|
+
PAYMENT_VOUCHER_CODE: "paymentVoucherCode",
|
|
39
|
+
ACTUAL_RECEIPT_PAYMENT: "actualReceiptPayment",
|
|
40
|
+
WDT_SHOP: "shopCode"
|
|
41
|
+
};
|
|
42
|
+
export var systemOrderMap = {
|
|
43
|
+
BS_SYSTEM_ORDER: {
|
|
44
|
+
no: "bsSystemOrderNo",
|
|
45
|
+
ids: "bsSystemSelectIds",
|
|
46
|
+
order: "bsSystemShowOrder"
|
|
47
|
+
},
|
|
48
|
+
KM_SYSTEM_ORDER: {
|
|
49
|
+
no: "kmSystemOrderNo",
|
|
50
|
+
ids: "kmSystemSelectIds",
|
|
51
|
+
order: "kmSystemShowOrder"
|
|
52
|
+
},
|
|
53
|
+
WLN_SYSTEM_ORDER: {
|
|
54
|
+
no: "wlnSystemOrderNo",
|
|
55
|
+
ids: "wlnSystemSelectIds",
|
|
56
|
+
order: "wlnSystemShowOrder"
|
|
57
|
+
},
|
|
58
|
+
WDT_SYSTEM_ORDER: {
|
|
59
|
+
no: "wdtSystemOrderNo",
|
|
60
|
+
ids: "wdtSystemSelectIds",
|
|
61
|
+
order: "wdtSystemShowOrder"
|
|
62
|
+
},
|
|
63
|
+
BS_E3_SYSTEM_ORDER: {
|
|
64
|
+
no: "bsE3SystemOrderNo",
|
|
65
|
+
ids: "bsE3SystemSelectIds",
|
|
66
|
+
order: "bsE3SystemShowOrder"
|
|
67
|
+
},
|
|
68
|
+
GY_SYSTEM_ORDER: {
|
|
69
|
+
no: "gySystemOrderNo",
|
|
70
|
+
ids: "gySystemSelectIds",
|
|
71
|
+
order: "gySystemShowOrder"
|
|
72
|
+
},
|
|
73
|
+
JST_SYSTEM_ORDER: {
|
|
74
|
+
no: "jstSystemOrderNo",
|
|
75
|
+
ids: "jstSystemSelectIds",
|
|
76
|
+
order: "jstSystemShowOrder"
|
|
77
|
+
}
|
|
78
|
+
};
|
|
79
|
+
|
|
80
|
+
//直接将key component 添加到 transformWorkOrderData中的componentProcessors
|
|
81
|
+
export var processSingleFieldTypeMapping = {
|
|
82
|
+
SKX_OUTBOUND_NOTICE_NO: "skxOutboundNoticeNo",
|
|
83
|
+
SKX_SHOP_NAME: "skxShopName",
|
|
84
|
+
SKX_WAREHOUSE: "skxWarehouse",
|
|
85
|
+
SKX_ORDER_TYPE: "skxOrderType",
|
|
86
|
+
SKX_ORDER_STATUS: "skxOrderStatus",
|
|
87
|
+
SKX_CREATE_TIME: "dateTime"
|
|
88
|
+
};
|
|
89
|
+
export var jsonParseSecurity = function jsonParseSecurity(value, securityValue) {
|
|
90
|
+
try {
|
|
91
|
+
return JSON.parse(value);
|
|
92
|
+
} catch (e) {
|
|
93
|
+
// console.error('JSON解析异常', value, typeof value);
|
|
94
|
+
return securityValue;
|
|
95
|
+
}
|
|
96
|
+
};
|
|
97
|
+
export var transTextToNumber = function transTextToNumber(value) {
|
|
98
|
+
return value ? +value : value;
|
|
99
|
+
};
|
|
100
|
+
export var formatPictures = function formatPictures(pictures) {
|
|
101
|
+
pictures = pictures.replace(/[\[\]]/g, "");
|
|
102
|
+
pictures = pictures.replace(/\s/g, "");
|
|
103
|
+
pictures = pictures ? pictures.split(",") : [];
|
|
104
|
+
return pictures;
|
|
105
|
+
};
|
|
106
|
+
var getItemValue = function getItemValue(item) {
|
|
107
|
+
return function (key) {
|
|
108
|
+
return item.jsonMap[key];
|
|
109
|
+
};
|
|
110
|
+
};
|
|
111
|
+
var processRadio = function processRadio(getValue) {
|
|
112
|
+
return function (nex, config) {
|
|
113
|
+
var radio, radioOther;
|
|
114
|
+
if (config !== null && config !== void 0 && config.radio && (config === null || config === void 0 ? void 0 : config.radio) === "其他") {
|
|
115
|
+
radio = config.showOther ? config.radio : undefined;
|
|
116
|
+
radioOther = config.showOther ? config.radioOther : undefined;
|
|
117
|
+
}
|
|
118
|
+
if (config !== null && config !== void 0 && config.radio && (config === null || config === void 0 ? void 0 : config.radio) !== "其他") {
|
|
119
|
+
radio = ((config === null || config === void 0 ? void 0 : config.options) || []).some(function (t) {
|
|
120
|
+
return t.value === (config === null || config === void 0 ? void 0 : config.radio);
|
|
121
|
+
}) ? config.radio : undefined;
|
|
122
|
+
}
|
|
123
|
+
return _defineProperty({}, nex.uniqueKey, {
|
|
124
|
+
value: getValue("".concat(nex.uniqueKey, "_radio")) || radio,
|
|
125
|
+
other: getValue("".concat(nex.uniqueKey, "_radioOther")) || radioOther
|
|
126
|
+
});
|
|
127
|
+
};
|
|
128
|
+
};
|
|
129
|
+
var processInput = function processInput(getValue) {
|
|
130
|
+
return function (nex, config) {
|
|
131
|
+
var _getValue;
|
|
132
|
+
return _defineProperty({}, nex.uniqueKey, (_getValue = getValue("".concat(nex.uniqueKey, "_input"))) !== null && _getValue !== void 0 ? _getValue : config === null || config === void 0 ? void 0 : config.input);
|
|
133
|
+
};
|
|
134
|
+
};
|
|
135
|
+
var processNumericalCalculation = function processNumericalCalculation(getValue) {
|
|
136
|
+
return function (nex, config) {
|
|
137
|
+
var _getValue2;
|
|
138
|
+
return _defineProperty({}, nex.uniqueKey, (_getValue2 = getValue("".concat(nex.uniqueKey, "_numericalCalculation"))) !== null && _getValue2 !== void 0 ? _getValue2 : config === null || config === void 0 ? void 0 : config.numericalCalculation);
|
|
139
|
+
};
|
|
140
|
+
};
|
|
141
|
+
var processTextarea = function processTextarea(getValue) {
|
|
142
|
+
return function (nex, config) {
|
|
143
|
+
return _defineProperty({}, nex.uniqueKey, getValue("".concat(nex.uniqueKey, "_textarea")) || (config === null || config === void 0 ? void 0 : config.textarea));
|
|
144
|
+
};
|
|
145
|
+
};
|
|
146
|
+
var processSelect = function processSelect(getValue) {
|
|
147
|
+
return function (nex, config) {
|
|
148
|
+
var select = ((config === null || config === void 0 ? void 0 : config.options) || []).some(function (item) {
|
|
149
|
+
return item.value === (config === null || config === void 0 ? void 0 : config.select);
|
|
150
|
+
}) ? config.select : undefined;
|
|
151
|
+
return _defineProperty({}, nex.uniqueKey, getValue("".concat(nex.uniqueKey, "_select")) || select);
|
|
152
|
+
};
|
|
153
|
+
};
|
|
154
|
+
var gyPaymentMethod = function gyPaymentMethod(getValue) {
|
|
155
|
+
return function (nex, config) {
|
|
156
|
+
return _defineProperty({}, nex.uniqueKey, getValue("".concat(nex.uniqueKey, "_gyPaymentMethod")));
|
|
157
|
+
};
|
|
158
|
+
};
|
|
159
|
+
var processRate = function processRate(getValue) {
|
|
160
|
+
return function (nex, config) {
|
|
161
|
+
return _defineProperty({}, nex.uniqueKey, jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_rate")), []));
|
|
162
|
+
};
|
|
163
|
+
};
|
|
164
|
+
var processFile = function processFile(getValue) {
|
|
165
|
+
return function (nex, config) {
|
|
166
|
+
return _defineProperty({}, nex.uniqueKey, jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_file")), []));
|
|
167
|
+
};
|
|
168
|
+
};
|
|
169
|
+
var processKmVideo = function processKmVideo(getValue) {
|
|
170
|
+
return function (nex, config) {
|
|
171
|
+
return _defineProperty({}, nex.uniqueKey, jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_kmVideo")), []));
|
|
172
|
+
};
|
|
173
|
+
};
|
|
174
|
+
var processPosting = function processPosting(getValue) {
|
|
175
|
+
return function (nex, config) {
|
|
176
|
+
var address = [transTextToNumber(getValue("".concat(nex.uniqueKey, "_postingProvince"))), transTextToNumber(getValue("".concat(nex.uniqueKey, "_postingCity")))];
|
|
177
|
+
var interceptDistrict = transTextToNumber(getValue("".concat(nex.uniqueKey, "_postingDistrict")));
|
|
178
|
+
interceptDistrict && address.push(interceptDistrict);
|
|
179
|
+
address = every(address, function (item) {
|
|
180
|
+
return !item;
|
|
181
|
+
}) ? [] : address;
|
|
182
|
+
return _defineProperty({}, nex.uniqueKey, {
|
|
183
|
+
postingAddress: address,
|
|
184
|
+
postingDetail: getValue("".concat(nex.uniqueKey, "_postingDetail")),
|
|
185
|
+
postingReceiverName: getValue("".concat(nex.uniqueKey, "_postingReceiverName")),
|
|
186
|
+
postingReceiverMobile: getValue("".concat(nex.uniqueKey, "_postingReceiverMobile"))
|
|
187
|
+
});
|
|
188
|
+
};
|
|
189
|
+
};
|
|
190
|
+
var processBuyerNickInput = function processBuyerNickInput(getValue) {
|
|
191
|
+
return function (nex, config) {
|
|
192
|
+
return _defineProperty({}, nex.uniqueKey, {
|
|
193
|
+
buyerNick: getValue("".concat(nex.uniqueKey, "_buyerNick")),
|
|
194
|
+
buyerOpenUid: getValue("".concat(nex.uniqueKey, "_buyerOpenUid"))
|
|
195
|
+
});
|
|
196
|
+
};
|
|
197
|
+
};
|
|
198
|
+
var processAliPayInput = function processAliPayInput(getValue) {
|
|
199
|
+
return function (nex, config) {
|
|
200
|
+
var _ref12;
|
|
201
|
+
return _ref12 = {}, _defineProperty(_ref12, nex.uniqueKey, {
|
|
202
|
+
name: getValue("".concat(nex.uniqueKey, "_alipayName")),
|
|
203
|
+
user: getValue("".concat(nex.uniqueKey, "_alipayAccount"))
|
|
204
|
+
}), _defineProperty(_ref12, "".concat(nex.uniqueKey, "_alipayName"), getValue("".concat(nex.uniqueKey, "_alipayName"))), _defineProperty(_ref12, "".concat(nex.uniqueKey, "_alipayAccount"), getValue("".concat(nex.uniqueKey, "_alipayAccount"))), _ref12;
|
|
205
|
+
};
|
|
206
|
+
};
|
|
207
|
+
var processCheckbox = function processCheckbox(getValue) {
|
|
208
|
+
return function (nex, config) {
|
|
209
|
+
var _config$checkbox, _config$checkbox2, _config$checkbox3, _config$checkbox4;
|
|
210
|
+
var checkbox = [],
|
|
211
|
+
checkboxOther = "";
|
|
212
|
+
if (config !== null && config !== void 0 && (_config$checkbox = config.checkbox) !== null && _config$checkbox !== void 0 && _config$checkbox.length && config !== null && config !== void 0 && (_config$checkbox2 = config.checkbox) !== null && _config$checkbox2 !== void 0 && _config$checkbox2.includes("其他")) {
|
|
213
|
+
checkbox = config.showOther ? config.checkbox : config.checkbox.filter(function (t) {
|
|
214
|
+
return t !== "其他";
|
|
215
|
+
});
|
|
216
|
+
checkboxOther = config.showOther ? config.checkboxOther : undefined;
|
|
217
|
+
}
|
|
218
|
+
if (config !== null && config !== void 0 && (_config$checkbox3 = config.checkbox) !== null && _config$checkbox3 !== void 0 && _config$checkbox3.length && !(config !== null && config !== void 0 && (_config$checkbox4 = config.checkbox) !== null && _config$checkbox4 !== void 0 && _config$checkbox4.includes("其他"))) {
|
|
219
|
+
checkbox = ((config === null || config === void 0 ? void 0 : config.options) || []).reduce(function (prv, next) {
|
|
220
|
+
if (config.checkbox.includes(next.value)) {
|
|
221
|
+
prv.push(next.value);
|
|
222
|
+
}
|
|
223
|
+
return prv;
|
|
224
|
+
}, []);
|
|
225
|
+
}
|
|
226
|
+
return _defineProperty({}, nex.uniqueKey, {
|
|
227
|
+
value: jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_checkbox")), "") || checkbox,
|
|
228
|
+
other: getValue("".concat(nex.uniqueKey, "_checkboxOther")) || checkboxOther
|
|
229
|
+
});
|
|
230
|
+
};
|
|
231
|
+
};
|
|
232
|
+
var processDatetime = function processDatetime(getValue) {
|
|
233
|
+
return function (nex, config) {
|
|
234
|
+
var v = getValue("".concat(nex.uniqueKey, "_dateTime"));
|
|
235
|
+
return _defineProperty({}, nex.uniqueKey, jsonParseSecurity(v, v) || (config === null || config === void 0 ? void 0 : config.dateTime));
|
|
236
|
+
};
|
|
237
|
+
};
|
|
238
|
+
var processPicture = function processPicture(getValue) {
|
|
239
|
+
return function (nex, config) {
|
|
240
|
+
var v = getValue("".concat(nex.uniqueKey, "_picture"));
|
|
241
|
+
return _defineProperty({}, nex.uniqueKey, v ? formatPictures(v).map(function (item) {
|
|
242
|
+
return "".concat(item);
|
|
243
|
+
}) : (config === null || config === void 0 ? void 0 : config.picture) || []);
|
|
244
|
+
};
|
|
245
|
+
};
|
|
246
|
+
var processPicturePro = function processPicturePro(getValue) {
|
|
247
|
+
return function (nex, config) {
|
|
248
|
+
var v = getValue("".concat(nex.uniqueKey, "_pictureProList"));
|
|
249
|
+
var picturePro = jsonParseSecurity(v, v || []) || [];
|
|
250
|
+
return _defineProperty({}, nex.uniqueKey, picturePro ? picturePro.map(function (item) {
|
|
251
|
+
return _objectSpread(_objectSpread({}, item), {}, {
|
|
252
|
+
url: item.url ? formatPictures(item.url)[0] : ""
|
|
253
|
+
});
|
|
254
|
+
}) : (config === null || config === void 0 ? void 0 : config.pictureProList) || []);
|
|
255
|
+
};
|
|
256
|
+
};
|
|
257
|
+
var wdtTags = function wdtTags(getValue) {
|
|
258
|
+
return function (nex, config) {
|
|
259
|
+
return _defineProperty({}, nex.uniqueKey, jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_wdtTags")), []));
|
|
260
|
+
};
|
|
261
|
+
};
|
|
262
|
+
var processBasicMultSelect = function processBasicMultSelect(getValue) {
|
|
263
|
+
return function (nex, config) {
|
|
264
|
+
var v = getValue("".concat(nex.uniqueKey, "_basicMultSelect"));
|
|
265
|
+
var basicMultSelect = ((config === null || config === void 0 ? void 0 : config.options) || []).reduce(function (prv, next) {
|
|
266
|
+
var _config$basicMultSele;
|
|
267
|
+
if (config !== null && config !== void 0 && (_config$basicMultSele = config.basicMultSelect) !== null && _config$basicMultSele !== void 0 && _config$basicMultSele.includes(next.value)) {
|
|
268
|
+
prv.push(next.value);
|
|
269
|
+
}
|
|
270
|
+
return prv;
|
|
271
|
+
}, []);
|
|
272
|
+
return _defineProperty({}, nex.uniqueKey, jsonParseSecurity(v, "") || basicMultSelect);
|
|
273
|
+
};
|
|
274
|
+
};
|
|
275
|
+
var processMultSelect = function processMultSelect(getValue) {
|
|
276
|
+
return function (nex, config) {
|
|
277
|
+
var v = getValue("".concat(nex.uniqueKey, "_multSelect"));
|
|
278
|
+
var parseValue = jsonParseSecurity(v, v || []) || [];
|
|
279
|
+
return _defineProperty({}, nex.uniqueKey, parseValue === null || parseValue === void 0 ? void 0 : parseValue.map(function (item) {
|
|
280
|
+
return item.actived;
|
|
281
|
+
}));
|
|
282
|
+
};
|
|
283
|
+
};
|
|
284
|
+
var processBasicAddress = function processBasicAddress(getValue) {
|
|
285
|
+
return function (nex, config) {
|
|
286
|
+
var address = [transTextToNumber(getValue("".concat(nex.uniqueKey, "_basicProvince"))), transTextToNumber(getValue("".concat(nex.uniqueKey, "_basicCity"))), transTextToNumber(getValue("".concat(nex.uniqueKey, "_basicDistrict")))];
|
|
287
|
+
address = every(address, function (item) {
|
|
288
|
+
return !item;
|
|
289
|
+
}) ? [] : address;
|
|
290
|
+
return _defineProperty({}, nex.uniqueKey, address);
|
|
291
|
+
};
|
|
292
|
+
};
|
|
293
|
+
var processReceiverAddressInput = function processReceiverAddressInput(getValue) {
|
|
294
|
+
return function (nex, config) {
|
|
295
|
+
var address = [transTextToNumber(getValue("".concat(nex.uniqueKey, "_province"))), transTextToNumber(getValue("".concat(nex.uniqueKey, "_city"))), transTextToNumber(getValue("".concat(nex.uniqueKey, "_district")))];
|
|
296
|
+
address = every(address, function (item) {
|
|
297
|
+
return !item;
|
|
298
|
+
}) ? [] : address;
|
|
299
|
+
return _defineProperty({}, nex.uniqueKey, {
|
|
300
|
+
address: address,
|
|
301
|
+
detail: getValue("".concat(nex.uniqueKey, "_address"))
|
|
302
|
+
});
|
|
303
|
+
};
|
|
304
|
+
};
|
|
305
|
+
var processSubForm = function processSubForm(getValue) {
|
|
306
|
+
return function (nex, config) {
|
|
307
|
+
return _defineProperty({}, nex.uniqueKey, jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_productList")), []));
|
|
308
|
+
};
|
|
309
|
+
};
|
|
310
|
+
var processExpressLogisticsSelect = function processExpressLogisticsSelect(getValue) {
|
|
311
|
+
return function (nex, config) {
|
|
312
|
+
var _ref23;
|
|
313
|
+
return _ref23 = {}, _defineProperty(_ref23, nex.uniqueKey, {
|
|
314
|
+
company: getValue("".concat(nex.uniqueKey, "_expressLogisticsCompany")),
|
|
315
|
+
order: getValue("".concat(nex.uniqueKey, "_expressLogisticsCode"))
|
|
316
|
+
}), _defineProperty(_ref23, "".concat(nex.uniqueKey, "_expressLogisticsCompany"), getValue("".concat(nex.uniqueKey, "_expressLogisticsCompany"))), _defineProperty(_ref23, "".concat(nex.uniqueKey, "_expressLogisticsCode"), getValue("".concat(nex.uniqueKey, "_expressLogisticsCode"))), _ref23;
|
|
317
|
+
};
|
|
318
|
+
};
|
|
319
|
+
var processReturnLogisticsSelect = function processReturnLogisticsSelect(getValue) {
|
|
320
|
+
return function (nex, config) {
|
|
321
|
+
var _ref24;
|
|
322
|
+
return _ref24 = {}, _defineProperty(_ref24, nex.uniqueKey, {
|
|
323
|
+
company: getValue("".concat(nex.uniqueKey, "_returnLogisticsCompany")),
|
|
324
|
+
order: getValue("".concat(nex.uniqueKey, "_returnLogisticsCode"))
|
|
325
|
+
}), _defineProperty(_ref24, "".concat(nex.uniqueKey, "_returnLogisticsCompany"), getValue("".concat(nex.uniqueKey, "_returnLogisticsCompany"))), _defineProperty(_ref24, "".concat(nex.uniqueKey, "_returnLogisticsCode"), getValue("".concat(nex.uniqueKey, "_returnLogisticsCode"))), _ref24;
|
|
326
|
+
};
|
|
327
|
+
};
|
|
328
|
+
var processRemarkInput = function processRemarkInput(getValue) {
|
|
329
|
+
return function (nex, config) {
|
|
330
|
+
var v = getValue("".concat(nex.uniqueKey, "_flag"));
|
|
331
|
+
var remark = getValue("".concat(nex.uniqueKey, "_remark"));
|
|
332
|
+
return _defineProperty({}, nex.uniqueKey, {
|
|
333
|
+
flag: v ? +v : config !== null && config !== void 0 && config.flag ? +(config === null || config === void 0 ? void 0 : config.flag) : "",
|
|
334
|
+
remark: remark || (config === null || config === void 0 ? void 0 : config.remark) || ""
|
|
335
|
+
});
|
|
336
|
+
};
|
|
337
|
+
};
|
|
338
|
+
var processStatus = function processStatus(getValue) {
|
|
339
|
+
return function (nex, config) {
|
|
340
|
+
var _ref26;
|
|
341
|
+
var customerService = getValue("".concat(nex.uniqueKey, "_customerService"));
|
|
342
|
+
return _ref26 = {}, _defineProperty(_ref26, nex.uniqueKey, {
|
|
343
|
+
status: getValue("".concat(nex.uniqueKey, "_status")) || (config === null || config === void 0 ? void 0 : config.status),
|
|
344
|
+
customerService: jsonParseSecurity(customerService, customerService)
|
|
345
|
+
}), _defineProperty(_ref26, "".concat(nex.uniqueKey, "_processTime"), getValue("processTime")), _defineProperty(_ref26, "".concat(nex.uniqueKey, "_lastProcessingTime"), getValue("lastProcessingTime")), _ref26;
|
|
346
|
+
};
|
|
347
|
+
};
|
|
348
|
+
var processOrdinaryInvoice = function processOrdinaryInvoice(getValue) {
|
|
349
|
+
return function (nex, config) {
|
|
350
|
+
var _ref27;
|
|
351
|
+
var ordinaryMoney = getValue("".concat(nex.uniqueKey, "_ordinaryMoney"));
|
|
352
|
+
var ordinarySerial = getValue("".concat(nex.uniqueKey, "_ordinarySerial"));
|
|
353
|
+
var ordinaryTaitou = getValue("".concat(nex.uniqueKey, "_ordinaryTaitou"));
|
|
354
|
+
return _ref27 = {}, _defineProperty(_ref27, nex.uniqueKey, {
|
|
355
|
+
ordinaryMoney: ordinaryMoney,
|
|
356
|
+
ordinarySerial: ordinarySerial,
|
|
357
|
+
ordinaryTaitou: ordinaryTaitou
|
|
358
|
+
}), _defineProperty(_ref27, "".concat(nex.uniqueKey, "_ordinaryMoney"), ordinaryMoney ? Number(ordinaryMoney).toFixed(2) : null), _defineProperty(_ref27, "".concat(nex.uniqueKey, "_ordinarySerial"), ordinarySerial), _defineProperty(_ref27, "".concat(nex.uniqueKey, "_ordinaryTaitou"), ordinaryTaitou), _ref27;
|
|
359
|
+
};
|
|
360
|
+
};
|
|
361
|
+
var processLogisticsInterception = function processLogisticsInterception(getValue) {
|
|
362
|
+
return function (nex, config) {
|
|
363
|
+
var address = [transTextToNumber(getValue("".concat(nex.uniqueKey, "_interceptProvince"))), transTextToNumber(getValue("".concat(nex.uniqueKey, "_interceptCity")))];
|
|
364
|
+
//兼容地址是只有省市的
|
|
365
|
+
var interceptDistrict = transTextToNumber(getValue("".concat(nex.uniqueKey, "_interceptDistrict")));
|
|
366
|
+
interceptDistrict && address.push(interceptDistrict);
|
|
367
|
+
address = every(address, function (item) {
|
|
368
|
+
return !item;
|
|
369
|
+
}) ? [] : address;
|
|
370
|
+
var subFields = ["interceptCompany", "interceptCode", "interceptType", "interceptSenderMobile", "interceptDetail", "interceptReceiverName", "interceptReceiverMobile", "interceptLogisticsStatus", "interceptLogisticsStatusOther", "interceptLogisticsSnapshot", "qySelfInterceptLogisticsStatus", "interceptLogisticsUserKCode", "interceptLogisticsUserSecretKey"];
|
|
371
|
+
var map = subFields.reduce(function (cur, nxt) {
|
|
372
|
+
return _objectSpread(_objectSpread({}, cur), {}, _defineProperty({}, nxt, getValue("".concat(nex.uniqueKey, "_").concat(nxt))));
|
|
373
|
+
}, {});
|
|
374
|
+
return _defineProperty({}, nex.uniqueKey, _objectSpread(_objectSpread({}, map), {}, {
|
|
375
|
+
interceptAddress: address,
|
|
376
|
+
interceptLogisticsApiStatus: jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_interceptLogisticsApiStatus")), {})
|
|
377
|
+
}));
|
|
378
|
+
};
|
|
379
|
+
};
|
|
380
|
+
var processLogisticsInterceptionMore = function processLogisticsInterceptionMore(getValue) {
|
|
381
|
+
return function (nex, config) {
|
|
382
|
+
return _defineProperty({}, nex.uniqueKey, jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_logisticsInterceptList")), [{}]));
|
|
383
|
+
};
|
|
384
|
+
};
|
|
385
|
+
var processLogisticsTrajectory = function processLogisticsTrajectory(getValue) {
|
|
386
|
+
return function (nex, config) {
|
|
387
|
+
var subFields = ["trajectoryCompany", "trajectoryCode", "trajectorySnapshot", "trajectoryPhone", "trajectoryApiStatus"];
|
|
388
|
+
var map = subFields.reduce(function (cur, nxt) {
|
|
389
|
+
return nxt === "trajectoryApiStatus" ? _objectSpread(_objectSpread({}, cur), {}, _defineProperty({}, nxt, jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_trajectoryApiStatus")), {}))) : _objectSpread(_objectSpread({}, cur), {}, _defineProperty({}, nxt, getValue("".concat(nex.uniqueKey, "_").concat(nxt))));
|
|
390
|
+
}, {});
|
|
391
|
+
return _defineProperty({}, nex.uniqueKey, map);
|
|
392
|
+
};
|
|
393
|
+
};
|
|
394
|
+
var processLogisticsTrajectoryMore = function processLogisticsTrajectoryMore(getValue) {
|
|
395
|
+
return function (nex, config) {
|
|
396
|
+
return _defineProperty({}, nex.uniqueKey, jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_trajectoryList")), []));
|
|
397
|
+
};
|
|
398
|
+
};
|
|
399
|
+
var processGoods = function processGoods(getValue) {
|
|
400
|
+
return function (nex, config) {
|
|
401
|
+
return _defineProperty({}, nex.uniqueKey, jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_itemList")), []));
|
|
402
|
+
};
|
|
403
|
+
};
|
|
404
|
+
var processItemSelectThird = function processItemSelectThird(getValue) {
|
|
405
|
+
return function (nex, config) {
|
|
406
|
+
var itemList = jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_itemList")), []);
|
|
407
|
+
itemList.forEach(function (key) {
|
|
408
|
+
key.itemId = key.itemId || key.supplierItemOuterId;
|
|
409
|
+
});
|
|
410
|
+
return _defineProperty({}, nex.uniqueKey, itemList);
|
|
411
|
+
};
|
|
412
|
+
};
|
|
413
|
+
var processEnterPrisePayment = function processEnterPrisePayment(getValue) {
|
|
414
|
+
return function (nex, config) {
|
|
415
|
+
var _ref34;
|
|
416
|
+
var subFields = ["enterprisePaymentAlipayNick", "enterprisePaymentAlipayNo", "enterprisePaymentBuyerNick", "enterprisePaymentBuyerOpenUid", "enterprisePaymentRefundFee", "enterprisePaymentStatus", "enterprisePaymentTid"];
|
|
417
|
+
var map = subFields.reduce(function (cur, nxt) {
|
|
418
|
+
return _objectSpread(_objectSpread({}, cur), {}, _defineProperty({}, nxt, getValue("".concat(nex.uniqueKey, "_").concat(nxt))));
|
|
419
|
+
}, {});
|
|
420
|
+
return _ref34 = {}, _defineProperty(_ref34, nex.uniqueKey, map), _defineProperty(_ref34, "".concat(nex.uniqueKey, "_enterprisePaymentAlipayNick"), getValue("".concat(nex.uniqueKey, "_enterprisePaymentAlipayNick"))), _defineProperty(_ref34, "".concat(nex.uniqueKey, "_enterprisePaymentAlipayNo"), getValue("".concat(nex.uniqueKey, "_enterprisePaymentAlipayNo"))), _defineProperty(_ref34, "".concat(nex.uniqueKey, "_enterprisePaymentBuyerNick"), getValue("".concat(nex.uniqueKey, "_enterprisePaymentBuyerNick"))), _defineProperty(_ref34, "".concat(nex.uniqueKey, "_enterprisePaymentRefundFee"), getValue("".concat(nex.uniqueKey, "_enterprisePaymentRefundFee"))), _defineProperty(_ref34, "".concat(nex.uniqueKey, "_enterprisePaymentStatus"), getValue("".concat(nex.uniqueKey, "_enterprisePaymentStatus"))), _defineProperty(_ref34, "".concat(nex.uniqueKey, "_enterprisePaymentTime"), getValue("".concat(nex.uniqueKey, "_enterprisePaymentTime"))), _defineProperty(_ref34, "".concat(nex.uniqueKey, "_enterprisePaymentTid"), getValue("".concat(nex.uniqueKey, "_enterprisePaymentTid"))), _ref34;
|
|
421
|
+
};
|
|
422
|
+
};
|
|
423
|
+
var processJstLogistics = function processJstLogistics(getValue) {
|
|
424
|
+
return function (nex, config) {
|
|
425
|
+
var initValue = [{
|
|
426
|
+
logisticsCompany: null,
|
|
427
|
+
logisticsCode: null
|
|
428
|
+
}];
|
|
429
|
+
var itemList = jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_jstItemList")), initValue);
|
|
430
|
+
return _defineProperty({}, nex.uniqueKey, itemList !== null && itemList !== void 0 && itemList.length ? itemList : initValue);
|
|
431
|
+
};
|
|
432
|
+
};
|
|
433
|
+
var processJstItemSelectThird = function processJstItemSelectThird(getValue) {
|
|
434
|
+
return function (nex, config) {
|
|
435
|
+
var itemList = jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_jstItemList")), []);
|
|
436
|
+
return _defineProperty({}, nex.uniqueKey, itemList);
|
|
437
|
+
};
|
|
438
|
+
};
|
|
439
|
+
var processJstSupply = function processJstSupply(getValue) {
|
|
440
|
+
return function (nex, config) {
|
|
441
|
+
var initValue = [{
|
|
442
|
+
supplyId: null
|
|
443
|
+
}];
|
|
444
|
+
var itemList = jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_jstItemList")), initValue);
|
|
445
|
+
return _defineProperty({}, nex.uniqueKey, itemList !== null && itemList !== void 0 && itemList.length ? itemList : initValue);
|
|
446
|
+
};
|
|
447
|
+
};
|
|
448
|
+
var processJstSendGood = function processJstSendGood(getValue) {
|
|
449
|
+
return function (nex, config) {
|
|
450
|
+
var initValue = [{
|
|
451
|
+
sendName: "",
|
|
452
|
+
sendId: "",
|
|
453
|
+
sendSnapshotId: ""
|
|
454
|
+
}];
|
|
455
|
+
var itemList = jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_jstItemList")), initValue);
|
|
456
|
+
return _defineProperty({}, nex.uniqueKey, itemList !== null && itemList !== void 0 && itemList.length ? itemList : initValue);
|
|
457
|
+
};
|
|
458
|
+
};
|
|
459
|
+
var processBsMemo = function processBsMemo(getValue) {
|
|
460
|
+
return function (nex, config) {
|
|
461
|
+
return _defineProperty({}, nex.uniqueKey, {
|
|
462
|
+
remark: getValue("".concat(nex.uniqueKey, "_bsRemark")),
|
|
463
|
+
flag: getValue("".concat(nex.uniqueKey, "_bsFlag"))
|
|
464
|
+
});
|
|
465
|
+
};
|
|
466
|
+
};
|
|
467
|
+
var processReissueLogistics = function processReissueLogistics(getValue) {
|
|
468
|
+
return function (nex, config) {
|
|
469
|
+
var itemList = jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_reissueLogisticsList")), []);
|
|
470
|
+
return _defineProperty({}, nex.uniqueKey, itemList);
|
|
471
|
+
};
|
|
472
|
+
};
|
|
473
|
+
var processCallBackStatus = function processCallBackStatus(getValue) {
|
|
474
|
+
return function (nex, config) {
|
|
475
|
+
var STATUS_MAP = {
|
|
476
|
+
REISSUE_STATUS: {
|
|
477
|
+
status: "reissueStatusValue",
|
|
478
|
+
reason: "reissueReason"
|
|
479
|
+
},
|
|
480
|
+
ADJUST_WORK_ORDER_STATUS: {
|
|
481
|
+
status: "adjustWorkOrderStatusValue",
|
|
482
|
+
reason: "adjustWorkOrderReason"
|
|
483
|
+
},
|
|
484
|
+
CREATE_STATUS: {
|
|
485
|
+
status: "createStatusValue",
|
|
486
|
+
reason: "createReason"
|
|
487
|
+
},
|
|
488
|
+
INVOICE_STATUS: {
|
|
489
|
+
status: "invoiceStatusValue",
|
|
490
|
+
reason: "invoiceReason"
|
|
491
|
+
},
|
|
492
|
+
INVOICING_STATUS: {
|
|
493
|
+
status: "invoicingStatusValue",
|
|
494
|
+
reason: "invoicingReason"
|
|
495
|
+
},
|
|
496
|
+
AGREE_REFUND_STATUS: {
|
|
497
|
+
status: "agreeRefundStatusValue",
|
|
498
|
+
reason: "agreeRefundStatusReason"
|
|
499
|
+
},
|
|
500
|
+
REJECT_REFUND_STATUS: {
|
|
501
|
+
status: "rejectRefundStatusValue",
|
|
502
|
+
reason: "rejectRefundStatusReason"
|
|
503
|
+
},
|
|
504
|
+
AGREE_RETURN_GOODS_STATUS: {
|
|
505
|
+
status: "agreeReturnGoodsStatusValue",
|
|
506
|
+
reason: "agreeReturnGoodsStatusReason"
|
|
507
|
+
},
|
|
508
|
+
REJECT_RETURN_GOODS_STATUS: {
|
|
509
|
+
status: "rejectReturnGoodsStatusValue",
|
|
510
|
+
reason: "rejectReturnGoodsStatusReason"
|
|
511
|
+
},
|
|
512
|
+
ERP_AFTER_SALE_STATUS: {
|
|
513
|
+
status: "erpAfterSaleStatusValue",
|
|
514
|
+
reason: "erpAfterSaleStatusReason"
|
|
515
|
+
},
|
|
516
|
+
RETURN_EXCHANGE_GOODS_REVIEW_STATUS: {
|
|
517
|
+
status: "returnExchangeGoodsReviewStatusValue",
|
|
518
|
+
reason: "returnExchangeGoodsReviewStatusReason"
|
|
519
|
+
}
|
|
520
|
+
};
|
|
521
|
+
return _defineProperty({}, nex.uniqueKey, {
|
|
522
|
+
status: getValue("".concat(nex.uniqueKey, "_").concat(STATUS_MAP[nex.workOrderComponentType].status)),
|
|
523
|
+
reason: getValue("".concat(nex.uniqueKey, "_").concat(STATUS_MAP[nex.workOrderComponentType].reason))
|
|
524
|
+
});
|
|
525
|
+
};
|
|
526
|
+
};
|
|
527
|
+
var processSceneStatus = function processSceneStatus(getValue) {
|
|
528
|
+
return function (nex, config) {
|
|
529
|
+
var STATUS_LIST_MAP = {
|
|
530
|
+
RETURN_GOODS_STATUS: "returnGoodsStatusList",
|
|
531
|
+
EXCHANGE_STATUS: "exchangeReason",
|
|
532
|
+
WAREHOUSING_STATUS: "inStockStatusItemList",
|
|
533
|
+
BS_E3_WAREHOUSING_STATUS: "bsE3InStockStatusItemList",
|
|
534
|
+
MSG_STATUS: "msgStatusValues",
|
|
535
|
+
WDT_WAREHOUSING_STATUS: "wdtInStockStatusItemList"
|
|
536
|
+
};
|
|
537
|
+
return _defineProperty({}, nex.uniqueKey, jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_").concat(STATUS_LIST_MAP[nex.workOrderComponentType])), []));
|
|
538
|
+
};
|
|
539
|
+
};
|
|
540
|
+
var processErpLogistics = function processErpLogistics(getValue) {
|
|
541
|
+
return function (nex, config) {
|
|
542
|
+
var LogisticsMap = {
|
|
543
|
+
BS_LOGISTICS: {
|
|
544
|
+
listKey: "bsLogisticsList"
|
|
545
|
+
},
|
|
546
|
+
WLN_LOGISTICS: {
|
|
547
|
+
listKey: "wlnLogisticsList"
|
|
548
|
+
},
|
|
549
|
+
WDT_LOGISTICS: {
|
|
550
|
+
listKey: "wdtLogisticsList"
|
|
551
|
+
},
|
|
552
|
+
BS_E3_LOGISTICS: {
|
|
553
|
+
listKey: "bsE3LogisticsList"
|
|
554
|
+
},
|
|
555
|
+
KM_LOGISTICS: {
|
|
556
|
+
listKey: "kmLogisticsList"
|
|
557
|
+
},
|
|
558
|
+
GY_LOGISTICS: {
|
|
559
|
+
listKey: "gyLogisticsList"
|
|
560
|
+
},
|
|
561
|
+
SKX_LOGISTICS: {
|
|
562
|
+
listKey: "skxLogisticsList"
|
|
563
|
+
}
|
|
564
|
+
};
|
|
565
|
+
var initValue = [{
|
|
566
|
+
logisticsCompany: null,
|
|
567
|
+
logisticsCode: null
|
|
568
|
+
}];
|
|
569
|
+
var itemList = jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_").concat(LogisticsMap[nex.workOrderComponentType].listKey)), initValue);
|
|
570
|
+
return _defineProperty({}, nex.uniqueKey, itemList !== null && itemList !== void 0 && itemList.length ? itemList : initValue);
|
|
571
|
+
};
|
|
572
|
+
};
|
|
573
|
+
var processErpSendGood = function processErpSendGood(getValue) {
|
|
574
|
+
return function (nex, config) {
|
|
575
|
+
var sendGoodMap = {
|
|
576
|
+
BS_SEND_GOOD: {
|
|
577
|
+
list: "bsSendGood"
|
|
578
|
+
},
|
|
579
|
+
WLN_SEND_GOOD: {
|
|
580
|
+
list: "wlnSendGood"
|
|
581
|
+
},
|
|
582
|
+
WDT_SEND_GOOD: {
|
|
583
|
+
list: "wdtSendGood"
|
|
584
|
+
},
|
|
585
|
+
KM_SEND_GOOD: {
|
|
586
|
+
list: "kmSendGood"
|
|
587
|
+
},
|
|
588
|
+
BS_E3_SEND_GOOD: {
|
|
589
|
+
list: "bsE3SendGood"
|
|
590
|
+
},
|
|
591
|
+
GY_SEND_GOOD: {
|
|
592
|
+
list: "gySendGood"
|
|
593
|
+
}
|
|
594
|
+
};
|
|
595
|
+
var initValue = [{
|
|
596
|
+
sendName: "",
|
|
597
|
+
sendId: ""
|
|
598
|
+
}];
|
|
599
|
+
var itemList = jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_").concat(sendGoodMap[nex.workOrderComponentType].list)), initValue);
|
|
600
|
+
return _defineProperty({}, nex.uniqueKey, itemList !== null && itemList !== void 0 && itemList.length ? itemList : initValue);
|
|
601
|
+
};
|
|
602
|
+
};
|
|
603
|
+
var processBsPosting = function processBsPosting(getValue) {
|
|
604
|
+
return function (nex, config) {
|
|
605
|
+
var bsAddress = [transTextToNumber(getValue("".concat(nex.uniqueKey, "_bsPostingProvince"))), transTextToNumber(getValue("".concat(nex.uniqueKey, "_bsPostingCity")))];
|
|
606
|
+
//兼容地址是只有省市的
|
|
607
|
+
var bsInterceptDistrict = transTextToNumber(getValue("".concat(nex.uniqueKey, "_bsPostingDistrict")));
|
|
608
|
+
bsInterceptDistrict && bsAddress.push(bsInterceptDistrict);
|
|
609
|
+
bsAddress = every(bsAddress, function (item) {
|
|
610
|
+
return !item;
|
|
611
|
+
}) ? [] : bsAddress;
|
|
612
|
+
return _defineProperty({}, nex.uniqueKey, {
|
|
613
|
+
postingAddress: bsAddress,
|
|
614
|
+
postingDetail: getValue("".concat(nex.uniqueKey, "_bsPostingDetail")),
|
|
615
|
+
postingReceiverName: getValue("".concat(nex.uniqueKey, "_bsPostingReceiverName")),
|
|
616
|
+
postingReceiverMobile: getValue("".concat(nex.uniqueKey, "_bsPostingReceiverMobile"))
|
|
617
|
+
});
|
|
618
|
+
};
|
|
619
|
+
};
|
|
620
|
+
var processBsGoods = function processBsGoods(getValue) {
|
|
621
|
+
return function (nex, config) {
|
|
622
|
+
var _values = {
|
|
623
|
+
bsGoods: jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_bsGoods")), []),
|
|
624
|
+
shopCode: getValue("".concat(nex.uniqueKey, "_shopCode"))
|
|
625
|
+
};
|
|
626
|
+
return _defineProperty({}, nex.uniqueKey, _values);
|
|
627
|
+
};
|
|
628
|
+
};
|
|
629
|
+
var processWdtGoods = function processWdtGoods(templateColumns) {
|
|
630
|
+
return function (getValue) {
|
|
631
|
+
return function (nex, config) {
|
|
632
|
+
var _values = {
|
|
633
|
+
wdtGoods: jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_wdtGoods")), []),
|
|
634
|
+
shopCode: getValue("".concat(nex.uniqueKey, "_shopCode"))
|
|
635
|
+
};
|
|
636
|
+
var selectIds = [];
|
|
637
|
+
var orderNo = "";
|
|
638
|
+
var tradeId = templateColumns === null || templateColumns === void 0 ? void 0 : templateColumns.find(function (col) {
|
|
639
|
+
return col.workOrderComponentType === "TRADE_ID_INPUT";
|
|
640
|
+
});
|
|
641
|
+
if (tradeId) {
|
|
642
|
+
orderNo = getValue("".concat(tradeId.uniqueKey, "_").concat(updateWorkTypeKeys[tradeId.workOrderComponentType]));
|
|
643
|
+
}
|
|
644
|
+
var wdtSystemOrder = templateColumns === null || templateColumns === void 0 ? void 0 : templateColumns.find(function (col) {
|
|
645
|
+
return col.workOrderComponentType === "WDT_SYSTEM_ORDER";
|
|
646
|
+
});
|
|
647
|
+
if (wdtSystemOrder) {
|
|
648
|
+
selectIds = jsonParseSecurity(getValue("".concat(wdtSystemOrder.uniqueKey, "_").concat(systemOrderMap[wdtSystemOrder.workOrderComponentType].ids)), []);
|
|
649
|
+
}
|
|
650
|
+
_values.selectIds = selectIds;
|
|
651
|
+
_values.orderNo = orderNo;
|
|
652
|
+
return _defineProperty({}, nex.uniqueKey, _values);
|
|
653
|
+
};
|
|
654
|
+
};
|
|
655
|
+
};
|
|
656
|
+
var processBsE3Goods = function processBsE3Goods(templateColumns) {
|
|
657
|
+
return function (getValue) {
|
|
658
|
+
return function (nex, config) {
|
|
659
|
+
var _values = {
|
|
660
|
+
bsE3Goods: jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_bsE3Goods")), []),
|
|
661
|
+
shopCode: getValue("".concat(nex.uniqueKey, "_shopCode"))
|
|
662
|
+
};
|
|
663
|
+
var selectIds = [];
|
|
664
|
+
var orderNo = "";
|
|
665
|
+
var tradeId = templateColumns === null || templateColumns === void 0 ? void 0 : templateColumns.find(function (col) {
|
|
666
|
+
return col.workOrderComponentType === "TRADE_ID_INPUT";
|
|
667
|
+
});
|
|
668
|
+
if (tradeId) {
|
|
669
|
+
orderNo = getValue("".concat(tradeId.uniqueKey, "_").concat(updateWorkTypeKeys[tradeId.workOrderComponentType]));
|
|
670
|
+
}
|
|
671
|
+
var bsE3SystemOrder = templateColumns === null || templateColumns === void 0 ? void 0 : templateColumns.find(function (col) {
|
|
672
|
+
return col.workOrderComponentType === "BS_E3_SYSTEM_ORDER";
|
|
673
|
+
});
|
|
674
|
+
if (bsE3SystemOrder) {
|
|
675
|
+
selectIds = jsonParseSecurity(getValue("".concat(bsE3SystemOrder.uniqueKey, "_").concat(systemOrderMap[bsE3SystemOrder.workOrderComponentType].ids)), []);
|
|
676
|
+
}
|
|
677
|
+
_values.selectIds = selectIds;
|
|
678
|
+
_values.orderNo = orderNo;
|
|
679
|
+
return _defineProperty({}, nex.uniqueKey, _values);
|
|
680
|
+
};
|
|
681
|
+
};
|
|
682
|
+
};
|
|
683
|
+
var processJstGoods = function processJstGoods(templateColumns) {
|
|
684
|
+
return function (getValue) {
|
|
685
|
+
return function (nex, config) {
|
|
686
|
+
var _values = {
|
|
687
|
+
jstGoods: jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_jstGoods")), []),
|
|
688
|
+
shopCode: getValue("".concat(nex.uniqueKey, "_shopCode"))
|
|
689
|
+
};
|
|
690
|
+
var selectIds = [];
|
|
691
|
+
var orderNo = "";
|
|
692
|
+
var tradeId = templateColumns === null || templateColumns === void 0 ? void 0 : templateColumns.find(function (col) {
|
|
693
|
+
return col.workOrderComponentType === "TRADE_ID_INPUT";
|
|
694
|
+
});
|
|
695
|
+
if (tradeId) {
|
|
696
|
+
orderNo = getValue("".concat(tradeId.uniqueKey, "_").concat(updateWorkTypeKeys[tradeId.workOrderComponentType]));
|
|
697
|
+
}
|
|
698
|
+
var jstSystemOrder = templateColumns === null || templateColumns === void 0 ? void 0 : templateColumns.find(function (col) {
|
|
699
|
+
return col.workOrderComponentType === "JST_SYSTEM_ORDER";
|
|
700
|
+
});
|
|
701
|
+
if (jstSystemOrder) {
|
|
702
|
+
selectIds = jsonParseSecurity(getValue("".concat(jstSystemOrder.uniqueKey, "_").concat(systemOrderMap[jstSystemOrder.workOrderComponentType].ids)), []);
|
|
703
|
+
}
|
|
704
|
+
_values.selectIds = selectIds;
|
|
705
|
+
_values.orderNo = orderNo;
|
|
706
|
+
return _defineProperty({}, nex.uniqueKey, _values);
|
|
707
|
+
};
|
|
708
|
+
};
|
|
709
|
+
};
|
|
710
|
+
var processKmGoods = function processKmGoods(templateColumns) {
|
|
711
|
+
return function (getValue) {
|
|
712
|
+
return function (nex, config) {
|
|
713
|
+
var _values = {
|
|
714
|
+
kmGoods: jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_kmGoods")), []),
|
|
715
|
+
shopCode: getValue("".concat(nex.uniqueKey, "_shopCode"))
|
|
716
|
+
};
|
|
717
|
+
var selectIds = [];
|
|
718
|
+
var orderNo = "";
|
|
719
|
+
var tradeId = templateColumns === null || templateColumns === void 0 ? void 0 : templateColumns.find(function (col) {
|
|
720
|
+
return col.workOrderComponentType === "TRADE_ID_INPUT";
|
|
721
|
+
});
|
|
722
|
+
if (tradeId) {
|
|
723
|
+
orderNo = getValue("".concat(tradeId.uniqueKey, "_").concat(updateWorkTypeKeys[tradeId.workOrderComponentType]));
|
|
724
|
+
}
|
|
725
|
+
var kmSystemOrder = templateColumns === null || templateColumns === void 0 ? void 0 : templateColumns.find(function (col) {
|
|
726
|
+
return col.workOrderComponentType === "KM_SYSTEM_ORDER";
|
|
727
|
+
});
|
|
728
|
+
if (kmSystemOrder) {
|
|
729
|
+
selectIds = jsonParseSecurity(getValue("".concat(kmSystemOrder.uniqueKey, "_").concat(systemOrderMap[kmSystemOrder.workOrderComponentType].ids)), []);
|
|
730
|
+
}
|
|
731
|
+
_values.selectIds = selectIds;
|
|
732
|
+
_values.orderNo = orderNo;
|
|
733
|
+
return _defineProperty({}, nex.uniqueKey, _values);
|
|
734
|
+
};
|
|
735
|
+
};
|
|
736
|
+
};
|
|
737
|
+
var processGyGoods = function processGyGoods(templateColumns) {
|
|
738
|
+
return function (getValue) {
|
|
739
|
+
return function (nex, config) {
|
|
740
|
+
var _values = {
|
|
741
|
+
gyGoods: jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_gyGoods")), []),
|
|
742
|
+
shopCode: getValue("".concat(nex.uniqueKey, "_shopCode"))
|
|
743
|
+
};
|
|
744
|
+
var selectIds = [];
|
|
745
|
+
var orderNo = "";
|
|
746
|
+
var tradeId = templateColumns === null || templateColumns === void 0 ? void 0 : templateColumns.find(function (col) {
|
|
747
|
+
return col.workOrderComponentType === "TRADE_ID_INPUT";
|
|
748
|
+
});
|
|
749
|
+
if (tradeId) {
|
|
750
|
+
orderNo = getValue("".concat(tradeId.uniqueKey, "_").concat(updateWorkTypeKeys[tradeId.workOrderComponentType]));
|
|
751
|
+
}
|
|
752
|
+
var gySystemOrder = templateColumns === null || templateColumns === void 0 ? void 0 : templateColumns.find(function (col) {
|
|
753
|
+
return col.workOrderComponentType === "GY_SYSTEM_ORDER";
|
|
754
|
+
});
|
|
755
|
+
if (gySystemOrder) {
|
|
756
|
+
selectIds = jsonParseSecurity(getValue("".concat(gySystemOrder.uniqueKey, "_").concat(systemOrderMap[gySystemOrder.workOrderComponentType].ids)), []);
|
|
757
|
+
}
|
|
758
|
+
_values.selectIds = selectIds;
|
|
759
|
+
_values.orderNo = orderNo;
|
|
760
|
+
return _defineProperty({}, nex.uniqueKey, _values);
|
|
761
|
+
};
|
|
762
|
+
};
|
|
763
|
+
};
|
|
764
|
+
var processSkxGoods = function processSkxGoods(getValue) {
|
|
765
|
+
return function (nex, config) {
|
|
766
|
+
var _values = {
|
|
767
|
+
skxGoods: jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_skxGoods")), [])
|
|
768
|
+
};
|
|
769
|
+
return _defineProperty({}, nex.uniqueKey, _values);
|
|
770
|
+
};
|
|
771
|
+
};
|
|
772
|
+
var processBsReissueGoods = function processBsReissueGoods(getValue) {
|
|
773
|
+
return function (nex, config) {
|
|
774
|
+
return _defineProperty({}, nex.uniqueKey, {
|
|
775
|
+
bsReissueType: jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_bsReissueType")), []),
|
|
776
|
+
bsReissueGoods: jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_bsReissueGoods")), []),
|
|
777
|
+
shopCode: getValue("".concat(nex.uniqueKey, "_shopCode"))
|
|
778
|
+
});
|
|
779
|
+
};
|
|
780
|
+
};
|
|
781
|
+
var processBsExchangeGoods = function processBsExchangeGoods(getValue) {
|
|
782
|
+
return function (nex, config) {
|
|
783
|
+
var bsExchangeType = jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_bsExchangeType")), []);
|
|
784
|
+
var bsExchangeReturnGoods = jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_bsExchangeReturnGoods")), []);
|
|
785
|
+
var bsExchangeSwapOutGoods = jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_bsExchangeSwapOutGoods")), []);
|
|
786
|
+
//补发组装数据
|
|
787
|
+
if (bsExchangeType !== null && bsExchangeType !== void 0 && bsExchangeType.length && ["2", "4"].includes(bsExchangeType[0])) {
|
|
788
|
+
var maxLen = maxBy(bsExchangeReturnGoods, function (t) {
|
|
789
|
+
return t.index;
|
|
790
|
+
});
|
|
791
|
+
var newGoods = Array((maxLen === null || maxLen === void 0 ? void 0 : maxLen.index) + 1 || 0).map(function () {
|
|
792
|
+
return {
|
|
793
|
+
bsExchangeReturnGoods: [],
|
|
794
|
+
bsExchangeSwapOutGoods: []
|
|
795
|
+
};
|
|
796
|
+
});
|
|
797
|
+
bsExchangeReturnGoods.forEach(function (item) {
|
|
798
|
+
if (!newGoods[item.index]) {
|
|
799
|
+
newGoods[item.index] = {
|
|
800
|
+
bsExchangeReturnGoods: [],
|
|
801
|
+
bsExchangeSwapOutGoods: []
|
|
802
|
+
};
|
|
803
|
+
}
|
|
804
|
+
newGoods[item.index].bsExchangeReturnGoods.push(item);
|
|
805
|
+
});
|
|
806
|
+
bsExchangeSwapOutGoods.forEach(function (item) {
|
|
807
|
+
newGoods[item.index].bsExchangeSwapOutGoods.push(item);
|
|
808
|
+
});
|
|
809
|
+
bsExchangeReturnGoods = newGoods;
|
|
810
|
+
bsExchangeSwapOutGoods = [];
|
|
811
|
+
}
|
|
812
|
+
return _defineProperty({}, nex.uniqueKey, {
|
|
813
|
+
bsExchangeType: bsExchangeType,
|
|
814
|
+
bsExchangeReturnGoods: bsExchangeReturnGoods,
|
|
815
|
+
bsExchangeSwapOutGoods: bsExchangeSwapOutGoods,
|
|
816
|
+
bsExchangeGiftGoods: jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_bsExchangeGiftGoods")), []),
|
|
817
|
+
shopCode: getValue("".concat(nex.uniqueKey, "_shopCode"))
|
|
818
|
+
});
|
|
819
|
+
};
|
|
820
|
+
};
|
|
821
|
+
var processWdtExchangeGoods = function processWdtExchangeGoods(getValue) {
|
|
822
|
+
return function (nex, config) {
|
|
823
|
+
return _defineProperty({}, nex.uniqueKey, {
|
|
824
|
+
wdtExchangeGoods: jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_wdtExchangeGoods")), []),
|
|
825
|
+
shopCode: getValue("".concat(nex.uniqueKey, "_shopCode"))
|
|
826
|
+
});
|
|
827
|
+
};
|
|
828
|
+
};
|
|
829
|
+
var processJstExchangeGoods = function processJstExchangeGoods(getValue) {
|
|
830
|
+
return function (nex, config) {
|
|
831
|
+
return _defineProperty({}, nex.uniqueKey, {
|
|
832
|
+
jstExchangeGoods: jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_jstExchangeGoods")), []),
|
|
833
|
+
shopCode: getValue("".concat(nex.uniqueKey, "_shopCode"))
|
|
834
|
+
});
|
|
835
|
+
};
|
|
836
|
+
};
|
|
837
|
+
var processBsReturnGoods = function processBsReturnGoods(getValue) {
|
|
838
|
+
return function (nex, config) {
|
|
839
|
+
var _$concat;
|
|
840
|
+
var compType = nex.workOrderComponentType;
|
|
841
|
+
var returnGoodsMap = {
|
|
842
|
+
BS_RETURN_GOODS: {
|
|
843
|
+
returnTypeKey: "bsReturnType",
|
|
844
|
+
returnGoodsKey: "bsReturnGoods",
|
|
845
|
+
shopCodeKey: "shopCode"
|
|
846
|
+
}
|
|
847
|
+
};
|
|
848
|
+
return _defineProperty({}, "".concat(nex.uniqueKey), (_$concat = {}, _defineProperty(_$concat, returnGoodsMap[compType].returnTypeKey, jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_").concat(returnGoodsMap[compType].returnTypeKey)), [])), _defineProperty(_$concat, returnGoodsMap[compType].returnGoodsKey, jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_").concat(returnGoodsMap[compType].returnGoodsKey)), [])), _defineProperty(_$concat, returnGoodsMap[compType].shopCodeKey, getValue("".concat(nex.uniqueKey, "_").concat(returnGoodsMap[compType].shopCodeKey))), _$concat));
|
|
849
|
+
};
|
|
850
|
+
};
|
|
851
|
+
var processErpSystemOrder = function processErpSystemOrder(getValue) {
|
|
852
|
+
return function (nex, config) {
|
|
853
|
+
var systemOrderMap = {
|
|
854
|
+
BS_SYSTEM_ORDER: {
|
|
855
|
+
no: "bsSystemOrderNo",
|
|
856
|
+
ids: "bsSystemSelectIds",
|
|
857
|
+
order: "bsSystemShowOrder"
|
|
858
|
+
},
|
|
859
|
+
KM_SYSTEM_ORDER: {
|
|
860
|
+
no: "kmSystemOrderNo",
|
|
861
|
+
ids: "kmSystemSelectIds",
|
|
862
|
+
order: "kmSystemShowOrder"
|
|
863
|
+
},
|
|
864
|
+
WLN_SYSTEM_ORDER: {
|
|
865
|
+
no: "wlnSystemOrderNo",
|
|
866
|
+
ids: "wlnSystemSelectIds",
|
|
867
|
+
order: "wlnSystemShowOrder"
|
|
868
|
+
},
|
|
869
|
+
WDT_SYSTEM_ORDER: {
|
|
870
|
+
no: "wdtSystemOrderNo",
|
|
871
|
+
ids: "wdtSystemSelectIds",
|
|
872
|
+
order: "wdtSystemShowOrder"
|
|
873
|
+
},
|
|
874
|
+
BS_E3_SYSTEM_ORDER: {
|
|
875
|
+
no: "bsE3SystemOrderNo",
|
|
876
|
+
ids: "bsE3SystemSelectIds",
|
|
877
|
+
order: "bsE3SystemShowOrder"
|
|
878
|
+
},
|
|
879
|
+
GY_SYSTEM_ORDER: {
|
|
880
|
+
no: "gySystemOrderNo",
|
|
881
|
+
ids: "gySystemSelectIds",
|
|
882
|
+
order: "gySystemShowOrder"
|
|
883
|
+
},
|
|
884
|
+
JST_SYSTEM_ORDER: {
|
|
885
|
+
no: "jstSystemOrderNo",
|
|
886
|
+
ids: "jstSystemSelectIds",
|
|
887
|
+
order: "jstSystemShowOrder"
|
|
888
|
+
}
|
|
889
|
+
};
|
|
890
|
+
return _defineProperty({}, nex.uniqueKey, {
|
|
891
|
+
orderNo: getValue("".concat(nex.uniqueKey, "_").concat(systemOrderMap[nex.workOrderComponentType].no)),
|
|
892
|
+
orders: [],
|
|
893
|
+
selectIds: jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_").concat(systemOrderMap[nex.workOrderComponentType].ids)), []),
|
|
894
|
+
showOrderInfo: jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_").concat(systemOrderMap[nex.workOrderComponentType].order)), [])
|
|
895
|
+
});
|
|
896
|
+
};
|
|
897
|
+
};
|
|
898
|
+
var processBuyerMessageNotice = function processBuyerMessageNotice(getValue) {
|
|
899
|
+
return function (nex, config) {
|
|
900
|
+
return _defineProperty({}, nex.uniqueKey, getValue("".concat(nex.uniqueKey, "_buyerMessageNotice")) || (config === null || config === void 0 ? void 0 : config.select));
|
|
901
|
+
};
|
|
902
|
+
};
|
|
903
|
+
var processOrderType = function processOrderType(getValue) {
|
|
904
|
+
return function (nex, config) {
|
|
905
|
+
return _defineProperty({}, nex.uniqueKey, getValue("".concat(nex.uniqueKey, "_erpOrderType")) || (config === null || config === void 0 ? void 0 : config.select));
|
|
906
|
+
};
|
|
907
|
+
};
|
|
908
|
+
var processRefundType = function processRefundType(getValue) {
|
|
909
|
+
return function (nex, config) {
|
|
910
|
+
return _defineProperty({}, nex.uniqueKey, getValue("".concat(nex.uniqueKey, "_orderRefundType")) || (config === null || config === void 0 ? void 0 : config.select));
|
|
911
|
+
};
|
|
912
|
+
};
|
|
913
|
+
var processExecuteActionType = function processExecuteActionType(getValue) {
|
|
914
|
+
return function (nex, config) {
|
|
915
|
+
return _defineProperty({}, nex.uniqueKey, getValue("".concat(nex.uniqueKey, "_executeActionType")) || (config === null || config === void 0 ? void 0 : config.select));
|
|
916
|
+
};
|
|
917
|
+
};
|
|
918
|
+
var processErpTradeId = function processErpTradeId(getValue) {
|
|
919
|
+
return function (nex, config) {
|
|
920
|
+
var SYSTEM_ORDER_MAP = {
|
|
921
|
+
BS_DELIVERY_NO: {
|
|
922
|
+
key: "deliveryNoList",
|
|
923
|
+
defaultValue: [{
|
|
924
|
+
deliverNo: "",
|
|
925
|
+
systemOrderId: ""
|
|
926
|
+
}]
|
|
927
|
+
},
|
|
928
|
+
RETURN_GOODS_TRADE_ID: {
|
|
929
|
+
key: "returnGoodsTradeItemList",
|
|
930
|
+
defaultValue: []
|
|
931
|
+
},
|
|
932
|
+
REISSUE_TRADE_ID: {
|
|
933
|
+
key: "tradeItemList",
|
|
934
|
+
defaultValue: []
|
|
935
|
+
},
|
|
936
|
+
ERP_AFTER_SALE_TRADE_ID: {
|
|
937
|
+
key: "erpAfterSaleTradeItemList",
|
|
938
|
+
defaultValue: []
|
|
939
|
+
},
|
|
940
|
+
EXCHANGE_TRADE_ID: {
|
|
941
|
+
key: "tradeItemList",
|
|
942
|
+
defaultValue: []
|
|
943
|
+
}
|
|
944
|
+
};
|
|
945
|
+
return _defineProperty({}, nex.uniqueKey, jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_").concat(SYSTEM_ORDER_MAP[nex.workOrderComponentType].key)), SYSTEM_ORDER_MAP[nex.workOrderComponentType].defaultValue));
|
|
946
|
+
};
|
|
947
|
+
};
|
|
948
|
+
var processWlnGoods = function processWlnGoods(templateColumns) {
|
|
949
|
+
return function (getValue) {
|
|
950
|
+
return function (nex, config) {
|
|
951
|
+
var orderNo = "";
|
|
952
|
+
var tradeId = templateColumns === null || templateColumns === void 0 ? void 0 : templateColumns.find(function (col) {
|
|
953
|
+
return col.workOrderComponentType === "TRADE_ID_INPUT";
|
|
954
|
+
});
|
|
955
|
+
if (tradeId) {
|
|
956
|
+
orderNo = getValue("".concat(tradeId.uniqueKey, "_").concat(updateWorkTypeKeys[tradeId.workOrderComponentType]));
|
|
957
|
+
}
|
|
958
|
+
return _defineProperty({}, nex.uniqueKey, {
|
|
959
|
+
wlnGoods: jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_wlnGoods")), []),
|
|
960
|
+
shopCode: getValue("".concat(nex.uniqueKey, "_shopCode")),
|
|
961
|
+
orderNo: orderNo
|
|
962
|
+
});
|
|
963
|
+
};
|
|
964
|
+
};
|
|
965
|
+
};
|
|
966
|
+
var processWdtReissueGoods = function processWdtReissueGoods(templateColumns) {
|
|
967
|
+
return function (getValue) {
|
|
968
|
+
return function (nex, config) {
|
|
969
|
+
var orderNo = "";
|
|
970
|
+
var tradeId = templateColumns === null || templateColumns === void 0 ? void 0 : templateColumns.find(function (col) {
|
|
971
|
+
return col.workOrderComponentType === "TRADE_ID_INPUT";
|
|
972
|
+
});
|
|
973
|
+
if (tradeId) {
|
|
974
|
+
orderNo = getValue("".concat(tradeId.uniqueKey, "_").concat(updateWorkTypeKeys[tradeId.workOrderComponentType]));
|
|
975
|
+
}
|
|
976
|
+
return _defineProperty({}, nex.uniqueKey, {
|
|
977
|
+
wdtSystemOrder: {
|
|
978
|
+
orderNo: orderNo
|
|
979
|
+
},
|
|
980
|
+
wdtReissueType: jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_wdtReissueType")), !isNull(config === null || config === void 0 ? void 0 : config.initReason) ? [config.initReason] : ["1"]),
|
|
981
|
+
wdtReissueGoods: jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_wdtReissueGoods")), []),
|
|
982
|
+
shopCode: getValue("".concat(nex.uniqueKey, "_shopCode")),
|
|
983
|
+
wdtSystemOrderNo: getValue("".concat(nex.uniqueKey, "_wdtSystemOrderNo"))
|
|
984
|
+
});
|
|
985
|
+
};
|
|
986
|
+
};
|
|
987
|
+
};
|
|
988
|
+
var processWdtReturnGoods = function processWdtReturnGoods(templateColumns) {
|
|
989
|
+
return function (getValue) {
|
|
990
|
+
return function (nex, config) {
|
|
991
|
+
// let orderNo = '';
|
|
992
|
+
// const tradeId = templateColumns?.find(
|
|
993
|
+
// (col: { workOrderComponentType: string }) => col.workOrderComponentType === 'TRADE_ID_INPUT',
|
|
994
|
+
// );
|
|
995
|
+
// if (tradeId) {
|
|
996
|
+
// orderNo = getValue(
|
|
997
|
+
// `${tradeId.uniqueKey}_${updateWorkTypeKeys[tradeId.workOrderComponentType]}`,
|
|
998
|
+
// );
|
|
999
|
+
// }
|
|
1000
|
+
return _defineProperty({}, nex.uniqueKey, {
|
|
1001
|
+
wdtReturnType: jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_wdtReturnType")), !isNull(config === null || config === void 0 ? void 0 : config.initReason) ? [config.initReason] : ["1"]),
|
|
1002
|
+
wdtReturnGoods: jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_wdtReturnGoods")), []),
|
|
1003
|
+
shopCode: getValue("".concat(nex.uniqueKey, "_shopCode"))
|
|
1004
|
+
});
|
|
1005
|
+
};
|
|
1006
|
+
};
|
|
1007
|
+
};
|
|
1008
|
+
var processKmReissueGoods = function processKmReissueGoods(templateColumns) {
|
|
1009
|
+
return function (getValue) {
|
|
1010
|
+
return function (nex, config) {
|
|
1011
|
+
var orderNo = "";
|
|
1012
|
+
var tradeId = templateColumns === null || templateColumns === void 0 ? void 0 : templateColumns.find(function (col) {
|
|
1013
|
+
return col.workOrderComponentType === "TRADE_ID_INPUT";
|
|
1014
|
+
});
|
|
1015
|
+
if (tradeId) {
|
|
1016
|
+
orderNo = getValue("".concat(tradeId.uniqueKey, "_").concat(updateWorkTypeKeys[tradeId.workOrderComponentType]));
|
|
1017
|
+
}
|
|
1018
|
+
return _defineProperty({}, nex.uniqueKey, {
|
|
1019
|
+
kmSystemOrder: {
|
|
1020
|
+
orderNo: orderNo
|
|
1021
|
+
},
|
|
1022
|
+
kmReissueType: jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_kmReissueType")), !isNull(config === null || config === void 0 ? void 0 : config.initReason) ? [config.initReason] : ["1"]),
|
|
1023
|
+
kmReissueGoods: jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_kmReissueGoods")), []),
|
|
1024
|
+
shopCode: getValue("".concat(nex.uniqueKey, "_shopCode")),
|
|
1025
|
+
kmSystemOrderNo: getValue("".concat(nex.uniqueKey, "_kmSystemOrderNo"))
|
|
1026
|
+
});
|
|
1027
|
+
};
|
|
1028
|
+
};
|
|
1029
|
+
};
|
|
1030
|
+
var processGyReissueGoods = function processGyReissueGoods(templateColumns) {
|
|
1031
|
+
return function (getValue) {
|
|
1032
|
+
return function (nex, config) {
|
|
1033
|
+
var orderNo = "";
|
|
1034
|
+
var tradeId = templateColumns === null || templateColumns === void 0 ? void 0 : templateColumns.find(function (col) {
|
|
1035
|
+
return col.workOrderComponentType === "TRADE_ID_INPUT";
|
|
1036
|
+
});
|
|
1037
|
+
if (tradeId) {
|
|
1038
|
+
orderNo = getValue("".concat(tradeId.uniqueKey, "_").concat(updateWorkTypeKeys[tradeId.workOrderComponentType]));
|
|
1039
|
+
}
|
|
1040
|
+
return _defineProperty({}, nex.uniqueKey, {
|
|
1041
|
+
gySystemOrder: {
|
|
1042
|
+
orderNo: orderNo
|
|
1043
|
+
},
|
|
1044
|
+
gyReissueType: jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_gyReissueType")), !isNull(config === null || config === void 0 ? void 0 : config.initReason) ? [config.initReason] : ["1"]),
|
|
1045
|
+
gyReissueGoods: jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_gyReissueGoods")), []),
|
|
1046
|
+
shopCode: getValue("".concat(nex.uniqueKey, "_shopCode")),
|
|
1047
|
+
vipCode: getValue("".concat(nex.uniqueKey, "_vipCode")),
|
|
1048
|
+
gySystemOrderNo: getValue("".concat(nex.uniqueKey, "_gySystemOrderNo"))
|
|
1049
|
+
});
|
|
1050
|
+
};
|
|
1051
|
+
};
|
|
1052
|
+
};
|
|
1053
|
+
var processGyReturnGoods = function processGyReturnGoods(templateColumns) {
|
|
1054
|
+
return function (getValue) {
|
|
1055
|
+
return function (nex, config) {
|
|
1056
|
+
var orderNo = "";
|
|
1057
|
+
var tradeId = templateColumns === null || templateColumns === void 0 ? void 0 : templateColumns.find(function (col) {
|
|
1058
|
+
return col.workOrderComponentType === "TRADE_ID_INPUT";
|
|
1059
|
+
});
|
|
1060
|
+
if (tradeId) {
|
|
1061
|
+
orderNo = getValue("".concat(tradeId.uniqueKey, "_").concat(updateWorkTypeKeys[tradeId.workOrderComponentType]));
|
|
1062
|
+
}
|
|
1063
|
+
return _defineProperty({}, nex.uniqueKey, {
|
|
1064
|
+
gySystemOrder: {
|
|
1065
|
+
orderNo: orderNo
|
|
1066
|
+
},
|
|
1067
|
+
gyReturnType: jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_gyReturnType")), !isNull(config === null || config === void 0 ? void 0 : config.initReason) ? [config.initReason] : ["1"]),
|
|
1068
|
+
gyReturnGoods: jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_gyReturnGoods")), []),
|
|
1069
|
+
shopCode: getValue("".concat(nex.uniqueKey, "_shopCode")),
|
|
1070
|
+
gySystemOrderNo: getValue("".concat(nex.uniqueKey, "_gySystemOrderNo"))
|
|
1071
|
+
});
|
|
1072
|
+
};
|
|
1073
|
+
};
|
|
1074
|
+
};
|
|
1075
|
+
var processJstReissueGoods = function processJstReissueGoods(templateColumns) {
|
|
1076
|
+
return function (getValue) {
|
|
1077
|
+
return function (nex, config) {
|
|
1078
|
+
var orderNo = "";
|
|
1079
|
+
var tradeId = templateColumns === null || templateColumns === void 0 ? void 0 : templateColumns.find(function (col) {
|
|
1080
|
+
return col.workOrderComponentType === "TRADE_ID_INPUT";
|
|
1081
|
+
});
|
|
1082
|
+
if (tradeId) {
|
|
1083
|
+
orderNo = getValue("".concat(tradeId.uniqueKey, "_").concat(updateWorkTypeKeys[tradeId.workOrderComponentType]));
|
|
1084
|
+
}
|
|
1085
|
+
return _defineProperty({}, nex.uniqueKey, {
|
|
1086
|
+
jstSystemOrder: {
|
|
1087
|
+
orderNo: orderNo
|
|
1088
|
+
},
|
|
1089
|
+
jstReissueType: jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_jstReissueType")), !isNull(config === null || config === void 0 ? void 0 : config.initReason) ? [config.initReason] : ["1"]),
|
|
1090
|
+
jstReissueGoods: jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_jstReissueGoods")), []),
|
|
1091
|
+
jstSystemOrderBillType: getValue("".concat(nex.uniqueKey, "_jstSystemOrderBillType")) || "",
|
|
1092
|
+
shopCode: getValue("".concat(nex.uniqueKey, "_shopCode")),
|
|
1093
|
+
jstSystemOrderNo: getValue("".concat(nex.uniqueKey, "_jstSystemOrderNo"))
|
|
1094
|
+
});
|
|
1095
|
+
};
|
|
1096
|
+
};
|
|
1097
|
+
};
|
|
1098
|
+
var processJstReturnGoods = function processJstReturnGoods(templateColumns) {
|
|
1099
|
+
return function (getValue) {
|
|
1100
|
+
return function (nex, config) {
|
|
1101
|
+
var orderNo = "";
|
|
1102
|
+
var tradeId = templateColumns === null || templateColumns === void 0 ? void 0 : templateColumns.find(function (col) {
|
|
1103
|
+
return col.workOrderComponentType === "TRADE_ID_INPUT";
|
|
1104
|
+
});
|
|
1105
|
+
if (tradeId) {
|
|
1106
|
+
orderNo = getValue("".concat(tradeId.uniqueKey, "_").concat(updateWorkTypeKeys[tradeId.workOrderComponentType]));
|
|
1107
|
+
}
|
|
1108
|
+
return _defineProperty({}, nex.uniqueKey, {
|
|
1109
|
+
jstSystemOrder: {
|
|
1110
|
+
orderNo: orderNo
|
|
1111
|
+
},
|
|
1112
|
+
jstReturnType: jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_jstReturnType")), !isNull(config === null || config === void 0 ? void 0 : config.initReason) ? [config.initReason] : ["1"]),
|
|
1113
|
+
jstReturnGoods: jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_jstReturnGoods")), []),
|
|
1114
|
+
jstSystemOrderBillType: getValue("".concat(nex.uniqueKey, "_jstSystemOrderBillType")) || "",
|
|
1115
|
+
shopCode: getValue("".concat(nex.uniqueKey, "_shopCode")),
|
|
1116
|
+
jstSystemOrderNo: getValue("".concat(nex.uniqueKey, "_jstSystemOrderNo"))
|
|
1117
|
+
});
|
|
1118
|
+
};
|
|
1119
|
+
};
|
|
1120
|
+
};
|
|
1121
|
+
var processLabel = function processLabel(getValue) {
|
|
1122
|
+
return function (nex, config) {
|
|
1123
|
+
var _ref72;
|
|
1124
|
+
return _ref72 = {}, _defineProperty(_ref72, nex.uniqueKey, jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_label")), [])), _defineProperty(_ref72, "".concat(nex.uniqueKey, "_label"), jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_label")), [])), _ref72;
|
|
1125
|
+
};
|
|
1126
|
+
};
|
|
1127
|
+
var processMemberLevel = function processMemberLevel(getValue) {
|
|
1128
|
+
return function (nex, config) {
|
|
1129
|
+
var _ref73;
|
|
1130
|
+
return _ref73 = {}, _defineProperty(_ref73, nex.uniqueKey, jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_memberLevel")), [])), _defineProperty(_ref73, "".concat(nex.uniqueKey, "_memberLevel"), jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_memberLevel")), [])), _ref73;
|
|
1131
|
+
};
|
|
1132
|
+
};
|
|
1133
|
+
var processAfterSalesOrderId = function processAfterSalesOrderId(getValue) {
|
|
1134
|
+
return function (nex, config) {
|
|
1135
|
+
return _defineProperty({}, nex.uniqueKey, getValue("".concat(nex.uniqueKey, "_afterSalesOrderId")));
|
|
1136
|
+
};
|
|
1137
|
+
};
|
|
1138
|
+
var processSingleField = function processSingleField(getValue) {
|
|
1139
|
+
return function (nex, config) {
|
|
1140
|
+
return _defineProperty({}, nex.uniqueKey, getValue("".concat(nex.uniqueKey, "_").concat(updateWorkTypeKeys[nex.workOrderComponentType])));
|
|
1141
|
+
};
|
|
1142
|
+
};
|
|
1143
|
+
var processSingleFieldByKey = function processSingleFieldByKey(key) {
|
|
1144
|
+
return function (getValue) {
|
|
1145
|
+
return function (nex, config) {
|
|
1146
|
+
return _defineProperty({}, nex.uniqueKey, getValue("".concat(nex.uniqueKey, "_").concat(key)));
|
|
1147
|
+
};
|
|
1148
|
+
};
|
|
1149
|
+
};
|
|
1150
|
+
var processBsE3ReissueGoods = function processBsE3ReissueGoods(templateColumns) {
|
|
1151
|
+
return function (getValue) {
|
|
1152
|
+
return function (nex, config) {
|
|
1153
|
+
var orderNo = "";
|
|
1154
|
+
var tradeId = templateColumns === null || templateColumns === void 0 ? void 0 : templateColumns.find(function (col) {
|
|
1155
|
+
return col.workOrderComponentType === "TRADE_ID_INPUT";
|
|
1156
|
+
});
|
|
1157
|
+
if (tradeId) {
|
|
1158
|
+
orderNo = getValue("".concat(tradeId.uniqueKey, "_").concat(updateWorkTypeKeys[tradeId.workOrderComponentType]));
|
|
1159
|
+
}
|
|
1160
|
+
return _defineProperty({}, nex.uniqueKey, {
|
|
1161
|
+
bsE3SystemOrder: {
|
|
1162
|
+
orderNo: orderNo
|
|
1163
|
+
},
|
|
1164
|
+
bsE3SystemOrderNo: getValue("".concat(nex.uniqueKey, "_bsE3SystemOrderNo")),
|
|
1165
|
+
bsE3ReissueType: jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_bsE3ReissueType")), !isNull(config === null || config === void 0 ? void 0 : config.initReason) ? [config.initReason] : ["1"]),
|
|
1166
|
+
bsE3ReissueGoods: jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_bsE3ReissueGoods")), [])
|
|
1167
|
+
});
|
|
1168
|
+
};
|
|
1169
|
+
};
|
|
1170
|
+
};
|
|
1171
|
+
var transformWorkOrderData = function transformWorkOrderData(templateColumns) {
|
|
1172
|
+
var type = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : "edit";
|
|
1173
|
+
return function (item) {
|
|
1174
|
+
var getValue = getItemValue(item);
|
|
1175
|
+
var componentProcessors = _objectSpread({
|
|
1176
|
+
RADIO: processRadio,
|
|
1177
|
+
INPUT: processInput,
|
|
1178
|
+
NUMERICAL_CALCULATION: processNumericalCalculation,
|
|
1179
|
+
TEXTAREA: processTextarea,
|
|
1180
|
+
SELECT: processSelect,
|
|
1181
|
+
GY_PAYMENT_METHOD: gyPaymentMethod,
|
|
1182
|
+
RATE: processRate,
|
|
1183
|
+
FILE: processFile,
|
|
1184
|
+
POSTING: processPosting,
|
|
1185
|
+
BUYER_NICK_INPUT: processBuyerNickInput,
|
|
1186
|
+
ALI_PAY_INPUT: processAliPayInput,
|
|
1187
|
+
CHECKBOX: processCheckbox,
|
|
1188
|
+
DATETIME: processDatetime,
|
|
1189
|
+
PICTURE: processPicture,
|
|
1190
|
+
PICTURE_PRO: processPicturePro,
|
|
1191
|
+
BASIC_MULT_SELECT: processBasicMultSelect,
|
|
1192
|
+
MULT_SELECT: processMultSelect,
|
|
1193
|
+
BASIC_ADDRESS: processBasicAddress,
|
|
1194
|
+
RECEIVER_ADDRESS_INPUT: processReceiverAddressInput,
|
|
1195
|
+
SUBFORM: processSubForm,
|
|
1196
|
+
EXPRESS_LOGISTICS_SELECT: processExpressLogisticsSelect,
|
|
1197
|
+
RETURN_LOGISTICS_SELECT: processReturnLogisticsSelect,
|
|
1198
|
+
REMARK_INPUT: processRemarkInput,
|
|
1199
|
+
STATUS: processStatus,
|
|
1200
|
+
ORDINARY_INVOICE: processOrdinaryInvoice,
|
|
1201
|
+
LOGISTICS_INTERCEPTION: processLogisticsInterception,
|
|
1202
|
+
LOGISTICS_INTERCEPTION_MORE: processLogisticsInterceptionMore,
|
|
1203
|
+
LOGISTICS_TRAJECTORY: processLogisticsTrajectory,
|
|
1204
|
+
LOGISTICS_TRAJECTORY_MORE: processLogisticsTrajectoryMore,
|
|
1205
|
+
ITEM_SELECT: processGoods,
|
|
1206
|
+
ITEM_ENCODE: processGoods,
|
|
1207
|
+
ITEM_ID: processGoods,
|
|
1208
|
+
ITEM_SELECT_THIRD: processItemSelectThird,
|
|
1209
|
+
ENTERPRISE_PAYMENT: processEnterPrisePayment,
|
|
1210
|
+
JST_LOGISTICS: processJstLogistics,
|
|
1211
|
+
JST_ITEM_SELECT_THIRD: processJstItemSelectThird,
|
|
1212
|
+
JST_SUPPLY: processJstSupply,
|
|
1213
|
+
JST_SEND_GOOD: processJstSendGood,
|
|
1214
|
+
BS_MEMO: processBsMemo,
|
|
1215
|
+
REISSUE_LOGISTICS: processReissueLogistics,
|
|
1216
|
+
REISSUE_STATUS: processCallBackStatus,
|
|
1217
|
+
ADJUST_WORK_ORDER_STATUS: processCallBackStatus,
|
|
1218
|
+
CREATE_STATUS: processCallBackStatus,
|
|
1219
|
+
INVOICE_STATUS: processCallBackStatus,
|
|
1220
|
+
INVOICING_STATUS: processCallBackStatus,
|
|
1221
|
+
AGREE_REFUND_STATUS: processCallBackStatus,
|
|
1222
|
+
REJECT_REFUND_STATUS: processCallBackStatus,
|
|
1223
|
+
ERP_AFTER_SALE_STATUS: processCallBackStatus,
|
|
1224
|
+
AGREE_RETURN_GOODS_STATUS: processCallBackStatus,
|
|
1225
|
+
REJECT_RETURN_GOODS_STATUS: processCallBackStatus,
|
|
1226
|
+
RETURN_EXCHANGE_GOODS_REVIEW_STATUS: processCallBackStatus,
|
|
1227
|
+
RETURN_GOODS_STATUS: processSceneStatus,
|
|
1228
|
+
EXCHANGE_STATUS: processSceneStatus,
|
|
1229
|
+
WAREHOUSING_STATUS: processSceneStatus,
|
|
1230
|
+
BS_E3_WAREHOUSING_STATUS: processSceneStatus,
|
|
1231
|
+
MSG_STATUS: processSceneStatus,
|
|
1232
|
+
WDT_WAREHOUSING_STATUS: processSceneStatus,
|
|
1233
|
+
BS_LOGISTICS: processErpLogistics,
|
|
1234
|
+
WLN_LOGISTICS: processErpLogistics,
|
|
1235
|
+
WDT_LOGISTICS: processErpLogistics,
|
|
1236
|
+
GY_LOGISTICS: processErpLogistics,
|
|
1237
|
+
BS_E3_LOGISTICS: processErpLogistics,
|
|
1238
|
+
KM_LOGISTICS: processErpLogistics,
|
|
1239
|
+
BS_SEND_GOOD: processErpSendGood,
|
|
1240
|
+
WLN_SEND_GOOD: processErpSendGood,
|
|
1241
|
+
WDT_SEND_GOOD: processErpSendGood,
|
|
1242
|
+
BS_E3_SEND_GOOD: processErpSendGood,
|
|
1243
|
+
KM_SEND_GOOD: processErpSendGood,
|
|
1244
|
+
GY_SEND_GOOD: processErpSendGood,
|
|
1245
|
+
BS_POSTING: processBsPosting,
|
|
1246
|
+
BS_GOODS: processBsGoods,
|
|
1247
|
+
WDT_GOODS: processWdtGoods(templateColumns),
|
|
1248
|
+
BS_E3_GOODS: processBsE3Goods(templateColumns),
|
|
1249
|
+
GY_GOODS: processGyGoods(templateColumns),
|
|
1250
|
+
KM_GOODS: processKmGoods(templateColumns),
|
|
1251
|
+
KM_REISSUE_GOODS: processKmReissueGoods(templateColumns),
|
|
1252
|
+
JST_GOODS: processJstGoods(templateColumns),
|
|
1253
|
+
BS_REISSUE_GOODS: processBsReissueGoods,
|
|
1254
|
+
BS_EXCHANGE_GOODS: processBsExchangeGoods,
|
|
1255
|
+
WDT_EXCHANGE_GOODS: processWdtExchangeGoods,
|
|
1256
|
+
JST_EXCHANGE_GOODS: processJstExchangeGoods,
|
|
1257
|
+
BS_RETURN_GOODS: processBsReturnGoods,
|
|
1258
|
+
WDT_RETURN_GOODS: processWdtReturnGoods(templateColumns),
|
|
1259
|
+
JST_RETURN_GOODS: processJstReturnGoods(templateColumns),
|
|
1260
|
+
BS_SYSTEM_ORDER: processErpSystemOrder,
|
|
1261
|
+
KM_SYSTEM_ORDER: processErpSystemOrder,
|
|
1262
|
+
WLN_SYSTEM_ORDER: processErpSystemOrder,
|
|
1263
|
+
WDT_SYSTEM_ORDER: processErpSystemOrder,
|
|
1264
|
+
BS_E3_SYSTEM_ORDER: processErpSystemOrder,
|
|
1265
|
+
JST_SYSTEM_ORDER: processErpSystemOrder,
|
|
1266
|
+
GY_SYSTEM_ORDER: processErpSystemOrder,
|
|
1267
|
+
BUYER_MESSAGE_NOTICE: processBuyerMessageNotice,
|
|
1268
|
+
ORDER_TYPE: processOrderType,
|
|
1269
|
+
REFUND_TYPE: processRefundType,
|
|
1270
|
+
RETURN_GOODS_TRADE_ID: processErpTradeId,
|
|
1271
|
+
BS_DELIVERY_NO: processErpTradeId,
|
|
1272
|
+
REISSUE_TRADE_ID: processErpTradeId,
|
|
1273
|
+
ERP_AFTER_SALE_TRADE_ID: processErpTradeId,
|
|
1274
|
+
EXCHANGE_TRADE_ID: processErpTradeId,
|
|
1275
|
+
WLN_GOODS: processWlnGoods(templateColumns),
|
|
1276
|
+
WDT_REISSUE_GOODS: processWdtReissueGoods(templateColumns),
|
|
1277
|
+
GY_REISSUE_GOODS: processGyReissueGoods(templateColumns),
|
|
1278
|
+
GY_RETURN_GOODS: processGyReturnGoods(templateColumns),
|
|
1279
|
+
JST_REISSUE_GOODS: processJstReissueGoods(templateColumns),
|
|
1280
|
+
LABEL: processLabel,
|
|
1281
|
+
MEMBER_LEVEL: processMemberLevel,
|
|
1282
|
+
AFTER_SALES_ORDER_ID: processAfterSalesOrderId,
|
|
1283
|
+
BASIC_GRADE: processSingleField,
|
|
1284
|
+
TRADE_ID_INPUT: processSingleField,
|
|
1285
|
+
SHOP_NAME_INPUT: processSingleField,
|
|
1286
|
+
RECEIVER_NAME_INPUT: processSingleField,
|
|
1287
|
+
RECEIVER_MOBILE_INPUT: processSingleField,
|
|
1288
|
+
TRADE_CREATE_DATETIME: processSingleField,
|
|
1289
|
+
TRADE_PAYMENT_DATETIME: processSingleField,
|
|
1290
|
+
TRADE_DELIVERY_DATETIME: processSingleField,
|
|
1291
|
+
TRADE_CLOSING_DATETIME: processSingleField,
|
|
1292
|
+
TRADE_SIGNING_DATETIME: processSingleField,
|
|
1293
|
+
ACTUAL_PAYMENT: processSingleField,
|
|
1294
|
+
SYSTEM_ORDER_NO: processSingleField,
|
|
1295
|
+
BS_SIGNING_TIME: processSingleField,
|
|
1296
|
+
BS_SEND_TIME: processSingleField,
|
|
1297
|
+
BS_TRADE_PAYMENT_TIME: processSingleField,
|
|
1298
|
+
BS_NET_RECEIPTS: processSingleField,
|
|
1299
|
+
BS_PACKAGE_WEIGHT: processSingleField,
|
|
1300
|
+
BS_DEPOSIT: processSingleField,
|
|
1301
|
+
NEW_PAYMENT_STATUS: processSingleField,
|
|
1302
|
+
BUSINESS_ORDER_NO: processSingleField,
|
|
1303
|
+
PAYMENT_VOUCHER_CODE: processSingleField,
|
|
1304
|
+
BS_E3_REISSUE_GOODS: processBsE3ReissueGoods(templateColumns),
|
|
1305
|
+
ACTUAL_RECEIPT_PAYMENT: processSingleField,
|
|
1306
|
+
WDT_SHOP: processSingleField,
|
|
1307
|
+
KM_VIDEO: processKmVideo,
|
|
1308
|
+
WDT_TAGS: wdtTags,
|
|
1309
|
+
EXECUTE_ACTION_TYPE: processExecuteActionType,
|
|
1310
|
+
SKX_GOODS: processSkxGoods,
|
|
1311
|
+
SKX_LOGISTICS: processErpLogistics
|
|
1312
|
+
}, Object.keys(processSingleFieldTypeMapping).reduce(function (acc, key) {
|
|
1313
|
+
acc[key] = processSingleFieldByKey(processSingleFieldTypeMapping[key]);
|
|
1314
|
+
return acc;
|
|
1315
|
+
}, {}));
|
|
1316
|
+
return templateColumns.reduce(function (cur, nex) {
|
|
1317
|
+
var _componentProcessors;
|
|
1318
|
+
var config = type === "init" ? nex.componentConfig : {};
|
|
1319
|
+
var processFunc = (_componentProcessors = componentProcessors[nex.workOrderComponentType]) === null || _componentProcessors === void 0 ? void 0 : _componentProcessors.call(componentProcessors, getValue);
|
|
1320
|
+
if (processFunc) {
|
|
1321
|
+
return _objectSpread(_objectSpread({}, cur), processFunc(nex, config));
|
|
1322
|
+
}
|
|
1323
|
+
return cur; // 如果没有找到处理函数,返回当前累积对象
|
|
1324
|
+
}, {});
|
|
1325
|
+
};
|
|
1326
|
+
};
|
|
1327
|
+
export default transformWorkOrderData;
|