@kmkf-fe-packages/services-components 2.2.13-beta.86 → 2.2.13-beta.91
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.
|
@@ -178,11 +178,14 @@ var BsE3Reissue = /*#__PURE__*/_createClass(function BsE3Reissue(options) {
|
|
|
178
178
|
this.rules = this !== null && this !== void 0 && (_this$componentConfig6 = this.componentConfig) !== null && _this$componentConfig6 !== void 0 && _this$componentConfig6.required ? [{
|
|
179
179
|
required: true,
|
|
180
180
|
validator: function validator(_, value) {
|
|
181
|
-
var _value, _typeMap$options$type6;
|
|
181
|
+
var _value, _typeMap$options$type6, _typeMap$options$type8;
|
|
182
182
|
if (!value || !(value !== null && value !== void 0 && (_value = value["".concat((_typeMap$options$type6 = typeMap[options.type]) === null || _typeMap$options$type6 === void 0 ? void 0 : _typeMap$options$type6.key)]) !== null && _value !== void 0 && _value.length)) {
|
|
183
183
|
var _typeMap$options$type7;
|
|
184
184
|
return Promise.reject(new Error("".concat((_typeMap$options$type7 = typeMap[options.type]) === null || _typeMap$options$type7 === void 0 ? void 0 : _typeMap$options$type7.errMsg)));
|
|
185
185
|
}
|
|
186
|
+
if (!value || !(value !== null && value !== void 0 && value["".concat((_typeMap$options$type8 = typeMap[options.type]) === null || _typeMap$options$type8 === void 0 ? void 0 : _typeMap$options$type8.systemOrderNo)])) {
|
|
187
|
+
return Promise.reject(new Error("\u8BF7\u9009\u62E9\u8865\u53D1\u7CFB\u7EDF\u5355"));
|
|
188
|
+
}
|
|
186
189
|
return Promise.resolve();
|
|
187
190
|
}
|
|
188
191
|
}] : [];
|
|
@@ -256,18 +256,22 @@ var PublicReissue = /*#__PURE__*/_createClass(function PublicReissue(options) {
|
|
|
256
256
|
this.rules = [{
|
|
257
257
|
required: isRequired,
|
|
258
258
|
validator: function validator(_, value) {
|
|
259
|
-
var _value, _typeMap$options$type11;
|
|
259
|
+
var _value, _typeMap$options$type11, _typeMap$options$type13;
|
|
260
260
|
if (isRequired && (!value || !(value !== null && value !== void 0 && (_value = value["".concat((_typeMap$options$type11 = typeMap[options.type]) === null || _typeMap$options$type11 === void 0 ? void 0 : _typeMap$options$type11.key)]) !== null && _value !== void 0 && _value.length))) {
|
|
261
261
|
var _typeMap$options$type12;
|
|
262
262
|
return Promise.reject(new Error("".concat((_typeMap$options$type12 = typeMap[options.type]) === null || _typeMap$options$type12 === void 0 ? void 0 : _typeMap$options$type12.errMsg)));
|
|
263
263
|
}
|
|
264
|
+
// 快麦补发商品补发系统单需要校验
|
|
265
|
+
if (isRequired && ["KM_REISSUE_GOODS"].includes(options.type) && (!value || !(value !== null && value !== void 0 && value["".concat((_typeMap$options$type13 = typeMap[options.type]) === null || _typeMap$options$type13 === void 0 ? void 0 : _typeMap$options$type13.systemOrderNo)]))) {
|
|
266
|
+
return Promise.reject(new Error("\u8BF7\u9009\u62E9\u8865\u53D1\u7CFB\u7EDF\u5355"));
|
|
267
|
+
}
|
|
264
268
|
return Promise.resolve();
|
|
265
269
|
}
|
|
266
270
|
}, {
|
|
267
271
|
required: isRequired,
|
|
268
272
|
validator: function validator(_rule, value) {
|
|
269
|
-
var _typeMap$options$
|
|
270
|
-
return ((_typeMap$options$
|
|
273
|
+
var _typeMap$options$type14, _typeMap$options$type15;
|
|
274
|
+
return ((_typeMap$options$type14 = typeMap[options.type]) === null || _typeMap$options$type14 === void 0 ? void 0 : (_typeMap$options$type15 = _typeMap$options$type14.validator) === null || _typeMap$options$type15 === void 0 ? void 0 : _typeMap$options$type15.call(_typeMap$options$type14, _rule, value, options.type)) || function () {
|
|
271
275
|
return Promise.resolve();
|
|
272
276
|
};
|
|
273
277
|
}
|
|
@@ -18,7 +18,6 @@ declare class BasicSelect implements ComponentInterface {
|
|
|
18
18
|
getKeyByComponentType: (type: string) => any;
|
|
19
19
|
getIsValue: () => boolean;
|
|
20
20
|
editRender: (p: any) => React.JSX.Element;
|
|
21
|
-
getLabel: (record: Record) => any;
|
|
22
21
|
renderClient: (record: any) => React.JSX.Element | null;
|
|
23
22
|
renderPc: (value: any, record: Record) => React.JSX.Element;
|
|
24
23
|
renderLog: (r: Record) => React.JSX.Element | null;
|
|
@@ -81,17 +81,11 @@ var BasicSelect = /*#__PURE__*/_createClass(function BasicSelect(options) {
|
|
|
81
81
|
}))
|
|
82
82
|
});
|
|
83
83
|
});
|
|
84
|
-
_defineProperty(this, "getLabel", function (record) {
|
|
85
|
-
var _this$optionsMap;
|
|
86
|
-
var type = _this.type;
|
|
87
|
-
var key = record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_").concat(typeMap[type].key)];
|
|
88
|
-
return ((_this$optionsMap = _this.optionsMap) === null || _this$optionsMap === void 0 ? void 0 : _this$optionsMap[key]) || key;
|
|
89
|
-
});
|
|
90
84
|
_defineProperty(this, "renderClient", function (record) {
|
|
91
|
-
var _this$
|
|
85
|
+
var _this$optionsMap;
|
|
92
86
|
console.log("renderClient", record, _this.getIsValue());
|
|
93
87
|
// 特殊自定义组件为平台状态时匹配出label
|
|
94
|
-
var label = _this.getIsValue() ? (_this$
|
|
88
|
+
var label = _this.getIsValue() ? (_this$optionsMap = _this.optionsMap) === null || _this$optionsMap === void 0 ? void 0 : _this$optionsMap[record === null || record === void 0 ? void 0 : record[_this.id]] : record === null || record === void 0 ? void 0 : record[_this.id];
|
|
95
89
|
return !isNull(record === null || record === void 0 ? void 0 : record[_this.id]) ? /*#__PURE__*/React.createElement(ItemView, {
|
|
96
90
|
id: _this.id,
|
|
97
91
|
label: _this.name,
|
|
@@ -99,11 +93,11 @@ var BasicSelect = /*#__PURE__*/_createClass(function BasicSelect(options) {
|
|
|
99
93
|
}) : null;
|
|
100
94
|
});
|
|
101
95
|
_defineProperty(this, "renderPc", function (value, record) {
|
|
102
|
-
var _this$
|
|
96
|
+
var _this$optionsMap2;
|
|
103
97
|
var type = _this.type;
|
|
104
98
|
var key = record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_").concat(typeMap[type].key)];
|
|
105
99
|
// 特殊自定义组件为平台状态时匹配出label
|
|
106
|
-
var label = _this.getIsValue() ? ((_this$
|
|
100
|
+
var label = _this.getIsValue() ? ((_this$optionsMap2 = _this.optionsMap) === null || _this$optionsMap2 === void 0 ? void 0 : _this$optionsMap2[key]) || "" : key;
|
|
107
101
|
return /*#__PURE__*/React.createElement("span", null, label !== null && label !== void 0 ? label : "--");
|
|
108
102
|
});
|
|
109
103
|
_defineProperty(this, "renderLog", function (r) {
|
|
@@ -116,11 +110,11 @@ var BasicSelect = /*#__PURE__*/_createClass(function BasicSelect(options) {
|
|
|
116
110
|
return r === null || r === void 0 ? void 0 : r["".concat(_this.id, "_").concat(typeMap[type].key)];
|
|
117
111
|
});
|
|
118
112
|
_defineProperty(this, "renderExport", function (value, record) {
|
|
119
|
-
var _this$
|
|
113
|
+
var _this$optionsMap3;
|
|
120
114
|
var type = _this.type;
|
|
121
115
|
var key = record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_").concat(typeMap[type].key)];
|
|
122
116
|
// 特殊自定义组件为平台状态时匹配出label
|
|
123
|
-
var label = _this.getIsValue() ? ((_this$
|
|
117
|
+
var label = _this.getIsValue() ? ((_this$optionsMap3 = _this.optionsMap) === null || _this$optionsMap3 === void 0 ? void 0 : _this$optionsMap3[key]) || "" : key;
|
|
124
118
|
return label !== null && label !== void 0 ? label : "--";
|
|
125
119
|
});
|
|
126
120
|
_defineProperty(this, "filterConfig", function (item) {
|
package/dist/esm/factory.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { ReissueLogistics, JstItemSelect, JstSupply, JstSendGood, BasicInput, BasicAddress, BasicCascader, BasicCheckbox, BasicDataTime, BasicSelect, BasicRadio, BasicTextArea, BasicPicture, BasicPicturePro, BasicMultSelect, BasicGrade, BasicRate, BasicFile, BasicPosting, SubForm, CommonDataTime, TradeId, ShopName, BuyerNick, ReceiverName, ReceiverMobile, ReceiverAddress, TradeDateTime, Logistics, ReturnLogistics, ActualPayment, ERemark, AliPay, ItemSelect, ItemId, ItemEnCode, SystemOrderNo, Ordinary, ThirdItemSelect, FlowStatusSelect, FlowMarkSelect, FlowTag, Payment, TemplateSelect, WorkOrderId, PlatForm, ShopInput, Submitter, PrevSubmitter, FlowCreator, Handler, CompletedUser, LogisticsInterception, LogisticsMoreInterception, LogisticsTrajectory, LogisticsMoreTrajectory, FlowWorkOrderId, BsGoods, BsExchange, BsReissue, BsReturn, BsSystemOrder, BsLogistics, StatusSelect, CommonSystemOrder, CommonMultiStatus, Calculation, NodeDeadLine, HandlerDeadLine, NodeStayDuration, WlnGoods, BsPosting, MsgStatus, NodeInput, FlowWorkOrderStatus, WdtGoods, WdtReturn, WdtExchange, CommonInput, PaymentVoucherCode, Label, WdtReissue, GyReissue, AfterSalesOrderId, BsE3Goods, PublicGoods, PublicReissueGoods, PublicExchange, GyGoods, BsE3Reissue, MemberLevel, GyReturn, AsyncSelect, WdtShopSelect, KmVideo, BasicTypeInput, SkxIdInputSelect, SkxGoods, BasicSelectOption, OrderSubForm, FlowOverallStatusSelect } from "./index";
|
|
2
2
|
import { PickOption } from "./type";
|
|
3
|
-
export declare const factory: (type: string, options: PickOption) => BsLogistics | BsSystemOrder | CommonDataTime | BasicFile | FlowOverallStatusSelect | JstSendGood | MsgStatus | BasicPicture | BasicPicturePro | PublicGoods |
|
|
3
|
+
export declare const factory: (type: string, options: PickOption) => BsLogistics | BsSystemOrder | BsE3Reissue | CommonDataTime | BasicFile | FlowOverallStatusSelect | JstSendGood | MsgStatus | BasicPicture | BasicPicturePro | PublicGoods | PublicReissueGoods | ReturnLogistics | BasicSelect | ShopInput | WdtReissue | BasicInput | BasicTypeInput | BasicAddress | BasicCascader | BasicCheckbox | BasicDataTime | BasicSelectOption | BasicRadio | BasicTextArea | BasicMultSelect | BasicGrade | BasicRate | BasicPosting | SubForm | TradeId | ShopName | BuyerNick | ReceiverName | ReceiverMobile | ReceiverAddress | TradeDateTime | Logistics | ActualPayment | ERemark | AliPay | ItemSelect | ItemId | ItemEnCode | SystemOrderNo | Ordinary | ThirdItemSelect | Payment | ReissueLogistics | JstItemSelect | JstSupply | BsGoods | BsE3Goods | PublicExchange | BsExchange | BsReissue | BsReturn | FlowStatusSelect | FlowMarkSelect | FlowTag | TemplateSelect | WorkOrderId | LogisticsInterception | LogisticsMoreInterception | LogisticsTrajectory | LogisticsMoreTrajectory | PlatForm | Submitter | PrevSubmitter | FlowCreator | Handler | CompletedUser | FlowWorkOrderId | StatusSelect | Calculation | CommonSystemOrder | CommonMultiStatus | NodeDeadLine | HandlerDeadLine | NodeStayDuration | WlnGoods | BsPosting | NodeInput | FlowWorkOrderStatus | WdtGoods | WdtReturn | WdtExchange | WdtShopSelect | KmVideo | CommonInput | PaymentVoucherCode | Label | MemberLevel | AfterSalesOrderId | GyGoods | GyReissue | GyReturn | AsyncSelect | SkxIdInputSelect | SkxGoods | OrderSubForm;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@kmkf-fe-packages/services-components",
|
|
3
|
-
"version": "2.2.13-beta.
|
|
3
|
+
"version": "2.2.13-beta.91",
|
|
4
4
|
"module": "dist/esm/index.js",
|
|
5
5
|
"typings": "dist/esm/index.d.ts",
|
|
6
6
|
"files": [
|
|
@@ -21,8 +21,8 @@
|
|
|
21
21
|
]
|
|
22
22
|
},
|
|
23
23
|
"dependencies": {
|
|
24
|
-
"@kmkf-fe-packages/basic-components": "2.2.13-beta.
|
|
25
|
-
"@kmkf-fe-packages/kmkf-utils": "2.2.13-beta.
|
|
24
|
+
"@kmkf-fe-packages/basic-components": "2.2.13-beta.91",
|
|
25
|
+
"@kmkf-fe-packages/kmkf-utils": "2.2.13-beta.87",
|
|
26
26
|
"b64-to-blob": "^1.2.19",
|
|
27
27
|
"html2canvas": "^1.4.1",
|
|
28
28
|
"react-pdf-js": "^5.1.0"
|
|
@@ -41,7 +41,7 @@
|
|
|
41
41
|
"publishConfig": {
|
|
42
42
|
"access": "public"
|
|
43
43
|
},
|
|
44
|
-
"gitHead": "
|
|
44
|
+
"gitHead": "fafcb503a0efccb5d5f8219bea798faf6f392879",
|
|
45
45
|
"gitHooks": {
|
|
46
46
|
"pre-commit": "lint-staged"
|
|
47
47
|
}
|