@kmkf-fe-packages/services-components 0.8.13-alpha.1 → 0.8.13-alpha.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/esm/components/ReissueTradeId/index.js +10 -10
- package/dist/esm/components/{ReissueStatus → StatusSelect}/index.d.ts +3 -5
- package/dist/esm/components/{ReissueStatus → StatusSelect}/index.js +27 -19
- package/dist/esm/factory.d.ts +2 -2
- package/dist/esm/factory.js +2 -2
- package/dist/esm/index.d.ts +1 -1
- package/dist/esm/index.js +1 -1
- package/package.json +2 -2
|
@@ -44,16 +44,16 @@ var ReissueTradeId = /*#__PURE__*/_createClass(function ReissueTradeId(options)
|
|
|
44
44
|
message.success("复制成功");
|
|
45
45
|
});
|
|
46
46
|
_defineProperty(this, "renderPc", function (value, record) {
|
|
47
|
-
if ((record === null || record === void 0 ? void 0 : record["".concat(_this.id, "
|
|
47
|
+
if ((record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_reissueTradeId")]) === undefined) {
|
|
48
48
|
return /*#__PURE__*/React.createElement(React.Fragment, null, "--");
|
|
49
49
|
}
|
|
50
50
|
return /*#__PURE__*/React.createElement("span", {
|
|
51
51
|
onClick: function onClick(e) {
|
|
52
52
|
return e.stopPropagation();
|
|
53
53
|
}
|
|
54
|
-
}, /*#__PURE__*/React.createElement(React.Fragment, null, record === null || record === void 0 ? void 0 : record["".concat(_this.id, "
|
|
54
|
+
}, /*#__PURE__*/React.createElement(React.Fragment, null, record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_reissueTradeId")], /*#__PURE__*/React.createElement("span", {
|
|
55
55
|
onClick: function onClick(e) {
|
|
56
|
-
_this.copyHandle(record === null || record === void 0 ? void 0 : record["".concat(_this.id, "
|
|
56
|
+
_this.copyHandle(record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_reissueTradeId")]);
|
|
57
57
|
e.stopPropagation();
|
|
58
58
|
}
|
|
59
59
|
}, /*#__PURE__*/React.createElement("span", {
|
|
@@ -64,15 +64,15 @@ var ReissueTradeId = /*#__PURE__*/_createClass(function ReissueTradeId(options)
|
|
|
64
64
|
}, /*#__PURE__*/React.createElement(CopyOutlined, null)))));
|
|
65
65
|
});
|
|
66
66
|
_defineProperty(this, "renderLog", function (r) {
|
|
67
|
-
if (isNull(r === null || r === void 0 ? void 0 : r["".concat(_this.id, "
|
|
67
|
+
if (isNull(r === null || r === void 0 ? void 0 : r["".concat(_this.id, "_reissueTradeId")])) return null;
|
|
68
68
|
return _this.renderPc(undefined, r);
|
|
69
69
|
});
|
|
70
70
|
_defineProperty(this, "getComponentValue", function (r) {
|
|
71
|
-
return r === null || r === void 0 ? void 0 : r["".concat(_this.id, "
|
|
71
|
+
return r === null || r === void 0 ? void 0 : r["".concat(_this.id, "_reissueTradeId")];
|
|
72
72
|
});
|
|
73
73
|
_defineProperty(this, "renderExport", function (value, record) {
|
|
74
74
|
var _record;
|
|
75
|
-
return (_record = record === null || record === void 0 ? void 0 : record["".concat(_this.id, "
|
|
75
|
+
return (_record = record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_reissueTradeId")]) !== null && _record !== void 0 ? _record : "--";
|
|
76
76
|
});
|
|
77
77
|
_defineProperty(this, "editRender", function (p) {
|
|
78
78
|
var _this$componentConfig, _this$componentConfig2, _this$effects, _this$effects2;
|
|
@@ -99,14 +99,14 @@ var ReissueTradeId = /*#__PURE__*/_createClass(function ReissueTradeId(options)
|
|
|
99
99
|
return {
|
|
100
100
|
searchDefaultConditions: SYMBOL.in,
|
|
101
101
|
type: item.type,
|
|
102
|
-
id: "".concat(item.id, "
|
|
102
|
+
id: "".concat(item.id, "_reissueTradeId"),
|
|
103
103
|
// 过滤组件id
|
|
104
104
|
name: item.name,
|
|
105
105
|
// 过滤组件名称
|
|
106
106
|
filterComponentType: "Input",
|
|
107
107
|
filterFn: function filterFn(value) {
|
|
108
108
|
return function (i) {
|
|
109
|
-
return _filterFn.filterSplitComma(_filterFn.filterTableListItemColumnValue(i, item.id, "
|
|
109
|
+
return _filterFn.filterSplitComma(_filterFn.filterTableListItemColumnValue(i, item.id, "reissueTradeId"), value);
|
|
110
110
|
};
|
|
111
111
|
},
|
|
112
112
|
formatFilterValue: function formatFilterValue(input) {
|
|
@@ -116,8 +116,8 @@ var ReissueTradeId = /*#__PURE__*/_createClass(function ReissueTradeId(options)
|
|
|
116
116
|
});
|
|
117
117
|
this.name = options.name;
|
|
118
118
|
this.id = options.id;
|
|
119
|
-
this.sortField = "".concat(options.id, "
|
|
120
|
-
this.formField = "".concat(options.id, "
|
|
119
|
+
this.sortField = "".concat(options.id, "_reissueTradeId");
|
|
120
|
+
this.formField = "".concat(options.id, "_reissueTradeId");
|
|
121
121
|
this.type = options.type;
|
|
122
122
|
this.showContains = false;
|
|
123
123
|
this.onlyContainsString = true;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ComponentInterface, PickOption, ColumnConfig, Record } from '../../type';
|
|
2
2
|
import React from 'react';
|
|
3
|
-
declare class
|
|
3
|
+
declare class StatusSelect implements ComponentInterface {
|
|
4
4
|
name: string;
|
|
5
5
|
id: string;
|
|
6
6
|
sortField: string;
|
|
@@ -27,11 +27,9 @@ declare class BasicReissueStatusSelect implements ComponentInterface {
|
|
|
27
27
|
name: string;
|
|
28
28
|
filterComponentType: "MultipleSelect";
|
|
29
29
|
props: {
|
|
30
|
-
options:
|
|
31
|
-
value: string;
|
|
32
|
-
}[];
|
|
30
|
+
options: Record[];
|
|
33
31
|
};
|
|
34
32
|
filterFn: (value: string) => (i: Record) => boolean;
|
|
35
33
|
};
|
|
36
34
|
}
|
|
37
|
-
export default
|
|
35
|
+
export default StatusSelect;
|
|
@@ -14,14 +14,22 @@ import GetFormItem from "../GetFormItem";
|
|
|
14
14
|
import ItemView from "../../commonComponents/ItemView";
|
|
15
15
|
import { isNull, filterFn as _filterFn } from '@kmkf-fe-packages/kmkf-utils';
|
|
16
16
|
import { SYMBOL } from "../../constant";
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
17
|
+
// const statusOptions: Array<{ value: string }> = [{ value: '成功' }, { value: '失败' }]
|
|
18
|
+
var selectTypeMap = {
|
|
19
|
+
REISSUE_STATUS: {
|
|
20
|
+
options: [{
|
|
21
|
+
value: '成功',
|
|
22
|
+
label: '成功'
|
|
23
|
+
}, {
|
|
24
|
+
value: '失败',
|
|
25
|
+
label: '失败'
|
|
26
|
+
}],
|
|
27
|
+
key: 'reissueStatus'
|
|
28
|
+
}
|
|
29
|
+
};
|
|
30
|
+
var StatusSelect = /*#__PURE__*/_createClass(function StatusSelect(options) {
|
|
23
31
|
var _this = this;
|
|
24
|
-
_classCallCheck(this,
|
|
32
|
+
_classCallCheck(this, StatusSelect);
|
|
25
33
|
_defineProperty(this, "name", void 0);
|
|
26
34
|
_defineProperty(this, "id", void 0);
|
|
27
35
|
_defineProperty(this, "sortField", void 0);
|
|
@@ -57,51 +65,51 @@ var BasicReissueStatusSelect = /*#__PURE__*/_createClass(function BasicReissueSt
|
|
|
57
65
|
});
|
|
58
66
|
_defineProperty(this, "renderPc", function (value, record) {
|
|
59
67
|
var _record;
|
|
60
|
-
return /*#__PURE__*/React.createElement("span", null, (_record = record === null || record === void 0 ? void 0 : record["".concat(_this.id, "
|
|
68
|
+
return /*#__PURE__*/React.createElement("span", null, (_record = record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_").concat(selectTypeMap[_this.type].key)]) !== null && _record !== void 0 ? _record : '--');
|
|
61
69
|
});
|
|
62
70
|
_defineProperty(this, "renderLog", function (r) {
|
|
63
|
-
if (isNull(r === null || r === void 0 ? void 0 : r["".concat(_this.id, "
|
|
71
|
+
if (isNull(r === null || r === void 0 ? void 0 : r["".concat(_this.id, "_").concat(selectTypeMap[_this.type].key)])) return null;
|
|
64
72
|
return _this.renderPc(undefined, r);
|
|
65
73
|
});
|
|
66
74
|
_defineProperty(this, "getComponentValue", function (r) {
|
|
67
|
-
return r === null || r === void 0 ? void 0 : r["".concat(_this.id, "
|
|
75
|
+
return r === null || r === void 0 ? void 0 : r["".concat(_this.id, "_").concat(selectTypeMap[_this.type].key)];
|
|
68
76
|
});
|
|
69
77
|
_defineProperty(this, "renderExport", function (value, record) {
|
|
70
78
|
var _record2;
|
|
71
|
-
return (_record2 = record === null || record === void 0 ? void 0 : record["".concat(_this.id, "
|
|
79
|
+
return (_record2 = record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_").concat(selectTypeMap[_this.type].key)]) !== null && _record2 !== void 0 ? _record2 : '--';
|
|
72
80
|
});
|
|
73
81
|
_defineProperty(this, "filterConfig", function (item) {
|
|
74
82
|
return {
|
|
75
83
|
searchDefaultConditions: SYMBOL.in,
|
|
76
84
|
type: item.type,
|
|
77
|
-
id: "".concat(item.id, "
|
|
85
|
+
id: "".concat(item.id, "_").concat(selectTypeMap[_this.type].key),
|
|
78
86
|
// 过滤组件id
|
|
79
87
|
name: item.name,
|
|
80
88
|
// 过滤组件名称
|
|
81
89
|
filterComponentType: 'MultipleSelect',
|
|
82
90
|
props: {
|
|
83
|
-
options:
|
|
91
|
+
options: selectTypeMap[_this.type].options
|
|
84
92
|
},
|
|
85
93
|
filterFn: function filterFn(value) {
|
|
86
94
|
return function (i) {
|
|
87
|
-
return value === null || value === void 0 ? void 0 : value.includes(_filterFn.filterTableListItemColumnValue(i, item.id,
|
|
95
|
+
return value === null || value === void 0 ? void 0 : value.includes(_filterFn.filterTableListItemColumnValue(i, item.id, "".concat(selectTypeMap[_this.type].key)));
|
|
88
96
|
};
|
|
89
97
|
} // 第一个为选中值,第二个参数为表格行记录值
|
|
90
98
|
};
|
|
91
99
|
});
|
|
92
100
|
this.name = options.name;
|
|
93
101
|
this.id = options.id;
|
|
94
|
-
this.sortField = "".concat(options.id, "
|
|
95
|
-
this.formField = "".concat(options.id, "
|
|
102
|
+
this.sortField = "".concat(options.id, "_").concat(selectTypeMap[options.type].key);
|
|
103
|
+
this.formField = "".concat(options.id, "_").concat(selectTypeMap[options.type].key);
|
|
96
104
|
this.type = options.type;
|
|
97
105
|
this.componentConfig = _objectSpread(_objectSpread({}, options.componentConfig), {}, {
|
|
98
|
-
options:
|
|
106
|
+
options: selectTypeMap[options.type].options
|
|
99
107
|
});
|
|
100
108
|
this.rules = [];
|
|
101
109
|
this.isCombinationComponent = false;
|
|
102
110
|
this.canSort = true;
|
|
103
111
|
this.children = [];
|
|
104
112
|
this.dataType = 'string';
|
|
105
|
-
this.options =
|
|
113
|
+
this.options = selectTypeMap[options.type].options;
|
|
106
114
|
});
|
|
107
|
-
export default
|
|
115
|
+
export default StatusSelect;
|
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,
|
|
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, StatusSelect, ReissueTradeId } 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) => JstLogistics | ReissueTradeId | 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 | JstItemSelect | JstSendGood | JstSupply | BsGoods | BsExchange | BsReissue | FlowStatusSelect | TemplateSelect | WorkOrderId | LogisticsInterception | LogisticsTrajectory | PlatForm | ShopInput | Submitter | Handler | CompletedUser | FlowWorkOrderId;
|
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,
|
|
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, StatusSelect, ReissueTradeId } from "./index";
|
|
2
2
|
export var factory = function factory(type, options) {
|
|
3
3
|
var _options$componentCon;
|
|
4
4
|
switch (type) {
|
|
@@ -128,7 +128,7 @@ export var factory = function factory(type, options) {
|
|
|
128
128
|
case "OUTER_WORK_ORDER_ID_INPUT":
|
|
129
129
|
return new FlowWorkOrderId(options);
|
|
130
130
|
case "REISSUE_STATUS":
|
|
131
|
-
return new
|
|
131
|
+
return new StatusSelect(options);
|
|
132
132
|
case "REISSUE_TRADE_ID":
|
|
133
133
|
return new ReissueTradeId(options);
|
|
134
134
|
default:
|
package/dist/esm/index.d.ts
CHANGED
|
@@ -51,7 +51,7 @@ export { default as Submitter } from "./components/Submitter";
|
|
|
51
51
|
export { default as Handler } from "./components/Handler";
|
|
52
52
|
export { default as CompletedUser } from "./components/CompletedUser";
|
|
53
53
|
export { default as FlowWorkOrderId } from "./components/FlowWorkOrderId";
|
|
54
|
-
export { default as
|
|
54
|
+
export { default as StatusSelect } from "./components/StatusSelect";
|
|
55
55
|
export { default as ReissueTradeId } from "./components/ReissueTradeId";
|
|
56
56
|
export { factory } from "./factory";
|
|
57
57
|
export { default as PlatformAvatar } from "./commonComponents/PlatformAvatar";
|
package/dist/esm/index.js
CHANGED
|
@@ -51,7 +51,7 @@ export { default as Submitter } from "./components/Submitter";
|
|
|
51
51
|
export { default as Handler } from "./components/Handler";
|
|
52
52
|
export { default as CompletedUser } from "./components/CompletedUser";
|
|
53
53
|
export { default as FlowWorkOrderId } from "./components/FlowWorkOrderId";
|
|
54
|
-
export { default as
|
|
54
|
+
export { default as StatusSelect } from "./components/StatusSelect";
|
|
55
55
|
export { default as ReissueTradeId } from "./components/ReissueTradeId";
|
|
56
56
|
export { factory } from "./factory";
|
|
57
57
|
export { default as PlatformAvatar } from "./commonComponents/PlatformAvatar";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@kmkf-fe-packages/services-components",
|
|
3
|
-
"version": "0.8.13-alpha.
|
|
3
|
+
"version": "0.8.13-alpha.2",
|
|
4
4
|
"module": "dist/esm/index.js",
|
|
5
5
|
"typings": "dist/esm/index.d.ts",
|
|
6
6
|
"files": [
|
|
@@ -40,5 +40,5 @@
|
|
|
40
40
|
"gitHooks": {
|
|
41
41
|
"pre-commit": "lint-staged"
|
|
42
42
|
},
|
|
43
|
-
"gitHead": "
|
|
43
|
+
"gitHead": "e74ef6ea4058e5458728b9827a09c823c7df14a8"
|
|
44
44
|
}
|