@kmkf-fe-packages/kmkf-work-order-service-component 2.7.1 → 2.7.2
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/FlowTemplateDetailV2/common.js +1 -1
- package/dist/esm/FlowTemplateDetailV2/components/CurrentNode/index.d.ts +1 -0
- package/dist/esm/FlowTemplateDetailV2/components/CurrentNode/index.js +4 -2
- package/dist/esm/FlowTemplateDetailV2/components/FormRender/index.d.ts +1 -0
- package/dist/esm/FlowTemplateDetailV2/components/FormRender/index.js +75 -64
- package/dist/esm/FlowTemplateDetailV2/components/Item/index.js +1 -1
- package/dist/esm/FlowTemplateDetailV2/components/XiaozhiConversation/index.d.ts +21 -0
- package/dist/esm/FlowTemplateDetailV2/components/XiaozhiConversation/index.js +73 -0
- package/dist/esm/FlowTemplateDetailV2/index.js +27 -17
- package/dist/esm/common/utils/constant.js +11 -0
- package/dist/esm/common/utils/submitDataTransOldFormat.js +5 -0
- package/dist/esm/common/utils/tools.d.ts +1 -0
- package/dist/esm/common/utils/tools.js +213 -162
- package/dist/esm/common/utils/transformWorkOrderData.js +16 -2
- package/dist/esm/model/logicFlow/selector.d.ts +3 -0
- package/dist/esm/model/paymentWorkOrder/selector.d.ts +9 -0
- package/dist/esm/model/servers/api.d.ts +4 -0
- package/dist/esm/model/servers/api.js +10 -0
- package/dist/esm/model/singleShopWorkOrder/selector.d.ts +5 -0
- package/package.json +5 -5
- package/dist/esm/GlobalContext/hook/dist/useGetHasErpData.js +0 -52
- package/dist/esm/GlobalContext/orderQuery/dist/useGetErpAddressData.js +0 -180
- package/dist/esm/GlobalContext/orderQuery/dist/useGetErpLogisticsCompany.js +0 -186
- package/dist/esm/common/utils/dist/submitDataTransOldFormat.js +0 -899
- package/dist/esm/common/utils/dist/tools.js +0 -1326
- package/dist/esm/common/utils/dist/transformWorkOrderData.js +0 -965
- package/dist/esm/model/customizeWorkOrder/dist/api.js +0 -48
- package/dist/esm/model/customizeWorkOrder/dist/index.js +0 -370
- package/dist/esm/model/customizeWorkOrder/dist/selector.js +0 -63
- package/dist/esm/model/customizeWorkOrder/dist/types.js +0 -3
- package/dist/esm/model/dist/global.js +0 -44
- package/dist/esm/model/dist/hooks.js +0 -15
- package/dist/esm/model/dist/login.js +0 -245
- package/dist/esm/model/dist/store.js +0 -30
- package/dist/esm/model/dist/userData.js +0 -41
- package/dist/esm/model/dist/workOrder.js +0 -329
- package/dist/esm/model/flowTemplateDetail/dist/api.js +0 -192
- package/dist/esm/model/flowTemplateDetail/dist/types.js +0 -48
- package/dist/esm/model/logicFlow/dist/api.js +0 -14
- package/dist/esm/model/logicFlow/dist/index.js +0 -235
- package/dist/esm/model/logicFlow/dist/selector.js +0 -18
- package/dist/esm/model/logicFlow/dist/types.js +0 -3
- package/dist/esm/model/paymentWorkOrder/dist/index.js +0 -77
- package/dist/esm/model/paymentWorkOrder/dist/selector.js +0 -36
- package/dist/esm/model/paymentWorkOrder/dist/types.js +0 -3
- package/dist/esm/model/servers/dist/api.js +0 -545
- package/dist/esm/model/servers/dist/request.js +0 -63
- package/dist/esm/model/singleShopWorkOrder/dist/index.js +0 -216
- package/dist/esm/model/singleShopWorkOrder/dist/selector.js +0 -24
- package/dist/esm/model/singleShopWorkOrder/dist/types.js +0 -3
- package/dist/esm/model/types/dist/login.js +0 -3
- package/dist/esm/model/types/dist/singleWorkOrder.js +0 -3
- package/dist/esm/model/types/dist/workOrder.js +0 -3
|
@@ -40,7 +40,7 @@ export var FLOW_STATUS_V2 = {
|
|
|
40
40
|
RETURNING: '回退中'
|
|
41
41
|
};
|
|
42
42
|
//不能回填的组件type
|
|
43
|
-
export var CANNOT_BACK_FILL = ['LOGISTICS_TRAJECTORY', 'LOGISTICS_TRAJECTORY_MORE', 'BUYER_MESSAGE_NOTICE', 'MSG_STATUS', 'NEW_PAYMENT_STATUS', 'REISSUE_STATUS', 'REISSUE_LOGISTICS', 'RETURN_GOODS_STATUS', 'RETURN_GOODS_TRADE_ID', 'ADJUST_WORK_ORDER_STATUS', 'INVOICE_STATUS', 'INVOICING_STATUS', 'EXCHANGE_STATUS', 'WAREHOUSING_STATUS', 'BS_E3_WAREHOUSING_STATUS', 'WDT_WAREHOUSING_STATUS', 'JKY_WAREHOUSING_STATUS', 'EXCHANGE_TRADE_ID', 'REISSUE_TRADE_ID', 'SWAP_OUT_TRADE_ID', 'ERP_AFTER_SALE_TRADE_ID', 'LOGISTICS_INTERCEPTION', 'LOGISTICS_INTERCEPTION_MORE', 'ORDER_TYPE', 'REFUND_TYPE', 'RETURN_EXCHANGE_GOODS_REVIEW_STATUS', 'EXECUTE_ACTION_TYPE'];
|
|
43
|
+
export var CANNOT_BACK_FILL = ['LOGISTICS_TRAJECTORY', 'LOGISTICS_TRAJECTORY_MORE', 'BUYER_MESSAGE_NOTICE', 'MSG_STATUS', 'NEW_PAYMENT_STATUS', 'REISSUE_STATUS', 'REISSUE_LOGISTICS', 'RETURN_GOODS_STATUS', 'RETURN_GOODS_TRADE_ID', 'ADJUST_WORK_ORDER_STATUS', 'ERP_REMARK', 'INVOICE_STATUS', 'INVOICING_STATUS', 'EXCHANGE_STATUS', 'WAREHOUSING_STATUS', 'BS_E3_WAREHOUSING_STATUS', 'WDT_WAREHOUSING_STATUS', 'JKY_WAREHOUSING_STATUS', 'EXCHANGE_TRADE_ID', 'REISSUE_TRADE_ID', 'SWAP_OUT_TRADE_ID', 'ERP_AFTER_SALE_TRADE_ID', 'LOGISTICS_INTERCEPTION', 'LOGISTICS_INTERCEPTION_MORE', 'ORDER_TYPE', 'REFUND_TYPE', 'RETURN_EXCHANGE_GOODS_REVIEW_STATUS', 'EXECUTE_ACTION_TYPE'];
|
|
44
44
|
export var verifyHandle = function verifyHandle(data, componentDtoList) {
|
|
45
45
|
var _componentDtoList$fin, _componentDtoList$fin2, _data$paymentUniqueKe, _data$paymentUniqueKe2;
|
|
46
46
|
var res = {
|
|
@@ -14,6 +14,7 @@ declare type CurrentNodeProps = {
|
|
|
14
14
|
queryRemarkList: () => void;
|
|
15
15
|
autoSubmit?: boolean;
|
|
16
16
|
isSuperAdmin?: boolean;
|
|
17
|
+
autoFillThirdPartyFields?: boolean;
|
|
17
18
|
};
|
|
18
19
|
declare const _default: React.ForwardRefExoticComponent<CurrentNodeProps & React.RefAttributes<unknown>>;
|
|
19
20
|
export default _default;
|
|
@@ -69,7 +69,8 @@ var CurrentNode = function CurrentNode(props, ref) {
|
|
|
69
69
|
flowWorkOrderId = props.flowWorkOrderId,
|
|
70
70
|
queryRemarkList = props.queryRemarkList,
|
|
71
71
|
autoSubmit = props.autoSubmit,
|
|
72
|
-
onJumpPage = props.onJumpPage
|
|
72
|
+
onJumpPage = props.onJumpPage,
|
|
73
|
+
autoFillThirdPartyFields = props.autoFillThirdPartyFields;
|
|
73
74
|
var _useContext = useContext(Context),
|
|
74
75
|
dispatch = _useContext.dispatch;
|
|
75
76
|
// 是否是编辑状态
|
|
@@ -418,7 +419,8 @@ var CurrentNode = function CurrentNode(props, ref) {
|
|
|
418
419
|
flowAllShowHideRules: allShowHideRules,
|
|
419
420
|
isStartNodeWaiting: NodeType.START_NODE === (currentNodeDetail === null || currentNodeDetail === void 0 ? void 0 : (_currentNodeDetail$no25 = currentNodeDetail.nodeInfo) === null || _currentNodeDetail$no25 === void 0 ? void 0 : _currentNodeDetail$no25.nodeType) && [NodeStatus.WAITING].includes(currentNodeDetail === null || currentNodeDetail === void 0 ? void 0 : (_currentNodeDetail$wo23 = currentNodeDetail.workOrder) === null || _currentNodeDetail$wo23 === void 0 ? void 0 : _currentNodeDetail$wo23.flowStatus),
|
|
420
421
|
firstOrderBackfill: flowStatus !== FlowStatus.COMPLETED,
|
|
421
|
-
autoSubmit: autoSubmit
|
|
422
|
+
autoSubmit: autoSubmit,
|
|
423
|
+
autoFillThirdPartyFields: autoFillThirdPartyFields
|
|
422
424
|
})), isShowAutoNodeDetail && /*#__PURE__*/React.createElement(AutoTaskDetail, {
|
|
423
425
|
flowEventData: currentNodeDetail === null || currentNodeDetail === void 0 ? void 0 : currentNodeDetail.flowEventData,
|
|
424
426
|
shopList: shopList
|
|
@@ -33,6 +33,7 @@ declare type FormRenderProps = {
|
|
|
33
33
|
isErpUse?: boolean;
|
|
34
34
|
autoSubmit?: boolean;
|
|
35
35
|
isStartNodeWaiting?: boolean;
|
|
36
|
+
autoFillThirdPartyFields?: boolean;
|
|
36
37
|
};
|
|
37
38
|
declare const _default: React.ForwardRefExoticComponent<FormRenderProps & React.RefAttributes<unknown>>;
|
|
38
39
|
export default _default;
|
|
@@ -29,10 +29,10 @@ import { get, some, set, every, cloneDeep, isEmpty, intersection, throttle, grou
|
|
|
29
29
|
import 'moment/locale/zh-cn';
|
|
30
30
|
import { calcWorkOrderList, orderBack, getReplaceWarnValues, COMPONENT_MAP_NAME, EXCLUDE_REPLACE_TOP_COMPONENT,
|
|
31
31
|
// 重复检验不需要展示在顶部的
|
|
32
|
-
INNER_REPLACE_COMPONENT, reversalFormValues, wdtReturnBillNoBackValues, bsSystemOrderBackValues, kmSystemOrderBackValues, bsE3SystemOrderBackValues, wlnSystemOrderBackValues, gySystemOrderBackValues, jstSystemOrderBackValues, jySystemOrderBackValues, jkySystemOrderBackValues, getMappingConfigByTemplateDetail, wdtSystemOrderBackValues, setLogisticsInfo, getMappingTargetValue, FIXED_FIELD_CAN_MODIFY_SHOP } from "../../../common/utils/tools";
|
|
32
|
+
INNER_REPLACE_COMPONENT, reversalFormValues, wdtReturnBillNoBackValues, afterSaleOrderBackValues, bsSystemOrderBackValues, kmSystemOrderBackValues, bsE3SystemOrderBackValues, wlnSystemOrderBackValues, gySystemOrderBackValues, jstSystemOrderBackValues, jySystemOrderBackValues, jkySystemOrderBackValues, getMappingConfigByTemplateDetail, wdtSystemOrderBackValues, setLogisticsInfo, getMappingTargetValue, FIXED_FIELD_CAN_MODIFY_SHOP } from "../../../common/utils/tools";
|
|
33
33
|
import { replaceCheck, orderDetail, queryLabelByTradeId, queryMemberLevel } from "../../../model/servers/api";
|
|
34
34
|
import { factory } from '@kmkf-fe-packages/services-components';
|
|
35
|
-
import { getExpression, formatDisplayConfig, isNull, LabelData, setSessionStorage } from '@kmkf-fe-packages/kmkf-utils';
|
|
35
|
+
import { getExpression, formatDisplayConfig, isNull, LabelData, setSessionStorage, afterSaleOrderBack } from '@kmkf-fe-packages/kmkf-utils';
|
|
36
36
|
import ShopName from "../ShopName";
|
|
37
37
|
import { PlatForm } from "../../../model/flowTemplateDetail/types";
|
|
38
38
|
import { groupByPreNode, getCurrentNodeModifiedShowHideRule } from "./common";
|
|
@@ -95,7 +95,16 @@ var FormRender = function FormRender(props, ref) {
|
|
|
95
95
|
autoSubmit = _props$autoSubmit === void 0 ? false : _props$autoSubmit,
|
|
96
96
|
_props$isStartNodeWai = props.isStartNodeWaiting,
|
|
97
97
|
isStartNodeWaiting = _props$isStartNodeWai === void 0 ? false : _props$isStartNodeWai,
|
|
98
|
-
onJumpPage = props.onJumpPage
|
|
98
|
+
onJumpPage = props.onJumpPage,
|
|
99
|
+
autoFillThirdPartyFields = props.autoFillThirdPartyFields;
|
|
100
|
+
var notAutoFillFlag = useMemo(function () {
|
|
101
|
+
// autoFillThirdPartyFields=false 一票否决 → FALSE
|
|
102
|
+
if (autoFillThirdPartyFields === false) {
|
|
103
|
+
return false;
|
|
104
|
+
}
|
|
105
|
+
// 其余情况:notAutoFillWithFirstSubmit 或 preCreateAndNotModified 任一为 true → TRUE
|
|
106
|
+
return !!(record !== null && record !== void 0 && record.notAutoFillWithFirstSubmit || record !== null && record !== void 0 && record.preCreateAndNotModified);
|
|
107
|
+
}, [record === null || record === void 0 ? void 0 : record.notAutoFillWithFirstSubmit, record === null || record === void 0 ? void 0 : record.preCreateAndNotModified, autoFillThirdPartyFields]);
|
|
99
108
|
var shopIdToUniqueKeyMap = useMemo(function () {
|
|
100
109
|
var json = {};
|
|
101
110
|
shopList.forEach(function (shop) {
|
|
@@ -402,7 +411,7 @@ var FormRender = function FormRender(props, ref) {
|
|
|
402
411
|
}, [labelComponent, record]);
|
|
403
412
|
var queryDetail = /*#__PURE__*/function () {
|
|
404
413
|
var _ref3 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee2(_ref2) {
|
|
405
|
-
var workOrderId, shopId, shopList, record, orderNo, buyerId, buyerNick, jsonMap,
|
|
414
|
+
var workOrderId, shopId, shopList, record, orderNo, buyerId, buyerNick, jsonMap, newRecord, jsonMapOrderId, getCacheInfo, newFormValues, transData, initialValues, tradeIdUniqueKey, _record$jsonMap2, _record$jsonMap3, _userInfo$companyUser3, _companyUserConfig$pl, _companyUserConfig$pl2, _companyUserConfig$pl3, _record$jsonMap4, _record$jsonMap5, currentNodeTradeIdUniqueKey, _currentNodeTid, currentNodeExpressLogisticsCodeKey, currentNodeLogisticsCode, isSkx, _userInfo, companyUserConfig, hasWdt, preTradeId, tradeId, initFormValues, _getCacheInfo, _getCacheInfo2, _getCacheInfo3, _getCacheInfo4, _orderNo, _shopId, orderNoField, _transData, _initialValues, antFormEl;
|
|
406
415
|
return _regeneratorRuntime().wrap(function _callee2$(_context2) {
|
|
407
416
|
while (1) switch (_context2.prev = _context2.next) {
|
|
408
417
|
case 0:
|
|
@@ -432,7 +441,7 @@ var FormRender = function FormRender(props, ref) {
|
|
|
432
441
|
return prv;
|
|
433
442
|
}, {});
|
|
434
443
|
if (!workOrderId) {
|
|
435
|
-
_context2.next =
|
|
444
|
+
_context2.next = 58;
|
|
436
445
|
break;
|
|
437
446
|
}
|
|
438
447
|
// 先初始化端上内容
|
|
@@ -460,12 +469,12 @@ var FormRender = function FormRender(props, ref) {
|
|
|
460
469
|
}));
|
|
461
470
|
console.log('transData', get(transData, '0', {}));
|
|
462
471
|
initialValues = get(transData, '0', {});
|
|
463
|
-
newRecord.preCreateAndNotModified && !
|
|
472
|
+
newRecord.preCreateAndNotModified && !notAutoFillFlag && batchFillByMapping(initialValues);
|
|
464
473
|
orderBackReplace(transData, templateDetail);
|
|
465
474
|
// TODO: 非开始节点录入,都会有workOrderId,这里判断是否有前置组件含有订单号;如果存在订单号,进行订单反填。
|
|
466
475
|
tradeIdUniqueKey = findComponentUniqueKeyByType(templateDetail === null || templateDetail === void 0 ? void 0 : templateDetail.preNodeComponentDtoList, 'TRADE_ID_INPUT');
|
|
467
|
-
if (!
|
|
468
|
-
_context2.next =
|
|
476
|
+
if (!notAutoFillFlag) {
|
|
477
|
+
_context2.next = 54;
|
|
469
478
|
break;
|
|
470
479
|
}
|
|
471
480
|
currentNodeTradeIdUniqueKey = findComponentUniqueKeyByType(templateDetail === null || templateDetail === void 0 ? void 0 : templateDetail.componentDtoList, 'TRADE_ID_INPUT');
|
|
@@ -476,16 +485,18 @@ var FormRender = function FormRender(props, ref) {
|
|
|
476
485
|
_userInfo = JSON.parse(localStorage.getItem('reduxData_userInfo') || '{}');
|
|
477
486
|
companyUserConfig = (_userInfo$companyUser3 = _userInfo === null || _userInfo === void 0 ? void 0 : _userInfo.companyUserConfig) !== null && _userInfo$companyUser3 !== void 0 ? _userInfo$companyUser3 : {};
|
|
478
487
|
hasWdt = (_companyUserConfig$pl = companyUserConfig === null || companyUserConfig === void 0 ? void 0 : (_companyUserConfig$pl2 = companyUserConfig.plugins) === null || _companyUserConfig$pl2 === void 0 ? void 0 : (_companyUserConfig$pl3 = _companyUserConfig$pl2.wdt) === null || _companyUserConfig$pl3 === void 0 ? void 0 : _companyUserConfig$pl3.show) !== null && _companyUserConfig$pl !== void 0 ? _companyUserConfig$pl : false;
|
|
479
|
-
|
|
480
|
-
|
|
488
|
+
preTradeId = tradeIdUniqueKey && shopId && record !== null && record !== void 0 && (_record$jsonMap4 = record.jsonMap) !== null && _record$jsonMap4 !== void 0 && _record$jsonMap4["".concat(tradeIdUniqueKey, "_tradeId")] && firstOrderBackfill ? record === null || record === void 0 ? void 0 : (_record$jsonMap5 = record.jsonMap) === null || _record$jsonMap5 === void 0 ? void 0 : _record$jsonMap5["".concat(tradeIdUniqueKey, "_tradeId")] : undefined;
|
|
489
|
+
tradeId = _currentNodeTid || preTradeId;
|
|
490
|
+
if (!tradeId) {
|
|
491
|
+
_context2.next = 38;
|
|
481
492
|
break;
|
|
482
493
|
}
|
|
483
|
-
queryLabels(
|
|
484
|
-
queryMemberLevels(
|
|
485
|
-
_context2.next =
|
|
494
|
+
queryLabels(tradeId, shopId);
|
|
495
|
+
queryMemberLevels(tradeId, shopId);
|
|
496
|
+
_context2.next = 36;
|
|
486
497
|
return orderBack({
|
|
487
498
|
companyKey: companyKey,
|
|
488
|
-
order_no:
|
|
499
|
+
order_no: tradeId,
|
|
489
500
|
form: form,
|
|
490
501
|
shopId: shopId,
|
|
491
502
|
shopList: shopList,
|
|
@@ -496,15 +507,15 @@ var FormRender = function FormRender(props, ref) {
|
|
|
496
507
|
callKey: 1,
|
|
497
508
|
setLoading: setLoading
|
|
498
509
|
});
|
|
499
|
-
case 34:
|
|
500
|
-
_context2.next = 44;
|
|
501
|
-
break;
|
|
502
510
|
case 36:
|
|
511
|
+
_context2.next = 51;
|
|
512
|
+
break;
|
|
513
|
+
case 38:
|
|
503
514
|
if (!isSkx) {
|
|
504
|
-
_context2.next =
|
|
515
|
+
_context2.next = 44;
|
|
505
516
|
break;
|
|
506
517
|
}
|
|
507
|
-
_context2.next =
|
|
518
|
+
_context2.next = 41;
|
|
508
519
|
return skxOrderBack({
|
|
509
520
|
form: form,
|
|
510
521
|
companyKey: companyKey,
|
|
@@ -512,52 +523,40 @@ var FormRender = function FormRender(props, ref) {
|
|
|
512
523
|
componentOnBlur: componentOnBlur,
|
|
513
524
|
jsonMap: record === null || record === void 0 ? void 0 : record.jsonMap
|
|
514
525
|
});
|
|
515
|
-
case 39:
|
|
516
|
-
_context2.next = 44;
|
|
517
|
-
break;
|
|
518
526
|
case 41:
|
|
527
|
+
// 售后单反填
|
|
528
|
+
afterSaleOrderBack(form, templateDetail);
|
|
529
|
+
_context2.next = 51;
|
|
530
|
+
break;
|
|
531
|
+
case 44:
|
|
519
532
|
if (!(hasWdt && currentNodeLogisticsCode)) {
|
|
520
|
-
_context2.next =
|
|
533
|
+
_context2.next = 50;
|
|
521
534
|
break;
|
|
522
535
|
}
|
|
523
|
-
|
|
536
|
+
// 售后单反填
|
|
537
|
+
afterSaleOrderBack(form, templateDetail);
|
|
538
|
+
_context2.next = 48;
|
|
524
539
|
return componentOnBlur(currentNodeLogisticsCode, 'expressLogisticsCode');
|
|
525
|
-
case
|
|
540
|
+
case 48:
|
|
541
|
+
_context2.next = 51;
|
|
542
|
+
break;
|
|
543
|
+
case 50:
|
|
544
|
+
// 售后单反填
|
|
545
|
+
afterSaleOrderBack(form, templateDetail);
|
|
546
|
+
case 51:
|
|
526
547
|
// 仅在依赖值有值且映射值为空时触发一次映射
|
|
527
548
|
batchFillByMappingWhenTargetEmpty(initialValues);
|
|
528
|
-
_context2.next =
|
|
529
|
-
break;
|
|
530
|
-
case 47:
|
|
531
|
-
if (!(tradeIdUniqueKey && shopId && record !== null && record !== void 0 && (_record$jsonMap4 = record.jsonMap) !== null && _record$jsonMap4 !== void 0 && _record$jsonMap4["".concat(tradeIdUniqueKey, "_tradeId")] && firstOrderBackfill)) {
|
|
532
|
-
_context2.next = 54;
|
|
533
|
-
break;
|
|
534
|
-
}
|
|
535
|
-
queryLabels(record === null || record === void 0 ? void 0 : (_record$jsonMap5 = record.jsonMap) === null || _record$jsonMap5 === void 0 ? void 0 : _record$jsonMap5["".concat(tradeIdUniqueKey, "_tradeId")], shopId);
|
|
536
|
-
queryMemberLevels(record === null || record === void 0 ? void 0 : (_record$jsonMap6 = record.jsonMap) === null || _record$jsonMap6 === void 0 ? void 0 : _record$jsonMap6["".concat(tradeIdUniqueKey, "_tradeId")], shopId);
|
|
537
|
-
_context2.next = 52;
|
|
538
|
-
return orderBack({
|
|
539
|
-
companyKey: companyKey,
|
|
540
|
-
order_no: record === null || record === void 0 ? void 0 : (_record$jsonMap7 = record.jsonMap) === null || _record$jsonMap7 === void 0 ? void 0 : _record$jsonMap7["".concat(tradeIdUniqueKey, "_tradeId")],
|
|
541
|
-
form: form,
|
|
542
|
-
shopId: shopId,
|
|
543
|
-
shopList: shopList,
|
|
544
|
-
templateDetail: templateDetail,
|
|
545
|
-
callback: orderBackReplace,
|
|
546
|
-
fromQNCreateWorkOrderByOrderNo: fromQNCreateWorkOrderByOrderNo,
|
|
547
|
-
plat: plat,
|
|
548
|
-
callKey: 1,
|
|
549
|
-
setLoading: setLoading
|
|
550
|
-
});
|
|
551
|
-
case 52:
|
|
552
|
-
_context2.next = 55;
|
|
549
|
+
_context2.next = 56;
|
|
553
550
|
break;
|
|
554
551
|
case 54:
|
|
555
552
|
// 如果没有订单反填,则单独更新remark
|
|
556
553
|
fetchRemark(shopId, currentNodeTid);
|
|
557
|
-
|
|
558
|
-
|
|
554
|
+
// 售后单反填
|
|
555
|
+
afterSaleOrderBack(form, templateDetail);
|
|
556
|
+
case 56:
|
|
557
|
+
_context2.next = 82;
|
|
559
558
|
break;
|
|
560
|
-
case
|
|
559
|
+
case 58:
|
|
561
560
|
fillByShopId(shopId);
|
|
562
561
|
initFormValues = null;
|
|
563
562
|
if (plat !== null && plat !== void 0 && plat.subOrderNo) {
|
|
@@ -576,7 +575,7 @@ var FormRender = function FormRender(props, ref) {
|
|
|
576
575
|
|
|
577
576
|
// console.log(orderNo, initFormValues);
|
|
578
577
|
if (!initFormValues) {
|
|
579
|
-
_context2.next =
|
|
578
|
+
_context2.next = 69;
|
|
580
579
|
break;
|
|
581
580
|
}
|
|
582
581
|
form.setFieldsValue(_objectSpread(_objectSpread({}, initFormValues), {}, {
|
|
@@ -593,9 +592,9 @@ var FormRender = function FormRender(props, ref) {
|
|
|
593
592
|
_orderNo = orderNoField !== null && orderNoField !== void 0 && orderNoField.uniqueKey ? initFormValues[orderNoField === null || orderNoField === void 0 ? void 0 : orderNoField.uniqueKey] || _orderNo : _orderNo;
|
|
594
593
|
}
|
|
595
594
|
fetchRemark(_shopId, _orderNo);
|
|
596
|
-
_context2.next =
|
|
595
|
+
_context2.next = 82;
|
|
597
596
|
break;
|
|
598
|
-
case
|
|
597
|
+
case 69:
|
|
599
598
|
_transData = calcWorkOrderList([{
|
|
600
599
|
jsonMap: jsonMap
|
|
601
600
|
}], [].concat(_toConsumableArray((templateDetail === null || templateDetail === void 0 ? void 0 : templateDetail.preNodeComponentDtoList) || []), _toConsumableArray((templateDetail === null || templateDetail === void 0 ? void 0 : templateDetail.componentDtoList) || [])), 'init');
|
|
@@ -607,12 +606,12 @@ var FormRender = function FormRender(props, ref) {
|
|
|
607
606
|
batchFillByMapping(_initialValues);
|
|
608
607
|
//如果有订单号 订单返填 通过订单号入口进行工单录入,需要将订单数据反填到工单
|
|
609
608
|
if (!(orderNo && shopId)) {
|
|
610
|
-
_context2.next =
|
|
609
|
+
_context2.next = 80;
|
|
611
610
|
break;
|
|
612
611
|
}
|
|
613
612
|
queryLabels(orderNo, shopId);
|
|
614
613
|
queryMemberLevels(orderNo, shopId);
|
|
615
|
-
_context2.next =
|
|
614
|
+
_context2.next = 78;
|
|
616
615
|
return orderBack({
|
|
617
616
|
companyKey: companyKey,
|
|
618
617
|
order_no: orderNo,
|
|
@@ -627,13 +626,15 @@ var FormRender = function FormRender(props, ref) {
|
|
|
627
626
|
callKey: 2,
|
|
628
627
|
setLoading: setLoading
|
|
629
628
|
});
|
|
630
|
-
case
|
|
631
|
-
_context2.next =
|
|
629
|
+
case 78:
|
|
630
|
+
_context2.next = 82;
|
|
632
631
|
break;
|
|
633
|
-
case
|
|
632
|
+
case 80:
|
|
634
633
|
// 如果没有订单反填,则单独更新remark
|
|
635
634
|
fetchRemark(shopId, currentNodeTid);
|
|
636
|
-
|
|
635
|
+
// 售后单反填
|
|
636
|
+
afterSaleOrderBack(form, templateDetail);
|
|
637
|
+
case 82:
|
|
637
638
|
antFormEl = document.getElementsByClassName('ant-form');
|
|
638
639
|
(antFormEl === null || antFormEl === void 0 ? void 0 : antFormEl.length) > 0 && set(antFormEl, '0.scrollTop', 0);
|
|
639
640
|
resetMappingHideComponents();
|
|
@@ -642,7 +643,7 @@ var FormRender = function FormRender(props, ref) {
|
|
|
642
643
|
type: 'setaAutoSubmitFlag',
|
|
643
644
|
payload: true
|
|
644
645
|
});
|
|
645
|
-
case
|
|
646
|
+
case 86:
|
|
646
647
|
case "end":
|
|
647
648
|
return _context2.stop();
|
|
648
649
|
}
|
|
@@ -663,7 +664,7 @@ var FormRender = function FormRender(props, ref) {
|
|
|
663
664
|
buyerId: buyerId,
|
|
664
665
|
buyerNick: buyerNick
|
|
665
666
|
});
|
|
666
|
-
}, [workOrderId, record, shopId, isErpUse]);
|
|
667
|
+
}, [workOrderId, record, shopId, isErpUse, autoFillThirdPartyFields]);
|
|
667
668
|
|
|
668
669
|
// 重置映射隐藏的组件, 目前只有单选、下拉组件可能会因为映射关系隐藏
|
|
669
670
|
var resetMappingHideComponents = function resetMappingHideComponents() {
|
|
@@ -1025,6 +1026,13 @@ var FormRender = function FormRender(props, ref) {
|
|
|
1025
1026
|
form: form
|
|
1026
1027
|
});
|
|
1027
1028
|
}
|
|
1029
|
+
if (workOrderComponentType === 'PLATFORM_AFTER_SALES_ORDER') {
|
|
1030
|
+
afterSaleOrderBackValues({
|
|
1031
|
+
templateList: templateDetail,
|
|
1032
|
+
value: value,
|
|
1033
|
+
form: form
|
|
1034
|
+
});
|
|
1035
|
+
}
|
|
1028
1036
|
if (activeLogisticsComponents && ['INPUT', 'EXPRESS_LOGISTICS_SELECT', 'BS_LOGISTICS'].includes(workOrderComponentType)) {
|
|
1029
1037
|
setLogisticsInfo({
|
|
1030
1038
|
logisticsMappingConfig: activeLogisticsComponents,
|
|
@@ -1339,6 +1347,9 @@ var FormRender = function FormRender(props, ref) {
|
|
|
1339
1347
|
callKey: 4,
|
|
1340
1348
|
setLoading: setLoading
|
|
1341
1349
|
});
|
|
1350
|
+
} else {
|
|
1351
|
+
// 售后单反填
|
|
1352
|
+
afterSaleOrderBack(form, templateDetail);
|
|
1342
1353
|
}
|
|
1343
1354
|
}
|
|
1344
1355
|
};
|
|
@@ -274,7 +274,7 @@ var NodeItem = function NodeItem(props) {
|
|
|
274
274
|
isAllStaff: data === null || data === void 0 ? void 0 : (_data$data11 = data.data) === null || _data$data11 === void 0 ? void 0 : (_data$data11$nodeInfo = _data$data11.nodeInfo) === null || _data$data11$nodeInfo === void 0 ? void 0 : (_data$data11$nodeInfo2 = _data$data11$nodeInfo.assistants) === null || _data$data11$nodeInfo2 === void 0 ? void 0 : _data$data11$nodeInfo2.isAllStaff
|
|
275
275
|
});
|
|
276
276
|
}, [data, plat.userKey, assistantMap]);
|
|
277
|
-
var isShowAutoNodeDetail = isAutoNode && ['ORDER_MEMO_MANY_RULES', 'AFTER_SALE_AUTO_RETURN_GOODS_AGREE_REJECT', 'AFTER_SALE_AUTO_REFUND_REJECT', 'LOGISTICS_INTERCEPT_MULTI_RULE', 'MESSAGE_NOTIFY_EVENT', 'DING_TALK_ROBOT_NOTIFY', 'HTTP_INVOKE', 'ORDER_MEMO', 'WDT_STORE_STATUS', 'BS_E3_RETAIL_RETURN_IN_STOCK_SYNC', 'RETAIL_RETURN_IN_STOCK_SYNC', 'PLATFORM_LOGISTICS_INTERCEPT', 'LBDJ_ONE_PRICE_ORDER'].includes(eventNodeType);
|
|
277
|
+
var isShowAutoNodeDetail = isAutoNode && ['ORDER_MEMO_MANY_RULES', 'AFTER_SALE_AUTO_RETURN_GOODS_AGREE_REJECT', 'AFTER_SALE_AUTO_REFUND_REJECT', 'LOGISTICS_INTERCEPT_MULTI_RULE', 'MESSAGE_NOTIFY_EVENT', 'DING_TALK_ROBOT_NOTIFY', 'HTTP_INVOKE', 'ORDER_MEMO', 'WDT_STORE_STATUS', 'BS_E3_RETAIL_RETURN_IN_STOCK_SYNC', 'RETAIL_RETURN_IN_STOCK_SYNC', 'PLATFORM_LOGISTICS_INTERCEPT', 'LBDJ_ONE_PRICE_ORDER', 'JST_ORDER_REMARK'].includes(eventNodeType);
|
|
278
278
|
// 人工节点+打开状态+当前工单提交人是当前完成人+状态是待处理
|
|
279
279
|
var showEdit = isArtificialNode && open && isCurrentNodeHandler && !readonly && [FlowStatus.PROCESSING, FlowStatus.COMPLETED].includes(flowStatus);
|
|
280
280
|
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
export interface JumpCustomerIconProps {
|
|
3
|
+
tid: string;
|
|
4
|
+
shopName: string;
|
|
5
|
+
platformType: number;
|
|
6
|
+
onJumpPage?: (data: {
|
|
7
|
+
type: string;
|
|
8
|
+
params: string;
|
|
9
|
+
}) => void;
|
|
10
|
+
}
|
|
11
|
+
export declare const openCustomerDialog: ({ shopName, platformType, orderNumber, onJumpPage, }: {
|
|
12
|
+
shopName: string;
|
|
13
|
+
platformType: number;
|
|
14
|
+
orderNumber?: string | undefined;
|
|
15
|
+
onJumpPage?: ((data: {
|
|
16
|
+
type: string;
|
|
17
|
+
params: string;
|
|
18
|
+
}) => void) | undefined;
|
|
19
|
+
}) => void;
|
|
20
|
+
declare const JumpCustomerIcon: React.FC<JumpCustomerIconProps>;
|
|
21
|
+
export default JumpCustomerIcon;
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { Tooltip, Image } from 'antd';
|
|
3
|
+
import { Base64 } from 'js-base64';
|
|
4
|
+
import contact from "../../../common/imgs/contact.png";
|
|
5
|
+
var SUPPORTED_PLATFORMS = [0, 2, 3, 5, 6];
|
|
6
|
+
var platformTypeMap = {
|
|
7
|
+
0: 1,
|
|
8
|
+
// 淘宝
|
|
9
|
+
2: 2,
|
|
10
|
+
// 京东
|
|
11
|
+
3: 3,
|
|
12
|
+
// 拼多多
|
|
13
|
+
6: 4,
|
|
14
|
+
// 抖音
|
|
15
|
+
5: 5,
|
|
16
|
+
// 快手
|
|
17
|
+
24: 6 // 小红书
|
|
18
|
+
};
|
|
19
|
+
|
|
20
|
+
export var openCustomerDialog = function openCustomerDialog(_ref) {
|
|
21
|
+
var shopName = _ref.shopName,
|
|
22
|
+
platformType = _ref.platformType,
|
|
23
|
+
orderNumber = _ref.orderNumber,
|
|
24
|
+
onJumpPage = _ref.onJumpPage;
|
|
25
|
+
var type = platformTypeMap[platformType];
|
|
26
|
+
if (!type) return;
|
|
27
|
+
var params = {
|
|
28
|
+
event: 'open_buyers',
|
|
29
|
+
param: {
|
|
30
|
+
platformType: type,
|
|
31
|
+
shop: shopName,
|
|
32
|
+
order_number: orderNumber
|
|
33
|
+
}
|
|
34
|
+
};
|
|
35
|
+
console.log(params);
|
|
36
|
+
var jsonString = JSON.stringify(params);
|
|
37
|
+
var base64String = Base64.encodeURL(jsonString);
|
|
38
|
+
onJumpPage === null || onJumpPage === void 0 ? void 0 : onJumpPage({
|
|
39
|
+
type: 'Conversation',
|
|
40
|
+
params: base64String
|
|
41
|
+
});
|
|
42
|
+
};
|
|
43
|
+
var JumpCustomerIcon = function JumpCustomerIcon(_ref2) {
|
|
44
|
+
var tid = _ref2.tid,
|
|
45
|
+
shopName = _ref2.shopName,
|
|
46
|
+
platformType = _ref2.platformType,
|
|
47
|
+
onJumpPage = _ref2.onJumpPage;
|
|
48
|
+
if (!tid || !SUPPORTED_PLATFORMS.includes(platformType)) {
|
|
49
|
+
return null;
|
|
50
|
+
}
|
|
51
|
+
var handleClick = function handleClick() {
|
|
52
|
+
openCustomerDialog({
|
|
53
|
+
shopName: shopName,
|
|
54
|
+
platformType: platformType,
|
|
55
|
+
orderNumber: tid,
|
|
56
|
+
onJumpPage: onJumpPage
|
|
57
|
+
});
|
|
58
|
+
};
|
|
59
|
+
return /*#__PURE__*/React.createElement(Tooltip, {
|
|
60
|
+
title: "\u6253\u5F00\u5C0F\u667A\u5BA2\u6237\u7AEF"
|
|
61
|
+
}, /*#__PURE__*/React.createElement("span", {
|
|
62
|
+
onClick: handleClick,
|
|
63
|
+
style: {
|
|
64
|
+
cursor: 'pointer',
|
|
65
|
+
marginLeft: 8
|
|
66
|
+
}
|
|
67
|
+
}, /*#__PURE__*/React.createElement(Image, {
|
|
68
|
+
src: contact,
|
|
69
|
+
preview: false,
|
|
70
|
+
width: 12
|
|
71
|
+
})));
|
|
72
|
+
};
|
|
73
|
+
export default JumpCustomerIcon;
|
|
@@ -58,10 +58,11 @@ import { pollOperationResult } from "./pollOperationResult";
|
|
|
58
58
|
import { pushGyLog } from '@kmkf-fe-packages/kmkf-utils';
|
|
59
59
|
import { PlatForm } from "../WorkOrder/types";
|
|
60
60
|
import Layout from "./components/Layout";
|
|
61
|
+
import JumpCustomerIcon from "./components/XiaozhiConversation";
|
|
61
62
|
var Text = Typography.Text,
|
|
62
63
|
Link = Typography.Link;
|
|
63
64
|
var FlowTemplateDetail = function FlowTemplateDetail(props) {
|
|
64
|
-
var _currentNodeDetail$wo, _currentNodeDetail$no, _document, _document$cookie, _currentNodeDetail$wo2, _currentNodeDetail$no16, _shopList$find, _currentNodeDetail$no29, _currentNodeDetail$no30, _currentNodeDetail$
|
|
65
|
+
var _currentNodeDetail$wo, _currentNodeDetail$no, _document, _document$cookie, _currentNodeDetail$wo2, _currentNodeDetail$no16, _shopList$find, _currentNodeDetail$no29, _currentNodeDetail$no30, _currentNodeDetail$wo29, _currentNodeDetail$wo30, _JSON$parse, _currentNodeDetail$wo31, _currentNodeDetail$wo32, _currentNodeDetail$wo33, _currentNodeDetail$wo34, _currentNodeDetail$wo35, _currentNodeDetail$no31, _currentNodeDetail$no32;
|
|
65
66
|
var flowTemplateKey = props.flowTemplateKey,
|
|
66
67
|
_props$shopList = props.shopList,
|
|
67
68
|
shopList = _props$shopList === void 0 ? [] : _props$shopList,
|
|
@@ -80,6 +81,7 @@ var FlowTemplateDetail = function FlowTemplateDetail(props) {
|
|
|
80
81
|
callbackAutoSubmitResult = props.callbackAutoSubmitResult,
|
|
81
82
|
_props$otherInfo = props.otherInfo,
|
|
82
83
|
otherInfo = _props$otherInfo === void 0 ? {} : _props$otherInfo;
|
|
84
|
+
var autoFillThirdPartyFields = otherInfo.autoFillThirdPartyFields;
|
|
83
85
|
var _useContext = useContext(Context),
|
|
84
86
|
dispatch = _useContext.dispatch;
|
|
85
87
|
var flowRecordList = useSelector(selectFlowRecordList);
|
|
@@ -1174,17 +1176,19 @@ var FlowTemplateDetail = function FlowTemplateDetail(props) {
|
|
|
1174
1176
|
};
|
|
1175
1177
|
useEffect(function () {
|
|
1176
1178
|
if (autoSubmit && !isEmpty(currentNodeDetail)) {
|
|
1177
|
-
var _currentNodeDetail$wo25
|
|
1179
|
+
var _currentNodeDetail$wo25;
|
|
1178
1180
|
// SKX首节点满足下列条件、此时批量提交会等订单数据反填再提交, 其余企业批量提交还是原先逻辑,不涉及订单数据反填
|
|
1179
|
-
|
|
1181
|
+
// 优先使用外部传入的 autoFillThirdPartyFields,未传时降级使用 record 中的 notAutoFillWithFirstSubmit
|
|
1182
|
+
var effectiveAutoFill = autoFillThirdPartyFields !== undefined ? autoFillThirdPartyFields : currentNodeDetail === null || currentNodeDetail === void 0 ? void 0 : (_currentNodeDetail$wo25 = currentNodeDetail.workOrder) === null || _currentNodeDetail$wo25 === void 0 ? void 0 : _currentNodeDetail$wo25.notAutoFillWithFirstSubmit;
|
|
1183
|
+
if (effectiveAutoFill && autoSubmitFlag) {
|
|
1180
1184
|
autoSubmitFn();
|
|
1181
|
-
} else if (!
|
|
1185
|
+
} else if (!effectiveAutoFill && !autoSubmitFlag) {
|
|
1182
1186
|
autoSubmitFn();
|
|
1183
1187
|
}
|
|
1184
1188
|
}
|
|
1185
|
-
}, [currentNodeDetail, autoSubmitFlag]);
|
|
1189
|
+
}, [currentNodeDetail, autoSubmitFlag, autoFillThirdPartyFields]);
|
|
1186
1190
|
var isCurrentNodeHandler = useMemo(function () {
|
|
1187
|
-
var _currentNodeDetail$no17, _currentNodeDetail$no18, _currentNodeDetail$no19, _currentNodeDetail$no20, _currentNodeDetail$no21, _currentNodeDetail$no22, _currentNodeDetail$no23, _currentNodeDetail$no24, _currentNodeDetail$
|
|
1191
|
+
var _currentNodeDetail$no17, _currentNodeDetail$no18, _currentNodeDetail$no19, _currentNodeDetail$no20, _currentNodeDetail$no21, _currentNodeDetail$no22, _currentNodeDetail$no23, _currentNodeDetail$no24, _currentNodeDetail$wo26, _currentNodeDetail$no25, _currentNodeDetail$no26;
|
|
1188
1192
|
return currentUserHasOperatorAuth({
|
|
1189
1193
|
isSuperAdmin: isSuperAdmin,
|
|
1190
1194
|
assistantList: (currentNodeDetail === null || currentNodeDetail === void 0 ? void 0 : (_currentNodeDetail$no17 = currentNodeDetail.nodeInfo) === null || _currentNodeDetail$no17 === void 0 ? void 0 : _currentNodeDetail$no17.id) && assistantMap[currentNodeDetail === null || currentNodeDetail === void 0 ? void 0 : (_currentNodeDetail$no18 = currentNodeDetail.nodeInfo) === null || _currentNodeDetail$no18 === void 0 ? void 0 : _currentNodeDetail$no18.id] || [],
|
|
@@ -1192,7 +1196,7 @@ var FlowTemplateDetail = function FlowTemplateDetail(props) {
|
|
|
1192
1196
|
currentUserKey: plat.userKey,
|
|
1193
1197
|
staffIds: (currentNodeDetail === null || currentNodeDetail === void 0 ? void 0 : (_currentNodeDetail$no21 = currentNodeDetail.nodeInfo) === null || _currentNodeDetail$no21 === void 0 ? void 0 : (_currentNodeDetail$no22 = _currentNodeDetail$no21.assistants) === null || _currentNodeDetail$no22 === void 0 ? void 0 : _currentNodeDetail$no22.staffIds) || [],
|
|
1194
1198
|
operateDataPermission: currentNodeDetail === null || currentNodeDetail === void 0 ? void 0 : (_currentNodeDetail$no23 = currentNodeDetail.nodeInfo) === null || _currentNodeDetail$no23 === void 0 ? void 0 : (_currentNodeDetail$no24 = _currentNodeDetail$no23.assistants) === null || _currentNodeDetail$no24 === void 0 ? void 0 : _currentNodeDetail$no24.operateDataPermission,
|
|
1195
|
-
handlerList: (currentNodeDetail === null || currentNodeDetail === void 0 ? void 0 : (_currentNodeDetail$
|
|
1199
|
+
handlerList: (currentNodeDetail === null || currentNodeDetail === void 0 ? void 0 : (_currentNodeDetail$wo26 = currentNodeDetail.workOrder) === null || _currentNodeDetail$wo26 === void 0 ? void 0 : _currentNodeDetail$wo26.handlerList) || [],
|
|
1196
1200
|
isAllStaff: currentNodeDetail === null || currentNodeDetail === void 0 ? void 0 : (_currentNodeDetail$no25 = currentNodeDetail.nodeInfo) === null || _currentNodeDetail$no25 === void 0 ? void 0 : (_currentNodeDetail$no26 = _currentNodeDetail$no25.assistants) === null || _currentNodeDetail$no26 === void 0 ? void 0 : _currentNodeDetail$no26.isAllStaff
|
|
1197
1201
|
});
|
|
1198
1202
|
}, [currentNodeDetail, plat, assistantMap, useGroupMap]);
|
|
@@ -1201,9 +1205,9 @@ var FlowTemplateDetail = function FlowTemplateDetail(props) {
|
|
|
1201
1205
|
return item.accessToken === (currentNodeDetail === null || currentNodeDetail === void 0 ? void 0 : (_currentNodeDetail$no27 = currentNodeDetail.nodeInfo) === null || _currentNodeDetail$no27 === void 0 ? void 0 : (_currentNodeDetail$no28 = _currentNodeDetail$no27.relationEvent) === null || _currentNodeDetail$no28 === void 0 ? void 0 : _currentNodeDetail$no28.defaultShopUniqueKey);
|
|
1202
1206
|
})) === null || _shopList$find === void 0 ? void 0 : _shopList$find.shopId;
|
|
1203
1207
|
var ReportOrderRender = function ReportOrderRender(props) {
|
|
1204
|
-
var _currentNodeDetail$
|
|
1208
|
+
var _currentNodeDetail$wo27, _currentNodeDetail$wo28;
|
|
1205
1209
|
var details = props.details;
|
|
1206
|
-
var componentDtoList = currentNodeDetail === null || currentNodeDetail === void 0 ? void 0 : (_currentNodeDetail$
|
|
1210
|
+
var componentDtoList = currentNodeDetail === null || currentNodeDetail === void 0 ? void 0 : (_currentNodeDetail$wo27 = currentNodeDetail.workOrderTemplateInfo) === null || _currentNodeDetail$wo27 === void 0 ? void 0 : _currentNodeDetail$wo27.componentDtoList.filter(function (t) {
|
|
1207
1211
|
return !CANNOT_BACK_FILL.includes(t.workOrderComponentType || '');
|
|
1208
1212
|
});
|
|
1209
1213
|
//获取可以返填的组件值
|
|
@@ -1211,7 +1215,7 @@ var FlowTemplateDetail = function FlowTemplateDetail(props) {
|
|
|
1211
1215
|
_calcWorkOrderList2 = _slicedToArray(_calcWorkOrderList, 1),
|
|
1212
1216
|
transData = _calcWorkOrderList2[0];
|
|
1213
1217
|
//获取表单显示值
|
|
1214
|
-
var _calcWorkOrderList3 = calcWorkOrderList([details], currentNodeDetail === null || currentNodeDetail === void 0 ? void 0 : (_currentNodeDetail$
|
|
1218
|
+
var _calcWorkOrderList3 = calcWorkOrderList([details], currentNodeDetail === null || currentNodeDetail === void 0 ? void 0 : (_currentNodeDetail$wo28 = currentNodeDetail.workOrderTemplateInfo) === null || _currentNodeDetail$wo28 === void 0 ? void 0 : _currentNodeDetail$wo28.componentDtoList),
|
|
1215
1219
|
_calcWorkOrderList4 = _slicedToArray(_calcWorkOrderList3, 1),
|
|
1216
1220
|
transDataall = _calcWorkOrderList4[0];
|
|
1217
1221
|
return /*#__PURE__*/React.createElement("div", {
|
|
@@ -1389,17 +1393,22 @@ var FlowTemplateDetail = function FlowTemplateDetail(props) {
|
|
|
1389
1393
|
}), shopItem === null || shopItem === void 0 ? void 0 : shopItem.shopName, "-"), /*#__PURE__*/React.createElement("span", null, flowWorkOrderId), !['created', 'edit'].includes(privilege) && /*#__PURE__*/React.createElement(Button, {
|
|
1390
1394
|
type: "link",
|
|
1391
1395
|
onClick: handleFollow
|
|
1392
|
-
}, !follow ? '关注' : '已关注'),
|
|
1396
|
+
}, !follow ? '关注' : '已关注'), plat.platform === PlatForm.PC && shopItem && !shopItem.notJoin && /*#__PURE__*/React.createElement(JumpCustomerIcon, {
|
|
1397
|
+
tid: tid,
|
|
1398
|
+
shopName: shopItem.shopSource == 0 ? shopItem.thirdUserNick : shopItem.shopName,
|
|
1399
|
+
platformType: shopItem.shopSource,
|
|
1400
|
+
onJumpPage: onJumpPage
|
|
1401
|
+
}), showImplementationEnter && /*#__PURE__*/React.createElement(Button, {
|
|
1393
1402
|
onClick: openFeedbackModal,
|
|
1394
1403
|
type: "link"
|
|
1395
|
-
}, "\u5FEB\u901F\u521B\u5EFA\u5B9E\u65BD\u5DE5\u5355"), plat.platform === PlatForm.XIAOZHI && ['2'].includes(String(otherInfo === null || otherInfo === void 0 ? void 0 : otherInfo.xzClientPlatformType)) && ((otherInfo === null || otherInfo === void 0 ? void 0 : otherInfo.buyerOpenUid) || (currentNodeDetail === null || currentNodeDetail === void 0 ? void 0 : (_currentNodeDetail$
|
|
1404
|
+
}, "\u5FEB\u901F\u521B\u5EFA\u5B9E\u65BD\u5DE5\u5355"), plat.platform === PlatForm.XIAOZHI && ['2'].includes(String(otherInfo === null || otherInfo === void 0 ? void 0 : otherInfo.xzClientPlatformType)) && ((otherInfo === null || otherInfo === void 0 ? void 0 : otherInfo.buyerOpenUid) || (currentNodeDetail === null || currentNodeDetail === void 0 ? void 0 : (_currentNodeDetail$wo29 = currentNodeDetail.workOrder) === null || _currentNodeDetail$wo29 === void 0 ? void 0 : _currentNodeDetail$wo29.buyerOpenUid)) && /*#__PURE__*/React.createElement(JumpBuyer, {
|
|
1396
1405
|
order_number: tid,
|
|
1397
1406
|
shop: (otherInfo === null || otherInfo === void 0 ? void 0 : otherInfo.taobaoNick) || '',
|
|
1398
|
-
buyer: (otherInfo === null || otherInfo === void 0 ? void 0 : otherInfo.buyerOpenUid) || (currentNodeDetail === null || currentNodeDetail === void 0 ? void 0 : (_currentNodeDetail$
|
|
1407
|
+
buyer: (otherInfo === null || otherInfo === void 0 ? void 0 : otherInfo.buyerOpenUid) || (currentNodeDetail === null || currentNodeDetail === void 0 ? void 0 : (_currentNodeDetail$wo30 = currentNodeDetail.workOrder) === null || _currentNodeDetail$wo30 === void 0 ? void 0 : _currentNodeDetail$wo30.buyerOpenUid),
|
|
1399
1408
|
platformType: otherInfo === null || otherInfo === void 0 ? void 0 : otherInfo.xzClientPlatformType
|
|
1400
|
-
})), /*#__PURE__*/React.createElement("div", null, (_JSON$parse = JSON.parse((currentNodeDetail === null || currentNodeDetail === void 0 ? void 0 : (_currentNodeDetail$
|
|
1409
|
+
})), /*#__PURE__*/React.createElement("div", null, (_JSON$parse = JSON.parse((currentNodeDetail === null || currentNodeDetail === void 0 ? void 0 : (_currentNodeDetail$wo31 = currentNodeDetail.workOrder) === null || _currentNodeDetail$wo31 === void 0 ? void 0 : (_currentNodeDetail$wo32 = _currentNodeDetail$wo31.jsonMap) === null || _currentNodeDetail$wo32 === void 0 ? void 0 : _currentNodeDetail$wo32.flowTags) || '[]')) !== null && _JSON$parse !== void 0 && _JSON$parse.includes('AI_BUILD') ? /*#__PURE__*/React.createElement(Tag, {
|
|
1401
1410
|
color: "blue"
|
|
1402
|
-
}, "AI\u81EA\u52A8\u5EFA\u5355-".concat(WORK_ORDER_STATUS_AI_BUILD[currentNodeDetail === null || currentNodeDetail === void 0 ? void 0 : (_currentNodeDetail$
|
|
1411
|
+
}, "AI\u81EA\u52A8\u5EFA\u5355-".concat(WORK_ORDER_STATUS_AI_BUILD[currentNodeDetail === null || currentNodeDetail === void 0 ? void 0 : (_currentNodeDetail$wo33 = currentNodeDetail.workOrder) === null || _currentNodeDetail$wo33 === void 0 ? void 0 : (_currentNodeDetail$wo34 = _currentNodeDetail$wo33.jsonMap) === null || _currentNodeDetail$wo34 === void 0 ? void 0 : _currentNodeDetail$wo34.flowStatus])) : null)), flowStatus && /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Row, {
|
|
1403
1412
|
justify: 'space-between',
|
|
1404
1413
|
className: "header"
|
|
1405
1414
|
}, /*#__PURE__*/React.createElement(Col, null, /*#__PURE__*/React.createElement("div", {
|
|
@@ -1468,7 +1477,7 @@ var FlowTemplateDetail = function FlowTemplateDetail(props) {
|
|
|
1468
1477
|
isSuperAdmin: isSuperAdmin
|
|
1469
1478
|
}));
|
|
1470
1479
|
}), currentNodeDetail && /*#__PURE__*/React.createElement(Timeline.Item, {
|
|
1471
|
-
key: (currentNodeDetail === null || currentNodeDetail === void 0 ? void 0 : (_currentNodeDetail$
|
|
1480
|
+
key: (currentNodeDetail === null || currentNodeDetail === void 0 ? void 0 : (_currentNodeDetail$wo35 = currentNodeDetail.workOrder) === null || _currentNodeDetail$wo35 === void 0 ? void 0 : _currentNodeDetail$wo35.id) || 'current-node'
|
|
1472
1481
|
}, /*#__PURE__*/React.createElement(CurrentNode, {
|
|
1473
1482
|
ref: currentNodeRef,
|
|
1474
1483
|
flowTemplateId: flowTemplateId,
|
|
@@ -1483,7 +1492,8 @@ var FlowTemplateDetail = function FlowTemplateDetail(props) {
|
|
|
1483
1492
|
onReminder: handleReminder,
|
|
1484
1493
|
queryRemarkList: queryRemarkList,
|
|
1485
1494
|
autoSubmit: autoSubmit,
|
|
1486
|
-
isSuperAdmin: isSuperAdmin
|
|
1495
|
+
isSuperAdmin: isSuperAdmin,
|
|
1496
|
+
autoFillThirdPartyFields: autoFillThirdPartyFields
|
|
1487
1497
|
}))), (remarkList === null || remarkList === void 0 ? void 0 : remarkList.length) > 0 && !['created', 'edit'].includes(privilege) && /*#__PURE__*/React.createElement(RemarkShow, _extends({}, remarkList[0], {
|
|
1488
1498
|
readonly: readonly,
|
|
1489
1499
|
handleOpenRemarkList: handleOpenRemarkList,
|
|
@@ -192,6 +192,10 @@ export var SUBMIT_COMPONENT_STATUS_MAP = {
|
|
|
192
192
|
REPAIR_ORDER_STATUS: {
|
|
193
193
|
status: 'repairOrderStatusValue',
|
|
194
194
|
reason: 'repairOrderStatusReason'
|
|
195
|
+
},
|
|
196
|
+
ERP_REMARK: {
|
|
197
|
+
status: 'erpRemarkStatusValue',
|
|
198
|
+
reason: 'erpRemarkStatusReason'
|
|
195
199
|
}
|
|
196
200
|
};
|
|
197
201
|
export var SUBMIT_COMPONENT_GOOD_STATUS_MAP = {
|
|
@@ -478,6 +482,13 @@ export var SUBMIT_COMPONENT_SYSTEM_ORDER_MAP = {
|
|
|
478
482
|
ids: 'jkySystemSelectIds',
|
|
479
483
|
order: 'jkySystemShowOrder',
|
|
480
484
|
select: 'tradeNo'
|
|
485
|
+
},
|
|
486
|
+
PLATFORM_AFTER_SALES_ORDER: {
|
|
487
|
+
no: 'platformAfaterSalesOrderNo',
|
|
488
|
+
ids: 'platformAfaterSalesSelectIds',
|
|
489
|
+
order: 'platformAfaterSalesShowOrder',
|
|
490
|
+
select: 'platformAfaterSalesTradeNo',
|
|
491
|
+
shopId: 'platformAfaterSalesShopId'
|
|
481
492
|
}
|
|
482
493
|
};
|
|
483
494
|
export var platformMap = {
|
|
@@ -734,6 +734,9 @@ var handleSystemOrder = function handleSystemOrder(_ref51) {
|
|
|
734
734
|
select: (selectIds || []).includes(item === null || item === void 0 ? void 0 : item[SUBMIT_COMPONENT_SYSTEM_ORDER_MAP[type].select])
|
|
735
735
|
});
|
|
736
736
|
}));
|
|
737
|
+
if (SUBMIT_COMPONENT_SYSTEM_ORDER_MAP[type].shopId) {
|
|
738
|
+
addContent(SUBMIT_COMPONENT_SYSTEM_ORDER_MAP[type].shopId, getNowData("".concat(item.uniqueKey, ".shopId"), ''));
|
|
739
|
+
}
|
|
737
740
|
};
|
|
738
741
|
};
|
|
739
742
|
var handleBuyerMessageNotice = function handleBuyerMessageNotice(_ref52) {
|
|
@@ -918,6 +921,7 @@ var processComponent = function processComponent(_ref63) {
|
|
|
918
921
|
case 'ITEM_ENCODE':
|
|
919
922
|
wrapFn(handleOnlyAddContentArrayValue);
|
|
920
923
|
break;
|
|
924
|
+
case 'ERP_REMARK':
|
|
921
925
|
case 'REISSUE_STATUS':
|
|
922
926
|
case 'ADJUST_WORK_ORDER_STATUS':
|
|
923
927
|
case 'CREATE_STATUS':
|
|
@@ -1114,6 +1118,7 @@ var processComponent = function processComponent(_ref63) {
|
|
|
1114
1118
|
case 'JY_SYSTEM_ORDER':
|
|
1115
1119
|
case 'JKY_SYSTEM_ORDER':
|
|
1116
1120
|
case 'WDT_RETURN_BILL_NO':
|
|
1121
|
+
case 'PLATFORM_AFTER_SALES_ORDER':
|
|
1117
1122
|
wrapFn(handleSystemOrder);
|
|
1118
1123
|
break;
|
|
1119
1124
|
case 'BUYER_MESSAGE_NOTICE':
|
|
@@ -87,6 +87,7 @@ export declare const deleteCacheOrder: ({ templateList, values, nodeId, flowTemp
|
|
|
87
87
|
plat: any;
|
|
88
88
|
unDeleteOrderInfo: boolean;
|
|
89
89
|
}) => void;
|
|
90
|
+
export declare const afterSaleOrderBackValues: ({ templateList, value, form }: any) => void;
|
|
90
91
|
export declare const wdtReturnBillNoBackValues: ({ templateList, value, form }: any) => void;
|
|
91
92
|
export declare const bsSystemOrderBackValues: ({ templateList, value, form }: any) => void;
|
|
92
93
|
export declare const bsE3SystemOrderBackValues: ({ templateList, value, form }: any) => void;
|