@kmkf-fe-packages/services-components 0.8.17-alpha.34 → 0.8.17-alpha.36
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/dist/esm/components/BS/BsReturn/index.d.ts +54 -0
- package/dist/esm/components/BS/BsReturn/index.js +150 -0
- package/dist/esm/components/BS/common/BsMemo.d.ts +4 -4
- package/dist/esm/components/BS/common/BsMemo.js +15 -14
- package/dist/esm/components/BS/common/BsType.d.ts +4 -4
- package/dist/esm/components/BS/common/BsType.js +13 -12
- package/dist/esm/components/CommonMultiStatus/index.js +23 -21
- package/dist/esm/components/StatusSelect/index.js +14 -0
- package/dist/esm/factory.d.ts +2 -2
- package/dist/esm/factory.js +4 -1
- package/dist/esm/index.d.ts +1 -0
- package/dist/esm/index.js +1 -0
- package/package.json +4 -4
package/README.md
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
### 关于组件后缀
|
|
2
|
-
- 针对于自定义组件的后缀,在提交的时候是以组件类型的驼峰式来命名的
|
|
2
|
+
- 针对于自定义组件的后缀,在提交的时候是以组件类型的驼峰式来命名的
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import { ComponentInterface, PickOption, ColumnConfig, Record } from "../../../type";
|
|
2
|
+
import React from "react";
|
|
3
|
+
import { BsType, BsMemo, BsHeaderGood } from "../common/index";
|
|
4
|
+
declare class BsReturn implements ComponentInterface {
|
|
5
|
+
name: string;
|
|
6
|
+
id: string;
|
|
7
|
+
sortField: string;
|
|
8
|
+
type: string;
|
|
9
|
+
rules: any[];
|
|
10
|
+
componentConfig: ComponentInterface["componentConfig"];
|
|
11
|
+
effects: ComponentInterface["effects"];
|
|
12
|
+
isCombinationComponent: boolean;
|
|
13
|
+
formField: string;
|
|
14
|
+
canSort: boolean;
|
|
15
|
+
children: ComponentInterface[];
|
|
16
|
+
dataType: ComponentInterface["dataType"];
|
|
17
|
+
bsType: BsType;
|
|
18
|
+
bsMemo: BsMemo;
|
|
19
|
+
reissueGoods: BsHeaderGood;
|
|
20
|
+
constructor(options: PickOption);
|
|
21
|
+
renderClient: (record: any) => React.JSX.Element | null;
|
|
22
|
+
renderPc: () => null;
|
|
23
|
+
renderLog: (r: Record) => React.JSX.Element;
|
|
24
|
+
getComponentValue: (r: Record) => any;
|
|
25
|
+
renderExport: () => null;
|
|
26
|
+
editRender: (p: any) => React.JSX.Element;
|
|
27
|
+
filterConfig: (item: ColumnConfig) => ({
|
|
28
|
+
searchDefaultConditions: "in";
|
|
29
|
+
type: string;
|
|
30
|
+
id: string;
|
|
31
|
+
name: string;
|
|
32
|
+
filterComponentType: "Cascader";
|
|
33
|
+
props: {
|
|
34
|
+
options: any[] | undefined;
|
|
35
|
+
fieldNames: {
|
|
36
|
+
label: string;
|
|
37
|
+
value: string;
|
|
38
|
+
children: string;
|
|
39
|
+
};
|
|
40
|
+
};
|
|
41
|
+
formatFilterValue: (val: Array<string>) => string[] | undefined;
|
|
42
|
+
filterFn: (value: string) => (i: Record) => boolean;
|
|
43
|
+
} | {
|
|
44
|
+
searchDefaultConditions: "like";
|
|
45
|
+
type: string;
|
|
46
|
+
id: string;
|
|
47
|
+
name: string;
|
|
48
|
+
filterComponentType: "Input";
|
|
49
|
+
props?: undefined;
|
|
50
|
+
formatFilterValue?: undefined;
|
|
51
|
+
filterFn?: undefined;
|
|
52
|
+
})[];
|
|
53
|
+
}
|
|
54
|
+
export default BsReturn;
|
|
@@ -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 { BsReturn as BsReturnGoods } from "@kmkf-fe-packages/basic-components";
|
|
16
|
+
import { SYMBOL } from "../../../constant";
|
|
17
|
+
import { BsGoodsTable } from "../../Common";
|
|
18
|
+
import { BsType, BsMemo, BsHeaderGood } from "../common/index";
|
|
19
|
+
var BsReturn = /*#__PURE__*/_createClass(function BsReturn(options) {
|
|
20
|
+
var _this = this,
|
|
21
|
+
_this$componentConfig4;
|
|
22
|
+
_classCallCheck(this, BsReturn);
|
|
23
|
+
_defineProperty(this, "name", void 0);
|
|
24
|
+
_defineProperty(this, "id", void 0);
|
|
25
|
+
_defineProperty(this, "sortField", void 0);
|
|
26
|
+
_defineProperty(this, "type", void 0);
|
|
27
|
+
_defineProperty(this, "rules", void 0);
|
|
28
|
+
_defineProperty(this, "componentConfig", void 0);
|
|
29
|
+
_defineProperty(this, "effects", void 0);
|
|
30
|
+
_defineProperty(this, "isCombinationComponent", void 0);
|
|
31
|
+
_defineProperty(this, "formField", void 0);
|
|
32
|
+
_defineProperty(this, "canSort", void 0);
|
|
33
|
+
_defineProperty(this, "children", void 0);
|
|
34
|
+
_defineProperty(this, "dataType", void 0);
|
|
35
|
+
_defineProperty(this, "bsType", void 0);
|
|
36
|
+
_defineProperty(this, "bsMemo", 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.bsType.renderClient(record), _this.bsMemo.renderClient(record), record !== null && record !== void 0 && record["".concat(_this.id)].bsReturnGoods.length ? /*#__PURE__*/React.createElement(ItemView, {
|
|
41
|
+
id: _this.id,
|
|
42
|
+
label: _this.name,
|
|
43
|
+
value: /*#__PURE__*/React.createElement(BsGoodsTable, {
|
|
44
|
+
list: (record === null || record === void 0 ? void 0 : record["".concat(_this.id)].bsReturnGoods) || [],
|
|
45
|
+
showHeader: ((_this$componentConfig = _this.componentConfig) === null || _this$componentConfig === void 0 ? void 0 : _this$componentConfig.showHeader) || []
|
|
46
|
+
})
|
|
47
|
+
}) : null) : null;
|
|
48
|
+
});
|
|
49
|
+
_defineProperty(this, "renderPc", function () {
|
|
50
|
+
return null;
|
|
51
|
+
});
|
|
52
|
+
_defineProperty(this, "renderLog", function (r) {
|
|
53
|
+
var _this$componentConfig2;
|
|
54
|
+
return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("div", null, "\u5907\u6CE8\u7C7B\u578B:", _this.bsType.renderLog(r)), /*#__PURE__*/React.createElement("div", null, "\u5907\u6CE8\u4FE1\u606F:", _this.bsMemo.renderLog(r)), /*#__PURE__*/React.createElement("div", null, "\u5546\u54C1\uFF1A", /*#__PURE__*/React.createElement(BsGoodsTable, {
|
|
55
|
+
list: (r === null || r === void 0 ? void 0 : r["".concat(_this.id, "_bsReturnGoods")]) || [],
|
|
56
|
+
showHeader: ((_this$componentConfig2 = _this.componentConfig) === null || _this$componentConfig2 === void 0 ? void 0 : _this$componentConfig2.showHeader) || []
|
|
57
|
+
})));
|
|
58
|
+
});
|
|
59
|
+
_defineProperty(this, "getComponentValue", function (r) {
|
|
60
|
+
return r === null || r === void 0 ? void 0 : r["".concat(_this.id, "_bsReturnGoods")];
|
|
61
|
+
});
|
|
62
|
+
_defineProperty(this, "renderExport", function () {
|
|
63
|
+
return null;
|
|
64
|
+
});
|
|
65
|
+
_defineProperty(this, "editRender", function (p) {
|
|
66
|
+
var _this$componentConfig3, _this$effects, _this$effects2, _this$effects3;
|
|
67
|
+
return /*#__PURE__*/React.createElement(GetFormItem, {
|
|
68
|
+
title: _this.name,
|
|
69
|
+
name: _this.id,
|
|
70
|
+
rules: _this.rules,
|
|
71
|
+
required: false,
|
|
72
|
+
hidden: p === null || p === void 0 ? void 0 : p.hidden,
|
|
73
|
+
component: /*#__PURE__*/React.createElement(BsReturnGoods, _extends({}, _this.componentConfig, {
|
|
74
|
+
maxLength: ((_this$componentConfig3 = _this.componentConfig) === null || _this$componentConfig3 === void 0 ? void 0 : _this$componentConfig3.maxLength) || 20,
|
|
75
|
+
shopId: (_this$effects = _this.effects) === null || _this$effects === void 0 ? void 0 : _this$effects.shopId,
|
|
76
|
+
shopList: ((_this$effects2 = _this.effects) === null || _this$effects2 === void 0 ? void 0 : _this$effects2.shopList) || [],
|
|
77
|
+
companyKey: (_this$effects3 = _this.effects) === null || _this$effects3 === void 0 ? void 0 : _this$effects3.companyKey,
|
|
78
|
+
width: "90%"
|
|
79
|
+
}))
|
|
80
|
+
});
|
|
81
|
+
});
|
|
82
|
+
_defineProperty(this, "filterConfig", function (item) {
|
|
83
|
+
var _item$templateConfig;
|
|
84
|
+
return [{
|
|
85
|
+
searchDefaultConditions: SYMBOL.in,
|
|
86
|
+
type: item.type,
|
|
87
|
+
id: "".concat(item.id, "_bsReturnType"),
|
|
88
|
+
name: "".concat(item.name, "-\u9000\u8D27\u7C7B\u578B"),
|
|
89
|
+
filterComponentType: "Cascader",
|
|
90
|
+
props: {
|
|
91
|
+
options: item === null || item === void 0 ? void 0 : (_item$templateConfig = item.templateConfig) === null || _item$templateConfig === void 0 ? void 0 : _item$templateConfig.reasonList,
|
|
92
|
+
fieldNames: {
|
|
93
|
+
label: "label",
|
|
94
|
+
value: "value",
|
|
95
|
+
children: "children"
|
|
96
|
+
}
|
|
97
|
+
},
|
|
98
|
+
formatFilterValue: function formatFilterValue(val) {
|
|
99
|
+
if ((val === null || val === void 0 ? void 0 : val.length) > 0) {
|
|
100
|
+
return [val[val.length - 1]];
|
|
101
|
+
}
|
|
102
|
+
},
|
|
103
|
+
filterFn: function filterFn(value) {
|
|
104
|
+
return function (i) {
|
|
105
|
+
return _filterFn.filterSplitComma(_filterFn.filterTableListItemColumnValue(i, item.id, "bsReturnType"), value);
|
|
106
|
+
};
|
|
107
|
+
}
|
|
108
|
+
}, {
|
|
109
|
+
searchDefaultConditions: SYMBOL.like,
|
|
110
|
+
type: item.type,
|
|
111
|
+
id: "".concat(item.id, "_bsReturnGoods"),
|
|
112
|
+
name: "".concat(_this.name),
|
|
113
|
+
filterComponentType: "Input"
|
|
114
|
+
}];
|
|
115
|
+
});
|
|
116
|
+
this.name = options.name;
|
|
117
|
+
this.id = options.id;
|
|
118
|
+
this.sortField = "".concat(options.id);
|
|
119
|
+
this.formField = "".concat(options.id);
|
|
120
|
+
this.type = options.type;
|
|
121
|
+
this.effects = options === null || options === void 0 ? void 0 : options.effects;
|
|
122
|
+
this.isCombinationComponent = true;
|
|
123
|
+
this.canSort = false;
|
|
124
|
+
this.bsType = new BsType(_objectSpread(_objectSpread({}, options), {}, {
|
|
125
|
+
id: "".concat(options.id, "_bsReturnType"),
|
|
126
|
+
name: "退货类型"
|
|
127
|
+
}));
|
|
128
|
+
this.bsMemo = new BsMemo(_objectSpread(_objectSpread({}, options), {}, {
|
|
129
|
+
id: "".concat(options.id, "_bsReturnType_memo"),
|
|
130
|
+
name: "退货备注"
|
|
131
|
+
}));
|
|
132
|
+
this.reissueGoods = new BsHeaderGood(_objectSpread(_objectSpread({}, options), {}, {
|
|
133
|
+
id: "".concat(options.id, "_bsReturnGoods"),
|
|
134
|
+
name: "商品信息"
|
|
135
|
+
}));
|
|
136
|
+
this.children = [this.bsType, this.bsMemo, 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$bsReturnGoods;
|
|
142
|
+
if (!value || !(value !== null && value !== void 0 && (_value$bsReturnGoods = value.bsReturnGoods) !== null && _value$bsReturnGoods !== void 0 && _value$bsReturnGoods.length)) {
|
|
143
|
+
return Promise.reject(new Error("请选择bs退货商品"));
|
|
144
|
+
}
|
|
145
|
+
return Promise.resolve();
|
|
146
|
+
}
|
|
147
|
+
}] : [];
|
|
148
|
+
this.dataType = "object";
|
|
149
|
+
});
|
|
150
|
+
export default BsReturn;
|
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
import { ComponentInterface, PickOption, ALignType, Record } from
|
|
2
|
-
import React from
|
|
1
|
+
import { ComponentInterface, PickOption, ALignType, Record } from "../../../type";
|
|
2
|
+
import React from "react";
|
|
3
3
|
declare class BsMemo implements ComponentInterface {
|
|
4
4
|
name: string;
|
|
5
5
|
id: string;
|
|
6
6
|
sortField: string;
|
|
7
7
|
type: string;
|
|
8
|
-
componentConfig: ComponentInterface[
|
|
8
|
+
componentConfig: ComponentInterface["componentConfig"];
|
|
9
9
|
align: ALignType;
|
|
10
10
|
width: number;
|
|
11
11
|
isCombinationComponent: boolean;
|
|
12
12
|
formField: string;
|
|
13
13
|
canSort: boolean;
|
|
14
14
|
children: ComponentInterface[];
|
|
15
|
-
dataType: ComponentInterface[
|
|
15
|
+
dataType: ComponentInterface["dataType"];
|
|
16
16
|
constructor(options: PickOption);
|
|
17
17
|
getParentId: () => string;
|
|
18
18
|
renderClient: (r: any) => React.JSX.Element | null;
|
|
@@ -11,12 +11,13 @@ function _classCallCheck(instance, Constructor) { if (!(instance instanceof Cons
|
|
|
11
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
12
|
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
|
|
13
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
|
|
14
|
+
import React from "react";
|
|
15
15
|
import ItemView from "../../../commonComponents/ItemView";
|
|
16
|
-
import { isNull } from
|
|
16
|
+
import { isNull } from "@kmkf-fe-packages/kmkf-utils";
|
|
17
17
|
var componentType = {
|
|
18
|
-
BS_EXCHANGE_GOODS:
|
|
19
|
-
BS_REISSUE_GOODS:
|
|
18
|
+
BS_EXCHANGE_GOODS: "bsExchangeType",
|
|
19
|
+
BS_REISSUE_GOODS: "bsReissueType",
|
|
20
|
+
BS_RETURN_GOODS: "bsReturnType"
|
|
20
21
|
};
|
|
21
22
|
var BsMemo = /*#__PURE__*/_createClass(function BsMemo(options) {
|
|
22
23
|
var _this = this;
|
|
@@ -34,7 +35,7 @@ var BsMemo = /*#__PURE__*/_createClass(function BsMemo(options) {
|
|
|
34
35
|
_defineProperty(this, "children", void 0);
|
|
35
36
|
_defineProperty(this, "dataType", void 0);
|
|
36
37
|
_defineProperty(this, "getParentId", function () {
|
|
37
|
-
var _this$id$split = _this.id.split(
|
|
38
|
+
var _this$id$split = _this.id.split("_"),
|
|
38
39
|
_this$id$split2 = _slicedToArray(_this$id$split, 2),
|
|
39
40
|
key = _this$id$split2[0],
|
|
40
41
|
name = _this$id$split2[1];
|
|
@@ -42,14 +43,14 @@ var BsMemo = /*#__PURE__*/_createClass(function BsMemo(options) {
|
|
|
42
43
|
});
|
|
43
44
|
_defineProperty(this, "renderClient", function (r) {
|
|
44
45
|
var _r$key$componentType$, _r$key, _r$key$componentType$2, _r$key2, _r$key2$componentType, _find, _this$componentConfig, _find2;
|
|
45
|
-
var _this$getParentId$spl = _this.getParentId().split(
|
|
46
|
+
var _this$getParentId$spl = _this.getParentId().split("_"),
|
|
46
47
|
_this$getParentId$spl2 = _slicedToArray(_this$getParentId$spl, 1),
|
|
47
48
|
key = _this$getParentId$spl2[0];
|
|
48
49
|
if (!(r !== null && r !== void 0 && (_r$key$componentType$ = r[key][componentType[_this.type]]) !== null && _r$key$componentType$ !== void 0 && _r$key$componentType$.length)) {
|
|
49
50
|
return null;
|
|
50
51
|
}
|
|
51
|
-
var type = r !== null && r !== void 0 && r[key] ? r === null || r === void 0 ? void 0 : (_r$key = r[key]) === null || _r$key === void 0 ? void 0 : (_r$key$componentType$2 = _r$key[componentType[_this.type]]) === null || _r$key$componentType$2 === void 0 ? void 0 : _r$key$componentType$2[0] :
|
|
52
|
-
var memo = r !== null && r !== void 0 && r[key] ? r === null || r === void 0 ? void 0 : (_r$key2 = r[key]) === null || _r$key2 === void 0 ? void 0 : (_r$key2$componentType = _r$key2[componentType[_this.type]]) === null || _r$key2$componentType === void 0 ? void 0 : _r$key2$componentType[1] :
|
|
52
|
+
var type = r !== null && r !== void 0 && r[key] ? r === null || r === void 0 ? void 0 : (_r$key = r[key]) === null || _r$key === void 0 ? void 0 : (_r$key$componentType$2 = _r$key[componentType[_this.type]]) === null || _r$key$componentType$2 === void 0 ? void 0 : _r$key$componentType$2[0] : "";
|
|
53
|
+
var memo = r !== null && r !== void 0 && r[key] ? r === null || r === void 0 ? void 0 : (_r$key2 = r[key]) === null || _r$key2 === void 0 ? void 0 : (_r$key2$componentType = _r$key2[componentType[_this.type]]) === null || _r$key2$componentType === void 0 ? void 0 : _r$key2$componentType[1] : "";
|
|
53
54
|
var children = (_find = (((_this$componentConfig = _this.componentConfig) === null || _this$componentConfig === void 0 ? void 0 : _this$componentConfig.reasonList) || []).find(function (item) {
|
|
54
55
|
return item.value === type;
|
|
55
56
|
})) === null || _find === void 0 ? void 0 : _find.children;
|
|
@@ -64,7 +65,7 @@ var BsMemo = /*#__PURE__*/_createClass(function BsMemo(options) {
|
|
|
64
65
|
});
|
|
65
66
|
_defineProperty(this, "renderPc", function (value, record) {
|
|
66
67
|
var _this$getComponentVal;
|
|
67
|
-
return /*#__PURE__*/React.createElement("span", null, (_this$getComponentVal = _this.getComponentValue(record)) !== null && _this$getComponentVal !== void 0 ? _this$getComponentVal :
|
|
68
|
+
return /*#__PURE__*/React.createElement("span", null, (_this$getComponentVal = _this.getComponentValue(record)) !== null && _this$getComponentVal !== void 0 ? _this$getComponentVal : "--");
|
|
68
69
|
});
|
|
69
70
|
_defineProperty(this, "renderLog", function (r) {
|
|
70
71
|
var id = _this.getParentId();
|
|
@@ -74,8 +75,8 @@ var BsMemo = /*#__PURE__*/_createClass(function BsMemo(options) {
|
|
|
74
75
|
_defineProperty(this, "getComponentValue", function (r) {
|
|
75
76
|
var _r$id, _r$id2, _find3, _this$componentConfig2, _find4;
|
|
76
77
|
var id = _this.getParentId();
|
|
77
|
-
var type = r !== null && r !== void 0 && r[id] ? r === null || r === void 0 ? void 0 : (_r$id = r[id]) === null || _r$id === void 0 ? void 0 : _r$id[0] :
|
|
78
|
-
var memo = r !== null && r !== void 0 && r[id] ? r === null || r === void 0 ? void 0 : (_r$id2 = r[id]) === null || _r$id2 === void 0 ? void 0 : _r$id2[1] :
|
|
78
|
+
var type = r !== null && r !== void 0 && r[id] ? r === null || r === void 0 ? void 0 : (_r$id = r[id]) === null || _r$id === void 0 ? void 0 : _r$id[0] : "";
|
|
79
|
+
var memo = r !== null && r !== void 0 && r[id] ? r === null || r === void 0 ? void 0 : (_r$id2 = r[id]) === null || _r$id2 === void 0 ? void 0 : _r$id2[1] : "";
|
|
79
80
|
var children = (_find3 = (((_this$componentConfig2 = _this.componentConfig) === null || _this$componentConfig2 === void 0 ? void 0 : _this$componentConfig2.reasonList) || []).find(function (item) {
|
|
80
81
|
return item.value === type;
|
|
81
82
|
})) === null || _find3 === void 0 ? void 0 : _find3.children;
|
|
@@ -86,7 +87,7 @@ var BsMemo = /*#__PURE__*/_createClass(function BsMemo(options) {
|
|
|
86
87
|
});
|
|
87
88
|
_defineProperty(this, "renderExport", function (value, record) {
|
|
88
89
|
var _this$getComponentVal2;
|
|
89
|
-
return (_this$getComponentVal2 = _this.getComponentValue(record)) !== null && _this$getComponentVal2 !== void 0 ? _this$getComponentVal2 :
|
|
90
|
+
return (_this$getComponentVal2 = _this.getComponentValue(record)) !== null && _this$getComponentVal2 !== void 0 ? _this$getComponentVal2 : "--";
|
|
90
91
|
});
|
|
91
92
|
_defineProperty(this, "editRender", function () {
|
|
92
93
|
return null;
|
|
@@ -100,11 +101,11 @@ var BsMemo = /*#__PURE__*/_createClass(function BsMemo(options) {
|
|
|
100
101
|
this.formField = options.id;
|
|
101
102
|
this.type = options.type;
|
|
102
103
|
this.componentConfig = options.componentConfig;
|
|
103
|
-
this.align =
|
|
104
|
+
this.align = "left";
|
|
104
105
|
this.width = 140;
|
|
105
106
|
this.isCombinationComponent = false;
|
|
106
107
|
this.canSort = false;
|
|
107
|
-
this.dataType =
|
|
108
|
+
this.dataType = "string";
|
|
108
109
|
this.children = [];
|
|
109
110
|
});
|
|
110
111
|
export default BsMemo;
|
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
import { ComponentInterface, PickOption, ColumnConfig, ALignType, Record } from
|
|
2
|
-
import React from
|
|
1
|
+
import { ComponentInterface, PickOption, ColumnConfig, ALignType, Record } from "../../../type";
|
|
2
|
+
import React from "react";
|
|
3
3
|
declare class BsType implements ComponentInterface {
|
|
4
4
|
name: string;
|
|
5
5
|
id: string;
|
|
6
6
|
sortField: string;
|
|
7
7
|
type: string;
|
|
8
|
-
componentConfig: ComponentInterface[
|
|
8
|
+
componentConfig: ComponentInterface["componentConfig"];
|
|
9
9
|
align: ALignType;
|
|
10
10
|
width: number;
|
|
11
11
|
isCombinationComponent: boolean;
|
|
12
12
|
formField: string;
|
|
13
13
|
canSort: boolean;
|
|
14
14
|
children: ComponentInterface[];
|
|
15
|
-
dataType: ComponentInterface[
|
|
15
|
+
dataType: ComponentInterface["dataType"];
|
|
16
16
|
constructor(options: PickOption);
|
|
17
17
|
getParentId: () => string;
|
|
18
18
|
renderClient: (record: any) => React.JSX.Element | null;
|
|
@@ -11,13 +11,14 @@ function _classCallCheck(instance, Constructor) { if (!(instance instanceof Cons
|
|
|
11
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
12
|
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
|
|
13
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
|
|
14
|
+
import React from "react";
|
|
15
15
|
import ItemView from "../../../commonComponents/ItemView";
|
|
16
|
-
import { isNull, filterFn as _filterFn } from
|
|
16
|
+
import { isNull, filterFn as _filterFn } from "@kmkf-fe-packages/kmkf-utils";
|
|
17
17
|
import { SYMBOL } from "../../../constant";
|
|
18
18
|
var componentType = {
|
|
19
|
-
BS_EXCHANGE_GOODS:
|
|
20
|
-
BS_REISSUE_GOODS:
|
|
19
|
+
BS_EXCHANGE_GOODS: "bsExchangeType",
|
|
20
|
+
BS_REISSUE_GOODS: "bsReissueType",
|
|
21
|
+
BS_RETURN_GOODS: "bsReturnType"
|
|
21
22
|
};
|
|
22
23
|
var BsType = /*#__PURE__*/_createClass(function BsType(options) {
|
|
23
24
|
var _this = this;
|
|
@@ -35,7 +36,7 @@ var BsType = /*#__PURE__*/_createClass(function BsType(options) {
|
|
|
35
36
|
_defineProperty(this, "children", void 0);
|
|
36
37
|
_defineProperty(this, "dataType", void 0);
|
|
37
38
|
_defineProperty(this, "getParentId", function () {
|
|
38
|
-
var _this$id$split = _this.id.split(
|
|
39
|
+
var _this$id$split = _this.id.split("_"),
|
|
39
40
|
_this$id$split2 = _slicedToArray(_this$id$split, 2),
|
|
40
41
|
key = _this$id$split2[0],
|
|
41
42
|
name = _this$id$split2[1];
|
|
@@ -43,7 +44,7 @@ var BsType = /*#__PURE__*/_createClass(function BsType(options) {
|
|
|
43
44
|
});
|
|
44
45
|
_defineProperty(this, "renderClient", function (record) {
|
|
45
46
|
var _record$key$component, _find, _this$componentConfig;
|
|
46
|
-
var _this$getParentId$spl = _this.getParentId().split(
|
|
47
|
+
var _this$getParentId$spl = _this.getParentId().split("_"),
|
|
47
48
|
_this$getParentId$spl2 = _slicedToArray(_this$getParentId$spl, 1),
|
|
48
49
|
key = _this$getParentId$spl2[0];
|
|
49
50
|
if (!(record !== null && record !== void 0 && (_record$key$component = record[key][componentType[_this.type]]) !== null && _record$key$component !== void 0 && _record$key$component.length)) {
|
|
@@ -61,7 +62,7 @@ var BsType = /*#__PURE__*/_createClass(function BsType(options) {
|
|
|
61
62
|
});
|
|
62
63
|
_defineProperty(this, "renderPc", function (value, record) {
|
|
63
64
|
var _this$getComponentVal;
|
|
64
|
-
return /*#__PURE__*/React.createElement("span", null, (_this$getComponentVal = _this.getComponentValue(record)) !== null && _this$getComponentVal !== void 0 ? _this$getComponentVal :
|
|
65
|
+
return /*#__PURE__*/React.createElement("span", null, (_this$getComponentVal = _this.getComponentValue(record)) !== null && _this$getComponentVal !== void 0 ? _this$getComponentVal : "--");
|
|
65
66
|
});
|
|
66
67
|
_defineProperty(this, "renderLog", function (r) {
|
|
67
68
|
var id = _this.getParentId();
|
|
@@ -71,7 +72,7 @@ var BsType = /*#__PURE__*/_createClass(function BsType(options) {
|
|
|
71
72
|
_defineProperty(this, "getComponentValue", function (r) {
|
|
72
73
|
var _r$id, _find2, _this$componentConfig2;
|
|
73
74
|
var id = _this.getParentId();
|
|
74
|
-
var type = r !== null && r !== void 0 && r[id] ? r === null || r === void 0 ? void 0 : (_r$id = r[id]) === null || _r$id === void 0 ? void 0 : _r$id[0] :
|
|
75
|
+
var type = r !== null && r !== void 0 && r[id] ? r === null || r === void 0 ? void 0 : (_r$id = r[id]) === null || _r$id === void 0 ? void 0 : _r$id[0] : "";
|
|
75
76
|
var text = (_find2 = (((_this$componentConfig2 = _this.componentConfig) === null || _this$componentConfig2 === void 0 ? void 0 : _this$componentConfig2.reasonList) || []).find(function (item) {
|
|
76
77
|
return item.value === type;
|
|
77
78
|
})) === null || _find2 === void 0 ? void 0 : _find2.label;
|
|
@@ -79,7 +80,7 @@ var BsType = /*#__PURE__*/_createClass(function BsType(options) {
|
|
|
79
80
|
});
|
|
80
81
|
_defineProperty(this, "renderExport", function (value, record) {
|
|
81
82
|
var _this$getComponentVal2;
|
|
82
|
-
return (_this$getComponentVal2 = _this.getComponentValue(record)) !== null && _this$getComponentVal2 !== void 0 ? _this$getComponentVal2 :
|
|
83
|
+
return (_this$getComponentVal2 = _this.getComponentValue(record)) !== null && _this$getComponentVal2 !== void 0 ? _this$getComponentVal2 : "--";
|
|
83
84
|
});
|
|
84
85
|
_defineProperty(this, "editRender", function () {
|
|
85
86
|
return null;
|
|
@@ -93,7 +94,7 @@ var BsType = /*#__PURE__*/_createClass(function BsType(options) {
|
|
|
93
94
|
type: item.type,
|
|
94
95
|
id: _this.id,
|
|
95
96
|
name: "".concat(item.name, "-\u7C7B\u578B"),
|
|
96
|
-
filterComponentType:
|
|
97
|
+
filterComponentType: "Cascader",
|
|
97
98
|
props: {
|
|
98
99
|
options: (item === null || item === void 0 ? void 0 : (_item$config = item.config) === null || _item$config === void 0 ? void 0 : _item$config.reasonList) || []
|
|
99
100
|
},
|
|
@@ -115,11 +116,11 @@ var BsType = /*#__PURE__*/_createClass(function BsType(options) {
|
|
|
115
116
|
this.formField = options.id;
|
|
116
117
|
this.type = options.type;
|
|
117
118
|
this.componentConfig = options.componentConfig;
|
|
118
|
-
this.align =
|
|
119
|
+
this.align = "left";
|
|
119
120
|
this.width = 140;
|
|
120
121
|
this.isCombinationComponent = false;
|
|
121
122
|
this.canSort = false;
|
|
122
|
-
this.dataType =
|
|
123
|
+
this.dataType = "string";
|
|
123
124
|
this.children = [];
|
|
124
125
|
});
|
|
125
126
|
export default BsType;
|
|
@@ -70,7 +70,7 @@ var CommonMultiStatus = /*#__PURE__*/_createClass(function CommonMultiStatus(opt
|
|
|
70
70
|
}) : null;
|
|
71
71
|
});
|
|
72
72
|
_defineProperty(this, "renderPc", function (value, record) {
|
|
73
|
-
var _typeMap$_this$type4, _typeMap$_this$type5;
|
|
73
|
+
var _typeMap$_this$type4, _typeMap$_this$type5, _typeMap$_this$type6, _typeMap$_this$type7;
|
|
74
74
|
var list = record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_").concat((_typeMap$_this$type4 = typeMap[_this.type]) === null || _typeMap$_this$type4 === void 0 ? void 0 : _typeMap$_this$type4.key)];
|
|
75
75
|
//兼容多个商品
|
|
76
76
|
return /*#__PURE__*/React.createElement("span", {
|
|
@@ -78,30 +78,32 @@ var CommonMultiStatus = /*#__PURE__*/_createClass(function CommonMultiStatus(opt
|
|
|
78
78
|
return e.stopPropagation();
|
|
79
79
|
}
|
|
80
80
|
}, /*#__PURE__*/React.createElement(CommonOrderContent, {
|
|
81
|
-
list:
|
|
82
|
-
|
|
81
|
+
list: record === null || record === void 0 ? void 0 : record[_this.id],
|
|
82
|
+
valueKey: (_typeMap$_this$type5 = typeMap[_this.type]) === null || _typeMap$_this$type5 === void 0 ? void 0 : _typeMap$_this$type5.valueKey,
|
|
83
|
+
failValue: (_typeMap$_this$type6 = typeMap[_this.type]) === null || _typeMap$_this$type6 === void 0 ? void 0 : _typeMap$_this$type6.failValue,
|
|
84
|
+
options: (_typeMap$_this$type7 = typeMap[_this.type]) === null || _typeMap$_this$type7 === void 0 ? void 0 : _typeMap$_this$type7.options
|
|
83
85
|
}));
|
|
84
86
|
});
|
|
85
87
|
_defineProperty(this, "renderLog", function (r) {
|
|
86
|
-
var _typeMap$_this$
|
|
87
|
-
var list = r === null || r === void 0 ? void 0 : r["".concat(_this.id, "_").concat((_typeMap$_this$
|
|
88
|
+
var _typeMap$_this$type8;
|
|
89
|
+
var list = r === null || r === void 0 ? void 0 : r["".concat(_this.id, "_").concat((_typeMap$_this$type8 = typeMap[_this.type]) === null || _typeMap$_this$type8 === void 0 ? void 0 : _typeMap$_this$type8.key)];
|
|
88
90
|
if (isNull(list)) return null;
|
|
89
91
|
return _this.renderPc(undefined, r);
|
|
90
92
|
});
|
|
91
93
|
_defineProperty(this, "getComponentValue", function (r) {
|
|
92
|
-
var _typeMap$_this$
|
|
93
|
-
return r === null || r === void 0 ? void 0 : r["".concat(_this.id, "_").concat((_typeMap$_this$
|
|
94
|
+
var _typeMap$_this$type9;
|
|
95
|
+
return r === null || r === void 0 ? void 0 : r["".concat(_this.id, "_").concat((_typeMap$_this$type9 = typeMap[_this.type]) === null || _typeMap$_this$type9 === void 0 ? void 0 : _typeMap$_this$type9.key)];
|
|
94
96
|
});
|
|
95
97
|
_defineProperty(this, "renderExport", function (value, record) {
|
|
96
|
-
var _typeMap$_this$
|
|
97
|
-
var list = record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_").concat((_typeMap$_this$
|
|
98
|
+
var _typeMap$_this$type10;
|
|
99
|
+
var list = record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_").concat((_typeMap$_this$type10 = typeMap[_this.type]) === null || _typeMap$_this$type10 === void 0 ? void 0 : _typeMap$_this$type10.key)];
|
|
98
100
|
return (list || []).map(function (item) {
|
|
99
|
-
var _typeMap$_this$
|
|
100
|
-
return item === null || item === void 0 ? void 0 : item[(_typeMap$_this$
|
|
101
|
+
var _typeMap$_this$type11;
|
|
102
|
+
return item === null || item === void 0 ? void 0 : item[(_typeMap$_this$type11 = typeMap[_this.type]) === null || _typeMap$_this$type11 === void 0 ? void 0 : _typeMap$_this$type11.valueKey];
|
|
101
103
|
}).join(",");
|
|
102
104
|
});
|
|
103
105
|
_defineProperty(this, "editRender", function (p) {
|
|
104
|
-
var _this$componentConfig, _this$componentConfig2, _typeMap$_this$
|
|
106
|
+
var _this$componentConfig, _this$componentConfig2, _typeMap$_this$type12;
|
|
105
107
|
return /*#__PURE__*/React.createElement(GetFormItem, {
|
|
106
108
|
title: _this.name,
|
|
107
109
|
name: _this.id,
|
|
@@ -109,23 +111,23 @@ var CommonMultiStatus = /*#__PURE__*/_createClass(function CommonMultiStatus(opt
|
|
|
109
111
|
hidden: p === null || p === void 0 ? void 0 : p.hidden,
|
|
110
112
|
required: (_this$componentConfig = (_this$componentConfig2 = _this.componentConfig) === null || _this$componentConfig2 === void 0 ? void 0 : _this$componentConfig2.required) !== null && _this$componentConfig !== void 0 ? _this$componentConfig : false,
|
|
111
113
|
component: /*#__PURE__*/React.createElement(Status, _extends({}, _this.componentConfig, {
|
|
112
|
-
type: (_typeMap$_this$
|
|
114
|
+
type: (_typeMap$_this$type12 = typeMap[_this.type]) === null || _typeMap$_this$type12 === void 0 ? void 0 : _typeMap$_this$type12.type,
|
|
113
115
|
failValue: typeMap[_this.type].failValue
|
|
114
116
|
}))
|
|
115
117
|
});
|
|
116
118
|
});
|
|
117
119
|
_defineProperty(this, "filterConfig", function (item) {
|
|
118
|
-
var _typeMap$_this$
|
|
120
|
+
var _typeMap$_this$type13;
|
|
119
121
|
return [{
|
|
120
122
|
searchDefaultConditions: SYMBOL.like,
|
|
121
123
|
type: item.type,
|
|
122
|
-
id: "".concat(item.id, "_").concat((_typeMap$_this$
|
|
124
|
+
id: "".concat(item.id, "_").concat((_typeMap$_this$type13 = typeMap[_this.type]) === null || _typeMap$_this$type13 === void 0 ? void 0 : _typeMap$_this$type13.code),
|
|
123
125
|
name: "".concat(_this.name),
|
|
124
126
|
filterComponentType: "Input",
|
|
125
127
|
filterFn: function filterFn(value) {
|
|
126
128
|
return function (i) {
|
|
127
|
-
var _typeMap$_this$
|
|
128
|
-
return _filterFn.filterSplitComma(_filterFn.filterTableListItemColumnValue(i, item.id, (_typeMap$_this$
|
|
129
|
+
var _typeMap$_this$type14;
|
|
130
|
+
return _filterFn.filterSplitComma(_filterFn.filterTableListItemColumnValue(i, item.id, (_typeMap$_this$type14 = typeMap[_this.type]) === null || _typeMap$_this$type14 === void 0 ? void 0 : _typeMap$_this$type14.code), value);
|
|
129
131
|
};
|
|
130
132
|
}
|
|
131
133
|
}];
|
|
@@ -146,12 +148,12 @@ var CommonMultiStatus = /*#__PURE__*/_createClass(function CommonMultiStatus(opt
|
|
|
146
148
|
required: true,
|
|
147
149
|
validator: function validator(_, value) {
|
|
148
150
|
var hasNo = (value || []).some(function (item) {
|
|
149
|
-
var _typeMap$_this$
|
|
150
|
-
return item[(_typeMap$_this$
|
|
151
|
+
var _typeMap$_this$type15;
|
|
152
|
+
return item[(_typeMap$_this$type15 = typeMap[_this.type]) === null || _typeMap$_this$type15 === void 0 ? void 0 : _typeMap$_this$type15.valueKey];
|
|
151
153
|
});
|
|
152
154
|
if (!hasNo) {
|
|
153
|
-
var _typeMap$_this$
|
|
154
|
-
return Promise.reject(new Error("\u81F3\u5C11\u586B\u5199\u4E00\u4E2A\u5B8C\u6574\u7684".concat((_typeMap$_this$
|
|
155
|
+
var _typeMap$_this$type16;
|
|
156
|
+
return Promise.reject(new Error("\u81F3\u5C11\u586B\u5199\u4E00\u4E2A\u5B8C\u6574\u7684".concat((_typeMap$_this$type16 = typeMap[_this.type]) === null || _typeMap$_this$type16 === void 0 ? void 0 : _typeMap$_this$type16.name)));
|
|
155
157
|
}
|
|
156
158
|
return Promise.resolve();
|
|
157
159
|
}
|
|
@@ -57,6 +57,20 @@ var selectTypeMap = {
|
|
|
57
57
|
key: "adjustWorkOrderStatusValue",
|
|
58
58
|
info: "adjustWorkOrderReason",
|
|
59
59
|
failValue: "失败"
|
|
60
|
+
},
|
|
61
|
+
CREATE_STATUS: {
|
|
62
|
+
options: [{
|
|
63
|
+
value: "成功",
|
|
64
|
+
label: "成功",
|
|
65
|
+
color: "#52c41a"
|
|
66
|
+
}, {
|
|
67
|
+
value: "失败",
|
|
68
|
+
label: "失败",
|
|
69
|
+
color: "#ff4d4f"
|
|
70
|
+
}],
|
|
71
|
+
key: "createStatusValue",
|
|
72
|
+
info: "createReason",
|
|
73
|
+
failValue: "失败"
|
|
60
74
|
}
|
|
61
75
|
};
|
|
62
76
|
var StatusSelect = /*#__PURE__*/_createClass(function StatusSelect(options) {
|
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, ErpTradeId, BuyerNick, ReceiverName, ReceiverMobile, ReceiverAddress, TradeDateTime, Logistics, ReturnLogistics, ActualPayment, ERemark, AliPay, ItemSelect, ItemId, ItemEnCode, SystemOrderNo, Ordinary, ThirdItemSelect, FlowStatusSelect, Payment, TemplateSelect, WorkOrderId, PlatForm, ShopInput, Submitter, Handler, CompletedUser, LogisticsInterception, LogisticsTrajectory, FlowWorkOrderId, BsGoods, BsExchange, BsReissue, BsSystemOrder, StatusSelect, CommonTradeId, CommonSystemOrder, CommonMultiStatus, Calculation, NodeDeadLine, HandlerDeadLine, NodeStayDuration } 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, ErpTradeId, BuyerNick, ReceiverName, ReceiverMobile, ReceiverAddress, TradeDateTime, Logistics, ReturnLogistics, ActualPayment, ERemark, AliPay, ItemSelect, ItemId, ItemEnCode, SystemOrderNo, Ordinary, ThirdItemSelect, FlowStatusSelect, Payment, TemplateSelect, WorkOrderId, PlatForm, ShopInput, Submitter, Handler, CompletedUser, LogisticsInterception, LogisticsTrajectory, FlowWorkOrderId, BsGoods, BsExchange, BsReissue, BsReturn, BsSystemOrder, StatusSelect, CommonTradeId, CommonSystemOrder, CommonMultiStatus, Calculation, NodeDeadLine, HandlerDeadLine, NodeStayDuration } from "./index";
|
|
2
2
|
import { PickOption } from "./type";
|
|
3
|
-
export declare const factory: (type: string, options: PickOption) =>
|
|
3
|
+
export declare const factory: (type: string, options: PickOption) => BsReturn | CommonMultiStatus | StatusSelect | BasicInput | BasicAddress | BasicCascader | BasicCheckbox | BasicDataTime | BasicSelect | BasicRadio | BasicTextArea | BasicPicture | BasicMultSelect | BasicGrade | BasicRate | BasicFile | BasicPosting | CommonDataTime | TradeId | ErpTradeId | ShopName | BuyerNick | ReceiverName | ReceiverMobile | ReceiverAddress | TradeDateTime | Logistics | ReturnLogistics | ActualPayment | ERemark | AliPay | ItemSelect | ItemId | ItemEnCode | SystemOrderNo | Ordinary | ThirdItemSelect | Payment | JstLogistics | JstItemSelect | JstSendGood | JstSupply | BsSystemOrder | BsGoods | BsExchange | BsReissue | FlowStatusSelect | TemplateSelect | WorkOrderId | LogisticsInterception | LogisticsTrajectory | PlatForm | ShopInput | Submitter | Handler | CompletedUser | FlowWorkOrderId | CommonTradeId | Calculation | CommonSystemOrder | NodeDeadLine | HandlerDeadLine | NodeStayDuration;
|
package/dist/esm/factory.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
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, Payment, TemplateSelect, WorkOrderId, PlatForm, ShopInput, Submitter, Handler, CompletedUser, LogisticsInterception, LogisticsTrajectory, FlowWorkOrderId, BsGoods, BsExchange, BsReissue, BsSystemOrder, StatusSelect, CommonTradeId, CommonSystemOrder, CommonMultiStatus, Calculation, NodeDeadLine, HandlerDeadLine, NodeStayDuration } 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, ErpTradeId, BuyerNick, ReceiverName, ReceiverMobile, ReceiverAddress, TradeDateTime, Logistics, ReturnLogistics, ActualPayment, ERemark, AliPay, ItemSelect, ItemId, ItemEnCode, SystemOrderNo, Ordinary, ThirdItemSelect, FlowStatusSelect, Payment, TemplateSelect, WorkOrderId, PlatForm, ShopInput, Submitter, Handler, CompletedUser, LogisticsInterception, LogisticsTrajectory, FlowWorkOrderId, BsGoods, BsExchange, BsReissue, BsReturn, BsSystemOrder, StatusSelect, CommonTradeId, CommonSystemOrder, CommonMultiStatus, Calculation, NodeDeadLine, HandlerDeadLine, NodeStayDuration } from "./index";
|
|
2
2
|
export var factory = function factory(type, options) {
|
|
3
3
|
var _options$componentCon;
|
|
4
4
|
switch (type) {
|
|
@@ -125,6 +125,8 @@ export var factory = function factory(type, options) {
|
|
|
125
125
|
return new BsExchange(options);
|
|
126
126
|
case "BS_REISSUE_GOODS":
|
|
127
127
|
return new BsReissue(options);
|
|
128
|
+
case "BS_RETURN_GOODS":
|
|
129
|
+
return new BsReturn(options);
|
|
128
130
|
case "BS_DELIVERY_NO":
|
|
129
131
|
case "RETURN_GOODS_TRADE_ID":
|
|
130
132
|
return new CommonSystemOrder(options);
|
|
@@ -135,6 +137,7 @@ export var factory = function factory(type, options) {
|
|
|
135
137
|
case "REISSUE_STATUS":
|
|
136
138
|
case "EXCHANGE_STATUS":
|
|
137
139
|
case "ADJUST_WORK_ORDER_STATUS":
|
|
140
|
+
case "CREATE_STATUS":
|
|
138
141
|
return new StatusSelect(options);
|
|
139
142
|
case "RETURN_GOODS_STATUS":
|
|
140
143
|
return new CommonMultiStatus(options);
|
package/dist/esm/index.d.ts
CHANGED
|
@@ -41,6 +41,7 @@ export { default as BsSystemOrder } from "./components/BS/BsSystemOrder";
|
|
|
41
41
|
export { default as BsGoods } from "./components/BS/BsGoods";
|
|
42
42
|
export { default as BsExchange } from "./components/BS/BsExchange";
|
|
43
43
|
export { default as BsReissue } from "./components/BS/BsReissue";
|
|
44
|
+
export { default as BsReturn } from "./components/BS/BsReturn";
|
|
44
45
|
export { default as FlowStatusSelect } from "./components/FlowStatusSelect";
|
|
45
46
|
export { default as TemplateSelect } from "./components/TemplateSelect";
|
|
46
47
|
export { default as WorkOrderId } from "./components/WorkOrderId";
|
package/dist/esm/index.js
CHANGED
|
@@ -41,6 +41,7 @@ export { default as BsSystemOrder } from "./components/BS/BsSystemOrder";
|
|
|
41
41
|
export { default as BsGoods } from "./components/BS/BsGoods";
|
|
42
42
|
export { default as BsExchange } from "./components/BS/BsExchange";
|
|
43
43
|
export { default as BsReissue } from "./components/BS/BsReissue";
|
|
44
|
+
export { default as BsReturn } from "./components/BS/BsReturn";
|
|
44
45
|
export { default as FlowStatusSelect } from "./components/FlowStatusSelect";
|
|
45
46
|
export { default as TemplateSelect } from "./components/TemplateSelect";
|
|
46
47
|
export { default as WorkOrderId } from "./components/WorkOrderId";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@kmkf-fe-packages/services-components",
|
|
3
|
-
"version": "0.8.17-alpha.
|
|
3
|
+
"version": "0.8.17-alpha.36",
|
|
4
4
|
"module": "dist/esm/index.js",
|
|
5
5
|
"typings": "dist/esm/index.d.ts",
|
|
6
6
|
"files": [
|
|
@@ -26,8 +26,8 @@
|
|
|
26
26
|
"father": "^4.1.7"
|
|
27
27
|
},
|
|
28
28
|
"dependencies": {
|
|
29
|
-
"@kmkf-fe-packages/basic-components": "^0.8.17-alpha.
|
|
30
|
-
"@kmkf-fe-packages/kmkf-utils": "^0.8.17-alpha.
|
|
29
|
+
"@kmkf-fe-packages/basic-components": "^0.8.17-alpha.36",
|
|
30
|
+
"@kmkf-fe-packages/kmkf-utils": "^0.8.17-alpha.36"
|
|
31
31
|
},
|
|
32
32
|
"peerDependencies": {
|
|
33
33
|
"@ant-design/icons": "^4.7.0",
|
|
@@ -40,5 +40,5 @@
|
|
|
40
40
|
"gitHooks": {
|
|
41
41
|
"pre-commit": "lint-staged"
|
|
42
42
|
},
|
|
43
|
-
"gitHead": "
|
|
43
|
+
"gitHead": "51396112d02f02e2de2ad6c5805ae0d90bdb0667"
|
|
44
44
|
}
|