@kmkf-fe-packages/services-components 0.7.15-alpha.69 → 0.7.15-alpha.70

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.
@@ -14,7 +14,8 @@ declare class ErpTradeId implements ComponentInterface {
14
14
  dataType: ComponentInterface['dataType'];
15
15
  constructor(options: PickOption);
16
16
  renderClient: (record: any) => React.JSX.Element | null;
17
- renderPc: (value: any, record: Record) => React.JSX.Element;
17
+ copyHandle: (text: string) => void;
18
+ renderPc: (value: unknown, record: Record) => React.JSX.Element;
18
19
  renderLog: (r: Record) => React.JSX.Element | null;
19
20
  getComponentValue: (r: Record) => any;
20
21
  renderExport: (value: any, record: Record) => any;
@@ -7,6 +7,9 @@ function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _ty
7
7
  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); }
8
8
  import React from 'react';
9
9
  import { TradeId } from '@kmkf-fe-packages/basic-components';
10
+ import copy from 'copy-to-clipboard';
11
+ import { message } from 'antd';
12
+ import { CopyOutlined } from '@ant-design/icons';
10
13
  import GetFormItem from "../GetFormItem";
11
14
  import ItemView from "../../commonComponents/ItemView";
12
15
  import { isNull, filterFn as _filterFn } from '@kmkf-fe-packages/kmkf-utils';
@@ -32,9 +35,29 @@ var ErpTradeId = /*#__PURE__*/_createClass(function ErpTradeId(options) {
32
35
  value: record === null || record === void 0 ? void 0 : record[_this.id]
33
36
  }) : null;
34
37
  });
38
+ _defineProperty(this, "copyHandle", function (text) {
39
+ copy(text);
40
+ message.success('复制成功');
41
+ });
35
42
  _defineProperty(this, "renderPc", function (value, record) {
36
- var _record;
37
- return /*#__PURE__*/React.createElement("span", null, (_record = record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_tradeId")]) !== null && _record !== void 0 ? _record : '--');
43
+ if ((record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_tradeId")]) === undefined) {
44
+ return /*#__PURE__*/React.createElement(React.Fragment, null, "--");
45
+ }
46
+ return /*#__PURE__*/React.createElement("span", {
47
+ onClick: function onClick(e) {
48
+ return e.stopPropagation();
49
+ }
50
+ }, /*#__PURE__*/React.createElement(React.Fragment, null, record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_tradeId")], /*#__PURE__*/React.createElement("span", {
51
+ onClick: function onClick(e) {
52
+ _this.copyHandle(record === null || record === void 0 ? void 0 : record["".concat(_this.id)]);
53
+ e.stopPropagation();
54
+ }
55
+ }, /*#__PURE__*/React.createElement("span", {
56
+ style: {
57
+ paddingLeft: '4px',
58
+ cursor: 'pointer'
59
+ }
60
+ }, /*#__PURE__*/React.createElement(CopyOutlined, null)))));
38
61
  });
39
62
  _defineProperty(this, "renderLog", function (r) {
40
63
  if (isNull(r === null || r === void 0 ? void 0 : r["".concat(_this.id, "_tradeId")])) return null;
@@ -44,8 +67,8 @@ var ErpTradeId = /*#__PURE__*/_createClass(function ErpTradeId(options) {
44
67
  return r === null || r === void 0 ? void 0 : r["".concat(_this.id, "_tradeId")];
45
68
  });
46
69
  _defineProperty(this, "renderExport", function (value, record) {
47
- var _record2;
48
- return (_record2 = record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_tradeId")]) !== null && _record2 !== void 0 ? _record2 : '--';
70
+ var _record;
71
+ return (_record = record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_tradeId")]) !== null && _record !== void 0 ? _record : '--';
49
72
  });
50
73
  _defineProperty(this, "editRender", function (p) {
51
74
  var _this$componentConfig, _this$componentConfig2;
@@ -17,6 +17,7 @@ declare class ETradeId implements ComponentInterface {
17
17
  dataType: ComponentInterface['dataType'];
18
18
  constructor(options: PickOption);
19
19
  renderClient: (record: any) => React.JSX.Element | null;
20
+ copyHandle: (text: string) => void;
20
21
  renderPc: (value: unknown, record: Record) => React.JSX.Element;
21
22
  renderLog: (r: Record) => React.JSX.Element | null;
22
23
  getComponentValue: (r: Record) => any;
@@ -7,10 +7,13 @@ function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key i
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
9
  import React from 'react';
10
+ import { message } from 'antd';
10
11
  import { TradeId } from '@kmkf-fe-packages/basic-components';
12
+ import { CopyOutlined } from '@ant-design/icons';
11
13
  import GetFormItem from "../GetFormItem";
12
14
  import ItemView from "../../commonComponents/ItemView";
13
15
  import { isNull, filterFn as _filterFn } from '@kmkf-fe-packages/kmkf-utils';
16
+ import copy from 'copy-to-clipboard';
14
17
  import { SYMBOL } from "../../constant";
15
18
  var ETradeId = /*#__PURE__*/_createClass(function ETradeId(options) {
16
19
  var _this = this;
@@ -36,9 +39,29 @@ var ETradeId = /*#__PURE__*/_createClass(function ETradeId(options) {
36
39
  value: record === null || record === void 0 ? void 0 : record[_this.id]
37
40
  }) : null;
38
41
  });
42
+ _defineProperty(this, "copyHandle", function (text) {
43
+ copy(text);
44
+ message.success('复制成功');
45
+ });
39
46
  _defineProperty(this, "renderPc", function (value, record) {
40
- var _record;
41
- return /*#__PURE__*/React.createElement("span", null, (_record = record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_tradeId")]) !== null && _record !== void 0 ? _record : '--');
47
+ if ((record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_tradeId")]) === undefined) {
48
+ return /*#__PURE__*/React.createElement(React.Fragment, null, "--");
49
+ }
50
+ return /*#__PURE__*/React.createElement("span", {
51
+ onClick: function onClick(e) {
52
+ return e.stopPropagation();
53
+ }
54
+ }, /*#__PURE__*/React.createElement(React.Fragment, null, record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_tradeId")], /*#__PURE__*/React.createElement("span", {
55
+ onClick: function onClick(e) {
56
+ _this.copyHandle(record === null || record === void 0 ? void 0 : record["".concat(_this.id)]);
57
+ e.stopPropagation();
58
+ }
59
+ }, /*#__PURE__*/React.createElement("span", {
60
+ style: {
61
+ paddingLeft: '4px',
62
+ cursor: 'pointer'
63
+ }
64
+ }, /*#__PURE__*/React.createElement(CopyOutlined, null)))));
42
65
  });
43
66
  _defineProperty(this, "renderLog", function (r) {
44
67
  if (isNull(r === null || r === void 0 ? void 0 : r["".concat(_this.id, "_tradeId")])) return null;
@@ -48,8 +71,8 @@ var ETradeId = /*#__PURE__*/_createClass(function ETradeId(options) {
48
71
  return r === null || r === void 0 ? void 0 : r["".concat(_this.id, "_tradeId")];
49
72
  });
50
73
  _defineProperty(this, "renderExport", function (value, record) {
51
- var _record2;
52
- return (_record2 = record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_tradeId")]) !== null && _record2 !== void 0 ? _record2 : '--';
74
+ var _record;
75
+ return (_record = record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_tradeId")]) !== null && _record !== void 0 ? _record : '--';
53
76
  });
54
77
  _defineProperty(this, "editRender", function (p) {
55
78
  var _this$componentConfig, _this$componentConfig2, _this$effects, _this$effects2;
@@ -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, 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 } from "./index";
2
2
  import { PickOption } from "./type";
3
- export declare const factory: (type: string, options: PickOption) => ActualPayment | BasicAddress | AliPay | BsExchange | BsGoods | BsReissue | BuyerNick | BasicCascader | BasicCheckbox | CommonDataTime | CompletedUser | BasicDataTime | ItemEnCode | ItemId | ItemSelect | ErpTradeId | BasicFile | FlowStatusSelect | FlowWorkOrderId | BasicGrade | Handler | BasicInput | JstItemSelect | JstLogistics | JstSendGood | JstSupply | Logistics | LogisticsInterception | LogisticsTrajectory | BasicMultSelect | Ordinary | Payment | BasicPicture | PlatForm | BasicPosting | BasicRadio | BasicRate | ReceiverAddress | ReceiverMobile | ReceiverName | ERemark | ReturnLogistics | BasicSelect | ShopInput | ShopName | Submitter | SystemOrderNo | TemplateSelect | BasicTextArea | ThirdItemSelect | TradeDateTime | TradeId | WorkOrderId;
3
+ export declare const factory: (type: string, options: PickOption) => BsExchange | BasicFile | JstLogistics | BasicInput | BasicAddress | BasicCascader | BasicCheckbox | BasicDataTime | BasicSelect | BasicRadio | BasicTextArea | BasicPicture | BasicMultSelect | BasicGrade | BasicRate | 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 | BsReissue | FlowStatusSelect | TemplateSelect | WorkOrderId | LogisticsInterception | LogisticsTrajectory | PlatForm | ShopInput | Submitter | Handler | CompletedUser | FlowWorkOrderId;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kmkf-fe-packages/services-components",
3
- "version": "0.7.15-alpha.69",
3
+ "version": "0.7.15-alpha.70",
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.7.15-alpha.69",
30
- "@kmkf-fe-packages/kmkf-utils": "^0.7.15-alpha.69"
29
+ "@kmkf-fe-packages/basic-components": "^0.7.15-alpha.70",
30
+ "@kmkf-fe-packages/kmkf-utils": "^0.7.15-alpha.70"
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": "10f0ff0eb8ca3abf9895f3489db3cde4ffbfa05e"
43
+ "gitHead": "acde6f0a59a6e1516cea8fc29870bbc58d74d0a7"
44
44
  }