@kmkf-fe-packages/services-components 1.2.0 → 1.3.0-rc.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/esm/commonComponents/GlobalContext/index.d.ts +1 -1
- package/dist/esm/commonComponents/GlobalContext/index.js +3 -2
- package/dist/esm/components/BS/common/BsMemo.js +2 -1
- package/dist/esm/components/BS/common/BsType.js +2 -1
- package/dist/esm/components/Cascader/index.d.ts +1 -0
- package/dist/esm/components/Cascader/index.js +4 -1
- package/dist/esm/components/Common/index.d.ts +1 -1
- package/dist/esm/components/Common/index.js +185 -4
- package/dist/esm/components/CommonHeaderGood/index.js +182 -0
- package/dist/esm/components/CommonMultiStatus/index.js +25 -19
- package/dist/esm/components/CommonSystemOrder/index.js +10 -8
- package/dist/esm/components/Input/index.d.ts +1 -0
- package/dist/esm/components/Input/index.js +13 -5
- package/dist/esm/components/Label/index.d.ts +36 -0
- package/dist/esm/components/Label/index.js +142 -0
- package/dist/esm/components/StatusSelect/index.js +3 -0
- package/dist/esm/components/WDT/WdtExchange/index.d.ts +35 -0
- package/dist/esm/components/WDT/WdtExchange/index.js +183 -0
- package/dist/esm/components/WDT/WdtReturn/index.d.ts +54 -0
- package/dist/esm/components/WDT/WdtReturn/index.js +150 -0
- package/dist/esm/factory.d.ts +2 -2
- package/dist/esm/factory.js +7 -1
- package/dist/esm/index.d.ts +3 -0
- package/dist/esm/index.js +3 -0
- package/dist/esm/service/api.d.ts +1 -0
- package/dist/esm/service/api.js +20 -1
- package/dist/esm/type.d.ts +9 -3
- package/package.json +4 -4
|
@@ -0,0 +1,150 @@
|
|
|
1
|
+
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
2
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
3
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
4
|
+
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
5
|
+
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); } }
|
|
6
|
+
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
7
|
+
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
8
|
+
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; }
|
|
9
|
+
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
|
|
10
|
+
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); }
|
|
11
|
+
import React from "react";
|
|
12
|
+
import GetFormItem from "../../GetFormItem";
|
|
13
|
+
import ItemView from "../../../commonComponents/ItemView";
|
|
14
|
+
import { isNull, filterFn as _filterFn } from "@kmkf-fe-packages/kmkf-utils";
|
|
15
|
+
import { SYMBOL } from "../../../constant";
|
|
16
|
+
import { BsGoodsTable } from "../../Common";
|
|
17
|
+
import { BsType } from "../../BS/common/index";
|
|
18
|
+
import { CommonReturnGoods } from "@kmkf-fe-packages/basic-components";
|
|
19
|
+
import CommonHeaderGoods from "../../CommonHeaderGood";
|
|
20
|
+
var WdtReturn = /*#__PURE__*/_createClass(function WdtReturn(options) {
|
|
21
|
+
var _this = this,
|
|
22
|
+
_this$componentConfig4;
|
|
23
|
+
_classCallCheck(this, WdtReturn);
|
|
24
|
+
_defineProperty(this, "name", void 0);
|
|
25
|
+
_defineProperty(this, "id", void 0);
|
|
26
|
+
_defineProperty(this, "sortField", void 0);
|
|
27
|
+
_defineProperty(this, "type", void 0);
|
|
28
|
+
_defineProperty(this, "rules", void 0);
|
|
29
|
+
_defineProperty(this, "componentConfig", void 0);
|
|
30
|
+
_defineProperty(this, "effects", void 0);
|
|
31
|
+
_defineProperty(this, "isCombinationComponent", void 0);
|
|
32
|
+
_defineProperty(this, "formField", void 0);
|
|
33
|
+
_defineProperty(this, "canSort", void 0);
|
|
34
|
+
_defineProperty(this, "children", void 0);
|
|
35
|
+
_defineProperty(this, "dataType", void 0);
|
|
36
|
+
_defineProperty(this, "wdtType", void 0);
|
|
37
|
+
_defineProperty(this, "reissueGoods", void 0);
|
|
38
|
+
_defineProperty(this, "renderClient", function (record) {
|
|
39
|
+
var _this$componentConfig;
|
|
40
|
+
return !isNull(record === null || record === void 0 ? void 0 : record["".concat(_this.id)]) ? /*#__PURE__*/React.createElement(React.Fragment, null, _this.wdtType.renderClient(record), record !== null && record !== void 0 && record["".concat(_this.id)].wdtReturnGoods.length ? /*#__PURE__*/React.createElement(ItemView, {
|
|
41
|
+
id: _this.id,
|
|
42
|
+
label: _this.name,
|
|
43
|
+
value: /*#__PURE__*/React.createElement(BsGoodsTable, {
|
|
44
|
+
type: _this.type,
|
|
45
|
+
list: (record === null || record === void 0 ? void 0 : record["".concat(_this.id)].wdtReturnGoods) || [],
|
|
46
|
+
showHeader: ((_this$componentConfig = _this.componentConfig) === null || _this$componentConfig === void 0 ? void 0 : _this$componentConfig.showHeader) || []
|
|
47
|
+
})
|
|
48
|
+
}) : null) : null;
|
|
49
|
+
});
|
|
50
|
+
_defineProperty(this, "renderPc", function () {
|
|
51
|
+
return null;
|
|
52
|
+
});
|
|
53
|
+
_defineProperty(this, "renderLog", function (r) {
|
|
54
|
+
var _r, _r2, _this$componentConfig2;
|
|
55
|
+
return /*#__PURE__*/React.createElement(React.Fragment, null, r !== null && r !== void 0 && (_r = r["".concat(_this.id, "_wdtReturnType")]) !== null && _r !== void 0 && _r.length ? /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("div", null, "\u5907\u6CE8\u7C7B\u578B:", _this.wdtType.renderLog(r))) : null, r !== null && r !== void 0 && (_r2 = r["".concat(_this.id, "_wdtReturnGoods")]) !== null && _r2 !== void 0 && _r2.length ? /*#__PURE__*/React.createElement("div", null, "\u5546\u54C1\uFF1A", /*#__PURE__*/React.createElement(BsGoodsTable, {
|
|
56
|
+
type: _this.type,
|
|
57
|
+
list: (r === null || r === void 0 ? void 0 : r["".concat(_this.id, "_wdtReturnGoods")]) || [],
|
|
58
|
+
showHeader: ((_this$componentConfig2 = _this.componentConfig) === null || _this$componentConfig2 === void 0 ? void 0 : _this$componentConfig2.showHeader) || []
|
|
59
|
+
})) : null, r !== null && r !== void 0 && r["".concat(_this.id, "_shopCode")] ? /*#__PURE__*/React.createElement("div", null, "\u5E97\u94FAid:", r === null || r === void 0 ? void 0 : r["".concat(_this.id, "_shopCode")]) : null);
|
|
60
|
+
});
|
|
61
|
+
_defineProperty(this, "getComponentValue", function (r) {
|
|
62
|
+
return r === null || r === void 0 ? void 0 : r["".concat(_this.id, "_wdtReturnGoods")];
|
|
63
|
+
});
|
|
64
|
+
_defineProperty(this, "renderExport", function () {
|
|
65
|
+
return null;
|
|
66
|
+
});
|
|
67
|
+
_defineProperty(this, "editRender", function (p) {
|
|
68
|
+
var _this$componentConfig3, _this$effects, _this$effects2, _this$effects3;
|
|
69
|
+
return /*#__PURE__*/React.createElement(GetFormItem, {
|
|
70
|
+
title: _this.name,
|
|
71
|
+
name: _this.id,
|
|
72
|
+
rules: _this.rules,
|
|
73
|
+
required: false,
|
|
74
|
+
hidden: p === null || p === void 0 ? void 0 : p.hidden,
|
|
75
|
+
display: p === null || p === void 0 ? void 0 : p.display,
|
|
76
|
+
component: /*#__PURE__*/React.createElement(CommonReturnGoods, _extends({}, _this.componentConfig, {
|
|
77
|
+
maxLength: ((_this$componentConfig3 = _this.componentConfig) === null || _this$componentConfig3 === void 0 ? void 0 : _this$componentConfig3.maxLength) || 20,
|
|
78
|
+
shopId: (_this$effects = _this.effects) === null || _this$effects === void 0 ? void 0 : _this$effects.shopId,
|
|
79
|
+
shopList: ((_this$effects2 = _this.effects) === null || _this$effects2 === void 0 ? void 0 : _this$effects2.shopList) || [],
|
|
80
|
+
companyKey: (_this$effects3 = _this.effects) === null || _this$effects3 === void 0 ? void 0 : _this$effects3.companyKey,
|
|
81
|
+
type: "WDT_RETURN_GOODS",
|
|
82
|
+
width: "90%"
|
|
83
|
+
}))
|
|
84
|
+
});
|
|
85
|
+
});
|
|
86
|
+
_defineProperty(this, "filterConfig", function (item) {
|
|
87
|
+
var _item$templateConfig;
|
|
88
|
+
return [{
|
|
89
|
+
searchDefaultConditions: SYMBOL.in,
|
|
90
|
+
type: item.type,
|
|
91
|
+
id: "".concat(item.id, "_wdtReturnType"),
|
|
92
|
+
name: "".concat(item.name, "-\u9000\u8D27\u7C7B\u578B"),
|
|
93
|
+
filterComponentType: "Cascader",
|
|
94
|
+
props: {
|
|
95
|
+
options: item === null || item === void 0 ? void 0 : (_item$templateConfig = item.templateConfig) === null || _item$templateConfig === void 0 ? void 0 : _item$templateConfig.reasonList,
|
|
96
|
+
fieldNames: {
|
|
97
|
+
label: "label",
|
|
98
|
+
value: "value",
|
|
99
|
+
children: "children"
|
|
100
|
+
}
|
|
101
|
+
},
|
|
102
|
+
formatFilterValue: function formatFilterValue(val) {
|
|
103
|
+
if ((val === null || val === void 0 ? void 0 : val.length) > 0) {
|
|
104
|
+
return [val[val.length - 1]];
|
|
105
|
+
}
|
|
106
|
+
},
|
|
107
|
+
filterFn: function filterFn(value) {
|
|
108
|
+
return function (i) {
|
|
109
|
+
return _filterFn.filterSplitComma(_filterFn.filterTableListItemColumnValue(i, item.id, "wdtReturnType"), value);
|
|
110
|
+
};
|
|
111
|
+
}
|
|
112
|
+
}, {
|
|
113
|
+
searchDefaultConditions: SYMBOL.like,
|
|
114
|
+
type: item.type,
|
|
115
|
+
id: "".concat(item.id, "_wdtReturnGoods"),
|
|
116
|
+
name: "".concat(_this.name),
|
|
117
|
+
filterComponentType: "Input"
|
|
118
|
+
}];
|
|
119
|
+
});
|
|
120
|
+
this.name = options.name;
|
|
121
|
+
this.id = options.id;
|
|
122
|
+
this.sortField = "".concat(options.id);
|
|
123
|
+
this.formField = "".concat(options.id);
|
|
124
|
+
this.type = options.type;
|
|
125
|
+
this.effects = options === null || options === void 0 ? void 0 : options.effects;
|
|
126
|
+
this.isCombinationComponent = true;
|
|
127
|
+
this.canSort = false;
|
|
128
|
+
this.wdtType = new BsType(_objectSpread(_objectSpread({}, options), {}, {
|
|
129
|
+
id: "".concat(options.id, "_wdtReturnType"),
|
|
130
|
+
name: "退货类型"
|
|
131
|
+
}));
|
|
132
|
+
this.reissueGoods = new CommonHeaderGoods(_objectSpread(_objectSpread({}, options), {}, {
|
|
133
|
+
id: "".concat(options.id, "_wdtReturnGoods"),
|
|
134
|
+
name: "商品信息"
|
|
135
|
+
}));
|
|
136
|
+
this.children = [this.wdtType, this.reissueGoods];
|
|
137
|
+
this.componentConfig = options === null || options === void 0 ? void 0 : options.componentConfig;
|
|
138
|
+
this.rules = this !== null && this !== void 0 && (_this$componentConfig4 = this.componentConfig) !== null && _this$componentConfig4 !== void 0 && _this$componentConfig4.required ? [{
|
|
139
|
+
required: true,
|
|
140
|
+
validator: function validator(_, value) {
|
|
141
|
+
var _value$wdtReturnGoods;
|
|
142
|
+
if (!value || !(value !== null && value !== void 0 && (_value$wdtReturnGoods = value.wdtReturnGoods) !== null && _value$wdtReturnGoods !== void 0 && _value$wdtReturnGoods.length)) {
|
|
143
|
+
return Promise.reject(new Error("请选择wdt退货商品"));
|
|
144
|
+
}
|
|
145
|
+
return Promise.resolve();
|
|
146
|
+
}
|
|
147
|
+
}] : [];
|
|
148
|
+
this.dataType = "object";
|
|
149
|
+
});
|
|
150
|
+
export default WdtReturn;
|
package/dist/esm/factory.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { JstLogistics, JstItemSelect, JstSupply, JstSendGood, BasicInput, BasicAddress, BasicCascader, BasicCheckbox, BasicDataTime, BasicSelect, BasicRadio, BasicTextArea, BasicPicture, BasicMultSelect, BasicGrade, BasicRate, BasicFile, BasicPosting, 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, CommonInput, PaymentVoucherCode, WdtReissue } from "./index";
|
|
1
|
+
import { JstLogistics, JstItemSelect, JstSupply, JstSendGood, BasicInput, BasicAddress, BasicCascader, BasicCheckbox, BasicDataTime, BasicSelect, BasicRadio, BasicTextArea, BasicPicture, BasicMultSelect, BasicGrade, BasicRate, BasicFile, BasicPosting, 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 } from "./index";
|
|
2
2
|
import { PickOption } from "./type";
|
|
3
|
-
export declare const factory: (type: string, options: PickOption) => AliPay | BasicCascader | CommonMultiStatus | CommonSystemOrder | FlowMarkSelect | BasicInput | MsgStatus | StatusSelect | BasicAddress | BasicCheckbox | BasicDataTime | BasicSelect | BasicRadio | BasicTextArea | BasicPicture | BasicMultSelect | BasicGrade | BasicRate | BasicFile | BasicPosting | CommonDataTime | TradeId | ShopName | BuyerNick | ReceiverName | ReceiverMobile | ReceiverAddress | TradeDateTime | Logistics | ReturnLogistics | ActualPayment | ERemark | ItemSelect | ItemId | ItemEnCode | SystemOrderNo | Ordinary | ThirdItemSelect | Payment | JstLogistics | JstItemSelect | JstSendGood | JstSupply | BsSystemOrder | BsGoods | BsExchange | BsReissue | BsReturn | BsLogistics | FlowStatusSelect | FlowTag | TemplateSelect | WorkOrderId | LogisticsInterception | LogisticsMoreInterception | LogisticsTrajectory | LogisticsMoreTrajectory | PlatForm | ShopInput | Submitter | PrevSubmitter | FlowCreator | Handler | CompletedUser | FlowWorkOrderId | Calculation | NodeDeadLine | HandlerDeadLine | NodeStayDuration | WlnGoods | BsPosting | NodeInput | FlowWorkOrderStatus | WdtGoods | WdtReissue | CommonInput | PaymentVoucherCode;
|
|
3
|
+
export declare const factory: (type: string, options: PickOption) => AliPay | BasicCascader | CommonMultiStatus | CommonSystemOrder | FlowMarkSelect | BasicInput | Label | MsgStatus | StatusSelect | WdtExchange | WdtReturn | BasicAddress | BasicCheckbox | BasicDataTime | BasicSelect | BasicRadio | BasicTextArea | BasicPicture | BasicMultSelect | BasicGrade | BasicRate | BasicFile | BasicPosting | CommonDataTime | TradeId | ShopName | BuyerNick | ReceiverName | ReceiverMobile | ReceiverAddress | TradeDateTime | Logistics | ReturnLogistics | ActualPayment | ERemark | ItemSelect | ItemId | ItemEnCode | SystemOrderNo | Ordinary | ThirdItemSelect | Payment | JstLogistics | JstItemSelect | JstSendGood | JstSupply | BsSystemOrder | BsGoods | BsExchange | BsReissue | BsReturn | BsLogistics | FlowStatusSelect | FlowTag | TemplateSelect | WorkOrderId | LogisticsInterception | LogisticsMoreInterception | LogisticsTrajectory | LogisticsMoreTrajectory | PlatForm | ShopInput | Submitter | PrevSubmitter | FlowCreator | Handler | CompletedUser | FlowWorkOrderId | Calculation | NodeDeadLine | HandlerDeadLine | NodeStayDuration | WlnGoods | BsPosting | NodeInput | FlowWorkOrderStatus | WdtGoods | WdtReissue | CommonInput | PaymentVoucherCode;
|
package/dist/esm/factory.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { JstLogistics, JstItemSelect, JstSupply, JstSendGood, BasicInput, BasicAddress, BasicCascader, BasicCheckbox, BasicDataTime, BasicSelect, BasicRadio, BasicTextArea, BasicPicture, BasicMultSelect, BasicGrade, BasicRate, BasicFile, BasicPosting, CommonDataTime, TradeId, ShopName, ErpTradeId, 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,
|
|
2
2
|
// CommonTradeId,
|
|
3
|
-
CommonSystemOrder, CommonMultiStatus, Calculation, NodeDeadLine, HandlerDeadLine, NodeStayDuration, WlnGoods, BsPosting, MsgStatus, NodeInput, FlowWorkOrderStatus, WdtGoods, CommonInput, PaymentVoucherCode, WdtReissue } from "./index";
|
|
3
|
+
CommonSystemOrder, CommonMultiStatus, Calculation, NodeDeadLine, HandlerDeadLine, NodeStayDuration, WlnGoods, BsPosting, MsgStatus, NodeInput, FlowWorkOrderStatus, WdtGoods, WdtReturn, WdtExchange, CommonInput, PaymentVoucherCode, Label, WdtReissue } from "./index";
|
|
4
4
|
export var factory = function factory(type, options) {
|
|
5
5
|
var _options$componentCon;
|
|
6
6
|
switch (type) {
|
|
@@ -141,12 +141,16 @@ export var factory = function factory(type, options) {
|
|
|
141
141
|
return new BsGoods(options);
|
|
142
142
|
case "BS_EXCHANGE_GOODS":
|
|
143
143
|
return new BsExchange(options);
|
|
144
|
+
case "WDT_EXCHANGE_GOODS":
|
|
145
|
+
return new WdtExchange(options);
|
|
144
146
|
case "BS_REISSUE_GOODS":
|
|
145
147
|
return new BsReissue(options);
|
|
146
148
|
case "WDT_REISSUE_GOODS":
|
|
147
149
|
return new WdtReissue(options);
|
|
148
150
|
case "BS_RETURN_GOODS":
|
|
149
151
|
return new BsReturn(options);
|
|
152
|
+
case "WDT_RETURN_GOODS":
|
|
153
|
+
return new WdtReturn(options);
|
|
150
154
|
case "REISSUE_TRADE_ID":
|
|
151
155
|
case "BS_DELIVERY_NO":
|
|
152
156
|
case "RETURN_GOODS_TRADE_ID":
|
|
@@ -204,6 +208,8 @@ export var factory = function factory(type, options) {
|
|
|
204
208
|
return new CommonInput(options);
|
|
205
209
|
case "PAYMENT_VOUCHER_CODE":
|
|
206
210
|
return new PaymentVoucherCode(options);
|
|
211
|
+
case "LABEL":
|
|
212
|
+
return new Label(options);
|
|
207
213
|
default:
|
|
208
214
|
return new BasicInput(options);
|
|
209
215
|
}
|
package/dist/esm/index.d.ts
CHANGED
|
@@ -75,8 +75,11 @@ export { default as FlowWorkOrderStatus } from "./components/FlowWorkOrderStatus
|
|
|
75
75
|
export { default as MsgStatus } from "./components/MsgStatus";
|
|
76
76
|
export { default as WdtGoods } from "./components/WDT/WdtGoods";
|
|
77
77
|
export { default as WdtReissue } from "./components/WDT/WdtRessuie";
|
|
78
|
+
export { default as WdtReturn } from "./components/WDT/WdtReturn";
|
|
79
|
+
export { default as WdtExchange } from "./components/WDT/WdtExchange";
|
|
78
80
|
export { default as CommonInput } from "./components/CommonInput";
|
|
79
81
|
export { default as PaymentVoucherCode } from "./components/PaymentVoucherCode";
|
|
82
|
+
export { default as Label } from "./components/Label";
|
|
80
83
|
export { default as KmErpOrderNum } from "./components/ErpTradeId/components/OrderNum";
|
|
81
84
|
export { factory } from "./factory";
|
|
82
85
|
export { default as PlatformAvatar } from "./commonComponents/PlatformAvatar";
|
package/dist/esm/index.js
CHANGED
|
@@ -75,8 +75,11 @@ export { default as FlowWorkOrderStatus } from "./components/FlowWorkOrderStatus
|
|
|
75
75
|
export { default as MsgStatus } from "./components/MsgStatus";
|
|
76
76
|
export { default as WdtGoods } from "./components/WDT/WdtGoods";
|
|
77
77
|
export { default as WdtReissue } from "./components/WDT/WdtRessuie";
|
|
78
|
+
export { default as WdtReturn } from "./components/WDT/WdtReturn";
|
|
79
|
+
export { default as WdtExchange } from "./components/WDT/WdtExchange";
|
|
78
80
|
export { default as CommonInput } from "./components/CommonInput";
|
|
79
81
|
export { default as PaymentVoucherCode } from "./components/PaymentVoucherCode";
|
|
82
|
+
export { default as Label } from "./components/Label";
|
|
80
83
|
// TODO: ERP 打款工单使用
|
|
81
84
|
export { default as KmErpOrderNum } from "./components/ErpTradeId/components/OrderNum";
|
|
82
85
|
export { factory } from "./factory";
|
|
@@ -9,3 +9,4 @@ export declare const queryAllLogisticsCompany: () => Promise<void>;
|
|
|
9
9
|
export declare const queryWdtLogisticsCompany: () => Promise<void>;
|
|
10
10
|
export declare const queryWdtSendData: () => Promise<void>;
|
|
11
11
|
export declare const getAlipayBillReceipt: (data: any) => Promise<any>;
|
|
12
|
+
export declare const queryLabel: () => Promise<any>;
|
package/dist/esm/service/api.js
CHANGED
|
@@ -10,7 +10,7 @@ function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o =
|
|
|
10
10
|
function _iterableToArray(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
|
|
11
11
|
function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToArray(arr); }
|
|
12
12
|
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, WdtSendData, servers, WDT } from "@kmkf-fe-packages/kmkf-utils";
|
|
13
|
+
import { AddressData, toTree, BsAddressData, WdtAddressData, PlatData, ExpressInterceptData, LogisticsAddressData, ExpressData, LabelData, WdtSendData, servers, WDT } from "@kmkf-fe-packages/kmkf-utils";
|
|
14
14
|
import get from "lodash/get";
|
|
15
15
|
import request from "./request";
|
|
16
16
|
// 重复校验
|
|
@@ -267,4 +267,23 @@ export var getAlipayBillReceipt = function getAlipayBillReceipt(data) {
|
|
|
267
267
|
method: "post",
|
|
268
268
|
data: data
|
|
269
269
|
});
|
|
270
|
+
};
|
|
271
|
+
export var queryLabel = function queryLabel() {
|
|
272
|
+
return request({
|
|
273
|
+
url: "/qy/diamond/getConfigInfo",
|
|
274
|
+
method: "get",
|
|
275
|
+
data: {
|
|
276
|
+
key: 'RISK_WARING_LABEL_LIST'
|
|
277
|
+
}
|
|
278
|
+
}).then(function (res) {
|
|
279
|
+
var data = res.data;
|
|
280
|
+
var instance = LabelData.getInstance();
|
|
281
|
+
try {
|
|
282
|
+
var finalData = JSON.parse(data);
|
|
283
|
+
instance.labelData = finalData;
|
|
284
|
+
} catch (e) {
|
|
285
|
+
console.error('转换标签数据数据异常');
|
|
286
|
+
instance.labelData = [];
|
|
287
|
+
}
|
|
288
|
+
});
|
|
270
289
|
};
|
package/dist/esm/type.d.ts
CHANGED
|
@@ -47,10 +47,11 @@ export interface ComponentInterface {
|
|
|
47
47
|
rules?: any[];
|
|
48
48
|
width?: number;
|
|
49
49
|
align?: ALignType;
|
|
50
|
-
dataType:
|
|
51
|
-
format?:
|
|
50
|
+
dataType: "string" | "number" | "boolean" | "array" | "range" | "object";
|
|
51
|
+
format?: "dateTime" | "date" | "time" | "cascader" | "shopInput" | "staffGroup";
|
|
52
52
|
options?: Array<any>;
|
|
53
53
|
templateId?: string;
|
|
54
|
+
flowTemplateKey?: string;
|
|
54
55
|
workOrderUniqueKey?: string;
|
|
55
56
|
platform?: PlatForm;
|
|
56
57
|
parentName?: string;
|
|
@@ -168,6 +169,11 @@ export interface ComponentInterface {
|
|
|
168
169
|
rulesOptions?: Array<any>;
|
|
169
170
|
selectRules?: Array<string>;
|
|
170
171
|
logistics?: string;
|
|
172
|
+
belongType?: string;
|
|
173
|
+
repeatConfig?: {
|
|
174
|
+
repeatRange: string;
|
|
175
|
+
repeatComponents: any[];
|
|
176
|
+
};
|
|
171
177
|
};
|
|
172
178
|
effects?: {
|
|
173
179
|
queryWorkOrderDetail?: (r: Record) => void;
|
|
@@ -236,7 +242,7 @@ export interface ComponentInterface {
|
|
|
236
242
|
getComponentValue: (r: Record) => any;
|
|
237
243
|
formDataTransform?: (r: any) => any;
|
|
238
244
|
}
|
|
239
|
-
export declare type PickOption = Pick<ComponentInterface, "name" | "id" | "type" | "componentConfig" | "effects" | "columnHeader" | "templateId" | "workOrderUniqueKey" | "platform" | "parentName" | "width">;
|
|
245
|
+
export declare type PickOption = Pick<ComponentInterface, "name" | "id" | "type" | "componentConfig" | "effects" | "columnHeader" | "templateId" | "workOrderUniqueKey" | "platform" | "parentName" | "width" | "flowTemplateKey">;
|
|
240
246
|
export declare type ColumnConfig = {
|
|
241
247
|
id: string;
|
|
242
248
|
name: string;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@kmkf-fe-packages/services-components",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.3.0-rc.0",
|
|
4
4
|
"module": "dist/esm/index.js",
|
|
5
5
|
"typings": "dist/esm/index.d.ts",
|
|
6
6
|
"files": [
|
|
@@ -20,8 +20,8 @@
|
|
|
20
20
|
]
|
|
21
21
|
},
|
|
22
22
|
"dependencies": {
|
|
23
|
-
"@kmkf-fe-packages/basic-components": "1.
|
|
24
|
-
"@kmkf-fe-packages/kmkf-utils": "1.
|
|
23
|
+
"@kmkf-fe-packages/basic-components": "1.3.0-rc.0",
|
|
24
|
+
"@kmkf-fe-packages/kmkf-utils": "1.3.0-rc.0"
|
|
25
25
|
},
|
|
26
26
|
"devDependencies": {
|
|
27
27
|
"@typescript-eslint/eslint-plugin": "^5.59.2",
|
|
@@ -37,7 +37,7 @@
|
|
|
37
37
|
"publishConfig": {
|
|
38
38
|
"access": "public"
|
|
39
39
|
},
|
|
40
|
-
"gitHead": "
|
|
40
|
+
"gitHead": "9c12f39cee1a086e3c49778be6c26e64bdc0833b",
|
|
41
41
|
"gitHooks": {
|
|
42
42
|
"pre-commit": "lint-staged"
|
|
43
43
|
}
|