@kmkf-fe-packages/services-components 1.19.8-beta.2 → 1.19.8-beta.21
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/commonComponents/GlobalContext/index.d.ts +1 -1
- package/dist/esm/commonComponents/GlobalContext/index.js +2 -1
- package/dist/esm/components/BS/BsLogistics/index.d.ts +1 -0
- package/dist/esm/components/BS/BsLogistics/index.js +23 -10
- package/dist/esm/components/BS/BsSystemOrder/index.js +29 -8
- package/dist/esm/components/BS/common/expressCode.js +3 -0
- package/dist/esm/components/BS/common/expressCompany.js +3 -0
- package/dist/esm/components/BsE3/BsReissueE3/index.js +1 -1
- package/dist/esm/components/BsE3/ReissueGift/index.d.ts +26 -0
- package/dist/esm/components/BsE3/ReissueGift/index.js +83 -0
- package/dist/esm/components/Common/index.js +38 -11
- package/dist/esm/components/CommonHeaderGood/index.js +17 -13
- package/dist/esm/components/JST/JstSendGood/index.js +41 -31
- package/dist/esm/components/KmErpSendGood/index.js +7 -7
- package/dist/esm/components/MsgStatus/index.js +6 -1
- package/dist/esm/components/Select/index.js +11 -8
- package/dist/esm/factory.d.ts +1 -1
- package/dist/esm/factory.js +2 -0
- package/dist/esm/service/api.d.ts +1 -0
- package/dist/esm/service/api.js +25 -5
- package/dist/esm/type.d.ts +4 -0
- package/package.json +4 -4
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from "react";
|
|
2
|
-
declare type RequestType = "queryAddressData" | "queryBsAddressData" | "queryExpressInterceptData" | "queryLogisticsAddressData" | "queryPlatData" | "queryWdtAddressData" | "queryAllLogisticsCompany" | "queryLabel" | "queryWdtLogisticsCompany" | "queryWdtSendData";
|
|
2
|
+
declare type RequestType = "queryAddressData" | "queryBsAddressData" | "queryExpressInterceptData" | "queryLogisticsAddressData" | "queryPlatData" | "queryWdtAddressData" | "queryAllLogisticsCompany" | "queryLabel" | "queryWdtLogisticsCompany" | "queryBsE3LogisticsCompany" | "queryWdtSendData";
|
|
3
3
|
declare const Global: ({ children, requestList, repeatRequestList, }: React.PropsWithChildren<{
|
|
4
4
|
requestList?: RequestType[] | undefined;
|
|
5
5
|
repeatRequestList?: Record<string, () => Promise<any>> | undefined;
|
|
@@ -15,7 +15,7 @@ function _iterableToArrayLimit(arr, i) { var _i = null == arr ? null : "undefine
|
|
|
15
15
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
16
16
|
import React, { useEffect, useState } from "react";
|
|
17
17
|
import { Skeleton, Button, Alert, Space } from "antd";
|
|
18
|
-
import { queryExpressInterceptData, queryLogisticsAddressData, queryPlatData, queryLabel, queryAllLogisticsCompany, queryWdtLogisticsCompany, queryWdtSendData } from "../../service/api";
|
|
18
|
+
import { queryExpressInterceptData, queryLogisticsAddressData, queryPlatData, queryLabel, queryAllLogisticsCompany, queryWdtLogisticsCompany, queryBsE3LogisticsCompany, queryWdtSendData } from "../../service/api";
|
|
19
19
|
import { servers } from "@kmkf-fe-packages/kmkf-utils";
|
|
20
20
|
var Global = function Global(_ref) {
|
|
21
21
|
var children = _ref.children,
|
|
@@ -43,6 +43,7 @@ var Global = function Global(_ref) {
|
|
|
43
43
|
queryLabel: queryLabel,
|
|
44
44
|
queryWdtAddressData: servers.queryWdtAddressData,
|
|
45
45
|
queryWdtLogisticsCompany: queryWdtLogisticsCompany,
|
|
46
|
+
queryBsE3LogisticsCompany: queryBsE3LogisticsCompany,
|
|
46
47
|
queryWdtSendData: queryWdtSendData
|
|
47
48
|
};
|
|
48
49
|
mergeMapping = _objectSpread(_objectSpread({}, mapping), repeatRequestList);
|
|
@@ -14,6 +14,7 @@ declare class BsLogistics implements ComponentInterface {
|
|
|
14
14
|
[key: string]: any;
|
|
15
15
|
}[];
|
|
16
16
|
type: string;
|
|
17
|
+
platformType: string;
|
|
17
18
|
rules: any[];
|
|
18
19
|
componentConfig: ComponentInterface["componentConfig"];
|
|
19
20
|
expressDateInstance: InstanceType<typeof ExpressData>;
|
|
@@ -23,19 +23,29 @@ var typeMap = {
|
|
|
23
23
|
key: "bsLogisticsList",
|
|
24
24
|
name: "bs",
|
|
25
25
|
company: "bsLogisticsCompany",
|
|
26
|
-
code: "bsLogisticsCode"
|
|
26
|
+
code: "bsLogisticsCode",
|
|
27
|
+
platformType: "default"
|
|
28
|
+
},
|
|
29
|
+
BS_E3_LOGISTICS: {
|
|
30
|
+
key: "bsE3LogisticsList",
|
|
31
|
+
name: "bsE3",
|
|
32
|
+
company: "bsE3LogisticsCompany",
|
|
33
|
+
code: "bsE3LogisticsCode",
|
|
34
|
+
platformType: "bsE3"
|
|
27
35
|
},
|
|
28
36
|
WLN_LOGISTICS: {
|
|
29
37
|
key: "wlnLogisticsList",
|
|
30
38
|
name: "万里牛",
|
|
31
39
|
company: "wlnLogisticsCompany",
|
|
32
|
-
code: "wlnLogisticsCode"
|
|
40
|
+
code: "wlnLogisticsCode",
|
|
41
|
+
platformType: "default"
|
|
33
42
|
},
|
|
34
43
|
WDT_LOGISTICS: {
|
|
35
44
|
key: "wdtLogisticsList",
|
|
36
45
|
name: "旺店通",
|
|
37
46
|
company: "wdtLogisticsCompany",
|
|
38
|
-
code: "wdtLogisticsCode"
|
|
47
|
+
code: "wdtLogisticsCode",
|
|
48
|
+
platformType: "wdt"
|
|
39
49
|
}
|
|
40
50
|
};
|
|
41
51
|
var BsLogistics = /*#__PURE__*/_createClass(function BsLogistics(_options) {
|
|
@@ -46,6 +56,7 @@ var BsLogistics = /*#__PURE__*/_createClass(function BsLogistics(_options) {
|
|
|
46
56
|
_typeMap$_options$typ4,
|
|
47
57
|
_typeMap$_options$typ5,
|
|
48
58
|
_typeMap$_options$typ6,
|
|
59
|
+
_typeMap$_options$typ7,
|
|
49
60
|
_this$componentConfig5,
|
|
50
61
|
_this$componentConfig7;
|
|
51
62
|
_classCallCheck(this, BsLogistics);
|
|
@@ -54,6 +65,7 @@ var BsLogistics = /*#__PURE__*/_createClass(function BsLogistics(_options) {
|
|
|
54
65
|
_defineProperty(this, "sortField", void 0);
|
|
55
66
|
_defineProperty(this, "sortChildField", void 0);
|
|
56
67
|
_defineProperty(this, "type", void 0);
|
|
68
|
+
_defineProperty(this, "platformType", void 0);
|
|
57
69
|
_defineProperty(this, "rules", void 0);
|
|
58
70
|
_defineProperty(this, "componentConfig", void 0);
|
|
59
71
|
_defineProperty(this, "expressDateInstance", void 0);
|
|
@@ -74,7 +86,7 @@ var BsLogistics = /*#__PURE__*/_createClass(function BsLogistics(_options) {
|
|
|
74
86
|
value: /*#__PURE__*/React.createElement(JstGoodImage, {
|
|
75
87
|
list: record === null || record === void 0 ? void 0 : record[_this.id],
|
|
76
88
|
type: 1,
|
|
77
|
-
platformType: _this.
|
|
89
|
+
platformType: _this.platformType
|
|
78
90
|
})
|
|
79
91
|
}) : null;
|
|
80
92
|
});
|
|
@@ -104,7 +116,7 @@ var BsLogistics = /*#__PURE__*/_createClass(function BsLogistics(_options) {
|
|
|
104
116
|
}, /*#__PURE__*/React.createElement(JstGoodImage, {
|
|
105
117
|
list: list,
|
|
106
118
|
type: 1,
|
|
107
|
-
platformType: _this.
|
|
119
|
+
platformType: _this.platformType
|
|
108
120
|
}));
|
|
109
121
|
});
|
|
110
122
|
_defineProperty(this, "renderLog", function (r) {
|
|
@@ -132,7 +144,7 @@ var BsLogistics = /*#__PURE__*/_createClass(function BsLogistics(_options) {
|
|
|
132
144
|
tooltip: (_this$componentConfig3 = _this.componentConfig) !== null && _this$componentConfig3 !== void 0 && _this$componentConfig3.showTooltip ? (_this$componentConfig4 = _this.componentConfig) === null || _this$componentConfig4 === void 0 ? void 0 : _this$componentConfig4.tooltip : '',
|
|
133
145
|
component: /*#__PURE__*/React.createElement(JstGoods, _extends({}, _this.componentConfig, {
|
|
134
146
|
type: 1,
|
|
135
|
-
platformType: _this.
|
|
147
|
+
platformType: _this.platformType,
|
|
136
148
|
options: _this.expressDateInstance.getExpressData(),
|
|
137
149
|
onChange: p === null || p === void 0 ? void 0 : p.onChange
|
|
138
150
|
}))
|
|
@@ -151,20 +163,21 @@ var BsLogistics = /*#__PURE__*/_createClass(function BsLogistics(_options) {
|
|
|
151
163
|
this.sortField = "".concat(_options.id, "_").concat((_typeMap$_options$typ = typeMap[_options.type]) === null || _typeMap$_options$typ === void 0 ? void 0 : _typeMap$_options$typ.key);
|
|
152
164
|
this.formField = "".concat(_options.id, "_").concat((_typeMap$_options$typ2 = typeMap[_options.type]) === null || _typeMap$_options$typ2 === void 0 ? void 0 : _typeMap$_options$typ2.key);
|
|
153
165
|
this.type = _options.type;
|
|
166
|
+
this.platformType = (_typeMap$_options$typ3 = typeMap[_options.type]) === null || _typeMap$_options$typ3 === void 0 ? void 0 : _typeMap$_options$typ3.platformType;
|
|
154
167
|
this.componentConfig = _options.componentConfig;
|
|
155
168
|
this.isCombinationComponent = true;
|
|
156
169
|
this.canSort = false;
|
|
157
170
|
this.expressCompany = new ExpressCompany(_objectSpread(_objectSpread({}, _options), {}, {
|
|
158
171
|
name: "物流公司",
|
|
159
172
|
parentName: this.name,
|
|
160
|
-
id: "".concat(_options.id, "_").concat((_typeMap$_options$
|
|
173
|
+
id: "".concat(_options.id, "_").concat((_typeMap$_options$typ4 = typeMap[_options.type]) === null || _typeMap$_options$typ4 === void 0 ? void 0 : _typeMap$_options$typ4.key, "_").concat((_typeMap$_options$typ5 = typeMap[_options.type]) === null || _typeMap$_options$typ5 === void 0 ? void 0 : _typeMap$_options$typ5.company),
|
|
161
174
|
width: 200,
|
|
162
|
-
platformType: this.
|
|
175
|
+
platformType: this.platformType
|
|
163
176
|
}));
|
|
164
177
|
this.expressCode = new ExpressCode(_objectSpread(_objectSpread({}, _options), {}, {
|
|
165
178
|
name: "物流单号",
|
|
166
179
|
parentName: this.name,
|
|
167
|
-
id: "".concat(_options.id, "_").concat((_typeMap$_options$
|
|
180
|
+
id: "".concat(_options.id, "_").concat((_typeMap$_options$typ6 = typeMap[_options.type]) === null || _typeMap$_options$typ6 === void 0 ? void 0 : _typeMap$_options$typ6.key, "_").concat((_typeMap$_options$typ7 = typeMap[_options.type]) === null || _typeMap$_options$typ7 === void 0 ? void 0 : _typeMap$_options$typ7.code),
|
|
168
181
|
width: 200
|
|
169
182
|
}));
|
|
170
183
|
this.children = [this.expressCompany, this.expressCode];
|
|
@@ -189,7 +202,7 @@ var BsLogistics = /*#__PURE__*/_createClass(function BsLogistics(_options) {
|
|
|
189
202
|
return Promise.resolve();
|
|
190
203
|
}
|
|
191
204
|
}] : [];
|
|
192
|
-
this.expressDateInstance = ExpressData.getInstance(this.
|
|
205
|
+
this.expressDateInstance = ExpressData.getInstance(this.platformType);
|
|
193
206
|
this.sortChildField = this.getSortChildFields(((_this$componentConfig7 = this.componentConfig) === null || _this$componentConfig7 === void 0 ? void 0 : _this$componentConfig7.showField) || "", _options);
|
|
194
207
|
});
|
|
195
208
|
export default BsLogistics;
|
|
@@ -11,7 +11,7 @@ function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input ==
|
|
|
11
11
|
import React from 'react';
|
|
12
12
|
import GetFormItem from "../../GetFormItem";
|
|
13
13
|
import ItemView from "../../../commonComponents/ItemView";
|
|
14
|
-
import { isNull } from '@kmkf-fe-packages/kmkf-utils';
|
|
14
|
+
import { isNull, BS_E3_BOOLEAN_STATUS_MAP, BS_E3_ORDER_STATUS_MAP } from '@kmkf-fe-packages/kmkf-utils';
|
|
15
15
|
import { BsSystemOrder as SystemOrder } from '@kmkf-fe-packages/basic-components';
|
|
16
16
|
import { BsSystemOrderTable } from "../../Common";
|
|
17
17
|
import { BsHeaderChild } from "../common/index";
|
|
@@ -84,37 +84,58 @@ var typeMap = {
|
|
|
84
84
|
title: "订单状态",
|
|
85
85
|
dataIndex: "orderStatus",
|
|
86
86
|
width: 100,
|
|
87
|
-
ellipsis: true
|
|
87
|
+
ellipsis: true,
|
|
88
|
+
render: function render(val) {
|
|
89
|
+
return /*#__PURE__*/React.createElement("span", null, BS_E3_ORDER_STATUS_MAP[val] || val);
|
|
90
|
+
}
|
|
88
91
|
}, {
|
|
89
92
|
title: "是否被拆分",
|
|
90
93
|
dataIndex: "isSplit",
|
|
91
94
|
width: 100,
|
|
92
|
-
ellipsis: true
|
|
95
|
+
ellipsis: true,
|
|
96
|
+
render: function render(val) {
|
|
97
|
+
return /*#__PURE__*/React.createElement("span", null, BS_E3_BOOLEAN_STATUS_MAP[val] || val);
|
|
98
|
+
}
|
|
93
99
|
}, {
|
|
94
100
|
title: "是否拆分子单",
|
|
95
101
|
dataIndex: "isSplitNew",
|
|
96
102
|
width: 100,
|
|
97
|
-
ellipsis: true
|
|
103
|
+
ellipsis: true,
|
|
104
|
+
render: function render(val) {
|
|
105
|
+
return /*#__PURE__*/React.createElement("span", null, BS_E3_BOOLEAN_STATUS_MAP[val] || val);
|
|
106
|
+
}
|
|
98
107
|
}, {
|
|
99
108
|
title: "是否被合并",
|
|
100
109
|
dataIndex: "isCombine",
|
|
101
110
|
width: 100,
|
|
102
|
-
ellipsis: true
|
|
111
|
+
ellipsis: true,
|
|
112
|
+
render: function render(val) {
|
|
113
|
+
return /*#__PURE__*/React.createElement("span", null, BS_E3_BOOLEAN_STATUS_MAP[val] || val);
|
|
114
|
+
}
|
|
103
115
|
}, {
|
|
104
116
|
title: "是否合并新单",
|
|
105
117
|
dataIndex: "isCombineNew",
|
|
106
118
|
width: 100,
|
|
107
|
-
ellipsis: true
|
|
119
|
+
ellipsis: true,
|
|
120
|
+
render: function render(val) {
|
|
121
|
+
return /*#__PURE__*/React.createElement("span", null, BS_E3_BOOLEAN_STATUS_MAP[val] || val);
|
|
122
|
+
}
|
|
108
123
|
}, {
|
|
109
124
|
title: "是否复制单",
|
|
110
125
|
dataIndex: "isCopy",
|
|
111
126
|
width: 100,
|
|
112
|
-
ellipsis: true
|
|
127
|
+
ellipsis: true,
|
|
128
|
+
render: function render(val) {
|
|
129
|
+
return /*#__PURE__*/React.createElement("span", null, BS_E3_BOOLEAN_STATUS_MAP[val] || val);
|
|
130
|
+
}
|
|
113
131
|
}, {
|
|
114
132
|
title: "是否换货单",
|
|
115
133
|
dataIndex: "isExchangeOrder",
|
|
116
134
|
width: 100,
|
|
117
|
-
ellipsis: true
|
|
135
|
+
ellipsis: true,
|
|
136
|
+
render: function render(val) {
|
|
137
|
+
return /*#__PURE__*/React.createElement("span", null, BS_E3_BOOLEAN_STATUS_MAP[val] || val);
|
|
138
|
+
}
|
|
118
139
|
}, {
|
|
119
140
|
title: "订单备注",
|
|
120
141
|
dataIndex: "orderMsg",
|
|
@@ -163,7 +163,7 @@ var BsE3Reissue = /*#__PURE__*/_createClass(function BsE3Reissue(options) {
|
|
|
163
163
|
name: "百胜补发系统订单号"
|
|
164
164
|
}));
|
|
165
165
|
this.bsMemo = new BsMemo(_objectSpread(_objectSpread({}, options), {}, {
|
|
166
|
-
id: "".concat(options.id, "_").concat((_typeMap$options$type3 = typeMap[options.type]) === null || _typeMap$options$type3 === void 0 ? void 0 : _typeMap$options$type3.
|
|
166
|
+
id: "".concat(options.id, "_").concat((_typeMap$options$type3 = typeMap[options.type]) === null || _typeMap$options$type3 === void 0 ? void 0 : _typeMap$options$type3.remark),
|
|
167
167
|
name: "百胜补发备注"
|
|
168
168
|
}));
|
|
169
169
|
this.reissueGoods = this.type === "BS_REISSUE_GOODS" ? new BsHeaderGood(_objectSpread(_objectSpread({}, options), {}, {
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { ComponentInterface, PickOption, ALignType, Record } from '../../../type';
|
|
2
|
+
import React from 'react';
|
|
3
|
+
declare class ReissueGift implements ComponentInterface {
|
|
4
|
+
name: string;
|
|
5
|
+
id: string;
|
|
6
|
+
sortField: string;
|
|
7
|
+
type: string;
|
|
8
|
+
componentConfig: ComponentInterface['componentConfig'];
|
|
9
|
+
align: ALignType;
|
|
10
|
+
width: number;
|
|
11
|
+
isCombinationComponent: boolean;
|
|
12
|
+
formField: string;
|
|
13
|
+
canSort: boolean;
|
|
14
|
+
children: ComponentInterface[];
|
|
15
|
+
dataType: ComponentInterface['dataType'];
|
|
16
|
+
constructor(options: PickOption);
|
|
17
|
+
getParentId: () => string;
|
|
18
|
+
renderClient: (record: any) => React.JSX.Element | null;
|
|
19
|
+
renderPc: (value: unknown, record: Record) => "--" | "是" | "否";
|
|
20
|
+
renderLog: (r: Record) => "--" | "是" | "否" | null;
|
|
21
|
+
getComponentValue: (r: Record) => "--" | "是" | "否";
|
|
22
|
+
renderExport: (value: string, record: Record) => "--" | "是" | "否";
|
|
23
|
+
editRender: () => null;
|
|
24
|
+
filterConfig: () => never[];
|
|
25
|
+
}
|
|
26
|
+
export default ReissueGift;
|
|
@@ -0,0 +1,83 @@
|
|
|
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 _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
3
|
+
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
4
|
+
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
|
|
5
|
+
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
|
|
6
|
+
function _iterableToArrayLimit(arr, i) { var _i = null == arr ? null : "undefined" != typeof Symbol && arr[Symbol.iterator] || arr["@@iterator"]; if (null != _i) { var _s, _e, _x, _r, _arr = [], _n = !0, _d = !1; try { if (_x = (_i = _i.call(arr)).next, 0 === i) { if (Object(_i) !== _i) return; _n = !1; } else for (; !(_n = (_s = _x.call(_i)).done) && (_arr.push(_s.value), _arr.length !== i); _n = !0); } catch (err) { _d = !0, _e = err; } finally { try { if (!_n && null != _i.return && (_r = _i.return(), Object(_r) !== _r)) return; } finally { if (_d) throw _e; } } return _arr; } }
|
|
7
|
+
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
8
|
+
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor); } }
|
|
9
|
+
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
10
|
+
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
11
|
+
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; }
|
|
12
|
+
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
|
|
13
|
+
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); }
|
|
14
|
+
import React from 'react';
|
|
15
|
+
import ItemView from "../../../commonComponents/ItemView";
|
|
16
|
+
import { isNull } from '@kmkf-fe-packages/kmkf-utils';
|
|
17
|
+
var ReissueGift = /*#__PURE__*/_createClass(function ReissueGift(options) {
|
|
18
|
+
var _this = this;
|
|
19
|
+
_classCallCheck(this, ReissueGift);
|
|
20
|
+
_defineProperty(this, "name", void 0);
|
|
21
|
+
_defineProperty(this, "id", void 0);
|
|
22
|
+
_defineProperty(this, "sortField", void 0);
|
|
23
|
+
_defineProperty(this, "type", void 0);
|
|
24
|
+
_defineProperty(this, "componentConfig", void 0);
|
|
25
|
+
_defineProperty(this, "align", void 0);
|
|
26
|
+
_defineProperty(this, "width", void 0);
|
|
27
|
+
_defineProperty(this, "isCombinationComponent", void 0);
|
|
28
|
+
_defineProperty(this, "formField", void 0);
|
|
29
|
+
_defineProperty(this, "canSort", void 0);
|
|
30
|
+
_defineProperty(this, "children", void 0);
|
|
31
|
+
_defineProperty(this, "dataType", void 0);
|
|
32
|
+
_defineProperty(this, "getParentId", function () {
|
|
33
|
+
var _this$id$split = _this.id.split('_'),
|
|
34
|
+
_this$id$split2 = _slicedToArray(_this$id$split, 3),
|
|
35
|
+
key = _this$id$split2[0],
|
|
36
|
+
name = _this$id$split2[1],
|
|
37
|
+
code = _this$id$split2[2];
|
|
38
|
+
return "".concat(key, "_").concat(name);
|
|
39
|
+
});
|
|
40
|
+
_defineProperty(this, "renderClient", function (record) {
|
|
41
|
+
return !isNull(record === null || record === void 0 ? void 0 : record[_this.id]) ? /*#__PURE__*/React.createElement(ItemView, {
|
|
42
|
+
id: _this.id,
|
|
43
|
+
label: _this.name,
|
|
44
|
+
value: _this.getComponentValue(record)
|
|
45
|
+
}) : null;
|
|
46
|
+
});
|
|
47
|
+
_defineProperty(this, "renderPc", function (value, record) {
|
|
48
|
+
return _this.getComponentValue(record);
|
|
49
|
+
});
|
|
50
|
+
_defineProperty(this, "renderLog", function (r) {
|
|
51
|
+
var id = _this.getParentId();
|
|
52
|
+
if (isNull(r === null || r === void 0 ? void 0 : r[id])) return null;
|
|
53
|
+
return _this.renderPc(undefined, r);
|
|
54
|
+
});
|
|
55
|
+
_defineProperty(this, "getComponentValue", function (r) {
|
|
56
|
+
if (isNull(r === null || r === void 0 ? void 0 : r[_this.id])) {
|
|
57
|
+
return '--';
|
|
58
|
+
}
|
|
59
|
+
return +(r === null || r === void 0 ? void 0 : r[_this.id]) ? '是' : '否';
|
|
60
|
+
});
|
|
61
|
+
_defineProperty(this, "renderExport", function (value, record) {
|
|
62
|
+
return _this.getComponentValue(record);
|
|
63
|
+
});
|
|
64
|
+
_defineProperty(this, "editRender", function () {
|
|
65
|
+
return null;
|
|
66
|
+
});
|
|
67
|
+
_defineProperty(this, "filterConfig", function () {
|
|
68
|
+
return [];
|
|
69
|
+
});
|
|
70
|
+
this.name = options.name;
|
|
71
|
+
this.id = options.id;
|
|
72
|
+
this.sortField = options.id;
|
|
73
|
+
this.formField = options.id;
|
|
74
|
+
this.type = options.type;
|
|
75
|
+
this.componentConfig = options.componentConfig;
|
|
76
|
+
this.align = 'left';
|
|
77
|
+
this.width = (options === null || options === void 0 ? void 0 : options.width) || 100;
|
|
78
|
+
this.isCombinationComponent = false;
|
|
79
|
+
this.canSort = false;
|
|
80
|
+
this.dataType = 'string';
|
|
81
|
+
this.children = [];
|
|
82
|
+
});
|
|
83
|
+
export default ReissueGift;
|
|
@@ -14,7 +14,7 @@ function _iterableToArrayLimit(arr, i) { var _i = null == arr ? null : "undefine
|
|
|
14
14
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
15
15
|
import { Form, Button, Modal, Tooltip, Space, Image, Popover, Table, message, Typography } from "antd";
|
|
16
16
|
import React, { useState, useMemo } from "react";
|
|
17
|
-
import { ExpressData,
|
|
17
|
+
import { ExpressData, SendDataCenter, BS_E3_BOOLEAN_STATUS_MAP, BS_E3_ORDER_STATUS_MAP } from "@kmkf-fe-packages/kmkf-utils";
|
|
18
18
|
import { getAlipayBillReceipt } from "../../service/api";
|
|
19
19
|
import { CopyToClipboard } from 'react-copy-to-clipboard';
|
|
20
20
|
import styles from "./index.module.less";
|
|
@@ -258,6 +258,9 @@ export var JstGoodImage = function JstGoodImage(_ref6) {
|
|
|
258
258
|
type = _ref6.type,
|
|
259
259
|
_ref6$platformType = _ref6.platformType,
|
|
260
260
|
platformType = _ref6$platformType === void 0 ? 'default' : _ref6$platformType;
|
|
261
|
+
var getSendName = function getSendName(item, platformType) {
|
|
262
|
+
return SendDataCenter.getInstance(platformType).getSendNameByCode(item.sendName);
|
|
263
|
+
};
|
|
261
264
|
return list !== null && list !== void 0 && list.length ? (list || []).map(function (item, index) {
|
|
262
265
|
var logisticsCompany = item.logisticsCompany;
|
|
263
266
|
var company = ExpressData.getInstance(platformType).getExpressNameByCode(logisticsCompany);
|
|
@@ -276,7 +279,7 @@ export var JstGoodImage = function JstGoodImage(_ref6) {
|
|
|
276
279
|
text: item.logisticsCode
|
|
277
280
|
})) : company ? company : item.logisticsCode ? /*#__PURE__*/React.createElement(CopyText, {
|
|
278
281
|
text: item.logisticsCode
|
|
279
|
-
}) : null) : null, type === 2 ? /*#__PURE__*/React.createElement("span", null, item.supplyName && item.supplyId ? [item.supplyId, item.supplyName].join('/') : item.supplyId ? item.supplyId : item.supplyName) : null, type === 3 ? /*#__PURE__*/React.createElement("span", null, item.sendName && item.sendId ? [item.sendId,
|
|
282
|
+
}) : null) : null, type === 2 ? /*#__PURE__*/React.createElement("span", null, item.supplyName && item.supplyId ? [item.supplyId, item.supplyName].join('/') : item.supplyId ? item.supplyId : item.supplyName) : null, type === 3 ? /*#__PURE__*/React.createElement("span", null, item.sendName && item.sendId ? [item.sendId, getSendName(item, 'platformType')].join("/") : item.sendId ? item.sendId : getSendName(item, 'platformType')) : null, type === 4 ? /*#__PURE__*/React.createElement("span", null, (item === null || item === void 0 ? void 0 : item.deliveryNo) || '') : null));
|
|
280
283
|
}) : null;
|
|
281
284
|
};
|
|
282
285
|
export var BsExpressRender = function BsExpressRender(_ref7) {
|
|
@@ -889,7 +892,10 @@ export var BsGoodsTable = function BsGoodsTable(_ref11) {
|
|
|
889
892
|
title: "\u662F\u5426\u8D60\u54C1",
|
|
890
893
|
align: 'center',
|
|
891
894
|
ellipsis: true,
|
|
892
|
-
width: 100
|
|
895
|
+
width: 100,
|
|
896
|
+
render: function render(val) {
|
|
897
|
+
return /*#__PURE__*/React.createElement("span", null, BS_E3_BOOLEAN_STATUS_MAP[val] || val);
|
|
898
|
+
}
|
|
893
899
|
}];
|
|
894
900
|
}
|
|
895
901
|
break;
|
|
@@ -1160,41 +1166,62 @@ export var BsSystemOrderTable = function BsSystemOrderTable(_ref13) {
|
|
|
1160
1166
|
title: "订单状态",
|
|
1161
1167
|
dataIndex: "orderStatus",
|
|
1162
1168
|
width: 100,
|
|
1163
|
-
ellipsis: true
|
|
1169
|
+
ellipsis: true,
|
|
1170
|
+
render: function render(val) {
|
|
1171
|
+
return /*#__PURE__*/React.createElement("span", null, BS_E3_ORDER_STATUS_MAP[val] || val);
|
|
1172
|
+
}
|
|
1164
1173
|
}, {
|
|
1165
1174
|
title: "是否被拆分",
|
|
1166
1175
|
dataIndex: "isSplit",
|
|
1167
1176
|
width: 100,
|
|
1168
|
-
ellipsis: true
|
|
1177
|
+
ellipsis: true,
|
|
1178
|
+
render: function render(val) {
|
|
1179
|
+
return /*#__PURE__*/React.createElement("span", null, BS_E3_BOOLEAN_STATUS_MAP[val] || val);
|
|
1180
|
+
}
|
|
1169
1181
|
}, {
|
|
1170
1182
|
title: "是否拆分子单",
|
|
1171
1183
|
dataIndex: "isSplitNew",
|
|
1172
1184
|
width: 100,
|
|
1173
|
-
ellipsis: true
|
|
1185
|
+
ellipsis: true,
|
|
1186
|
+
render: function render(val) {
|
|
1187
|
+
return /*#__PURE__*/React.createElement("span", null, BS_E3_BOOLEAN_STATUS_MAP[val] || val);
|
|
1188
|
+
}
|
|
1174
1189
|
}, {
|
|
1175
1190
|
title: "是否被合并",
|
|
1176
1191
|
dataIndex: "isCombine",
|
|
1177
1192
|
width: 100,
|
|
1178
|
-
ellipsis: true
|
|
1193
|
+
ellipsis: true,
|
|
1194
|
+
render: function render(val) {
|
|
1195
|
+
return /*#__PURE__*/React.createElement("span", null, BS_E3_BOOLEAN_STATUS_MAP[val] || val);
|
|
1196
|
+
}
|
|
1179
1197
|
}, {
|
|
1180
1198
|
title: "是否合并新单",
|
|
1181
1199
|
dataIndex: "isCombineNew",
|
|
1182
1200
|
width: 100,
|
|
1183
|
-
ellipsis: true
|
|
1201
|
+
ellipsis: true,
|
|
1202
|
+
render: function render(val) {
|
|
1203
|
+
return /*#__PURE__*/React.createElement("span", null, BS_E3_BOOLEAN_STATUS_MAP[val] || val);
|
|
1204
|
+
}
|
|
1184
1205
|
}, {
|
|
1185
1206
|
title: "是否复制单",
|
|
1186
1207
|
dataIndex: "isCopy",
|
|
1187
1208
|
width: 100,
|
|
1188
|
-
ellipsis: true
|
|
1209
|
+
ellipsis: true,
|
|
1210
|
+
render: function render(val) {
|
|
1211
|
+
return /*#__PURE__*/React.createElement("span", null, BS_E3_BOOLEAN_STATUS_MAP[val] || val);
|
|
1212
|
+
}
|
|
1189
1213
|
}, {
|
|
1190
1214
|
title: "是否换货单",
|
|
1191
1215
|
dataIndex: "isExchangeOrder",
|
|
1192
1216
|
width: 100,
|
|
1193
|
-
ellipsis: true
|
|
1217
|
+
ellipsis: true,
|
|
1218
|
+
render: function render(val) {
|
|
1219
|
+
return /*#__PURE__*/React.createElement("span", null, BS_E3_BOOLEAN_STATUS_MAP[val] || val);
|
|
1220
|
+
}
|
|
1194
1221
|
}, {
|
|
1195
1222
|
title: "订单备注",
|
|
1196
1223
|
dataIndex: "orderMsg",
|
|
1197
|
-
width:
|
|
1224
|
+
width: 100,
|
|
1198
1225
|
ellipsis: true
|
|
1199
1226
|
}]
|
|
1200
1227
|
};
|
|
@@ -19,8 +19,9 @@ function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _ty
|
|
|
19
19
|
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); }
|
|
20
20
|
import React from "react";
|
|
21
21
|
import ItemView from "../../commonComponents/ItemView";
|
|
22
|
-
import { isNull } from "@kmkf-fe-packages/kmkf-utils";
|
|
22
|
+
import { isNull, BS_E3_BOOLEAN_STATUS_MAP } from "@kmkf-fe-packages/kmkf-utils";
|
|
23
23
|
import { BsHeaderPic, BsHeaderChild } from "../BS/common";
|
|
24
|
+
import ReissueGift from "../BsE3/ReissueGift";
|
|
24
25
|
var GoodHeaderMap = {
|
|
25
26
|
"WDT_GOODS": {
|
|
26
27
|
headerMap: {
|
|
@@ -419,7 +420,10 @@ var GoodHeaderMap = {
|
|
|
419
420
|
component: BsHeaderChild,
|
|
420
421
|
name: "是否赠品",
|
|
421
422
|
key: "isGift",
|
|
422
|
-
width: 80
|
|
423
|
+
width: 80,
|
|
424
|
+
render: function render(val) {
|
|
425
|
+
return /*#__PURE__*/React.createElement("span", null, BS_E3_BOOLEAN_STATUS_MAP[val] || val);
|
|
426
|
+
}
|
|
423
427
|
}
|
|
424
428
|
},
|
|
425
429
|
itemKey: {
|
|
@@ -466,13 +470,13 @@ var GoodHeaderMap = {
|
|
|
466
470
|
component: BsHeaderChild,
|
|
467
471
|
name: "商品名称",
|
|
468
472
|
key: "goodsName",
|
|
469
|
-
width:
|
|
473
|
+
width: 200
|
|
470
474
|
},
|
|
471
475
|
goodsShortName: {
|
|
472
476
|
component: BsHeaderChild,
|
|
473
477
|
name: "商品简称",
|
|
474
478
|
key: "goodsShortName",
|
|
475
|
-
width:
|
|
479
|
+
width: 150
|
|
476
480
|
},
|
|
477
481
|
picPath: {
|
|
478
482
|
component: BsHeaderChild,
|
|
@@ -496,13 +500,13 @@ var GoodHeaderMap = {
|
|
|
496
500
|
component: BsHeaderChild,
|
|
497
501
|
name: "颜色名称",
|
|
498
502
|
key: "colorName",
|
|
499
|
-
width:
|
|
503
|
+
width: 150
|
|
500
504
|
},
|
|
501
505
|
colorCode: {
|
|
502
506
|
component: BsHeaderChild,
|
|
503
507
|
name: "颜色代码",
|
|
504
508
|
key: "colorCode",
|
|
505
|
-
width:
|
|
509
|
+
width: 150
|
|
506
510
|
},
|
|
507
511
|
sizeName: {
|
|
508
512
|
component: BsHeaderChild,
|
|
@@ -514,37 +518,37 @@ var GoodHeaderMap = {
|
|
|
514
518
|
component: BsHeaderChild,
|
|
515
519
|
name: "尺码代码",
|
|
516
520
|
key: "sizeCode",
|
|
517
|
-
width:
|
|
521
|
+
width: 150
|
|
518
522
|
},
|
|
519
523
|
brandName: {
|
|
520
524
|
component: BsHeaderChild,
|
|
521
525
|
name: "品牌名称",
|
|
522
526
|
key: "brandName",
|
|
523
|
-
width:
|
|
527
|
+
width: 150
|
|
524
528
|
},
|
|
525
529
|
goodsNumber: {
|
|
526
530
|
component: BsHeaderChild,
|
|
527
531
|
name: "商品数量",
|
|
528
532
|
key: "goodsNumber",
|
|
529
|
-
width:
|
|
533
|
+
width: 150
|
|
530
534
|
},
|
|
531
535
|
goodsPrice: {
|
|
532
536
|
component: BsHeaderChild,
|
|
533
537
|
name: "商品单价",
|
|
534
538
|
key: "goodsPrice",
|
|
535
|
-
width:
|
|
539
|
+
width: 150
|
|
536
540
|
},
|
|
537
541
|
shopPrice: {
|
|
538
542
|
component: BsHeaderChild,
|
|
539
543
|
name: "商品网店售价",
|
|
540
544
|
key: "shopPrice",
|
|
541
|
-
width:
|
|
545
|
+
width: 150
|
|
542
546
|
},
|
|
543
547
|
isGift: {
|
|
544
|
-
component:
|
|
548
|
+
component: ReissueGift,
|
|
545
549
|
name: "是否赠品",
|
|
546
550
|
key: "isGift",
|
|
547
|
-
width:
|
|
551
|
+
width: 150
|
|
548
552
|
}
|
|
549
553
|
},
|
|
550
554
|
itemKey: {
|
|
@@ -12,32 +12,43 @@ import GetFormItem from "../../GetFormItem";
|
|
|
12
12
|
import { JstGoodImage } from "../../Common";
|
|
13
13
|
import { JstGoods } from "@kmkf-fe-packages/basic-components";
|
|
14
14
|
import ItemView from "../../../commonComponents/ItemView";
|
|
15
|
-
import { isNull, filterFn as _filterFn,
|
|
15
|
+
import { isNull, filterFn as _filterFn, SendDataCenter } from "@kmkf-fe-packages/kmkf-utils";
|
|
16
16
|
import { SYMBOL } from "../../../constant";
|
|
17
17
|
var typeMap = {
|
|
18
18
|
JST_SEND_GOOD: {
|
|
19
19
|
key: "jstItemList",
|
|
20
20
|
name: "jst",
|
|
21
21
|
sendId: "sendId",
|
|
22
|
-
sendName: "sendName"
|
|
22
|
+
sendName: "sendName",
|
|
23
|
+
platformType: 'default'
|
|
23
24
|
},
|
|
24
25
|
BS_SEND_GOOD: {
|
|
25
26
|
key: "bsSendGood",
|
|
26
27
|
name: "bs",
|
|
27
28
|
sendId: "bsSendId",
|
|
28
|
-
sendName: "bsSendName"
|
|
29
|
+
sendName: "bsSendName",
|
|
30
|
+
platformType: 'default'
|
|
31
|
+
},
|
|
32
|
+
BS_E3_SEND_GOOD: {
|
|
33
|
+
key: "bsE3SendGood",
|
|
34
|
+
name: "bsE3",
|
|
35
|
+
sendId: "bsE3SendId",
|
|
36
|
+
sendName: "bsE3SendName",
|
|
37
|
+
platformType: 'bsE3'
|
|
29
38
|
},
|
|
30
39
|
WLN_SEND_GOOD: {
|
|
31
40
|
key: "wlnSendGood",
|
|
32
41
|
name: "wln",
|
|
33
42
|
sendId: "wlnSendId",
|
|
34
|
-
sendName: "wlnSendName"
|
|
43
|
+
sendName: "wlnSendName",
|
|
44
|
+
platformType: 'default'
|
|
35
45
|
},
|
|
36
46
|
WDT_SEND_GOOD: {
|
|
37
47
|
key: "wdtSendGood",
|
|
38
48
|
name: "wdt",
|
|
39
49
|
sendId: "wdtSendId",
|
|
40
|
-
sendName: "wdtSendName"
|
|
50
|
+
sendName: "wdtSendName",
|
|
51
|
+
platformType: 'wdt'
|
|
41
52
|
}
|
|
42
53
|
};
|
|
43
54
|
var JstSendGood = /*#__PURE__*/_createClass(function JstSendGood(_options) {
|
|
@@ -75,12 +86,11 @@ var JstSendGood = /*#__PURE__*/_createClass(function JstSendGood(_options) {
|
|
|
75
86
|
dataType: "arrayObject",
|
|
76
87
|
disabled: type === 'sendName'
|
|
77
88
|
};
|
|
78
|
-
|
|
79
|
-
sendName.options = WdtSendData.getInstance().getWdtSendData() || [];
|
|
80
|
-
}
|
|
89
|
+
sendName.options = fieldType && SendDataCenter.getInstance(fieldType).getSendData();
|
|
81
90
|
return [sendName, sendId];
|
|
82
91
|
});
|
|
83
92
|
_defineProperty(this, "renderClient", function (record) {
|
|
93
|
+
var _typeMap$_this$type;
|
|
84
94
|
var isShow = Array.isArray(record === null || record === void 0 ? void 0 : record[_this.id]) ? some(record === null || record === void 0 ? void 0 : record[_this.id], function (item) {
|
|
85
95
|
return !isNull(item);
|
|
86
96
|
}) : false;
|
|
@@ -90,13 +100,13 @@ var JstSendGood = /*#__PURE__*/_createClass(function JstSendGood(_options) {
|
|
|
90
100
|
value: /*#__PURE__*/React.createElement(JstGoodImage, {
|
|
91
101
|
list: record === null || record === void 0 ? void 0 : record[_this.id],
|
|
92
102
|
type: 3,
|
|
93
|
-
platformType: _this.type ===
|
|
103
|
+
platformType: (_typeMap$_this$type = typeMap[_this.type]) === null || _typeMap$_this$type === void 0 ? void 0 : _typeMap$_this$type.platformType
|
|
94
104
|
})
|
|
95
105
|
}) : null;
|
|
96
106
|
});
|
|
97
107
|
_defineProperty(this, "renderPc", function (value, record) {
|
|
98
|
-
var _typeMap$_this$
|
|
99
|
-
var list = record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_").concat((_typeMap$_this$
|
|
108
|
+
var _typeMap$_this$type2, _typeMap$_this$type3;
|
|
109
|
+
var list = record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_").concat((_typeMap$_this$type2 = typeMap[_this.type]) === null || _typeMap$_this$type2 === void 0 ? void 0 : _typeMap$_this$type2.key)];
|
|
100
110
|
//兼容多个商品
|
|
101
111
|
return /*#__PURE__*/React.createElement("span", {
|
|
102
112
|
onClick: function onClick(e) {
|
|
@@ -105,28 +115,28 @@ var JstSendGood = /*#__PURE__*/_createClass(function JstSendGood(_options) {
|
|
|
105
115
|
}, /*#__PURE__*/React.createElement(JstGoodImage, {
|
|
106
116
|
list: list,
|
|
107
117
|
type: 3,
|
|
108
|
-
platformType: _this.type ===
|
|
118
|
+
platformType: (_typeMap$_this$type3 = typeMap[_this.type]) === null || _typeMap$_this$type3 === void 0 ? void 0 : _typeMap$_this$type3.platformType
|
|
109
119
|
}));
|
|
110
120
|
});
|
|
111
121
|
_defineProperty(this, "renderLog", function (r) {
|
|
112
|
-
var _typeMap$_this$
|
|
113
|
-
var list = r === null || r === void 0 ? void 0 : r["".concat(_this.id, "_").concat((_typeMap$_this$
|
|
122
|
+
var _typeMap$_this$type4;
|
|
123
|
+
var list = r === null || r === void 0 ? void 0 : r["".concat(_this.id, "_").concat((_typeMap$_this$type4 = typeMap[_this.type]) === null || _typeMap$_this$type4 === void 0 ? void 0 : _typeMap$_this$type4.key)];
|
|
114
124
|
if (isNull(list)) return null;
|
|
115
125
|
return _this.renderPc(undefined, r);
|
|
116
126
|
});
|
|
117
127
|
_defineProperty(this, "getComponentValue", function (r) {
|
|
118
|
-
var _typeMap$_this$
|
|
119
|
-
return r === null || r === void 0 ? void 0 : r["".concat(_this.id, "_").concat((_typeMap$_this$
|
|
128
|
+
var _typeMap$_this$type5;
|
|
129
|
+
return r === null || r === void 0 ? void 0 : r["".concat(_this.id, "_").concat((_typeMap$_this$type5 = typeMap[_this.type]) === null || _typeMap$_this$type5 === void 0 ? void 0 : _typeMap$_this$type5.key)];
|
|
120
130
|
});
|
|
121
131
|
_defineProperty(this, "renderExport", function (value, record) {
|
|
122
|
-
var _typeMap$_this$
|
|
123
|
-
var list = record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_").concat((_typeMap$_this$
|
|
132
|
+
var _typeMap$_this$type6;
|
|
133
|
+
var list = record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_").concat((_typeMap$_this$type6 = typeMap[_this.type]) === null || _typeMap$_this$type6 === void 0 ? void 0 : _typeMap$_this$type6.key)];
|
|
124
134
|
return (list || []).map(function (item) {
|
|
125
|
-
return [item === null || item === void 0 ? void 0 : item.sendId, _this.type
|
|
135
|
+
return [item === null || item === void 0 ? void 0 : item.sendId, SendDataCenter.getInstance(_this.type).getSendNameByCode(item === null || item === void 0 ? void 0 : item.sendName)].join("/");
|
|
126
136
|
}).join(",");
|
|
127
137
|
});
|
|
128
138
|
_defineProperty(this, "editRender", function (p) {
|
|
129
|
-
var _this$componentConfig, _this$componentConfig2;
|
|
139
|
+
var _this$componentConfig, _this$componentConfig2, _typeMap$_this$type7;
|
|
130
140
|
return /*#__PURE__*/React.createElement(GetFormItem, {
|
|
131
141
|
title: _this.name,
|
|
132
142
|
name: _this.id,
|
|
@@ -137,20 +147,20 @@ var JstSendGood = /*#__PURE__*/_createClass(function JstSendGood(_options) {
|
|
|
137
147
|
tooltip: (_this$componentConfig = _this.componentConfig) !== null && _this$componentConfig !== void 0 && _this$componentConfig.showTooltip ? (_this$componentConfig2 = _this.componentConfig) === null || _this$componentConfig2 === void 0 ? void 0 : _this$componentConfig2.tooltip : '',
|
|
138
148
|
component: /*#__PURE__*/React.createElement(JstGoods, _extends({}, _this.componentConfig, {
|
|
139
149
|
type: 3,
|
|
140
|
-
platformType: _this.type ===
|
|
150
|
+
platformType: (_typeMap$_this$type7 = typeMap[_this.type]) === null || _typeMap$_this$type7 === void 0 ? void 0 : _typeMap$_this$type7.platformType
|
|
141
151
|
}))
|
|
142
152
|
});
|
|
143
153
|
});
|
|
144
154
|
_defineProperty(this, "filterConfig", function (item) {
|
|
145
|
-
var _typeMap$_this$
|
|
146
|
-
return [_this.type === 'WDT_SEND_GOOD' ? {
|
|
155
|
+
var _typeMap$_this$type8, _typeMap$_this$type9, _typeMap$_this$type11;
|
|
156
|
+
return [_this.type === 'WDT_SEND_GOOD' || _this.type === 'BS_E3_SEND_GOOD' ? {
|
|
147
157
|
searchDefaultConditions: SYMBOL.in,
|
|
148
158
|
type: item.type,
|
|
149
|
-
id: "".concat(item.id, "_").concat((_typeMap$_this$
|
|
159
|
+
id: "".concat(item.id, "_").concat((_typeMap$_this$type8 = typeMap[_this.type]) === null || _typeMap$_this$type8 === void 0 ? void 0 : _typeMap$_this$type8.sendName),
|
|
150
160
|
name: "".concat(_this.name, "\u540D\u79F0"),
|
|
151
161
|
filterComponentType: "MultipleSelect",
|
|
152
162
|
props: {
|
|
153
|
-
options:
|
|
163
|
+
options: SendDataCenter.getInstance(item.type).getSendData()
|
|
154
164
|
},
|
|
155
165
|
filterFn: function filterFn(value) {
|
|
156
166
|
return function (i) {
|
|
@@ -165,13 +175,13 @@ var JstSendGood = /*#__PURE__*/_createClass(function JstSendGood(_options) {
|
|
|
165
175
|
} : {
|
|
166
176
|
searchDefaultConditions: SYMBOL.like,
|
|
167
177
|
type: item.type,
|
|
168
|
-
id: "".concat(item.id, "_").concat((_typeMap$_this$
|
|
178
|
+
id: "".concat(item.id, "_").concat((_typeMap$_this$type9 = typeMap[_this.type]) === null || _typeMap$_this$type9 === void 0 ? void 0 : _typeMap$_this$type9.sendName),
|
|
169
179
|
name: "".concat(_this.name, "\u540D\u79F0"),
|
|
170
180
|
filterComponentType: "Input",
|
|
171
181
|
filterFn: function filterFn(value) {
|
|
172
182
|
return function (i) {
|
|
173
|
-
var _ref2, _typeMap$_this$
|
|
174
|
-
return (_ref2 = _filterFn.filterTableListItemColumnValue(i, item.id, (_typeMap$_this$
|
|
183
|
+
var _ref2, _typeMap$_this$type10;
|
|
184
|
+
return (_ref2 = _filterFn.filterTableListItemColumnValue(i, item.id, (_typeMap$_this$type10 = typeMap[_this.type]) === null || _typeMap$_this$type10 === void 0 ? void 0 : _typeMap$_this$type10.key) || []) === null || _ref2 === void 0 ? void 0 : _ref2.some(function (item) {
|
|
175
185
|
var _String2;
|
|
176
186
|
var name = item !== null && item !== void 0 && item.sendName ? (_String2 = String(item === null || item === void 0 ? void 0 : item.sendName)) === null || _String2 === void 0 ? void 0 : _String2.includes(value) : false;
|
|
177
187
|
return name;
|
|
@@ -181,13 +191,13 @@ var JstSendGood = /*#__PURE__*/_createClass(function JstSendGood(_options) {
|
|
|
181
191
|
}, {
|
|
182
192
|
searchDefaultConditions: SYMBOL.like,
|
|
183
193
|
type: item.type,
|
|
184
|
-
id: "".concat(item.id, "_").concat((_typeMap$_this$
|
|
194
|
+
id: "".concat(item.id, "_").concat((_typeMap$_this$type11 = typeMap[_this.type]) === null || _typeMap$_this$type11 === void 0 ? void 0 : _typeMap$_this$type11.sendId),
|
|
185
195
|
name: "".concat(_this.name, "\u7F16\u7801"),
|
|
186
196
|
filterComponentType: "Input",
|
|
187
197
|
filterFn: function filterFn(value) {
|
|
188
198
|
return function (i) {
|
|
189
|
-
var _ref3, _typeMap$_this$
|
|
190
|
-
return (_ref3 = _filterFn.filterTableListItemColumnValue(i, item.id, (_typeMap$_this$
|
|
199
|
+
var _ref3, _typeMap$_this$type12;
|
|
200
|
+
return (_ref3 = _filterFn.filterTableListItemColumnValue(i, item.id, (_typeMap$_this$type12 = typeMap[_this.type]) === null || _typeMap$_this$type12 === void 0 ? void 0 : _typeMap$_this$type12.key) || []) === null || _ref3 === void 0 ? void 0 : _ref3.some(function (item) {
|
|
191
201
|
var _String3;
|
|
192
202
|
var id = item !== null && item !== void 0 && item.sendId ? (_String3 = String(item === null || item === void 0 ? void 0 : item.sendId)) === null || _String3 === void 0 ? void 0 : _String3.includes(value) : false;
|
|
193
203
|
return id;
|
|
@@ -12,7 +12,7 @@ import GetFormItem from "../GetFormItem";
|
|
|
12
12
|
import { JstGoodImage } from "../Common";
|
|
13
13
|
import { JstGoods } from "@kmkf-fe-packages/basic-components";
|
|
14
14
|
import ItemView from "../../commonComponents/ItemView";
|
|
15
|
-
import { isNull, filterFn as _filterFn,
|
|
15
|
+
import { isNull, filterFn as _filterFn, SendDataCenter } from "@kmkf-fe-packages/kmkf-utils";
|
|
16
16
|
import { SYMBOL } from "../../constant";
|
|
17
17
|
var JstSendGood = /*#__PURE__*/_createClass(function JstSendGood(_options) {
|
|
18
18
|
var _this = this,
|
|
@@ -58,7 +58,7 @@ var JstSendGood = /*#__PURE__*/_createClass(function JstSendGood(_options) {
|
|
|
58
58
|
value: /*#__PURE__*/React.createElement(JstGoodImage, {
|
|
59
59
|
list: record === null || record === void 0 ? void 0 : record[_this.id],
|
|
60
60
|
type: 3,
|
|
61
|
-
platformType:
|
|
61
|
+
platformType: 'default'
|
|
62
62
|
})
|
|
63
63
|
}) : null;
|
|
64
64
|
});
|
|
@@ -72,7 +72,7 @@ var JstSendGood = /*#__PURE__*/_createClass(function JstSendGood(_options) {
|
|
|
72
72
|
}, /*#__PURE__*/React.createElement(JstGoodImage, {
|
|
73
73
|
list: list,
|
|
74
74
|
type: 3,
|
|
75
|
-
platformType:
|
|
75
|
+
platformType: 'default'
|
|
76
76
|
}));
|
|
77
77
|
});
|
|
78
78
|
_defineProperty(this, "renderLog", function (r) {
|
|
@@ -86,7 +86,7 @@ var JstSendGood = /*#__PURE__*/_createClass(function JstSendGood(_options) {
|
|
|
86
86
|
_defineProperty(this, "renderExport", function (value, record) {
|
|
87
87
|
var list = record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_").concat(_this.suffixKey)];
|
|
88
88
|
return (list || []).map(function (item) {
|
|
89
|
-
return [item === null || item === void 0 ? void 0 : item.sendId, _this.type
|
|
89
|
+
return [item === null || item === void 0 ? void 0 : item.sendId, SendDataCenter.getInstance(_this.type).getSendNameByCode(item === null || item === void 0 ? void 0 : item.sendName)].join("/");
|
|
90
90
|
}).join(",");
|
|
91
91
|
});
|
|
92
92
|
_defineProperty(this, "editRender", function (p) {
|
|
@@ -101,19 +101,19 @@ var JstSendGood = /*#__PURE__*/_createClass(function JstSendGood(_options) {
|
|
|
101
101
|
tooltip: (_this$componentConfig = _this.componentConfig) !== null && _this$componentConfig !== void 0 && _this$componentConfig.showTooltip ? (_this$componentConfig2 = _this.componentConfig) === null || _this$componentConfig2 === void 0 ? void 0 : _this$componentConfig2.tooltip : '',
|
|
102
102
|
component: /*#__PURE__*/React.createElement(JstGoods, _extends({}, _this.componentConfig, {
|
|
103
103
|
type: 3,
|
|
104
|
-
platformType:
|
|
104
|
+
platformType: 'default'
|
|
105
105
|
}))
|
|
106
106
|
});
|
|
107
107
|
});
|
|
108
108
|
_defineProperty(this, "filterConfig", function (item) {
|
|
109
|
-
return [_this.type === 'WDT_SEND_GOOD' ? {
|
|
109
|
+
return [_this.type === 'WDT_SEND_GOOD' || _this.type === 'BS_E3_SEND_GOOD' ? {
|
|
110
110
|
searchDefaultConditions: SYMBOL.in,
|
|
111
111
|
type: item.type,
|
|
112
112
|
id: "".concat(item.id, "_").concat(_this.suffixSendName),
|
|
113
113
|
name: "".concat(_this.name, "\u540D\u79F0"),
|
|
114
114
|
filterComponentType: "MultipleSelect",
|
|
115
115
|
props: {
|
|
116
|
-
options:
|
|
116
|
+
options: SendDataCenter.getInstance(_this.type).getSendData()
|
|
117
117
|
},
|
|
118
118
|
filterFn: function filterFn(value) {
|
|
119
119
|
return function (i) {
|
|
@@ -39,10 +39,15 @@ var typeMap = {
|
|
|
39
39
|
label: '等待执行',
|
|
40
40
|
color: '#e7780f'
|
|
41
41
|
}, {
|
|
42
|
-
oldValue: '
|
|
42
|
+
oldValue: '不满足条件,无需执行',
|
|
43
43
|
value: '不满足条件,无需执行',
|
|
44
44
|
label: '不满足条件,无需执行',
|
|
45
45
|
color: '#8A8A8A'
|
|
46
|
+
}, {
|
|
47
|
+
oldValue: '暂不满足条件,等待执行',
|
|
48
|
+
value: '暂不满足条件,等待执行',
|
|
49
|
+
label: '暂不满足条件,等待执行',
|
|
50
|
+
color: '#4D90F7'
|
|
46
51
|
}],
|
|
47
52
|
key: 'msgStatusValues',
|
|
48
53
|
code: 'msgStatus4Search',
|
|
@@ -26,7 +26,7 @@ var typeMap = {
|
|
|
26
26
|
};
|
|
27
27
|
var BasicSelect = /*#__PURE__*/_createClass(function BasicSelect(options) {
|
|
28
28
|
var _this = this,
|
|
29
|
-
_this$
|
|
29
|
+
_this$componentConfig8,
|
|
30
30
|
_this$options;
|
|
31
31
|
_classCallCheck(this, BasicSelect);
|
|
32
32
|
_defineProperty(this, "name", void 0);
|
|
@@ -63,8 +63,9 @@ var BasicSelect = /*#__PURE__*/_createClass(function BasicSelect(options) {
|
|
|
63
63
|
});
|
|
64
64
|
});
|
|
65
65
|
_defineProperty(this, "renderClient", function (record) {
|
|
66
|
-
var _this$optionsMap;
|
|
67
|
-
|
|
66
|
+
var _this$componentConfig5, _this$optionsMap;
|
|
67
|
+
// 特殊自定义组件为平台状态时匹配出label
|
|
68
|
+
var label = ((_this$componentConfig5 = _this.componentConfig) === null || _this$componentConfig5 === void 0 ? void 0 : _this$componentConfig5.webUniqueKey) === 'PLATFORM_STATUS' ? (_this$optionsMap = _this.optionsMap) === null || _this$optionsMap === void 0 ? void 0 : _this$optionsMap[record === null || record === void 0 ? void 0 : record[_this.id]] : record === null || record === void 0 ? void 0 : record[_this.id];
|
|
68
69
|
return !isNull(record === null || record === void 0 ? void 0 : record[_this.id]) ? /*#__PURE__*/React.createElement(ItemView, {
|
|
69
70
|
id: _this.id,
|
|
70
71
|
label: _this.name,
|
|
@@ -72,10 +73,11 @@ var BasicSelect = /*#__PURE__*/_createClass(function BasicSelect(options) {
|
|
|
72
73
|
}) : null;
|
|
73
74
|
});
|
|
74
75
|
_defineProperty(this, "renderPc", function (value, record) {
|
|
75
|
-
var _this$optionsMap2;
|
|
76
|
+
var _this$componentConfig6, _this$optionsMap2;
|
|
76
77
|
var type = _this.type;
|
|
77
78
|
var key = record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_").concat(typeMap[type].key)];
|
|
78
|
-
|
|
79
|
+
// 特殊自定义组件为平台状态时匹配出label
|
|
80
|
+
var label = ((_this$componentConfig6 = _this.componentConfig) === null || _this$componentConfig6 === void 0 ? void 0 : _this$componentConfig6.webUniqueKey) === 'PLATFORM_STATUS' ? ((_this$optionsMap2 = _this.optionsMap) === null || _this$optionsMap2 === void 0 ? void 0 : _this$optionsMap2[key]) || '' : key;
|
|
79
81
|
return /*#__PURE__*/React.createElement("span", null, label !== null && label !== void 0 ? label : "--");
|
|
80
82
|
});
|
|
81
83
|
_defineProperty(this, "renderLog", function (r) {
|
|
@@ -88,10 +90,11 @@ var BasicSelect = /*#__PURE__*/_createClass(function BasicSelect(options) {
|
|
|
88
90
|
return r === null || r === void 0 ? void 0 : r["".concat(_this.id, "_").concat(typeMap[type].key)];
|
|
89
91
|
});
|
|
90
92
|
_defineProperty(this, "renderExport", function (value, record) {
|
|
91
|
-
var _this$optionsMap3;
|
|
93
|
+
var _this$componentConfig7, _this$optionsMap3;
|
|
92
94
|
var type = _this.type;
|
|
93
95
|
var key = record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_").concat(typeMap[type].key)];
|
|
94
|
-
|
|
96
|
+
// 特殊自定义组件为平台状态时匹配出label
|
|
97
|
+
var label = ((_this$componentConfig7 = _this.componentConfig) === null || _this$componentConfig7 === void 0 ? void 0 : _this$componentConfig7.webUniqueKey) === 'PLATFORM_STATUS' ? ((_this$optionsMap3 = _this.optionsMap) === null || _this$optionsMap3 === void 0 ? void 0 : _this$optionsMap3[key]) || '' : key;
|
|
95
98
|
return label !== null && label !== void 0 ? label : "--";
|
|
96
99
|
});
|
|
97
100
|
_defineProperty(this, "filterConfig", function (item) {
|
|
@@ -126,7 +129,7 @@ var BasicSelect = /*#__PURE__*/_createClass(function BasicSelect(options) {
|
|
|
126
129
|
this.canSort = true;
|
|
127
130
|
this.children = [];
|
|
128
131
|
this.dataType = "string";
|
|
129
|
-
this.options = ((_this$
|
|
132
|
+
this.options = ((_this$componentConfig8 = this.componentConfig) === null || _this$componentConfig8 === void 0 ? void 0 : _this$componentConfig8.options) || [];
|
|
130
133
|
this.optionsMap = (_this$options = this.options) === null || _this$options === void 0 ? void 0 : _this$options.reduce(function (prev, next) {
|
|
131
134
|
prev[next.value] = next.label;
|
|
132
135
|
return prev;
|
package/dist/esm/factory.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { JstLogistics, JstItemSelect, JstSupply, JstSendGood, BasicInput, BasicAddress, BasicCascader, BasicCheckbox, BasicDataTime, BasicSelect, BasicRadio, BasicTextArea, BasicPicture, BasicMultSelect, BasicGrade, BasicRate, BasicFile, BasicPosting, SubForm, CommonDataTime, TradeId, ShopName, BuyerNick, ReceiverName, ReceiverMobile, ReceiverAddress, TradeDateTime, Logistics, ReturnLogistics, ActualPayment, ERemark, AliPay, ItemSelect, ItemId, ItemEnCode, SystemOrderNo, Ordinary, ThirdItemSelect, FlowStatusSelect, FlowMarkSelect, FlowTag, Payment, TemplateSelect, WorkOrderId, PlatForm, ShopInput, Submitter, PrevSubmitter, FlowCreator, Handler, CompletedUser, LogisticsInterception, LogisticsMoreInterception, LogisticsTrajectory, LogisticsMoreTrajectory, FlowWorkOrderId, BsGoods, BsExchange, BsReissue, BsReturn, BsSystemOrder, BsLogistics, StatusSelect, CommonSystemOrder, CommonMultiStatus, Calculation, NodeDeadLine, HandlerDeadLine, NodeStayDuration, WlnGoods, BsPosting, MsgStatus, NodeInput, FlowWorkOrderStatus, WdtGoods, WdtReturn, WdtExchange, CommonInput, PaymentVoucherCode, Label, WdtReissue, KmErpSendGood, AfterSalesOrderId, BsE3Goods, BsE3Reissue } from "./index";
|
|
2
2
|
import { PickOption } from "./type";
|
|
3
|
-
export declare const factory: (type: string, options: PickOption) => ActualPayment | BsLogistics |
|
|
3
|
+
export declare const factory: (type: string, options: PickOption) => ActualPayment | BsLogistics | JstSendGood | KmErpSendGood | MsgStatus | BasicSelect | BasicInput | BasicAddress | BasicCascader | BasicCheckbox | BasicDataTime | BasicRadio | BasicTextArea | BasicPicture | BasicMultSelect | BasicGrade | BasicRate | BasicFile | BasicPosting | SubForm | CommonDataTime | TradeId | ShopName | BuyerNick | ReceiverName | ReceiverMobile | ReceiverAddress | TradeDateTime | Logistics | ReturnLogistics | ERemark | AliPay | ItemSelect | ItemId | ItemEnCode | SystemOrderNo | Ordinary | ThirdItemSelect | Payment | JstLogistics | JstItemSelect | JstSupply | BsSystemOrder | BsGoods | BsE3Goods | BsE3Reissue | BsExchange | BsReissue | BsReturn | FlowStatusSelect | FlowMarkSelect | FlowTag | TemplateSelect | WorkOrderId | LogisticsInterception | LogisticsMoreInterception | LogisticsTrajectory | LogisticsMoreTrajectory | PlatForm | ShopInput | Submitter | PrevSubmitter | FlowCreator | Handler | CompletedUser | FlowWorkOrderId | StatusSelect | Calculation | CommonSystemOrder | CommonMultiStatus | NodeDeadLine | HandlerDeadLine | NodeStayDuration | WlnGoods | BsPosting | NodeInput | FlowWorkOrderStatus | WdtGoods | WdtReissue | WdtReturn | WdtExchange | CommonInput | PaymentVoucherCode | Label | AfterSalesOrderId;
|
package/dist/esm/factory.js
CHANGED
|
@@ -136,6 +136,7 @@ export var factory = function factory(type, options) {
|
|
|
136
136
|
return new BsSystemOrder(options);
|
|
137
137
|
case "JST_SEND_GOOD":
|
|
138
138
|
case "BS_SEND_GOOD":
|
|
139
|
+
case "BS_E3_SEND_GOOD":
|
|
139
140
|
case "WLN_SEND_GOOD":
|
|
140
141
|
case "WDT_SEND_GOOD":
|
|
141
142
|
return new JstSendGood(options);
|
|
@@ -165,6 +166,7 @@ export var factory = function factory(type, options) {
|
|
|
165
166
|
case "EXCHANGE_TRADE_ID":
|
|
166
167
|
return new CommonSystemOrder(options);
|
|
167
168
|
case "BS_LOGISTICS":
|
|
169
|
+
case "BS_E3_LOGISTICS":
|
|
168
170
|
case "WLN_LOGISTICS":
|
|
169
171
|
case "WDT_LOGISTICS":
|
|
170
172
|
return new BsLogistics(options);
|
|
@@ -7,6 +7,7 @@ export declare const queryExpressInterceptData: () => Promise<void>;
|
|
|
7
7
|
export declare const queryLogisticsAddressData: () => Promise<void>;
|
|
8
8
|
export declare const queryAllLogisticsCompany: () => Promise<void>;
|
|
9
9
|
export declare const queryWdtLogisticsCompany: () => Promise<void>;
|
|
10
|
+
export declare const queryBsE3LogisticsCompany: () => Promise<void>;
|
|
10
11
|
export declare const queryWdtSendData: () => Promise<void>;
|
|
11
12
|
export declare const getAlipayBillReceipt: (data: any) => Promise<any>;
|
|
12
13
|
export declare const queryLabel: () => Promise<any>;
|
package/dist/esm/service/api.js
CHANGED
|
@@ -1,4 +1,7 @@
|
|
|
1
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 _regeneratorRuntime() { "use strict"; /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */ _regeneratorRuntime = function _regeneratorRuntime() { return exports; }; var exports = {}, Op = Object.prototype, hasOwn = Op.hasOwnProperty, defineProperty = Object.defineProperty || function (obj, key, desc) { obj[key] = desc.value; }, $Symbol = "function" == typeof Symbol ? Symbol : {}, iteratorSymbol = $Symbol.iterator || "@@iterator", asyncIteratorSymbol = $Symbol.asyncIterator || "@@asyncIterator", toStringTagSymbol = $Symbol.toStringTag || "@@toStringTag"; function define(obj, key, value) { return Object.defineProperty(obj, key, { value: value, enumerable: !0, configurable: !0, writable: !0 }), obj[key]; } try { define({}, ""); } catch (err) { define = function define(obj, key, value) { return obj[key] = value; }; } function wrap(innerFn, outerFn, self, tryLocsList) { var protoGenerator = outerFn && outerFn.prototype instanceof Generator ? outerFn : Generator, generator = Object.create(protoGenerator.prototype), context = new Context(tryLocsList || []); return defineProperty(generator, "_invoke", { value: makeInvokeMethod(innerFn, self, context) }), generator; } function tryCatch(fn, obj, arg) { try { return { type: "normal", arg: fn.call(obj, arg) }; } catch (err) { return { type: "throw", arg: err }; } } exports.wrap = wrap; var ContinueSentinel = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} var IteratorPrototype = {}; define(IteratorPrototype, iteratorSymbol, function () { return this; }); var getProto = Object.getPrototypeOf, NativeIteratorPrototype = getProto && getProto(getProto(values([]))); NativeIteratorPrototype && NativeIteratorPrototype !== Op && hasOwn.call(NativeIteratorPrototype, iteratorSymbol) && (IteratorPrototype = NativeIteratorPrototype); var Gp = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(IteratorPrototype); function defineIteratorMethods(prototype) { ["next", "throw", "return"].forEach(function (method) { define(prototype, method, function (arg) { return this._invoke(method, arg); }); }); } function AsyncIterator(generator, PromiseImpl) { function invoke(method, arg, resolve, reject) { var record = tryCatch(generator[method], generator, arg); if ("throw" !== record.type) { var result = record.arg, value = result.value; return value && "object" == _typeof(value) && hasOwn.call(value, "__await") ? PromiseImpl.resolve(value.__await).then(function (value) { invoke("next", value, resolve, reject); }, function (err) { invoke("throw", err, resolve, reject); }) : PromiseImpl.resolve(value).then(function (unwrapped) { result.value = unwrapped, resolve(result); }, function (error) { return invoke("throw", error, resolve, reject); }); } reject(record.arg); } var previousPromise; defineProperty(this, "_invoke", { value: function value(method, arg) { function callInvokeWithMethodAndArg() { return new PromiseImpl(function (resolve, reject) { invoke(method, arg, resolve, reject); }); } return previousPromise = previousPromise ? previousPromise.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg(); } }); } function makeInvokeMethod(innerFn, self, context) { var state = "suspendedStart"; return function (method, arg) { if ("executing" === state) throw new Error("Generator is already running"); if ("completed" === state) { if ("throw" === method) throw arg; return doneResult(); } for (context.method = method, context.arg = arg;;) { var delegate = context.delegate; if (delegate) { var delegateResult = maybeInvokeDelegate(delegate, context); if (delegateResult) { if (delegateResult === ContinueSentinel) continue; return delegateResult; } } if ("next" === context.method) context.sent = context._sent = context.arg;else if ("throw" === context.method) { if ("suspendedStart" === state) throw state = "completed", context.arg; context.dispatchException(context.arg); } else "return" === context.method && context.abrupt("return", context.arg); state = "executing"; var record = tryCatch(innerFn, self, context); if ("normal" === record.type) { if (state = context.done ? "completed" : "suspendedYield", record.arg === ContinueSentinel) continue; return { value: record.arg, done: context.done }; } "throw" === record.type && (state = "completed", context.method = "throw", context.arg = record.arg); } }; } function maybeInvokeDelegate(delegate, context) { var methodName = context.method, method = delegate.iterator[methodName]; if (undefined === method) return context.delegate = null, "throw" === methodName && delegate.iterator.return && (context.method = "return", context.arg = undefined, maybeInvokeDelegate(delegate, context), "throw" === context.method) || "return" !== methodName && (context.method = "throw", context.arg = new TypeError("The iterator does not provide a '" + methodName + "' method")), ContinueSentinel; var record = tryCatch(method, delegate.iterator, context.arg); if ("throw" === record.type) return context.method = "throw", context.arg = record.arg, context.delegate = null, ContinueSentinel; var info = record.arg; return info ? info.done ? (context[delegate.resultName] = info.value, context.next = delegate.nextLoc, "return" !== context.method && (context.method = "next", context.arg = undefined), context.delegate = null, ContinueSentinel) : info : (context.method = "throw", context.arg = new TypeError("iterator result is not an object"), context.delegate = null, ContinueSentinel); } function pushTryEntry(locs) { var entry = { tryLoc: locs[0] }; 1 in locs && (entry.catchLoc = locs[1]), 2 in locs && (entry.finallyLoc = locs[2], entry.afterLoc = locs[3]), this.tryEntries.push(entry); } function resetTryEntry(entry) { var record = entry.completion || {}; record.type = "normal", delete record.arg, entry.completion = record; } function Context(tryLocsList) { this.tryEntries = [{ tryLoc: "root" }], tryLocsList.forEach(pushTryEntry, this), this.reset(!0); } function values(iterable) { if (iterable) { var iteratorMethod = iterable[iteratorSymbol]; if (iteratorMethod) return iteratorMethod.call(iterable); if ("function" == typeof iterable.next) return iterable; if (!isNaN(iterable.length)) { var i = -1, next = function next() { for (; ++i < iterable.length;) if (hasOwn.call(iterable, i)) return next.value = iterable[i], next.done = !1, next; return next.value = undefined, next.done = !0, next; }; return next.next = next; } } return { next: doneResult }; } function doneResult() { return { value: undefined, done: !0 }; } return GeneratorFunction.prototype = GeneratorFunctionPrototype, defineProperty(Gp, "constructor", { value: GeneratorFunctionPrototype, configurable: !0 }), defineProperty(GeneratorFunctionPrototype, "constructor", { value: GeneratorFunction, configurable: !0 }), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, toStringTagSymbol, "GeneratorFunction"), exports.isGeneratorFunction = function (genFun) { var ctor = "function" == typeof genFun && genFun.constructor; return !!ctor && (ctor === GeneratorFunction || "GeneratorFunction" === (ctor.displayName || ctor.name)); }, exports.mark = function (genFun) { return Object.setPrototypeOf ? Object.setPrototypeOf(genFun, GeneratorFunctionPrototype) : (genFun.__proto__ = GeneratorFunctionPrototype, define(genFun, toStringTagSymbol, "GeneratorFunction")), genFun.prototype = Object.create(Gp), genFun; }, exports.awrap = function (arg) { return { __await: arg }; }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, asyncIteratorSymbol, function () { return this; }), exports.AsyncIterator = AsyncIterator, exports.async = function (innerFn, outerFn, self, tryLocsList, PromiseImpl) { void 0 === PromiseImpl && (PromiseImpl = Promise); var iter = new AsyncIterator(wrap(innerFn, outerFn, self, tryLocsList), PromiseImpl); return exports.isGeneratorFunction(outerFn) ? iter : iter.next().then(function (result) { return result.done ? result.value : iter.next(); }); }, defineIteratorMethods(Gp), define(Gp, toStringTagSymbol, "Generator"), define(Gp, iteratorSymbol, function () { return this; }), define(Gp, "toString", function () { return "[object Generator]"; }), exports.keys = function (val) { var object = Object(val), keys = []; for (var key in object) keys.push(key); return keys.reverse(), function next() { for (; keys.length;) { var key = keys.pop(); if (key in object) return next.value = key, next.done = !1, next; } return next.done = !0, next; }; }, exports.values = values, Context.prototype = { constructor: Context, reset: function reset(skipTempReset) { if (this.prev = 0, this.next = 0, this.sent = this._sent = undefined, this.done = !1, this.delegate = null, this.method = "next", this.arg = undefined, this.tryEntries.forEach(resetTryEntry), !skipTempReset) for (var name in this) "t" === name.charAt(0) && hasOwn.call(this, name) && !isNaN(+name.slice(1)) && (this[name] = undefined); }, stop: function stop() { this.done = !0; var rootRecord = this.tryEntries[0].completion; if ("throw" === rootRecord.type) throw rootRecord.arg; return this.rval; }, dispatchException: function dispatchException(exception) { if (this.done) throw exception; var context = this; function handle(loc, caught) { return record.type = "throw", record.arg = exception, context.next = loc, caught && (context.method = "next", context.arg = undefined), !!caught; } for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i], record = entry.completion; if ("root" === entry.tryLoc) return handle("end"); if (entry.tryLoc <= this.prev) { var hasCatch = hasOwn.call(entry, "catchLoc"), hasFinally = hasOwn.call(entry, "finallyLoc"); if (hasCatch && hasFinally) { if (this.prev < entry.catchLoc) return handle(entry.catchLoc, !0); if (this.prev < entry.finallyLoc) return handle(entry.finallyLoc); } else if (hasCatch) { if (this.prev < entry.catchLoc) return handle(entry.catchLoc, !0); } else { if (!hasFinally) throw new Error("try statement without catch or finally"); if (this.prev < entry.finallyLoc) return handle(entry.finallyLoc); } } } }, abrupt: function abrupt(type, arg) { for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i]; if (entry.tryLoc <= this.prev && hasOwn.call(entry, "finallyLoc") && this.prev < entry.finallyLoc) { var finallyEntry = entry; break; } } finallyEntry && ("break" === type || "continue" === type) && finallyEntry.tryLoc <= arg && arg <= finallyEntry.finallyLoc && (finallyEntry = null); var record = finallyEntry ? finallyEntry.completion : {}; return record.type = type, record.arg = arg, finallyEntry ? (this.method = "next", this.next = finallyEntry.finallyLoc, ContinueSentinel) : this.complete(record); }, complete: function complete(record, afterLoc) { if ("throw" === record.type) throw record.arg; return "break" === record.type || "continue" === record.type ? this.next = record.arg : "return" === record.type ? (this.rval = this.arg = record.arg, this.method = "return", this.next = "end") : "normal" === record.type && afterLoc && (this.next = afterLoc), ContinueSentinel; }, finish: function finish(finallyLoc) { for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i]; if (entry.finallyLoc === finallyLoc) return this.complete(entry.completion, entry.afterLoc), resetTryEntry(entry), ContinueSentinel; } }, catch: function _catch(tryLoc) { for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i]; if (entry.tryLoc === tryLoc) { var record = entry.completion; if ("throw" === record.type) { var thrown = record.arg; resetTryEntry(entry); } return thrown; } } throw new Error("illegal catch attempt"); }, delegateYield: function delegateYield(iterable, resultName, nextLoc) { return this.delegate = { iterator: values(iterable), resultName: resultName, nextLoc: nextLoc }, "next" === this.method && (this.arg = undefined), ContinueSentinel; } }, exports; }
|
|
3
|
+
function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { Promise.resolve(value).then(_next, _throw); } }
|
|
4
|
+
function _asyncToGenerator(fn) { return function () { var self = this, args = arguments; return new Promise(function (resolve, reject) { var gen = fn.apply(self, args); function _next(value) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "next", value); } function _throw(err) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "throw", err); } _next(undefined); }); }; }
|
|
2
5
|
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
6
|
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
7
|
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; }
|
|
@@ -10,7 +13,7 @@ function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o =
|
|
|
10
13
|
function _iterableToArray(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
|
|
11
14
|
function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToArray(arr); }
|
|
12
15
|
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
|
|
13
|
-
import { AddressData, toTree, BsAddressData, WdtAddressData, PlatData, ExpressInterceptData, LogisticsAddressData, ExpressData, LabelData,
|
|
16
|
+
import { AddressData, toTree, BsAddressData, WdtAddressData, PlatData, ExpressInterceptData, LogisticsAddressData, ExpressData, LabelData, SendDataCenter, servers } from "@kmkf-fe-packages/kmkf-utils";
|
|
14
17
|
import get from "lodash/get";
|
|
15
18
|
import request from "./request";
|
|
16
19
|
// 重复校验
|
|
@@ -257,12 +260,29 @@ export var queryWdtLogisticsCompany = function queryWdtLogisticsCompany() {
|
|
|
257
260
|
instance.expressData = data;
|
|
258
261
|
}).catch(console.log);
|
|
259
262
|
};
|
|
260
|
-
export var
|
|
261
|
-
var instance =
|
|
262
|
-
return
|
|
263
|
-
instance.
|
|
263
|
+
export var queryBsE3LogisticsCompany = function queryBsE3LogisticsCompany() {
|
|
264
|
+
var instance = ExpressData.getInstance('bsE3');
|
|
265
|
+
return servers.BSE3.getLogisticsDataAsync().then(function (data) {
|
|
266
|
+
instance.expressData = data;
|
|
264
267
|
}).catch(console.log);
|
|
265
268
|
};
|
|
269
|
+
export var queryWdtSendData = /*#__PURE__*/function () {
|
|
270
|
+
var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
|
|
271
|
+
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
272
|
+
while (1) switch (_context.prev = _context.next) {
|
|
273
|
+
case 0:
|
|
274
|
+
_context.next = 2;
|
|
275
|
+
return SendDataCenter.fetchData();
|
|
276
|
+
case 2:
|
|
277
|
+
case "end":
|
|
278
|
+
return _context.stop();
|
|
279
|
+
}
|
|
280
|
+
}, _callee);
|
|
281
|
+
}));
|
|
282
|
+
return function queryWdtSendData() {
|
|
283
|
+
return _ref.apply(this, arguments);
|
|
284
|
+
};
|
|
285
|
+
}();
|
|
266
286
|
// 获取支付宝电子回单
|
|
267
287
|
export var getAlipayBillReceipt = function getAlipayBillReceipt(data) {
|
|
268
288
|
return request({
|
package/dist/esm/type.d.ts
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@kmkf-fe-packages/services-components",
|
|
3
|
-
"version": "1.19.8-beta.
|
|
3
|
+
"version": "1.19.8-beta.21",
|
|
4
4
|
"module": "dist/esm/index.js",
|
|
5
5
|
"typings": "dist/esm/index.d.ts",
|
|
6
6
|
"files": [
|
|
@@ -21,8 +21,8 @@
|
|
|
21
21
|
]
|
|
22
22
|
},
|
|
23
23
|
"dependencies": {
|
|
24
|
-
"@kmkf-fe-packages/basic-components": "1.19.8-beta.
|
|
25
|
-
"@kmkf-fe-packages/kmkf-utils": "1.19.8-beta.
|
|
24
|
+
"@kmkf-fe-packages/basic-components": "1.19.8-beta.21",
|
|
25
|
+
"@kmkf-fe-packages/kmkf-utils": "1.19.8-beta.21",
|
|
26
26
|
"b64-to-blob": "^1.2.19",
|
|
27
27
|
"html2canvas": "^1.4.1",
|
|
28
28
|
"react-pdf-js": "^5.1.0"
|
|
@@ -41,7 +41,7 @@
|
|
|
41
41
|
"publishConfig": {
|
|
42
42
|
"access": "public"
|
|
43
43
|
},
|
|
44
|
-
"gitHead": "
|
|
44
|
+
"gitHead": "2832c9a0bbb4c8fede1e331231777324dd827482",
|
|
45
45
|
"gitHooks": {
|
|
46
46
|
"pre-commit": "lint-staged"
|
|
47
47
|
}
|