@kmkf-fe-packages/services-components 0.23.1-beta.1 → 0.23.1-beta.4
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/components/BS/BsLogistics/index.js +5 -4
- package/dist/esm/components/BS/BsSystemOrder/index.d.ts +7 -6
- package/dist/esm/components/BS/BsSystemOrder/index.js +22 -19
- package/dist/esm/components/BS/DeliveryNo/index.d.ts +6 -5
- package/dist/esm/components/BS/DeliveryNo/index.js +15 -12
- package/dist/esm/components/BS/common/BsMemo.d.ts +4 -4
- package/dist/esm/components/BS/common/BsMemo.js +16 -15
- package/dist/esm/components/BS/common/BsType.d.ts +4 -4
- package/dist/esm/components/BS/common/BsType.js +14 -13
- package/dist/esm/components/Common/index.d.ts +2 -1
- package/dist/esm/components/Common/index.js +168 -68
- package/dist/esm/components/CommonMultiStatus/index.d.ts +6 -5
- package/dist/esm/components/CommonMultiStatus/index.js +58 -51
- package/dist/esm/components/CommonSystemOrder/index.d.ts +6 -5
- package/dist/esm/components/CommonSystemOrder/index.js +29 -26
- package/dist/esm/components/Input/index.d.ts +7 -6
- package/dist/esm/components/Input/index.js +37 -26
- package/dist/esm/components/JST/JstLogistics/index.d.ts +11 -0
- package/dist/esm/components/JST/JstLogistics/index.js +21 -7
- package/dist/esm/components/Logistics/index.d.ts +6 -6
- package/dist/esm/components/Logistics/index.js +16 -15
- package/dist/esm/components/LogisticsMoreTrajectory/index.d.ts +48 -0
- package/dist/esm/components/LogisticsMoreTrajectory/index.js +119 -0
- package/dist/esm/components/LogisticsMoreTrajectory/trajectoryCode.d.ts +34 -0
- package/dist/esm/components/LogisticsMoreTrajectory/trajectoryCode.js +98 -0
- package/dist/esm/components/LogisticsMoreTrajectory/trajectoryCompany.d.ts +40 -0
- package/dist/esm/components/LogisticsMoreTrajectory/trajectoryCompany.js +95 -0
- package/dist/esm/components/LogisticsMoreTrajectory/trajectorySnapshot.d.ts +32 -0
- package/dist/esm/components/LogisticsMoreTrajectory/trajectorySnapshot.js +74 -0
- package/dist/esm/components/Payment/index.d.ts +12 -12
- package/dist/esm/components/Payment/index.js +11 -12
- package/dist/esm/components/TradeId/index.d.ts +1 -1
- package/dist/esm/components/TradeId/index.js +2 -2
- package/dist/esm/components/WDT/WdtGoods/index.d.ts +33 -0
- package/dist/esm/components/WDT/WdtGoods/index.js +121 -0
- package/dist/esm/constant.d.ts +1 -0
- package/dist/esm/constant.js +8 -0
- package/dist/esm/factory.d.ts +2 -2
- package/dist/esm/factory.js +13 -8
- package/dist/esm/index.d.ts +2 -0
- package/dist/esm/index.js +2 -0
- package/dist/esm/type.d.ts +12 -12
- package/package.json +4 -4
|
@@ -93,7 +93,7 @@ var BsLogistics = /*#__PURE__*/_createClass(function BsLogistics(_options) {
|
|
|
93
93
|
dataType: "string"
|
|
94
94
|
}];
|
|
95
95
|
}
|
|
96
|
-
if (type ===
|
|
96
|
+
if (type === "logisticsCompany") {
|
|
97
97
|
var _typeMap$options$type3;
|
|
98
98
|
return [{
|
|
99
99
|
name: "物流公司",
|
|
@@ -102,7 +102,7 @@ var BsLogistics = /*#__PURE__*/_createClass(function BsLogistics(_options) {
|
|
|
102
102
|
dataType: "string"
|
|
103
103
|
}];
|
|
104
104
|
}
|
|
105
|
-
if (type ===
|
|
105
|
+
if (type === "logisticsCode") {
|
|
106
106
|
var _typeMap$options$type4;
|
|
107
107
|
return [{
|
|
108
108
|
name: "物流单号",
|
|
@@ -148,7 +148,8 @@ var BsLogistics = /*#__PURE__*/_createClass(function BsLogistics(_options) {
|
|
|
148
148
|
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,
|
|
149
149
|
component: /*#__PURE__*/React.createElement(JstGoods, _extends({}, _this.componentConfig, {
|
|
150
150
|
type: 1,
|
|
151
|
-
options: _this.expressDateInstance.getExpressData()
|
|
151
|
+
options: _this.expressDateInstance.getExpressData(),
|
|
152
|
+
onChange: p === null || p === void 0 ? void 0 : p.onChange
|
|
152
153
|
}))
|
|
153
154
|
});
|
|
154
155
|
});
|
|
@@ -202,6 +203,6 @@ var BsLogistics = /*#__PURE__*/_createClass(function BsLogistics(_options) {
|
|
|
202
203
|
}
|
|
203
204
|
}] : [];
|
|
204
205
|
this.expressDateInstance = ExpressData.getInstance();
|
|
205
|
-
this.sortChildField = this.getSortChildFields(((_this$componentConfig4 = this.componentConfig) === null || _this$componentConfig4 === void 0 ? void 0 : _this$componentConfig4.showField) ||
|
|
206
|
+
this.sortChildField = this.getSortChildFields(((_this$componentConfig4 = this.componentConfig) === null || _this$componentConfig4 === void 0 ? void 0 : _this$componentConfig4.showField) || "", _options);
|
|
206
207
|
});
|
|
207
208
|
export default BsLogistics;
|
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
import { ComponentInterface, PickOption, ColumnConfig, Record } from
|
|
2
|
-
import React from
|
|
1
|
+
import { ComponentInterface, PickOption, ColumnConfig, Record } from '../../../type';
|
|
2
|
+
import React from 'react';
|
|
3
3
|
declare class BsSystemOrder implements ComponentInterface {
|
|
4
4
|
name: string;
|
|
5
5
|
id: string;
|
|
6
6
|
sortField: string;
|
|
7
7
|
type: string;
|
|
8
8
|
rules: any[];
|
|
9
|
-
componentConfig: ComponentInterface[
|
|
10
|
-
effects: ComponentInterface[
|
|
9
|
+
componentConfig: ComponentInterface['componentConfig'];
|
|
10
|
+
effects: ComponentInterface['effects'];
|
|
11
11
|
isCombinationComponent: boolean;
|
|
12
12
|
formField: string;
|
|
13
13
|
canSort: boolean;
|
|
14
|
-
dataType: ComponentInterface[
|
|
14
|
+
dataType: ComponentInterface['dataType'];
|
|
15
15
|
children: ComponentInterface[];
|
|
16
16
|
constructor(options: PickOption);
|
|
17
17
|
renderClient: (record: any) => React.JSX.Element | null;
|
|
@@ -21,11 +21,12 @@ declare class BsSystemOrder implements ComponentInterface {
|
|
|
21
21
|
renderExport: () => null;
|
|
22
22
|
editRender: (p: any) => React.JSX.Element;
|
|
23
23
|
filterConfig: (item: ColumnConfig) => {
|
|
24
|
-
searchDefaultConditions: "
|
|
24
|
+
searchDefaultConditions: "in";
|
|
25
25
|
type: string;
|
|
26
26
|
id: string;
|
|
27
27
|
name: string;
|
|
28
28
|
filterComponentType: "Input";
|
|
29
|
+
formatFilterValue: (input: string) => string | string[];
|
|
29
30
|
}[];
|
|
30
31
|
}
|
|
31
32
|
export default BsSystemOrder;
|
|
@@ -8,28 +8,28 @@ function _classCallCheck(instance, Constructor) { if (!(instance instanceof Cons
|
|
|
8
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
9
|
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
|
|
10
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
|
|
11
|
+
import React from 'react';
|
|
12
12
|
import GetFormItem from "../../GetFormItem";
|
|
13
13
|
import ItemView from "../../../commonComponents/ItemView";
|
|
14
|
-
import { isNull } from
|
|
15
|
-
import { BsSystemOrder as SystemOrder } from
|
|
14
|
+
import { isNull } from '@kmkf-fe-packages/kmkf-utils';
|
|
15
|
+
import { BsSystemOrder as SystemOrder } from '@kmkf-fe-packages/basic-components';
|
|
16
16
|
import { BsSystemOrderTable } from "../../Common";
|
|
17
17
|
import { BsHeaderChild } from "../common/index";
|
|
18
|
-
import { SYMBOL } from "../../../constant";
|
|
18
|
+
import { SYMBOL, batchInput } from "../../../constant";
|
|
19
19
|
var typeMap = {
|
|
20
20
|
BS_SYSTEM_ORDER: {
|
|
21
|
-
key:
|
|
22
|
-
name:
|
|
23
|
-
typeName:
|
|
24
|
-
tagName:
|
|
25
|
-
selectId:
|
|
21
|
+
key: 'bsSystemShowOrder',
|
|
22
|
+
name: 'bs',
|
|
23
|
+
typeName: '单据类型',
|
|
24
|
+
tagName: '标签',
|
|
25
|
+
selectId: 'bsSystemSelectIds'
|
|
26
26
|
},
|
|
27
27
|
WLN_SYSTEM_ORDER: {
|
|
28
|
-
key:
|
|
29
|
-
name:
|
|
30
|
-
typeName:
|
|
31
|
-
tagName:
|
|
32
|
-
selectId:
|
|
28
|
+
key: 'wlnSystemShowOrder',
|
|
29
|
+
name: '万里牛',
|
|
30
|
+
typeName: '订单类型',
|
|
31
|
+
tagName: '标记',
|
|
32
|
+
selectId: 'wlnSystemSelectIds'
|
|
33
33
|
},
|
|
34
34
|
WDT_SYSTEM_ORDER: {
|
|
35
35
|
key: "wdtSystemShowOrder",
|
|
@@ -99,13 +99,16 @@ var BsSystemOrder = /*#__PURE__*/_createClass(function BsSystemOrder(options) {
|
|
|
99
99
|
});
|
|
100
100
|
_defineProperty(this, "filterConfig", function (item) {
|
|
101
101
|
return [{
|
|
102
|
-
searchDefaultConditions: SYMBOL.
|
|
102
|
+
searchDefaultConditions: SYMBOL.in,
|
|
103
103
|
type: item.type,
|
|
104
|
-
id: "".concat(item.id, "_").concat(typeMap[_this.type].
|
|
104
|
+
id: "".concat(item.id, "_").concat(typeMap[_this.type].selectId),
|
|
105
105
|
// 过滤组件id
|
|
106
106
|
name: item.name,
|
|
107
107
|
// 过滤组件名称
|
|
108
|
-
filterComponentType:
|
|
108
|
+
filterComponentType: 'Input',
|
|
109
|
+
formatFilterValue: function formatFilterValue(input) {
|
|
110
|
+
return batchInput(input);
|
|
111
|
+
}
|
|
109
112
|
}];
|
|
110
113
|
});
|
|
111
114
|
this.name = options.name;
|
|
@@ -121,7 +124,7 @@ var BsSystemOrder = /*#__PURE__*/_createClass(function BsSystemOrder(options) {
|
|
|
121
124
|
id: "".concat(options.id, "_").concat(typeMap[options.type].key, "_billType"),
|
|
122
125
|
width: 150
|
|
123
126
|
})), new BsHeaderChild(_objectSpread(_objectSpread({}, options), {}, {
|
|
124
|
-
name:
|
|
127
|
+
name: '系统订单号',
|
|
125
128
|
id: "".concat(options.id, "_").concat(typeMap[options.type].key, "_billNo"),
|
|
126
129
|
width: 150
|
|
127
130
|
})), new BsHeaderChild(_objectSpread(_objectSpread({}, options), {}, {
|
|
@@ -140,6 +143,6 @@ var BsSystemOrder = /*#__PURE__*/_createClass(function BsSystemOrder(options) {
|
|
|
140
143
|
return Promise.resolve();
|
|
141
144
|
}
|
|
142
145
|
}] : [];
|
|
143
|
-
this.dataType =
|
|
146
|
+
this.dataType = 'object';
|
|
144
147
|
});
|
|
145
148
|
export default BsSystemOrder;
|
|
@@ -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 DeliveryNo implements ComponentInterface {
|
|
4
4
|
name: string;
|
|
5
5
|
id: string;
|
|
6
6
|
sortField: string;
|
|
7
7
|
type: string;
|
|
8
8
|
rules: any[];
|
|
9
|
-
componentConfig: ComponentInterface[
|
|
9
|
+
componentConfig: ComponentInterface['componentConfig'];
|
|
10
10
|
align: ALignType;
|
|
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
|
renderClient: (record: any) => React.JSX.Element | null;
|
|
18
18
|
renderPc: (value: any, record: Record) => React.JSX.Element;
|
|
@@ -21,12 +21,13 @@ declare class DeliveryNo implements ComponentInterface {
|
|
|
21
21
|
renderExport: (value: any, record: any) => any;
|
|
22
22
|
editRender: (p: any) => React.JSX.Element;
|
|
23
23
|
filterConfig: (item: ColumnConfig) => {
|
|
24
|
-
searchDefaultConditions: "
|
|
24
|
+
searchDefaultConditions: "in";
|
|
25
25
|
type: string;
|
|
26
26
|
id: string;
|
|
27
27
|
name: string;
|
|
28
28
|
filterComponentType: "Input";
|
|
29
29
|
filterFn: (value: string) => (i: Record) => boolean;
|
|
30
|
+
formatFilterValue: (input: string) => string | string[];
|
|
30
31
|
}[];
|
|
31
32
|
}
|
|
32
33
|
export default DeliveryNo;
|
|
@@ -6,18 +6,18 @@ function _classCallCheck(instance, Constructor) { if (!(instance instanceof Cons
|
|
|
6
6
|
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; }
|
|
7
7
|
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
|
|
8
8
|
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); }
|
|
9
|
-
import React from
|
|
10
|
-
import some from
|
|
9
|
+
import React from 'react';
|
|
10
|
+
import some from 'lodash/some';
|
|
11
11
|
import GetFormItem from "../../GetFormItem";
|
|
12
12
|
import { CommonOrderContent } from "../../Common";
|
|
13
|
-
import { CommonSystemOrder } from
|
|
13
|
+
import { CommonSystemOrder } from '@kmkf-fe-packages/basic-components';
|
|
14
14
|
import ItemView from "../../../commonComponents/ItemView";
|
|
15
|
-
import { isNull, filterFn as _filterFn } from
|
|
16
|
-
import { SYMBOL } from "../../../constant";
|
|
15
|
+
import { isNull, filterFn as _filterFn } from '@kmkf-fe-packages/kmkf-utils';
|
|
16
|
+
import { SYMBOL, batchInput } from "../../../constant";
|
|
17
17
|
var typeMap = {
|
|
18
18
|
BS_DELIVERY_NO: {
|
|
19
|
-
key:
|
|
20
|
-
code:
|
|
19
|
+
key: 'deliveryNoList',
|
|
20
|
+
code: 'deliveryNoIds'
|
|
21
21
|
}
|
|
22
22
|
};
|
|
23
23
|
var DeliveryNo = /*#__PURE__*/_createClass(function DeliveryNo(options) {
|
|
@@ -79,7 +79,7 @@ var DeliveryNo = /*#__PURE__*/_createClass(function DeliveryNo(options) {
|
|
|
79
79
|
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)];
|
|
80
80
|
return (list || []).map(function (item) {
|
|
81
81
|
return item === null || item === void 0 ? void 0 : item.deliveryNo;
|
|
82
|
-
}).join(
|
|
82
|
+
}).join(',');
|
|
83
83
|
});
|
|
84
84
|
_defineProperty(this, "editRender", function (p) {
|
|
85
85
|
var _this$componentConfig, _this$componentConfig2;
|
|
@@ -97,16 +97,19 @@ var DeliveryNo = /*#__PURE__*/_createClass(function DeliveryNo(options) {
|
|
|
97
97
|
_defineProperty(this, "filterConfig", function (item) {
|
|
98
98
|
var _typeMap$_this$type5;
|
|
99
99
|
return [{
|
|
100
|
-
searchDefaultConditions: SYMBOL.
|
|
100
|
+
searchDefaultConditions: SYMBOL.in,
|
|
101
101
|
type: item.type,
|
|
102
102
|
id: "".concat(item.id, "_").concat((_typeMap$_this$type5 = typeMap[_this.type]) === null || _typeMap$_this$type5 === void 0 ? void 0 : _typeMap$_this$type5.code),
|
|
103
103
|
name: "".concat(_this.name),
|
|
104
|
-
filterComponentType:
|
|
104
|
+
filterComponentType: 'Input',
|
|
105
105
|
filterFn: function filterFn(value) {
|
|
106
106
|
return function (i) {
|
|
107
107
|
var _typeMap$_this$type6;
|
|
108
108
|
return _filterFn.filterSplitComma(_filterFn.filterTableListItemColumnValue(i, item.id, (_typeMap$_this$type6 = typeMap[_this.type]) === null || _typeMap$_this$type6 === void 0 ? void 0 : _typeMap$_this$type6.code), value);
|
|
109
109
|
};
|
|
110
|
+
},
|
|
111
|
+
formatFilterValue: function formatFilterValue(input) {
|
|
112
|
+
return batchInput(input);
|
|
110
113
|
}
|
|
111
114
|
}];
|
|
112
115
|
});
|
|
@@ -119,7 +122,7 @@ var DeliveryNo = /*#__PURE__*/_createClass(function DeliveryNo(options) {
|
|
|
119
122
|
this.isCombinationComponent = false;
|
|
120
123
|
this.canSort = false;
|
|
121
124
|
this.children = [];
|
|
122
|
-
this.dataType =
|
|
125
|
+
this.dataType = 'object';
|
|
123
126
|
this.rules = (_this$componentConfig3 = this.componentConfig) !== null && _this$componentConfig3 !== void 0 && _this$componentConfig3.required ? [{
|
|
124
127
|
required: true,
|
|
125
128
|
validator: function validator(_, value) {
|
|
@@ -132,6 +135,6 @@ var DeliveryNo = /*#__PURE__*/_createClass(function DeliveryNo(options) {
|
|
|
132
135
|
return Promise.resolve();
|
|
133
136
|
}
|
|
134
137
|
}] : [];
|
|
135
|
-
this.align =
|
|
138
|
+
this.align = 'left';
|
|
136
139
|
});
|
|
137
140
|
export default DeliveryNo;
|
|
@@ -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,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 } from
|
|
16
|
+
import { isNull } from '@kmkf-fe-packages/kmkf-utils';
|
|
17
17
|
var componentType = {
|
|
18
|
-
BS_EXCHANGE_GOODS:
|
|
19
|
-
BS_REISSUE_GOODS:
|
|
20
|
-
BS_RETURN_GOODS:
|
|
18
|
+
BS_EXCHANGE_GOODS: 'bsExchangeType',
|
|
19
|
+
BS_REISSUE_GOODS: 'bsReissueType',
|
|
20
|
+
BS_RETURN_GOODS: 'bsReturnType',
|
|
21
|
+
WDT_REISSUE_GOODS: 'wdtReissueType'
|
|
21
22
|
};
|
|
22
23
|
var BsMemo = /*#__PURE__*/_createClass(function BsMemo(options) {
|
|
23
24
|
var _this = this;
|
|
@@ -35,7 +36,7 @@ var BsMemo = /*#__PURE__*/_createClass(function BsMemo(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,14 +44,14 @@ var BsMemo = /*#__PURE__*/_createClass(function BsMemo(options) {
|
|
|
43
44
|
});
|
|
44
45
|
_defineProperty(this, "renderClient", function (r) {
|
|
45
46
|
var _r$key$componentType$, _r$key, _r$key$componentType$2, _r$key2, _r$key2$componentType, _find, _this$componentConfig, _find2;
|
|
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 (!(r !== null && r !== void 0 && (_r$key$componentType$ = r[key][componentType[_this.type]]) !== null && _r$key$componentType$ !== void 0 && _r$key$componentType$.length)) {
|
|
50
51
|
return null;
|
|
51
52
|
}
|
|
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
|
+
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] : '';
|
|
54
|
+
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] : '';
|
|
54
55
|
var children = (_find = (((_this$componentConfig = _this.componentConfig) === null || _this$componentConfig === void 0 ? void 0 : _this$componentConfig.reasonList) || []).find(function (item) {
|
|
55
56
|
return item.value === type;
|
|
56
57
|
})) === null || _find === void 0 ? void 0 : _find.children;
|
|
@@ -65,7 +66,7 @@ var BsMemo = /*#__PURE__*/_createClass(function BsMemo(options) {
|
|
|
65
66
|
});
|
|
66
67
|
_defineProperty(this, "renderPc", function (value, record) {
|
|
67
68
|
var _this$getComponentVal;
|
|
68
|
-
return /*#__PURE__*/React.createElement("span", null, (_this$getComponentVal = _this.getComponentValue(record)) !== null && _this$getComponentVal !== void 0 ? _this$getComponentVal :
|
|
69
|
+
return /*#__PURE__*/React.createElement("span", null, (_this$getComponentVal = _this.getComponentValue(record)) !== null && _this$getComponentVal !== void 0 ? _this$getComponentVal : '--');
|
|
69
70
|
});
|
|
70
71
|
_defineProperty(this, "renderLog", function (r) {
|
|
71
72
|
var id = _this.getParentId();
|
|
@@ -75,8 +76,8 @@ var BsMemo = /*#__PURE__*/_createClass(function BsMemo(options) {
|
|
|
75
76
|
_defineProperty(this, "getComponentValue", function (r) {
|
|
76
77
|
var _r$id, _r$id2, _find3, _this$componentConfig2, _find4;
|
|
77
78
|
var id = _this.getParentId();
|
|
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
|
+
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] : '';
|
|
80
|
+
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] : '';
|
|
80
81
|
var children = (_find3 = (((_this$componentConfig2 = _this.componentConfig) === null || _this$componentConfig2 === void 0 ? void 0 : _this$componentConfig2.reasonList) || []).find(function (item) {
|
|
81
82
|
return item.value === type;
|
|
82
83
|
})) === null || _find3 === void 0 ? void 0 : _find3.children;
|
|
@@ -87,7 +88,7 @@ var BsMemo = /*#__PURE__*/_createClass(function BsMemo(options) {
|
|
|
87
88
|
});
|
|
88
89
|
_defineProperty(this, "renderExport", function (value, record) {
|
|
89
90
|
var _this$getComponentVal2;
|
|
90
|
-
return (_this$getComponentVal2 = _this.getComponentValue(record)) !== null && _this$getComponentVal2 !== void 0 ? _this$getComponentVal2 :
|
|
91
|
+
return (_this$getComponentVal2 = _this.getComponentValue(record)) !== null && _this$getComponentVal2 !== void 0 ? _this$getComponentVal2 : '--';
|
|
91
92
|
});
|
|
92
93
|
_defineProperty(this, "editRender", function () {
|
|
93
94
|
return null;
|
|
@@ -101,11 +102,11 @@ var BsMemo = /*#__PURE__*/_createClass(function BsMemo(options) {
|
|
|
101
102
|
this.formField = options.id;
|
|
102
103
|
this.type = options.type;
|
|
103
104
|
this.componentConfig = options.componentConfig;
|
|
104
|
-
this.align =
|
|
105
|
+
this.align = 'left';
|
|
105
106
|
this.width = 140;
|
|
106
107
|
this.isCombinationComponent = false;
|
|
107
108
|
this.canSort = false;
|
|
108
|
-
this.dataType =
|
|
109
|
+
this.dataType = 'string';
|
|
109
110
|
this.children = [];
|
|
110
111
|
});
|
|
111
112
|
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,14 +11,15 @@ 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:
|
|
21
|
-
BS_RETURN_GOODS:
|
|
19
|
+
BS_EXCHANGE_GOODS: 'bsExchangeType',
|
|
20
|
+
BS_REISSUE_GOODS: 'bsReissueType',
|
|
21
|
+
BS_RETURN_GOODS: 'bsReturnType',
|
|
22
|
+
WDT_REISSUE_GOODS: 'wdtReissueType'
|
|
22
23
|
};
|
|
23
24
|
var BsType = /*#__PURE__*/_createClass(function BsType(options) {
|
|
24
25
|
var _this = this;
|
|
@@ -36,7 +37,7 @@ var BsType = /*#__PURE__*/_createClass(function BsType(options) {
|
|
|
36
37
|
_defineProperty(this, "children", void 0);
|
|
37
38
|
_defineProperty(this, "dataType", void 0);
|
|
38
39
|
_defineProperty(this, "getParentId", function () {
|
|
39
|
-
var _this$id$split = _this.id.split(
|
|
40
|
+
var _this$id$split = _this.id.split('_'),
|
|
40
41
|
_this$id$split2 = _slicedToArray(_this$id$split, 2),
|
|
41
42
|
key = _this$id$split2[0],
|
|
42
43
|
name = _this$id$split2[1];
|
|
@@ -44,7 +45,7 @@ var BsType = /*#__PURE__*/_createClass(function BsType(options) {
|
|
|
44
45
|
});
|
|
45
46
|
_defineProperty(this, "renderClient", function (record) {
|
|
46
47
|
var _record$key$component, _find, _this$componentConfig;
|
|
47
|
-
var _this$getParentId$spl = _this.getParentId().split(
|
|
48
|
+
var _this$getParentId$spl = _this.getParentId().split('_'),
|
|
48
49
|
_this$getParentId$spl2 = _slicedToArray(_this$getParentId$spl, 1),
|
|
49
50
|
key = _this$getParentId$spl2[0];
|
|
50
51
|
if (!(record !== null && record !== void 0 && (_record$key$component = record[key][componentType[_this.type]]) !== null && _record$key$component !== void 0 && _record$key$component.length)) {
|
|
@@ -62,7 +63,7 @@ var BsType = /*#__PURE__*/_createClass(function BsType(options) {
|
|
|
62
63
|
});
|
|
63
64
|
_defineProperty(this, "renderPc", function (value, record) {
|
|
64
65
|
var _this$getComponentVal;
|
|
65
|
-
return /*#__PURE__*/React.createElement("span", null, (_this$getComponentVal = _this.getComponentValue(record)) !== null && _this$getComponentVal !== void 0 ? _this$getComponentVal :
|
|
66
|
+
return /*#__PURE__*/React.createElement("span", null, (_this$getComponentVal = _this.getComponentValue(record)) !== null && _this$getComponentVal !== void 0 ? _this$getComponentVal : '--');
|
|
66
67
|
});
|
|
67
68
|
_defineProperty(this, "renderLog", function (r) {
|
|
68
69
|
var id = _this.getParentId();
|
|
@@ -72,7 +73,7 @@ var BsType = /*#__PURE__*/_createClass(function BsType(options) {
|
|
|
72
73
|
_defineProperty(this, "getComponentValue", function (r) {
|
|
73
74
|
var _r$id, _find2, _this$componentConfig2;
|
|
74
75
|
var id = _this.getParentId();
|
|
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] :
|
|
76
|
+
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] : '';
|
|
76
77
|
var text = (_find2 = (((_this$componentConfig2 = _this.componentConfig) === null || _this$componentConfig2 === void 0 ? void 0 : _this$componentConfig2.reasonList) || []).find(function (item) {
|
|
77
78
|
return item.value === type;
|
|
78
79
|
})) === null || _find2 === void 0 ? void 0 : _find2.label;
|
|
@@ -80,7 +81,7 @@ var BsType = /*#__PURE__*/_createClass(function BsType(options) {
|
|
|
80
81
|
});
|
|
81
82
|
_defineProperty(this, "renderExport", function (value, record) {
|
|
82
83
|
var _this$getComponentVal2;
|
|
83
|
-
return (_this$getComponentVal2 = _this.getComponentValue(record)) !== null && _this$getComponentVal2 !== void 0 ? _this$getComponentVal2 :
|
|
84
|
+
return (_this$getComponentVal2 = _this.getComponentValue(record)) !== null && _this$getComponentVal2 !== void 0 ? _this$getComponentVal2 : '--';
|
|
84
85
|
});
|
|
85
86
|
_defineProperty(this, "editRender", function () {
|
|
86
87
|
return null;
|
|
@@ -94,7 +95,7 @@ var BsType = /*#__PURE__*/_createClass(function BsType(options) {
|
|
|
94
95
|
type: item.type,
|
|
95
96
|
id: _this.id,
|
|
96
97
|
name: "".concat(item.name, "-\u7C7B\u578B"),
|
|
97
|
-
filterComponentType:
|
|
98
|
+
filterComponentType: 'Cascader',
|
|
98
99
|
props: {
|
|
99
100
|
options: (item === null || item === void 0 ? void 0 : (_item$config = item.config) === null || _item$config === void 0 ? void 0 : _item$config.reasonList) || []
|
|
100
101
|
},
|
|
@@ -116,11 +117,11 @@ var BsType = /*#__PURE__*/_createClass(function BsType(options) {
|
|
|
116
117
|
this.formField = options.id;
|
|
117
118
|
this.type = options.type;
|
|
118
119
|
this.componentConfig = options.componentConfig;
|
|
119
|
-
this.align =
|
|
120
|
+
this.align = 'left';
|
|
120
121
|
this.width = 140;
|
|
121
122
|
this.isCombinationComponent = false;
|
|
122
123
|
this.canSort = false;
|
|
123
|
-
this.dataType =
|
|
124
|
+
this.dataType = 'string';
|
|
124
125
|
this.children = [];
|
|
125
126
|
});
|
|
126
127
|
export default BsType;
|
|
@@ -23,10 +23,11 @@ export declare const BsGoodImage: ({ item, index }: {
|
|
|
23
23
|
}) => React.JSX.Element;
|
|
24
24
|
export declare const BsExchangeList: ({ list, showHeader }: any) => React.JSX.Element;
|
|
25
25
|
export declare const BsGoodPic: (list: string[]) => React.JSX.Element[];
|
|
26
|
-
export declare const BsGoodsTable: ({ list, showHeader, text, }: {
|
|
26
|
+
export declare const BsGoodsTable: ({ list, showHeader, text, type, }: {
|
|
27
27
|
list: any[];
|
|
28
28
|
showHeader: string[];
|
|
29
29
|
text?: string | undefined;
|
|
30
|
+
type?: string | undefined;
|
|
30
31
|
}) => React.JSX.Element;
|
|
31
32
|
export declare const FileRender: ({ fileList, canDownload }: any) => React.JSX.Element;
|
|
32
33
|
export declare const BsSystemOrderTable: ({ value, type }: any) => React.JSX.Element;
|