@kmkf-fe-packages/services-components 0.7.15-alpha.5 → 0.7.15-alpha.50

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.
Files changed (60) hide show
  1. package/dist/esm/commonComponents/QueryLogisticsTrack/index.js +23 -21
  2. package/dist/esm/components/BS/BsExchange/index.d.ts +6 -8
  3. package/dist/esm/components/BS/BsExchange/index.js +207 -116
  4. package/dist/esm/components/BS/BsGoods/index.d.ts +9 -9
  5. package/dist/esm/components/BS/BsGoods/index.js +82 -60
  6. package/dist/esm/components/BS/BsLogistics/index.d.ts +7 -7
  7. package/dist/esm/components/BS/BsLogistics/index.js +14 -14
  8. package/dist/esm/components/BS/BsReissue/index.d.ts +8 -5
  9. package/dist/esm/components/BS/BsReissue/index.js +89 -50
  10. package/dist/esm/components/BS/common/{BsChildCode.d.ts → BsHeaderCode.d.ts} +5 -4
  11. package/dist/esm/components/BS/common/{BsChildCode.js → BsHeaderCode.js} +27 -11
  12. package/dist/esm/components/BS/common/{BsChildMoney.d.ts → BsHeaderMoney.d.ts} +5 -4
  13. package/dist/esm/components/BS/common/{BsChildMoney.js → BsHeaderMoney.js} +27 -11
  14. package/dist/esm/components/BS/common/{BsChildName.d.ts → BsHeaderName.d.ts} +5 -4
  15. package/dist/esm/components/BS/common/{BsChildName.js → BsHeaderName.js} +28 -11
  16. package/dist/esm/components/BS/common/{BsChildNumber.d.ts → BsHeaderNumber.d.ts} +5 -4
  17. package/dist/esm/components/BS/common/{BsChildNumber.js → BsHeaderNumber.js} +27 -11
  18. package/dist/esm/components/BS/common/{BsChildPic.d.ts → BsHeaderPic.d.ts} +5 -4
  19. package/dist/esm/components/BS/common/{BsChildPic.js → BsHeaderPic.js} +26 -10
  20. package/dist/esm/components/BS/common/{BsChildShare.d.ts → BsHeaderShare.d.ts} +5 -4
  21. package/dist/esm/components/BS/common/{BsChildShare.js → BsHeaderShare.js} +27 -11
  22. package/dist/esm/components/BS/common/{BsChildSku.d.ts → BsHeaderSku.d.ts} +5 -4
  23. package/dist/esm/components/BS/common/{BsChildSku.js → BsHeaderSku.js} +27 -11
  24. package/dist/esm/components/BS/common/{BsChildType.d.ts → BsHeaderType.d.ts} +5 -4
  25. package/dist/esm/components/BS/common/{BsChildType.js → BsHeaderType.js} +27 -11
  26. package/dist/esm/components/BS/common/BsMemo.d.ts +4 -3
  27. package/dist/esm/components/BS/common/BsMemo.js +43 -13
  28. package/dist/esm/components/BS/common/BsType.d.ts +1 -0
  29. package/dist/esm/components/BS/common/BsType.js +34 -8
  30. package/dist/esm/components/BS/common/index.d.ts +10 -10
  31. package/dist/esm/components/BS/common/index.js +8 -8
  32. package/dist/esm/components/Cascader/index.d.ts +1 -0
  33. package/dist/esm/components/Cascader/index.js +3 -1
  34. package/dist/esm/components/Common/index.d.ts +5 -0
  35. package/dist/esm/components/Common/index.js +102 -2
  36. package/dist/esm/components/File/index.d.ts +4 -4
  37. package/dist/esm/components/File/index.js +29 -9
  38. package/dist/esm/components/FlowStatusSelect/index.d.ts +0 -1
  39. package/dist/esm/components/FlowStatusSelect/index.js +30 -24
  40. package/dist/esm/components/JST/JstLogistics/index.js +25 -8
  41. package/dist/esm/components/LogisticsTrajectory/index.d.ts +8 -9
  42. package/dist/esm/components/LogisticsTrajectory/index.js +12 -10
  43. package/dist/esm/components/LogisticsTrajectory/trajectoryCode.js +6 -5
  44. package/dist/esm/components/LogisticsTrajectory/trajectoryCompany.d.ts +6 -6
  45. package/dist/esm/components/LogisticsTrajectory/trajectoryCompany.js +8 -8
  46. package/dist/esm/components/LogisticsTrajectory/trajectorySnapshot.d.ts +0 -1
  47. package/dist/esm/components/LogisticsTrajectory/trajectorySnapshot.js +4 -10
  48. package/dist/esm/components/Payment/BuyerNick.js +1 -2
  49. package/dist/esm/components/Payment/index.d.ts +1 -0
  50. package/dist/esm/components/Payment/index.js +9 -6
  51. package/dist/esm/components/PostIng/index.d.ts +6 -29
  52. package/dist/esm/components/PostIng/index.js +73 -77
  53. package/dist/esm/factory.d.ts +2 -2
  54. package/dist/esm/factory.js +2 -3
  55. package/dist/esm/type.d.ts +15 -14
  56. package/package.json +4 -4
  57. package/dist/esm/components/BS/common/BsExchangeImage.d.ts +0 -31
  58. package/dist/esm/components/BS/common/BsExchangeImage.js +0 -126
  59. package/dist/esm/components/BS/common/BsGoodImage.d.ts +0 -31
  60. package/dist/esm/components/BS/common/BsGoodImage.js +0 -88
@@ -1,11 +1,15 @@
1
+ function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread(); }
2
+ function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
3
+ function _iterableToArray(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
4
+ function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToArray(arr); }
1
5
  function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
2
6
  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."); }
3
7
  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); }
4
8
  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; }
5
9
  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; } }
6
10
  function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
7
- import { Form, Button, Modal, Tooltip, Space, Image, Popover } from "antd";
8
- import React, { useState } from "react";
11
+ import { Form, Button, Modal, Tooltip, Space, Image, Popover, Table } from "antd";
12
+ import React, { useState, useMemo } from "react";
9
13
  import { ExpressData } from "@kmkf-fe-packages/kmkf-utils";
10
14
  import styles from "./index.module.less";
11
15
  import defaultImg from "./img/default-img.png";
@@ -285,4 +289,100 @@ export var BsGoodPic = function BsGoodPic(list) {
285
289
  src: t
286
290
  });
287
291
  });
292
+ };
293
+ export var BsGoodsTable = function BsGoodsTable(_ref9) {
294
+ var list = _ref9.list,
295
+ showHeader = _ref9.showHeader,
296
+ _ref9$text = _ref9.text,
297
+ text = _ref9$text === void 0 ? "" : _ref9$text;
298
+ //商品信息
299
+ var GOODS_INFO_COLUMNS = function GOODS_INFO_COLUMNS() {
300
+ var text = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : "";
301
+ return [{
302
+ dataIndex: "pic",
303
+ title: "\u56FE\u7247",
304
+ align: "center",
305
+ ellipsis: true,
306
+ width: 100,
307
+ render: function render(val) {
308
+ return /*#__PURE__*/React.createElement(Image, {
309
+ width: 60,
310
+ src: val
311
+ });
312
+ }
313
+ }, {
314
+ dataIndex: "name",
315
+ title: "".concat(text, "\u540D\u79F0"),
316
+ align: "center",
317
+ ellipsis: true,
318
+ width: 100
319
+ }, {
320
+ dataIndex: "code",
321
+ title: "".concat(text, "\u7F16\u7801"),
322
+ align: "center",
323
+ ellipsis: true,
324
+ width: 100
325
+ }, {
326
+ dataIndex: "sku",
327
+ title: "".concat(text, "sku\u7F16\u7801"),
328
+ align: "center",
329
+ ellipsis: true,
330
+ width: 100
331
+ }, {
332
+ dataIndex: "money",
333
+ title: "\u5B9E\u4ED8\u91D1\u989D",
334
+ align: "center",
335
+ ellipsis: true,
336
+ width: 100
337
+ }, {
338
+ dataIndex: "number",
339
+ title: "".concat(text, "\u6570\u91CF"),
340
+ align: "center",
341
+ ellipsis: true,
342
+ width: 100,
343
+ render: function render(val, record, index) {
344
+ return /*#__PURE__*/React.createElement("span", null, val);
345
+ }
346
+ }, {
347
+ dataIndex: "share",
348
+ title: "\u5206\u644A\u4EF7",
349
+ align: "center",
350
+ ellipsis: true,
351
+ width: 70
352
+ }, {
353
+ dataIndex: "type",
354
+ title: "\u8D60\u54C1\u7C7B\u578B",
355
+ align: "center",
356
+ ellipsis: true,
357
+ width: 100
358
+ }];
359
+ };
360
+ var newColumns = useMemo(function () {
361
+ var columnList = [{
362
+ dataIndex: "",
363
+ title: "序号",
364
+ align: "center",
365
+ ellipsis: true,
366
+ width: 50,
367
+ render: function render(val, record, index) {
368
+ return /*#__PURE__*/React.createElement("span", null, index + 1);
369
+ }
370
+ }].concat(_toConsumableArray(GOODS_INFO_COLUMNS(text).filter(function (t) {
371
+ return showHeader.includes(t === null || t === void 0 ? void 0 : t.dataIndex);
372
+ })));
373
+ return columnList;
374
+ }, [showHeader, list]);
375
+ return /*#__PURE__*/React.createElement(Table, {
376
+ columns: newColumns,
377
+ dataSource: list,
378
+ rowKey: "id",
379
+ size: "small",
380
+ pagination: false,
381
+ scroll: {
382
+ x: "100%"
383
+ },
384
+ locale: {
385
+ emptyText: "暂无数据"
386
+ }
387
+ });
288
388
  };
@@ -1,5 +1,5 @@
1
- import { ComponentInterface, PickOption, Record } from "../../type";
2
- import React from "react";
1
+ import { ComponentInterface, PickOption, Record } from '../../type';
2
+ import React from 'react';
3
3
  declare class BasicFile implements ComponentInterface {
4
4
  name: string;
5
5
  id: string;
@@ -7,11 +7,11 @@ declare class BasicFile implements ComponentInterface {
7
7
  formField: string;
8
8
  type: string;
9
9
  rules: any[];
10
- componentConfig: ComponentInterface["componentConfig"];
10
+ componentConfig: ComponentInterface['componentConfig'];
11
11
  isCombinationComponent: boolean;
12
12
  canSort: boolean;
13
13
  children: ComponentInterface[];
14
- dataType: ComponentInterface["dataType"];
14
+ dataType: ComponentInterface['dataType'];
15
15
  constructor(options: PickOption);
16
16
  renderPc: (value: any, record: Record) => any;
17
17
  renderLog: (r: Record) => any;
@@ -1,16 +1,22 @@
1
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
2
  function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
3
+ function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
4
+ 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."); }
5
+ 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); }
6
+ 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; }
7
+ 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; } }
8
+ function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
3
9
  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); } }
4
10
  function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
5
11
  function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
6
12
  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
13
  function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
8
14
  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 "react";
10
- import { ApaasUploadFile } from "@kmkf-fe-packages/basic-components";
15
+ import React from 'react';
16
+ import { ApaasUploadFile } from '@kmkf-fe-packages/basic-components';
11
17
  import GetFormItem from "../GetFormItem";
12
18
  import ItemView from "../../commonComponents/ItemView";
13
- import { isNull } from "@kmkf-fe-packages/kmkf-utils";
19
+ import { isNull } from '@kmkf-fe-packages/kmkf-utils';
14
20
  var BasicFile = /*#__PURE__*/_createClass(function BasicFile(options) {
15
21
  var _this = this;
16
22
  _classCallCheck(this, BasicFile);
@@ -32,7 +38,10 @@ var BasicFile = /*#__PURE__*/_createClass(function BasicFile(options) {
32
38
  }
33
39
  return fileList === null || fileList === void 0 ? void 0 : fileList.map(function (file) {
34
40
  return /*#__PURE__*/React.createElement("a", {
35
- href: file.url
41
+ href: file.url,
42
+ style: {
43
+ display: 'block'
44
+ }
36
45
  }, file.name);
37
46
  });
38
47
  });
@@ -44,10 +53,21 @@ var BasicFile = /*#__PURE__*/_createClass(function BasicFile(options) {
44
53
  return r === null || r === void 0 ? void 0 : r["".concat(_this.id, "_file")];
45
54
  });
46
55
  _defineProperty(this, "renderClient", function (record) {
47
- return !isNull(record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_file")]) ? /*#__PURE__*/React.createElement(ItemView, {
56
+ var _record$id;
57
+ var _this$id$split = _this.id.split('_'),
58
+ _this$id$split2 = _slicedToArray(_this$id$split, 1),
59
+ id = _this$id$split2[0];
60
+ return !isNull(record === null || record === void 0 ? void 0 : record[id]) ? /*#__PURE__*/React.createElement(ItemView, {
48
61
  id: _this.id,
49
62
  label: _this.name,
50
- value: _this.renderPc(null, record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_file")])
63
+ value: record === null || record === void 0 ? void 0 : (_record$id = record[id]) === null || _record$id === void 0 ? void 0 : _record$id.map(function (file) {
64
+ return /*#__PURE__*/React.createElement("a", {
65
+ href: file.url,
66
+ style: {
67
+ display: 'block'
68
+ }
69
+ }, file.name);
70
+ })
51
71
  }) : null;
52
72
  });
53
73
  _defineProperty(this, "editRender", function () {
@@ -64,11 +84,11 @@ var BasicFile = /*#__PURE__*/_createClass(function BasicFile(options) {
64
84
  });
65
85
  });
66
86
  _defineProperty(this, "renderExport", function (value, record) {
67
- var textArr = ((record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_rate")]) || []).reduce(function (prv, next) {
87
+ var textArr = ((record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_file")]) || []).reduce(function (prv, next) {
68
88
  prv.push(next.url);
69
89
  return prv;
70
90
  }, []);
71
- return textArr === null || textArr === void 0 ? void 0 : textArr.join(",");
91
+ return textArr === null || textArr === void 0 ? void 0 : textArr.join(',');
72
92
  });
73
93
  _defineProperty(this, "filterConfig", function () {
74
94
  return [];
@@ -83,6 +103,6 @@ var BasicFile = /*#__PURE__*/_createClass(function BasicFile(options) {
83
103
  this.isCombinationComponent = false;
84
104
  this.canSort = false;
85
105
  this.children = [];
86
- this.dataType = "array";
106
+ this.dataType = 'array';
87
107
  });
88
108
  export default BasicFile;
@@ -16,7 +16,6 @@ declare class WorkOrderId implements ComponentInterface {
16
16
  dataType: ComponentInterface['dataType'];
17
17
  options: ComponentInterface['options'];
18
18
  constructor(options: PickOption);
19
- renderMenu: (record: Record) => React.JSX.Element;
20
19
  renderPc: (value: any, record: Record) => React.JSX.Element;
21
20
  renderLog: (r: Record) => React.JSX.Element | null;
22
21
  getComponentValue: (r: Record) => any;
@@ -7,7 +7,6 @@ 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 { Dropdown, Menu } from 'antd';
11
10
  import { ApaasSelect } from '@kmkf-fe-packages/basic-components';
12
11
  import { filterFn as _filterFn } from '@kmkf-fe-packages/kmkf-utils';
13
12
  import GetFormItem from "../GetFormItem";
@@ -31,33 +30,18 @@ var WorkOrderId = /*#__PURE__*/_createClass(function WorkOrderId(options) {
31
30
  _defineProperty(this, "children", void 0);
32
31
  _defineProperty(this, "dataType", void 0);
33
32
  _defineProperty(this, "options", void 0);
34
- _defineProperty(this, "renderMenu", function (record) {
35
- var menu = /*#__PURE__*/React.createElement(Menu, {
36
- onClick: function onClick(_ref) {
37
- var _this$effects, _this$effects2;
38
- var key = _ref.key;
39
- typeof (_this === null || _this === void 0 ? void 0 : (_this$effects = _this.effects) === null || _this$effects === void 0 ? void 0 : _this$effects.handleChangeSingleWorkOrderStatus) === 'function' && (_this === null || _this === void 0 ? void 0 : (_this$effects2 = _this.effects) === null || _this$effects2 === void 0 ? void 0 : _this$effects2.handleChangeSingleWorkOrderStatus(key, record));
40
- }
41
- }, /*#__PURE__*/React.createElement(Menu.Item, {
42
- key: "HANDLING"
43
- }, "\u5904\u7406\u4E2D"), /*#__PURE__*/React.createElement(Menu.Item, {
44
- key: "STOPPING"
45
- }, "\u6682\u505C\u4E2D"), /*#__PURE__*/React.createElement(Menu.Item, {
46
- key: "COMPLETED"
47
- }, "\u5DF2\u5B8C\u6210"), /*#__PURE__*/React.createElement(Menu.Item, {
48
- key: "WAITING"
49
- }, "\u5F85\u5904\u7406"));
50
- return menu;
51
- });
52
33
  _defineProperty(this, "renderPc", function (value, record) {
53
34
  var status = get(_this.workOrderStatus, record === null || record === void 0 ? void 0 : record["".concat(_this.id)]);
54
- return status ? /*#__PURE__*/React.createElement(Dropdown, {
55
- overlay: _this.renderMenu(record)
56
- }, /*#__PURE__*/React.createElement("span", {
35
+ return status ?
36
+ /*#__PURE__*/
37
+ // <Dropdown overlay={this.renderMenu(record)}>
38
+ React.createElement("span", {
57
39
  style: {
58
40
  color: status.color
59
41
  }
60
- }, status === null || status === void 0 ? void 0 : status.label)) : /*#__PURE__*/React.createElement("span", null, "--");
42
+ }, status === null || status === void 0 ? void 0 : status.label)
43
+ // </Dropdown>
44
+ : /*#__PURE__*/React.createElement("span", null, "--");
61
45
  });
62
46
  _defineProperty(this, "renderLog", function (r) {
63
47
  var status = get(_this.workOrderStatus, r === null || r === void 0 ? void 0 : r["".concat(_this.id)]);
@@ -145,6 +129,11 @@ var WorkOrderId = /*#__PURE__*/_createClass(function WorkOrderId(options) {
145
129
  label: '已完成',
146
130
  color: '#73d13d',
147
131
  bgColor: '#73d13d'
132
+ },
133
+ "CLOSED": {
134
+ label: '已关闭',
135
+ color: 'rgba(0, 0, 0, 0.65)',
136
+ bgColor: 'rgba(0, 0, 0, 0.04);'
148
137
  }
149
138
  };
150
139
  this.dataType = 'string';
@@ -154,5 +143,22 @@ var WorkOrderId = /*#__PURE__*/_createClass(function WorkOrderId(options) {
154
143
  value: item
155
144
  };
156
145
  });
157
- });
146
+ }
147
+ // renderMenu = (record: Record) => {
148
+ // const menu = (
149
+ // <Menu
150
+ // onClick={({ key }) => {
151
+ // typeof this?.effects?.handleChangeSingleWorkOrderStatus === 'function' && this?.effects?.handleChangeSingleWorkOrderStatus(key, record)
152
+ // }}
153
+ // >
154
+ // <Menu.Item key="HANDLING">处理中</Menu.Item>
155
+ // <Menu.Item key="STOPPING">暂停中</Menu.Item>
156
+ // <Menu.Item key="COMPLETED">已完成</Menu.Item>
157
+ // <Menu.Item key="WAITING">待处理</Menu.Item>
158
+ // </Menu>
159
+ // );
160
+ // return menu;
161
+ // };
162
+ );
163
+
158
164
  export default WorkOrderId;
@@ -15,8 +15,20 @@ import { JstGoods } from "@kmkf-fe-packages/basic-components";
15
15
  import ItemView from "../../../commonComponents/ItemView";
16
16
  import { isNull, filterFn as _filterFn } from "@kmkf-fe-packages/kmkf-utils";
17
17
  import { SYMBOL } from "../../../constant";
18
+ var typeMap = {
19
+ JST_LOGISTICS: {
20
+ key: "jstItemList",
21
+ name: "jst"
22
+ },
23
+ BS_LOGISTICS: {
24
+ key: "bsLogisticsList",
25
+ name: "bs"
26
+ }
27
+ };
18
28
  var JstLogistics = /*#__PURE__*/_createClass(function JstLogistics(options) {
19
29
  var _this = this,
30
+ _typeMap$options$type,
31
+ _typeMap$options$type2,
20
32
  _this$componentConfig3;
21
33
  _classCallCheck(this, JstLogistics);
22
34
  _defineProperty(this, "name", void 0);
@@ -46,7 +58,8 @@ var JstLogistics = /*#__PURE__*/_createClass(function JstLogistics(options) {
46
58
  }) : null;
47
59
  });
48
60
  _defineProperty(this, "renderPc", function (value, record) {
49
- var list = record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_jstItemList")];
61
+ var _typeMap$_this$type;
62
+ var list = record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_").concat((_typeMap$_this$type = typeMap[_this.type]) === null || _typeMap$_this$type === void 0 ? void 0 : _typeMap$_this$type.key)];
50
63
  //兼容多个商品
51
64
  return /*#__PURE__*/React.createElement(JstGoodImage, {
52
65
  list: list,
@@ -54,15 +67,18 @@ var JstLogistics = /*#__PURE__*/_createClass(function JstLogistics(options) {
54
67
  });
55
68
  });
56
69
  _defineProperty(this, "renderLog", function (r) {
57
- var list = r === null || r === void 0 ? void 0 : r["".concat(_this.id, "_jstItemList")];
70
+ var _typeMap$_this$type2;
71
+ var list = r === null || r === void 0 ? void 0 : r["".concat(_this.id, "_").concat((_typeMap$_this$type2 = typeMap[_this.type]) === null || _typeMap$_this$type2 === void 0 ? void 0 : _typeMap$_this$type2.key)];
58
72
  if (isNull(list)) return null;
59
73
  return _this.renderPc(undefined, r);
60
74
  });
61
75
  _defineProperty(this, "getComponentValue", function (r) {
62
- return r === null || r === void 0 ? void 0 : r["".concat(_this.id, "_jstItemList")];
76
+ var _typeMap$_this$type3;
77
+ return r === null || r === void 0 ? void 0 : r["".concat(_this.id, "_").concat((_typeMap$_this$type3 = typeMap[_this.type]) === null || _typeMap$_this$type3 === void 0 ? void 0 : _typeMap$_this$type3.key)];
63
78
  });
64
79
  _defineProperty(this, "renderExport", function (value, record) {
65
- var list = record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_jstItemList")];
80
+ var _typeMap$_this$type4;
81
+ 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)];
66
82
  return (list || []).map(function (item) {
67
83
  return [_this.expressDateInstance.getExpressNameByCode(item === null || item === void 0 ? void 0 : item.logisticsCompany), item === null || item === void 0 ? void 0 : item.logisticsCode].join("/");
68
84
  }).join(",");
@@ -82,11 +98,12 @@ var JstLogistics = /*#__PURE__*/_createClass(function JstLogistics(options) {
82
98
  });
83
99
  });
84
100
  _defineProperty(this, "filterConfig", function (item) {
101
+ var _typeMap$_this$type5, _typeMap$_this$type6;
85
102
  return [{
86
103
  searchDefaultConditions: SYMBOL.like,
87
104
  type: item.type,
88
105
  id: "".concat(item.id, "_logisticsCode"),
89
- name: "jst\u7269\u6D41\u5355\u53F7",
106
+ name: "".concat((_typeMap$_this$type5 = typeMap[_this.type]) === null || _typeMap$_this$type5 === void 0 ? void 0 : _typeMap$_this$type5.name, "\u7269\u6D41\u5355\u53F7"),
90
107
  filterComponentType: "Input",
91
108
  filterFn: function filterFn(value) {
92
109
  return function (i) {
@@ -97,7 +114,7 @@ var JstLogistics = /*#__PURE__*/_createClass(function JstLogistics(options) {
97
114
  searchDefaultConditions: SYMBOL.in,
98
115
  type: item.type,
99
116
  id: "".concat(item.id, "_logisticsCompany"),
100
- name: "jst\u7269\u6D41\u516C\u53F8",
117
+ name: "".concat((_typeMap$_this$type6 = typeMap[_this.type]) === null || _typeMap$_this$type6 === void 0 ? void 0 : _typeMap$_this$type6.name, "\u7269\u6D41\u516C\u53F8"),
101
118
  filterComponentType: "MultipleSelect",
102
119
  props: {
103
120
  options: _this.expressDateInstance.getExpressData() || []
@@ -116,8 +133,8 @@ var JstLogistics = /*#__PURE__*/_createClass(function JstLogistics(options) {
116
133
  });
117
134
  this.name = options.name;
118
135
  this.id = options.id;
119
- this.sortField = "".concat(options.id, "_jstItemList");
120
- this.formField = "".concat(options.id, "_jstItemList");
136
+ this.sortField = "".concat(options.id, "_").concat((_typeMap$options$type = typeMap[options.type]) === null || _typeMap$options$type === void 0 ? void 0 : _typeMap$options$type.key);
137
+ this.formField = "".concat(options.id, "_").concat((_typeMap$options$type2 = typeMap[options.type]) === null || _typeMap$options$type2 === void 0 ? void 0 : _typeMap$options$type2.key);
121
138
  this.type = options.type;
122
139
  this.componentConfig = options.componentConfig;
123
140
  this.isCombinationComponent = false;
@@ -1,16 +1,16 @@
1
- import { ComponentInterface, PickOption, ColumnConfig, Record } from "../../type";
2
- import React from "react";
3
- import { ExpressData } from "@kmkf-fe-packages/kmkf-utils";
4
- import TrajectoryCompany from "./trajectoryCompany";
5
- import TrajectoryCode from "./trajectoryCode";
6
- import TrajectorySnapshot from "./trajectorySnapshot";
1
+ import { ComponentInterface, PickOption, ColumnConfig, Record } from '../../type';
2
+ import React from 'react';
3
+ import { ExpressData } from '@kmkf-fe-packages/kmkf-utils';
4
+ import TrajectoryCompany from './trajectoryCompany';
5
+ import TrajectoryCode from './trajectoryCode';
6
+ import TrajectorySnapshot from './trajectorySnapshot';
7
7
  declare class LogisticsTrajectory implements ComponentInterface {
8
8
  name: string;
9
9
  id: string;
10
10
  sortField: string;
11
11
  type: string;
12
12
  rules: any[];
13
- componentConfig: ComponentInterface["componentConfig"];
13
+ componentConfig: ComponentInterface['componentConfig'];
14
14
  expressDateInstance: InstanceType<typeof ExpressData>;
15
15
  express: TrajectoryCompany;
16
16
  expressCode: TrajectoryCode;
@@ -19,7 +19,7 @@ declare class LogisticsTrajectory implements ComponentInterface {
19
19
  formField: string;
20
20
  canSort: boolean;
21
21
  children: ComponentInterface[];
22
- dataType: ComponentInterface["dataType"];
22
+ dataType: ComponentInterface['dataType'];
23
23
  constructor(options: PickOption);
24
24
  editRender: (p: any) => React.JSX.Element;
25
25
  renderClient: (record: Record) => React.JSX.Element;
@@ -47,7 +47,6 @@ declare class LogisticsTrajectory implements ComponentInterface {
47
47
  id: string;
48
48
  name: string;
49
49
  filterComponentType: "Input";
50
- filterFn: (value: string) => (i: Record) => boolean;
51
50
  })[];
52
51
  }
53
52
  export default LogisticsTrajectory;
@@ -8,9 +8,9 @@ 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 "react";
12
- import { ExpressData } from "@kmkf-fe-packages/kmkf-utils";
13
- import { LogisticsTrajectory as Trajectory } from "@kmkf-fe-packages/basic-components";
11
+ import React from 'react';
12
+ import { ExpressData } from '@kmkf-fe-packages/kmkf-utils';
13
+ import { LogisticsTrajectory as Trajectory } from '@kmkf-fe-packages/basic-components';
14
14
  import TrajectoryCompany from "./trajectoryCompany";
15
15
  import TrajectoryCode from "./trajectoryCode";
16
16
  import TrajectorySnapshot from "./trajectorySnapshot";
@@ -67,7 +67,9 @@ var LogisticsTrajectory = /*#__PURE__*/_createClass(function LogisticsTrajectory
67
67
  return null;
68
68
  });
69
69
  _defineProperty(this, "filterConfig", function (item) {
70
- return [_this.express.filterConfig(item), _this.expressCode.filterConfig(item), _this.expressSnapshot.filterConfig(item)];
70
+ return [_this.express.filterConfig(_objectSpread(_objectSpread({}, item), {}, {
71
+ subKey: 'trajectoryCompany'
72
+ })), _this.expressCode.filterConfig(item), _this.expressSnapshot.filterConfig(item)];
71
73
  });
72
74
  this.name = options.name;
73
75
  this.id = options.id;
@@ -77,28 +79,28 @@ var LogisticsTrajectory = /*#__PURE__*/_createClass(function LogisticsTrajectory
77
79
  this.componentConfig = options.componentConfig;
78
80
  this.expressDateInstance = ExpressData.getInstance();
79
81
  this.express = new TrajectoryCompany(_objectSpread(_objectSpread({}, options), {}, {
80
- name: "物流公司",
82
+ name: "".concat(this.name, "-\u516C\u53F8"),
81
83
  id: "".concat(this.id, "_trajectoryCompany")
82
84
  }));
83
85
  this.expressCode = new TrajectoryCode(_objectSpread(_objectSpread({}, options), {}, {
84
- name: "物流单号",
86
+ name: "".concat(this.name, "-\u5355\u53F7"),
85
87
  id: "".concat(this.id)
86
88
  }));
87
89
  this.expressSnapshot = new TrajectorySnapshot(_objectSpread(_objectSpread({}, options), {}, {
88
- name: "物流快照",
90
+ name: "".concat(this.name, "-\u5FEB\u7167"),
89
91
  id: "".concat(this.id, "_trajectorySnapshot")
90
92
  }));
91
93
  this.isCombinationComponent = true;
92
94
  this.canSort = false;
93
- this.dataType = "object";
95
+ this.dataType = 'object';
94
96
  this.children = [this.express, this.expressCode, this.expressSnapshot];
95
97
  this.rules = (_this$componentConfig3 = this.componentConfig) !== null && _this$componentConfig3 !== void 0 && _this$componentConfig3.required ? [{
96
98
  validator: function validator(_, value) {
97
99
  if (!value.trajectoryCompany) {
98
- return Promise.reject(new Error("请选择物流公司"));
100
+ return Promise.reject(new Error('请选择物流公司'));
99
101
  }
100
102
  if (!value.trajectoryCode) {
101
- return Promise.reject(new Error("请输入物流单号"));
103
+ return Promise.reject(new Error('请输入物流单号'));
102
104
  }
103
105
  return Promise.resolve();
104
106
  }
@@ -31,12 +31,14 @@ var TrajectoryCode = /*#__PURE__*/_createClass(function TrajectoryCode(options)
31
31
  _defineProperty(this, "renderCode", function (record) {
32
32
  var w = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 500;
33
33
  var company = record === null || record === void 0 ? void 0 : record["".concat(_this.parentId, "_trajectoryCompany")];
34
+ var mobile = record === null || record === void 0 ? void 0 : record["".concat(_this.parentId, "_trajectoryPhone")];
34
35
  var code = record === null || record === void 0 ? void 0 : record[_this.id];
35
36
  return /*#__PURE__*/React.createElement("div", null, code ? /*#__PURE__*/React.createElement(QueryLogisticsTrack, {
37
+ title: code,
36
38
  modelWidth: w,
37
39
  interceptCompany: company,
38
40
  interceptCode: code,
39
- interceptSenderMobile: ""
41
+ interceptSenderMobile: mobile
40
42
  }) : "--");
41
43
  });
42
44
  _defineProperty(this, "renderClient", function (record) {
@@ -64,16 +66,15 @@ var TrajectoryCode = /*#__PURE__*/_createClass(function TrajectoryCode(options)
64
66
  return null;
65
67
  });
66
68
  _defineProperty(this, "filterConfig", function (item) {
67
- var subKey = item.subKey;
68
69
  return {
69
70
  searchDefaultConditions: SYMBOL.like,
70
71
  type: item.type,
71
- id: subKey ? "".concat(item.id, "_").concat(subKey) : item.id,
72
+ id: "".concat(item.id, "_trajectoryCode"),
72
73
  name: "".concat(item.name, "-\u7269\u6D41\u5355\u53F7"),
73
74
  filterComponentType: "Input",
74
75
  filterFn: function filterFn(value) {
75
76
  return function (i) {
76
- return _filterFn.filterSplitComma(_filterFn.filterTableListItemColumnValue(i, item.id, "".concat(subKey)), value);
77
+ return _filterFn.filterSplitComma(_filterFn.filterTableListItemColumnValue(i, item.id, "trajectoryCode"), value);
77
78
  };
78
79
  }
79
80
  };
@@ -96,7 +97,7 @@ var TrajectoryCode = /*#__PURE__*/_createClass(function TrajectoryCode(options)
96
97
  this.align = "left";
97
98
  this.width = 200;
98
99
  this.isCombinationComponent = false;
99
- this.canSort = true;
100
+ this.canSort = false;
100
101
  this.dataType = "string";
101
102
  this.children = [];
102
103
  });
@@ -1,13 +1,13 @@
1
- import { ComponentInterface, PickOption, ColumnConfig, ALignType, Record } from "../../type";
2
- import React from "react";
3
- import { ExpressData } from "@kmkf-fe-packages/kmkf-utils";
1
+ import { ComponentInterface, PickOption, ColumnConfig, ALignType, Record } from '../../type';
2
+ import React from 'react';
3
+ import { ExpressData } from '@kmkf-fe-packages/kmkf-utils';
4
4
  declare class TrajectoryCompany implements ComponentInterface {
5
5
  name: string;
6
6
  id: string;
7
7
  sortField: string;
8
8
  type: string;
9
9
  rules: any[];
10
- componentConfig: ComponentInterface["componentConfig"];
10
+ componentConfig: ComponentInterface['componentConfig'];
11
11
  align: ALignType;
12
12
  expressDateInstance: InstanceType<typeof ExpressData>;
13
13
  width: number;
@@ -15,8 +15,8 @@ declare class TrajectoryCompany implements ComponentInterface {
15
15
  formField: string;
16
16
  canSort: boolean;
17
17
  children: ComponentInterface[];
18
- dataType: ComponentInterface["dataType"];
19
- options: ComponentInterface["options"];
18
+ dataType: ComponentInterface['dataType'];
19
+ options: ComponentInterface['options'];
20
20
  constructor(options: PickOption);
21
21
  renderClient: (record: any) => React.JSX.Element | null;
22
22
  renderPc: (value: unknown, record: Record) => React.JSX.Element;
@@ -5,10 +5,10 @@ function _classCallCheck(instance, Constructor) { if (!(instance instanceof Cons
5
5
  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; }
6
6
  function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
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
- import React from "react";
9
- import { ExpressData } from "@kmkf-fe-packages/kmkf-utils";
8
+ import React from 'react';
9
+ import { ExpressData } from '@kmkf-fe-packages/kmkf-utils';
10
10
  import ItemView from "../../commonComponents/ItemView";
11
- import { isNull, filterFn as _filterFn } from "@kmkf-fe-packages/kmkf-utils";
11
+ import { isNull, filterFn as _filterFn } from '@kmkf-fe-packages/kmkf-utils';
12
12
  import { SYMBOL } from "../../constant";
13
13
  var TrajectoryCompany = /*#__PURE__*/_createClass(function TrajectoryCompany(options) {
14
14
  var _this = this;
@@ -61,13 +61,13 @@ var TrajectoryCompany = /*#__PURE__*/_createClass(function TrajectoryCompany(opt
61
61
  type: item.type,
62
62
  id: subKey ? "".concat(item.id, "_").concat(subKey) : item.id,
63
63
  name: "".concat(item.name, "-\u7269\u6D41\u516C\u53F8"),
64
- filterComponentType: "MultipleSelect",
64
+ filterComponentType: 'MultipleSelect',
65
65
  props: {
66
66
  options: _this.expressDateInstance.getExpressData() || []
67
67
  },
68
68
  filterFn: function filterFn(value) {
69
69
  return function (i) {
70
- return value === null || value === void 0 ? void 0 : value.includes(_filterFn.filterTableListItemColumnValue(i, item.id, "".concat(subKey)));
70
+ return _filterFn.filterSplitComma(_filterFn.filterTableListItemColumnValue(i, item.id, "".concat(subKey)), value);
71
71
  };
72
72
  }
73
73
  };
@@ -79,13 +79,13 @@ var TrajectoryCompany = /*#__PURE__*/_createClass(function TrajectoryCompany(opt
79
79
  this.type = options.type;
80
80
  this.componentConfig = options.componentConfig;
81
81
  this.rules = [];
82
- this.align = "left";
82
+ this.align = 'left';
83
83
  this.expressDateInstance = ExpressData.getInstance();
84
84
  this.width = 200;
85
85
  this.isCombinationComponent = false;
86
- this.canSort = true;
86
+ this.canSort = false;
87
87
  this.children = [];
88
- this.dataType = "string";
88
+ this.dataType = 'string';
89
89
  this.options = this.expressDateInstance.getExpressData() || [];
90
90
  });
91
91
  export default TrajectoryCompany;
@@ -26,7 +26,6 @@ declare class TrajectorySnapshot implements ComponentInterface {
26
26
  id: string;
27
27
  name: string;
28
28
  filterComponentType: "Input";
29
- filterFn: (value: string) => (i: Record) => boolean;
30
29
  };
31
30
  }
32
31
  export default TrajectorySnapshot;