@kmkf-fe-packages/services-components 1.19.8-beta.12 → 1.19.8-beta.13
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.
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { ComponentInterface, PickOption, ALignType, Record } from '../../../type';
|
|
2
|
+
import React from 'react';
|
|
3
|
+
declare class ReissueGift implements ComponentInterface {
|
|
4
|
+
name: string;
|
|
5
|
+
id: string;
|
|
6
|
+
sortField: string;
|
|
7
|
+
type: string;
|
|
8
|
+
componentConfig: ComponentInterface['componentConfig'];
|
|
9
|
+
align: ALignType;
|
|
10
|
+
width: number;
|
|
11
|
+
isCombinationComponent: boolean;
|
|
12
|
+
formField: string;
|
|
13
|
+
canSort: boolean;
|
|
14
|
+
children: ComponentInterface[];
|
|
15
|
+
dataType: ComponentInterface['dataType'];
|
|
16
|
+
constructor(options: PickOption);
|
|
17
|
+
getParentId: () => string;
|
|
18
|
+
renderClient: (record: any) => React.JSX.Element | null;
|
|
19
|
+
renderPc: (value: unknown, record: Record) => "--" | "是" | "否";
|
|
20
|
+
renderLog: (r: Record) => "--" | "是" | "否" | null;
|
|
21
|
+
getComponentValue: (r: Record) => "--" | "是" | "否";
|
|
22
|
+
renderExport: (value: string, record: Record) => "--" | "是" | "否";
|
|
23
|
+
editRender: () => null;
|
|
24
|
+
filterConfig: () => never[];
|
|
25
|
+
}
|
|
26
|
+
export default ReissueGift;
|
|
@@ -0,0 +1,83 @@
|
|
|
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 _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
3
|
+
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
4
|
+
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
|
|
5
|
+
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
|
|
6
|
+
function _iterableToArrayLimit(arr, i) { var _i = null == arr ? null : "undefined" != typeof Symbol && arr[Symbol.iterator] || arr["@@iterator"]; if (null != _i) { var _s, _e, _x, _r, _arr = [], _n = !0, _d = !1; try { if (_x = (_i = _i.call(arr)).next, 0 === i) { if (Object(_i) !== _i) return; _n = !1; } else for (; !(_n = (_s = _x.call(_i)).done) && (_arr.push(_s.value), _arr.length !== i); _n = !0); } catch (err) { _d = !0, _e = err; } finally { try { if (!_n && null != _i.return && (_r = _i.return(), Object(_r) !== _r)) return; } finally { if (_d) throw _e; } } return _arr; } }
|
|
7
|
+
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
8
|
+
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); } }
|
|
9
|
+
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
10
|
+
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
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
|
+
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
|
|
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 'react';
|
|
15
|
+
import ItemView from "../../../commonComponents/ItemView";
|
|
16
|
+
import { isNull } from '@kmkf-fe-packages/kmkf-utils';
|
|
17
|
+
var ReissueGift = /*#__PURE__*/_createClass(function ReissueGift(options) {
|
|
18
|
+
var _this = this;
|
|
19
|
+
_classCallCheck(this, ReissueGift);
|
|
20
|
+
_defineProperty(this, "name", void 0);
|
|
21
|
+
_defineProperty(this, "id", void 0);
|
|
22
|
+
_defineProperty(this, "sortField", void 0);
|
|
23
|
+
_defineProperty(this, "type", void 0);
|
|
24
|
+
_defineProperty(this, "componentConfig", void 0);
|
|
25
|
+
_defineProperty(this, "align", void 0);
|
|
26
|
+
_defineProperty(this, "width", void 0);
|
|
27
|
+
_defineProperty(this, "isCombinationComponent", void 0);
|
|
28
|
+
_defineProperty(this, "formField", void 0);
|
|
29
|
+
_defineProperty(this, "canSort", void 0);
|
|
30
|
+
_defineProperty(this, "children", void 0);
|
|
31
|
+
_defineProperty(this, "dataType", void 0);
|
|
32
|
+
_defineProperty(this, "getParentId", function () {
|
|
33
|
+
var _this$id$split = _this.id.split('_'),
|
|
34
|
+
_this$id$split2 = _slicedToArray(_this$id$split, 3),
|
|
35
|
+
key = _this$id$split2[0],
|
|
36
|
+
name = _this$id$split2[1],
|
|
37
|
+
code = _this$id$split2[2];
|
|
38
|
+
return "".concat(key, "_").concat(name);
|
|
39
|
+
});
|
|
40
|
+
_defineProperty(this, "renderClient", function (record) {
|
|
41
|
+
return !isNull(record === null || record === void 0 ? void 0 : record[_this.id]) ? /*#__PURE__*/React.createElement(ItemView, {
|
|
42
|
+
id: _this.id,
|
|
43
|
+
label: _this.name,
|
|
44
|
+
value: _this.getComponentValue(record)
|
|
45
|
+
}) : null;
|
|
46
|
+
});
|
|
47
|
+
_defineProperty(this, "renderPc", function (value, record) {
|
|
48
|
+
return _this.getComponentValue(record);
|
|
49
|
+
});
|
|
50
|
+
_defineProperty(this, "renderLog", function (r) {
|
|
51
|
+
var id = _this.getParentId();
|
|
52
|
+
if (isNull(r === null || r === void 0 ? void 0 : r[id])) return null;
|
|
53
|
+
return _this.renderPc(undefined, r);
|
|
54
|
+
});
|
|
55
|
+
_defineProperty(this, "getComponentValue", function (r) {
|
|
56
|
+
if (isNull(r === null || r === void 0 ? void 0 : r[_this.id])) {
|
|
57
|
+
return '--';
|
|
58
|
+
}
|
|
59
|
+
return +(r === null || r === void 0 ? void 0 : r[_this.id]) ? '是' : '否';
|
|
60
|
+
});
|
|
61
|
+
_defineProperty(this, "renderExport", function (value, record) {
|
|
62
|
+
return _this.getComponentValue(record);
|
|
63
|
+
});
|
|
64
|
+
_defineProperty(this, "editRender", function () {
|
|
65
|
+
return null;
|
|
66
|
+
});
|
|
67
|
+
_defineProperty(this, "filterConfig", function () {
|
|
68
|
+
return [];
|
|
69
|
+
});
|
|
70
|
+
this.name = options.name;
|
|
71
|
+
this.id = options.id;
|
|
72
|
+
this.sortField = options.id;
|
|
73
|
+
this.formField = options.id;
|
|
74
|
+
this.type = options.type;
|
|
75
|
+
this.componentConfig = options.componentConfig;
|
|
76
|
+
this.align = 'left';
|
|
77
|
+
this.width = (options === null || options === void 0 ? void 0 : options.width) || 100;
|
|
78
|
+
this.isCombinationComponent = false;
|
|
79
|
+
this.canSort = false;
|
|
80
|
+
this.dataType = 'string';
|
|
81
|
+
this.children = [];
|
|
82
|
+
});
|
|
83
|
+
export default ReissueGift;
|
|
@@ -21,6 +21,7 @@ import React from "react";
|
|
|
21
21
|
import ItemView from "../../commonComponents/ItemView";
|
|
22
22
|
import { isNull } from "@kmkf-fe-packages/kmkf-utils";
|
|
23
23
|
import { BsHeaderPic, BsHeaderChild } from "../BS/common";
|
|
24
|
+
import ReissueGift from "../BsE3/ReissueGift";
|
|
24
25
|
var GoodHeaderMap = {
|
|
25
26
|
"WDT_GOODS": {
|
|
26
27
|
headerMap: {
|
|
@@ -466,13 +467,13 @@ var GoodHeaderMap = {
|
|
|
466
467
|
component: BsHeaderChild,
|
|
467
468
|
name: "商品名称",
|
|
468
469
|
key: "goodsName",
|
|
469
|
-
width:
|
|
470
|
+
width: 200
|
|
470
471
|
},
|
|
471
472
|
goodsShortName: {
|
|
472
473
|
component: BsHeaderChild,
|
|
473
474
|
name: "商品简称",
|
|
474
475
|
key: "goodsShortName",
|
|
475
|
-
width:
|
|
476
|
+
width: 150
|
|
476
477
|
},
|
|
477
478
|
picPath: {
|
|
478
479
|
component: BsHeaderChild,
|
|
@@ -496,13 +497,13 @@ var GoodHeaderMap = {
|
|
|
496
497
|
component: BsHeaderChild,
|
|
497
498
|
name: "颜色名称",
|
|
498
499
|
key: "colorName",
|
|
499
|
-
width:
|
|
500
|
+
width: 150
|
|
500
501
|
},
|
|
501
502
|
colorCode: {
|
|
502
503
|
component: BsHeaderChild,
|
|
503
504
|
name: "颜色代码",
|
|
504
505
|
key: "colorCode",
|
|
505
|
-
width:
|
|
506
|
+
width: 150
|
|
506
507
|
},
|
|
507
508
|
sizeName: {
|
|
508
509
|
component: BsHeaderChild,
|
|
@@ -514,37 +515,37 @@ var GoodHeaderMap = {
|
|
|
514
515
|
component: BsHeaderChild,
|
|
515
516
|
name: "尺码代码",
|
|
516
517
|
key: "sizeCode",
|
|
517
|
-
width:
|
|
518
|
+
width: 150
|
|
518
519
|
},
|
|
519
520
|
brandName: {
|
|
520
521
|
component: BsHeaderChild,
|
|
521
522
|
name: "品牌名称",
|
|
522
523
|
key: "brandName",
|
|
523
|
-
width:
|
|
524
|
+
width: 150
|
|
524
525
|
},
|
|
525
526
|
goodsNumber: {
|
|
526
527
|
component: BsHeaderChild,
|
|
527
528
|
name: "商品数量",
|
|
528
529
|
key: "goodsNumber",
|
|
529
|
-
width:
|
|
530
|
+
width: 150
|
|
530
531
|
},
|
|
531
532
|
goodsPrice: {
|
|
532
533
|
component: BsHeaderChild,
|
|
533
534
|
name: "商品单价",
|
|
534
535
|
key: "goodsPrice",
|
|
535
|
-
width:
|
|
536
|
+
width: 150
|
|
536
537
|
},
|
|
537
538
|
shopPrice: {
|
|
538
539
|
component: BsHeaderChild,
|
|
539
540
|
name: "商品网店售价",
|
|
540
541
|
key: "shopPrice",
|
|
541
|
-
width:
|
|
542
|
+
width: 150
|
|
542
543
|
},
|
|
543
544
|
isGift: {
|
|
544
|
-
component:
|
|
545
|
+
component: ReissueGift,
|
|
545
546
|
name: "是否赠品",
|
|
546
547
|
key: "isGift",
|
|
547
|
-
width:
|
|
548
|
+
width: 150
|
|
548
549
|
}
|
|
549
550
|
},
|
|
550
551
|
itemKey: {
|
package/dist/esm/factory.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { JstLogistics, JstItemSelect, JstSupply, JstSendGood, BasicInput, BasicAddress, BasicCascader, BasicCheckbox, BasicDataTime, BasicSelect, BasicRadio, BasicTextArea, BasicPicture, 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, KmErpSendGood, AfterSalesOrderId, BsE3Goods, BsE3Reissue } from "./index";
|
|
2
2
|
import { PickOption } from "./type";
|
|
3
|
-
export declare const factory: (type: string, options: PickOption) => ActualPayment | BsLogistics |
|
|
3
|
+
export declare const factory: (type: string, options: PickOption) => ActualPayment | BsLogistics | JstSendGood | KmErpSendGood | MsgStatus | BasicSelect | BasicInput | BasicAddress | BasicCascader | BasicCheckbox | BasicDataTime | BasicRadio | BasicTextArea | BasicPicture | BasicMultSelect | BasicGrade | BasicRate | BasicFile | BasicPosting | SubForm | CommonDataTime | TradeId | ShopName | BuyerNick | ReceiverName | ReceiverMobile | ReceiverAddress | TradeDateTime | Logistics | ReturnLogistics | ERemark | AliPay | ItemSelect | ItemId | ItemEnCode | SystemOrderNo | Ordinary | ThirdItemSelect | Payment | JstLogistics | JstItemSelect | JstSupply | BsSystemOrder | BsGoods | BsE3Goods | BsE3Reissue | BsExchange | BsReissue | BsReturn | FlowStatusSelect | FlowMarkSelect | FlowTag | TemplateSelect | WorkOrderId | LogisticsInterception | LogisticsMoreInterception | LogisticsTrajectory | LogisticsMoreTrajectory | PlatForm | ShopInput | Submitter | PrevSubmitter | FlowCreator | Handler | CompletedUser | FlowWorkOrderId | StatusSelect | Calculation | CommonSystemOrder | CommonMultiStatus | NodeDeadLine | HandlerDeadLine | NodeStayDuration | WlnGoods | BsPosting | NodeInput | FlowWorkOrderStatus | WdtGoods | WdtReissue | WdtReturn | WdtExchange | CommonInput | PaymentVoucherCode | Label | AfterSalesOrderId;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@kmkf-fe-packages/services-components",
|
|
3
|
-
"version": "1.19.8-beta.
|
|
3
|
+
"version": "1.19.8-beta.13",
|
|
4
4
|
"module": "dist/esm/index.js",
|
|
5
5
|
"typings": "dist/esm/index.d.ts",
|
|
6
6
|
"files": [
|
|
@@ -21,7 +21,7 @@
|
|
|
21
21
|
]
|
|
22
22
|
},
|
|
23
23
|
"dependencies": {
|
|
24
|
-
"@kmkf-fe-packages/basic-components": "1.19.8-beta.
|
|
24
|
+
"@kmkf-fe-packages/basic-components": "1.19.8-beta.13",
|
|
25
25
|
"@kmkf-fe-packages/kmkf-utils": "1.19.8-beta.12",
|
|
26
26
|
"b64-to-blob": "^1.2.19",
|
|
27
27
|
"html2canvas": "^1.4.1",
|
|
@@ -41,7 +41,7 @@
|
|
|
41
41
|
"publishConfig": {
|
|
42
42
|
"access": "public"
|
|
43
43
|
},
|
|
44
|
-
"gitHead": "
|
|
44
|
+
"gitHead": "f03ac1e309210a72a6c4a0e5963534d9c77cc425",
|
|
45
45
|
"gitHooks": {
|
|
46
46
|
"pre-commit": "lint-staged"
|
|
47
47
|
}
|