@kmkf-fe-packages/services-components 2.2.31-beta.53 → 2.2.31-beta.57

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.
@@ -1,6 +1,6 @@
1
1
  import LogisticsInterception from "../components/LogisticsInterception";
2
2
  import LogisticsMoreInterception from "../components/LogisticsMoreInterception";
3
- export declare const newRenderColumnItem: (effects: any) => (item: any) => import("../components/AfterSalesOrderId").default | import("../components/BS/BsGoods").default | import("../components/BS/BsLogistics").default | import("../components/BS/BsSystemOrder").default | import("../components/BsE3/BsReissueE3").default | import("../components/BuyerNick").default | import("../components/Checkbox").default | import("../components/CommonDataTime").default | import("../components/CommonMultiStatus").default | import("../components/CommonSystemOrder").default | import("../components/EItemEnCode").default | import("../components/TradeId").default | import("../components/Input").default | import("../components/TypeInput").default | import("../components/Address").default | import("../components/Cascader").default | import("../components/DataTime").default | import("../components/Select").default | import("../components/SelectOption").default | import("../components/Radio").default | import("../components/TextArea").default | import("../components/Picture").default | import("../components/PicturePro").default | import("../components/MultSelect").default | import("../components/Grade").default | import("../components/Rate").default | import("../components/File").default | import("../components/PostIng").default | import("../components/SubForm").default | import("../components/ShopName").default | import("../components/ReceiverName").default | import("../components/ReceiverMobile").default | import("../components/ReceiverAddress").default | import("../components/TradeDateTime").default | import("../components/Logistics").default | import("../components/ReturnLogistics").default | import("../components/ActualPayment").default | import("../components/Remark").default | import("../components/Alipay").default | import("../components/EItemSelect").default | import("../components/EItemId").default | import("../components/SystemOrderNo").default | import("../components/Ordinary").default | import("../components/ThirdItemSelect").default | import("../components/Payment").default | import("../components/Reissue/Logistics").default | import("../components/JST/JstItemSelect").default | import("../components/JST/JstSendGood").default | import("../components/JST/JstSupply").default | import("../components/BsE3/BsGoods").default | import("../components/Public/Goods").default | import("../components/Public/ReissueGoods").default | import("../components/Public/Exchange").default | import("../components/BS/BsExchange").default | import("../components/BS/BsReissue").default | import("../components/BS/BsReturn").default | import("../components/FlowStatusSelect").default | import("../components/FlowMarkSelect").default | import("../components/FlowTag").default | import("../components/TemplateSelect").default | import("../components/WorkOrderId").default | LogisticsInterception | LogisticsMoreInterception | import("../components/LogisticsTrajectory").default | import("../components/LogisticsMoreTrajectory").default | import("../components/PlatForm").default | import("../components/ShopInput").default | import("../components/Submitter").default | import("../components/PrevSubmitter").default | import("../components/FlowCreator").default | import("../components/Handler").default | import("../components/CompletedUser").default | import("../components/FlowWorkOrderId").default | import("../components/StatusSelect").default | import("../components/Calculation").default | import("../components/NodeDeadLine").default | import("../components/HandlerDeadLine").default | import("../components/NodeStayDuration").default | import("../components/WLN/WlnGoods").default | import("../components/BS/BsPosting").default | import("../components/NodeInput").default | import("../components/FlowWorkOrderStatus").default | import("../components/MsgStatus").default | import("../components/WDT/WdtGoods").default | import("../components/WDT/WdtRessuie").default | import("../components/WDT/WdtReturn").default | import("../components/WDT/WdtExchange").default | import("../components/WDT/WdtShopSelect").default | import("../components/KM/KmVideo").default | import("../components/CommonInput").default | import("../components/PaymentVoucherCode").default | import("../components/Label").default | import("../components/MemberLevel").default | import("../components/GY/GyGoods").default | import("../components/GY/GyReissue").default | import("../components/GY/GyReturn").default | import("../components/Public/AsyncSelect").default | import("../components/SKX/SkxIdInputSelect").default | import("../components/SKX/SkxGoods").default | import("../components/OrderSubForm").default | import("../components/FlowOverallStatusSelect").default;
3
+ export declare const newRenderColumnItem: (effects: any) => (item: any) => import("../components/ActualPayment").default | import("../components/Address").default | import("../components/AfterSalesOrderId").default | import("../components/Alipay").default | import("../components/BS/BsExchange").default | import("../components/BS/BsGoods").default | import("../components/BS/BsLogistics").default | import("../components/BS/BsPosting").default | import("../components/BS/BsReissue").default | import("../components/BS/BsReturn").default | import("../components/BS/BsSystemOrder").default | import("../components/BsE3/BsGoods").default | import("../components/BsE3/BsReissueE3").default | import("../components/BuyerNick").default | import("../components/Calculation").default | import("../components/Cascader").default | import("../components/Checkbox").default | import("../components/CommonDataTime").default | import("../components/CommonInput").default | import("../components/CommonMultiStatus").default | import("../components/CommonSystemOrder").default | import("../components/CompletedUser").default | import("../components/DataTime").default | import("../components/EItemEnCode").default | import("../components/EItemId").default | import("../components/EItemSelect").default | import("../components/Input").default | import("../components/TypeInput").default | import("../components/Select").default | import("../components/SelectOption").default | import("../components/Radio").default | import("../components/TextArea").default | import("../components/Picture").default | import("../components/PicturePro").default | import("../components/MultSelect").default | import("../components/Grade").default | import("../components/Rate").default | import("../components/File").default | import("../components/PostIng").default | import("../components/SubForm").default | import("../components/TradeId").default | import("../components/ShopName").default | import("../components/ReceiverName").default | import("../components/ReceiverMobile").default | import("../components/ReceiverAddress").default | import("../components/TradeDateTime").default | import("../components/Logistics").default | import("../components/ReturnLogistics").default | import("../components/Remark").default | import("../components/SystemOrderNo").default | import("../components/Ordinary").default | import("../components/ThirdItemSelect").default | import("../components/Payment").default | import("../components/Reissue/Logistics").default | import("../components/JST/JstItemSelect").default | import("../components/JST/JstSendGood").default | import("../components/JST/JstSupply").default | import("../components/Public/Goods").default | import("../components/Public/ReissueGoods").default | import("../components/Public/Exchange").default | import("../components/FlowStatusSelect").default | import("../components/FlowMarkSelect").default | import("../components/FlowTag").default | import("../components/TemplateSelect").default | import("../components/WorkOrderId").default | LogisticsInterception | LogisticsMoreInterception | import("../components/LogisticsTrajectory").default | import("../components/LogisticsMoreTrajectory").default | import("../components/PlatForm").default | import("../components/ShopInput").default | import("../components/Submitter").default | import("../components/PrevSubmitter").default | import("../components/FlowCreator").default | import("../components/Handler").default | import("../components/FlowWorkOrderId").default | import("../components/StatusSelect").default | import("../components/NodeDeadLine").default | import("../components/HandlerDeadLine").default | import("../components/NodeStayDuration").default | import("../components/WLN/WlnGoods").default | import("../components/NodeInput").default | import("../components/FlowWorkOrderStatus").default | import("../components/MsgStatus").default | import("../components/WDT/WdtGoods").default | import("../components/WDT/WdtRessuie").default | import("../components/WDT/WdtReturn").default | import("../components/WDT/WdtExchange").default | import("../components/WDT/WdtShopSelect").default | import("../components/KM/KmVideo").default | import("../components/PaymentVoucherCode").default | import("../components/Label").default | import("../components/MemberLevel").default | import("../components/GY/GyGoods").default | import("../components/GY/GyReissue").default | import("../components/GY/GyReturn").default | import("../components/Public/AsyncSelect").default | import("../components/SKX/SkxIdInputSelect").default | import("../components/SKX/SkxGoods").default | import("../components/OrderSubForm").default | import("../components/FlowOverallStatusSelect").default;
4
4
  export declare const useColumnsConfig: ({ queryWorkOrderDetail, flatTemplateList, shopList, sortState, onChangeSort, handleReset, handleSubmit, handleChangeSingleWorkOrderMark, userList, tbAppKey, isShare, openSingleColumnsFilter, openSingleColumnsSort, }: {
5
5
  queryWorkOrderDetail?: ((p: any) => void) | undefined;
6
6
  flatTemplateList?: any;
@@ -207,6 +207,7 @@ var BsLogistics = /*#__PURE__*/_createClass(function BsLogistics(_options) {
207
207
  _defineProperty(this, "editRender", function (p) {
208
208
  var _this$componentConfig, _this$componentConfig2, _this$componentConfig3, _this$componentConfig4, _this$expressDateInst2, _typeMap$_this$type6;
209
209
  var onLogisticsCodeBlur = function onLogisticsCodeBlur(val) {
210
+ var _p$onBlur2;
210
211
  if (_this.isChange) {
211
212
  var _this$effects, _this$effects$form, _p$onBlur;
212
213
  (_this$effects = _this.effects) === null || _this$effects === void 0 ? void 0 : (_this$effects$form = _this$effects.form) === null || _this$effects$form === void 0 ? void 0 : _this$effects$form.setFieldsValue({
@@ -215,6 +216,7 @@ var BsLogistics = /*#__PURE__*/_createClass(function BsLogistics(_options) {
215
216
  _this.type === "SKX_RETURN_LOGISTICS" && (p === null || p === void 0 ? void 0 : (_p$onBlur = p.onBlur) === null || _p$onBlur === void 0 ? void 0 : _p$onBlur.call(p, val, "skxReturnTHLogisticsCode"));
216
217
  _this.isChange = false;
217
218
  }
219
+ _this.type === "SKX_LOGISTICS" && (p === null || p === void 0 ? void 0 : (_p$onBlur2 = p.onBlur) === null || _p$onBlur2 === void 0 ? void 0 : _p$onBlur2.call(p, val, "skxLogisticsCode"));
218
220
  };
219
221
  var onLogisticsCodeChange = function onLogisticsCodeChange() {
220
222
  _this.isChange = true;
@@ -1,17 +1,17 @@
1
- import { ComponentInterface, PickOption, ColumnConfig, Record } from '../../type';
2
- import React from 'react';
1
+ import { ComponentInterface, PickOption, ColumnConfig, Record } from "../../type";
2
+ import React from "react";
3
3
  declare class BasicInput implements ComponentInterface {
4
4
  name: string;
5
5
  id: string;
6
6
  sortField: string;
7
7
  type: string;
8
8
  rules: any[];
9
- componentConfig: ComponentInterface['componentConfig'];
9
+ componentConfig: ComponentInterface["componentConfig"];
10
10
  isCombinationComponent: boolean;
11
11
  formField: string;
12
12
  canSort: boolean;
13
13
  children: ComponentInterface[];
14
- dataType: ComponentInterface['dataType'];
14
+ dataType: ComponentInterface["dataType"];
15
15
  templateId?: string;
16
16
  flowTemplateKey?: string;
17
17
  workOrderUniqueKey?: string;
@@ -9,11 +9,11 @@ function _classCallCheck(instance, Constructor) { if (!(instance instanceof Cons
9
9
  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; }
10
10
  function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
11
11
  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); }
12
- import React from 'react';
13
- import { ApaasInput } from '@kmkf-fe-packages/basic-components';
12
+ import React from "react";
13
+ import { ApaasInput } from "@kmkf-fe-packages/basic-components";
14
14
  import GetFormItem from "../GetFormItem";
15
15
  import ItemView from "../../commonComponents/ItemView";
16
- import { isNull, filterFn as _filterFn } from '@kmkf-fe-packages/kmkf-utils';
16
+ import { isNull, filterFn as _filterFn } from "@kmkf-fe-packages/kmkf-utils";
17
17
  import { SYMBOL, batchInput, SEARCH_OPTIONS } from "../../constant";
18
18
  import { replaceCheck } from "../../service/api";
19
19
  var BasicInput = /*#__PURE__*/_createClass(function BasicInput(options) {
@@ -36,7 +36,7 @@ var BasicInput = /*#__PURE__*/_createClass(function BasicInput(options) {
36
36
  _defineProperty(this, "workOrderUniqueKey", void 0);
37
37
  _defineProperty(this, "renderPc", function (value, record) {
38
38
  var _record;
39
- return /*#__PURE__*/React.createElement("span", null, (_record = record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_input")]) !== null && _record !== void 0 ? _record : '--');
39
+ return /*#__PURE__*/React.createElement("span", null, (_record = record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_input")]) !== null && _record !== void 0 ? _record : "--");
40
40
  });
41
41
  _defineProperty(this, "renderLog", function (r) {
42
42
  if (isNull(r === null || r === void 0 ? void 0 : r["".concat(_this.id, "_input")])) return null;
@@ -48,7 +48,7 @@ var BasicInput = /*#__PURE__*/_createClass(function BasicInput(options) {
48
48
  _defineProperty(this, "renderExport", function (value, record) {
49
49
  var _this$componentConfig;
50
50
  if (!(record !== null && record !== void 0 && record["".concat(_this.id, "_input")])) {
51
- return '--';
51
+ return "--";
52
52
  }
53
53
  return (_this$componentConfig = _this.componentConfig) !== null && _this$componentConfig !== void 0 && _this$componentConfig.isNumber ? Number(record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_input")]) : record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_input")];
54
54
  });
@@ -67,14 +67,18 @@ var BasicInput = /*#__PURE__*/_createClass(function BasicInput(options) {
67
67
  rules: _this.rules,
68
68
  hidden: p === null || p === void 0 ? void 0 : p.hidden,
69
69
  display: p === null || p === void 0 ? void 0 : p.display,
70
- validateTrigger: ['onBlur', 'onChange'],
70
+ validateTrigger: ["onBlur", "onChange"],
71
71
  required: (_this$componentConfig2 = (_this$componentConfig3 = _this.componentConfig) === null || _this$componentConfig3 === void 0 ? void 0 : _this$componentConfig3.required) !== null && _this$componentConfig2 !== void 0 ? _this$componentConfig2 : false,
72
- tooltip: (_this$componentConfig4 = _this.componentConfig) !== null && _this$componentConfig4 !== void 0 && _this$componentConfig4.showTooltip ? (_this$componentConfig5 = _this.componentConfig) === null || _this$componentConfig5 === void 0 ? void 0 : _this$componentConfig5.tooltip : '',
72
+ tooltip: (_this$componentConfig4 = _this.componentConfig) !== null && _this$componentConfig4 !== void 0 && _this$componentConfig4.showTooltip ? (_this$componentConfig5 = _this.componentConfig) === null || _this$componentConfig5 === void 0 ? void 0 : _this$componentConfig5.tooltip : "",
73
73
  component: /*#__PURE__*/React.createElement(ApaasInput, _extends({}, _this.componentConfig, {
74
74
  placeholder: "\u8BF7\u8F93\u5165".concat(_this.name),
75
75
  onChange: function onChange(e) {
76
76
  var _this$componentConfig6, _e$target;
77
77
  return p === null || p === void 0 ? void 0 : p.onChange((_this$componentConfig6 = _this.componentConfig) !== null && _this$componentConfig6 !== void 0 && _this$componentConfig6.isNumber ? e : e === null || e === void 0 ? void 0 : (_e$target = e.target) === null || _e$target === void 0 ? void 0 : _e$target.value);
78
+ },
79
+ onBlur: function onBlur(e) {
80
+ var _this$componentConfig7, _e$target2;
81
+ return p === null || p === void 0 ? void 0 : p.onBlur((_this$componentConfig7 = _this.componentConfig) !== null && _this$componentConfig7 !== void 0 && _this$componentConfig7.isNumber ? e : e === null || e === void 0 ? void 0 : (_e$target2 = e.target) === null || _e$target2 === void 0 ? void 0 : _e$target2.value, "input");
78
82
  }
79
83
  }))
80
84
  });
@@ -90,17 +94,17 @@ var BasicInput = /*#__PURE__*/_createClass(function BasicInput(options) {
90
94
  // 过滤组件id
91
95
  name: item.name,
92
96
  // 过滤组件名称
93
- filterComponentType: 'SelectInput',
97
+ filterComponentType: "SelectInput",
94
98
  props: {
95
99
  filterOptions: SEARCH_OPTIONS
96
100
  },
97
101
  filterFn: function filterFn(value) {
98
102
  return function (i) {
99
- return "".concat(_filterFn.filterTableListItemColumnValue(i, item.id, 'input')).includes(value);
103
+ return "".concat(_filterFn.filterTableListItemColumnValue(i, item.id, "input")).includes(value);
100
104
  };
101
105
  },
102
106
  formatFilterValue: function formatFilterValue(value) {
103
- if (['in', 'anylike'].includes(value.type)) {
107
+ if (["in", "anylike"].includes(value.type)) {
104
108
  return batchInput(value.keywords);
105
109
  } else {
106
110
  return value;
@@ -119,7 +123,7 @@ var BasicInput = /*#__PURE__*/_createClass(function BasicInput(options) {
119
123
  this.workOrderUniqueKey = options === null || options === void 0 ? void 0 : options.workOrderUniqueKey;
120
124
  this.rules = [{
121
125
  validator: function validator(_, value) {
122
- var _this$componentConfig7, _this$componentConfig8, _this$componentConfig9, _this$componentConfig10, _this$componentConfig11, _this$componentConfig12;
126
+ var _this$componentConfig8, _this$componentConfig9, _this$componentConfig10, _this$componentConfig11, _this$componentConfig12, _this$componentConfig13;
123
127
  if (!value) {
124
128
  return Promise.resolve();
125
129
  }
@@ -127,23 +131,23 @@ var BasicInput = /*#__PURE__*/_createClass(function BasicInput(options) {
127
131
  var mail = /^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9]+(\.[a-zA-Z0-9-]+)*\.([a-zA-Z]{2,})$/;
128
132
  var phone = /^1\d{10}$/;
129
133
  var testList = [];
130
- ((_this$componentConfig7 = _this.componentConfig) === null || _this$componentConfig7 === void 0 ? void 0 : _this$componentConfig7.isNumber) && testList.push(number);
131
- ((_this$componentConfig8 = _this.componentConfig) === null || _this$componentConfig8 === void 0 ? void 0 : _this$componentConfig8.isMail) && testList.push(mail);
132
- ((_this$componentConfig9 = _this.componentConfig) === null || _this$componentConfig9 === void 0 ? void 0 : _this$componentConfig9.isPhone) && testList.push(phone);
134
+ ((_this$componentConfig8 = _this.componentConfig) === null || _this$componentConfig8 === void 0 ? void 0 : _this$componentConfig8.isNumber) && testList.push(number);
135
+ ((_this$componentConfig9 = _this.componentConfig) === null || _this$componentConfig9 === void 0 ? void 0 : _this$componentConfig9.isMail) && testList.push(mail);
136
+ ((_this$componentConfig10 = _this.componentConfig) === null || _this$componentConfig10 === void 0 ? void 0 : _this$componentConfig10.isPhone) && testList.push(phone);
133
137
  var isTest = testList.some(function (item) {
134
138
  return item.test(value);
135
139
  });
136
140
  if (testList.length && !isTest) {
137
- return Promise.reject(new Error('请填写正确的格式'));
141
+ return Promise.reject(new Error("请填写正确的格式"));
138
142
  }
139
- if ((_this$componentConfig10 = _this.componentConfig) !== null && _this$componentConfig10 !== void 0 && _this$componentConfig10.isNumber && value > Number.MAX_SAFE_INTEGER) {
140
- return Promise.reject(new Error('输入数值超出最大数字上限,请使用文本框替代当前数字输入框组件'));
143
+ if ((_this$componentConfig11 = _this.componentConfig) !== null && _this$componentConfig11 !== void 0 && _this$componentConfig11.isNumber && value > Number.MAX_SAFE_INTEGER) {
144
+ return Promise.reject(new Error("输入数值超出最大数字上限,请使用文本框替代当前数字输入框组件"));
141
145
  }
142
- if ((_this$componentConfig11 = _this.componentConfig) !== null && _this$componentConfig11 !== void 0 && (_this$componentConfig12 = _this$componentConfig11.rulesOptions) !== null && _this$componentConfig12 !== void 0 && _this$componentConfig12.length) {
143
- var _this$componentConfig13;
144
- var rulesList = (_this$componentConfig13 = _this.componentConfig) === null || _this$componentConfig13 === void 0 ? void 0 : _this$componentConfig13.rulesOptions.filter(function (item) {
145
- var _this$componentConfig14;
146
- return (((_this$componentConfig14 = _this.componentConfig) === null || _this$componentConfig14 === void 0 ? void 0 : _this$componentConfig14.selectRules) || []).includes(item.id);
146
+ if ((_this$componentConfig12 = _this.componentConfig) !== null && _this$componentConfig12 !== void 0 && (_this$componentConfig13 = _this$componentConfig12.rulesOptions) !== null && _this$componentConfig13 !== void 0 && _this$componentConfig13.length) {
147
+ var _this$componentConfig14;
148
+ var rulesList = (_this$componentConfig14 = _this.componentConfig) === null || _this$componentConfig14 === void 0 ? void 0 : _this$componentConfig14.rulesOptions.filter(function (item) {
149
+ var _this$componentConfig15;
150
+ return (((_this$componentConfig15 = _this.componentConfig) === null || _this$componentConfig15 === void 0 ? void 0 : _this$componentConfig15.selectRules) || []).includes(item.id);
147
151
  });
148
152
  if (!rulesList.length) {
149
153
  return Promise.resolve();
@@ -163,11 +167,11 @@ var BasicInput = /*#__PURE__*/_createClass(function BasicInput(options) {
163
167
  return Promise.resolve();
164
168
  }
165
169
  }, {
166
- validateTrigger: 'onBlur',
170
+ validateTrigger: "onBlur",
167
171
  validator: function () {
168
172
  var _validator = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(_, value) {
169
- var _this$componentConfig15;
170
- var _resultList$, params, _yield$replaceCheck, resultList, _this$componentConfig16, _this$componentConfig17, _this$componentConfig18, messageMap;
173
+ var _this$componentConfig16;
174
+ var _resultList$, params, _yield$replaceCheck, resultList, _this$componentConfig17, _this$componentConfig18, _this$componentConfig19, messageMap;
171
175
  return _regeneratorRuntime().wrap(function _callee$(_context) {
172
176
  while (1) switch (_context.prev = _context.next) {
173
177
  case 0:
@@ -177,7 +181,7 @@ var BasicInput = /*#__PURE__*/_createClass(function BasicInput(options) {
177
181
  }
178
182
  return _context.abrupt("return", Promise.resolve());
179
183
  case 2:
180
- if (!((_this$componentConfig15 = _this.componentConfig) !== null && _this$componentConfig15 !== void 0 && _this$componentConfig15.replaceWarn)) {
184
+ if (!((_this$componentConfig16 = _this.componentConfig) !== null && _this$componentConfig16 !== void 0 && _this$componentConfig16.replaceWarn)) {
181
185
  _context.next = 11;
182
186
  break;
183
187
  }
@@ -200,11 +204,11 @@ var BasicInput = /*#__PURE__*/_createClass(function BasicInput(options) {
200
204
  break;
201
205
  }
202
206
  messageMap = {
203
- currWorkOrder: '数据已存在本模版同节点中,不能重复提交',
204
- currFlow: '数据已存在本模版中,不能重复提交',
205
- allWorkOrder: '数据已存在其他模版中,不能重复提交'
207
+ currWorkOrder: "数据已存在本模版同节点中,不能重复提交",
208
+ currFlow: "数据已存在本模版中,不能重复提交",
209
+ allWorkOrder: "数据已存在其他模版中,不能重复提交"
206
210
  };
207
- return _context.abrupt("return", Promise.reject(new Error(messageMap[(_this$componentConfig16 = (_this$componentConfig17 = _this.componentConfig) === null || _this$componentConfig17 === void 0 ? void 0 : (_this$componentConfig18 = _this$componentConfig17.repeatConfig) === null || _this$componentConfig18 === void 0 ? void 0 : _this$componentConfig18.repeatRange) !== null && _this$componentConfig16 !== void 0 ? _this$componentConfig16 : ''] || '内容已存在,不能重复提交')));
211
+ return _context.abrupt("return", Promise.reject(new Error(messageMap[(_this$componentConfig17 = (_this$componentConfig18 = _this.componentConfig) === null || _this$componentConfig18 === void 0 ? void 0 : (_this$componentConfig19 = _this$componentConfig18.repeatConfig) === null || _this$componentConfig19 === void 0 ? void 0 : _this$componentConfig19.repeatRange) !== null && _this$componentConfig17 !== void 0 ? _this$componentConfig17 : ""] || "内容已存在,不能重复提交")));
208
212
  case 11:
209
213
  case "end":
210
214
  return _context.stop();
@@ -220,6 +224,6 @@ var BasicInput = /*#__PURE__*/_createClass(function BasicInput(options) {
220
224
  this.isCombinationComponent = false;
221
225
  this.canSort = true;
222
226
  this.children = [];
223
- this.dataType = options !== null && options !== void 0 && (_options$componentCon = options.componentConfig) !== null && _options$componentCon !== void 0 && _options$componentCon.isNumber ? 'number' : 'string';
227
+ this.dataType = options !== null && options !== void 0 && (_options$componentCon = options.componentConfig) !== null && _options$componentCon !== void 0 && _options$componentCon.isNumber ? "number" : "string";
224
228
  });
225
229
  export default BasicInput;
@@ -7,7 +7,7 @@ import District from "../BS/BsPosting/components//District";
7
7
  import Detail from "../BS/BsPosting/components//Detail";
8
8
  import ReceiverName from "../BS/BsPosting/components//ReceiverName";
9
9
  import ReceiverMobile from "../BS/BsPosting/components//ReceiverMobile";
10
- declare type SortColumnsField = Array<'province' | 'city' | 'district' | 'detail' | 'name' | 'mobile'>;
10
+ declare type SortColumnsField = Array<string>;
11
11
  declare class BasicPosting implements ComponentInterface {
12
12
  name: string;
13
13
  id: string;
@@ -72,14 +72,10 @@ var BasicPosting = /*#__PURE__*/_createClass(function BasicPosting(options) {
72
72
  });
73
73
  });
74
74
  _defineProperty(this, "getSortColumns", function (sortColumns) {
75
+ var _sortColumns$split;
75
76
  var defaultSortColumn = ['province', 'city', 'district', 'detail', 'name', 'mobile'];
76
77
  if (!sortColumns) return defaultSortColumn;
77
- try {
78
- var parseSortColumns = JSON.parse(sortColumns);
79
- return parseSortColumns;
80
- } catch (e) {
81
- return defaultSortColumn;
82
- }
78
+ return (_sortColumns$split = sortColumns === null || sortColumns === void 0 ? void 0 : sortColumns.split(',')) !== null && _sortColumns$split !== void 0 ? _sortColumns$split : [];
83
79
  });
84
80
  _defineProperty(this, "renderPc", function (value, record) {
85
81
  var _ref;
@@ -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 | CommonInput | JstSendGood | MsgStatus | BasicPosting | StatusSelect | BasicInput | BasicTypeInput | BasicAddress | BasicCascader | BasicCheckbox | BasicDataTime | BasicSelect | BasicSelectOption | BasicRadio | BasicTextArea | BasicPicture | BasicPicturePro | BasicMultSelect | BasicGrade | BasicRate | BasicFile | SubForm | CommonDataTime | TradeId | ShopName | BuyerNick | ReceiverName | ReceiverMobile | ReceiverAddress | TradeDateTime | Logistics | ReturnLogistics | ActualPayment | ERemark | AliPay | ItemSelect | ItemId | ItemEnCode | SystemOrderNo | Ordinary | ThirdItemSelect | Payment | ReissueLogistics | JstItemSelect | JstSupply | BsSystemOrder | BsGoods | BsE3Goods | PublicGoods | PublicReissueGoods | PublicExchange | BsE3Reissue | BsExchange | BsReissue | BsReturn | FlowStatusSelect | FlowMarkSelect | FlowTag | TemplateSelect | WorkOrderId | LogisticsInterception | LogisticsMoreInterception | LogisticsTrajectory | LogisticsMoreTrajectory | PlatForm | ShopInput | Submitter | PrevSubmitter | FlowCreator | Handler | CompletedUser | FlowWorkOrderId | Calculation | CommonSystemOrder | CommonMultiStatus | NodeDeadLine | HandlerDeadLine | NodeStayDuration | WlnGoods | BsPosting | NodeInput | FlowWorkOrderStatus | WdtGoods | WdtReissue | WdtReturn | WdtExchange | WdtShopSelect | KmVideo | PaymentVoucherCode | Label | MemberLevel | AfterSalesOrderId | GyGoods | GyReissue | GyReturn | AsyncSelect | SkxIdInputSelect | SkxGoods | OrderSubForm | FlowOverallStatusSelect;
3
+ export declare const factory: (type: string, options: PickOption) => BsLogistics | BsSystemOrder | BsE3Reissue | CommonInput | BasicInput | JstSendGood | MsgStatus | BasicPosting | PublicGoods | PublicReissueGoods | ReturnLogistics | StatusSelect | WdtReissue | BasicTypeInput | BasicAddress | BasicCascader | BasicCheckbox | BasicDataTime | BasicSelect | BasicSelectOption | BasicRadio | BasicTextArea | BasicPicture | BasicPicturePro | BasicMultSelect | BasicGrade | BasicRate | BasicFile | SubForm | CommonDataTime | 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 | ShopInput | Submitter | PrevSubmitter | FlowCreator | Handler | CompletedUser | FlowWorkOrderId | Calculation | CommonSystemOrder | CommonMultiStatus | NodeDeadLine | HandlerDeadLine | NodeStayDuration | WlnGoods | BsPosting | NodeInput | FlowWorkOrderStatus | WdtGoods | WdtReturn | WdtExchange | WdtShopSelect | KmVideo | PaymentVoucherCode | Label | MemberLevel | AfterSalesOrderId | GyGoods | GyReissue | GyReturn | AsyncSelect | SkxIdInputSelect | SkxGoods | OrderSubForm | FlowOverallStatusSelect;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kmkf-fe-packages/services-components",
3
- "version": "2.2.31-beta.53",
3
+ "version": "2.2.31-beta.57",
4
4
  "module": "dist/esm/index.js",
5
5
  "typings": "dist/esm/index.d.ts",
6
6
  "files": [
@@ -41,7 +41,7 @@
41
41
  "publishConfig": {
42
42
  "access": "public"
43
43
  },
44
- "gitHead": "da633abe80f99d28e5ab6d93e38822a002674de0",
44
+ "gitHead": "a70cd51a0127966607a31d3572f1285ae8dc15a4",
45
45
  "gitHooks": {
46
46
  "pre-commit": "lint-staged"
47
47
  }
@@ -1,52 +0,0 @@
1
- "use strict";
2
-
3
- exports.__esModule = true;
4
- var react_1 = require("react");
5
- var react_redux_1 = require("react-redux");
6
- var toolkit_1 = require("@reduxjs/toolkit");
7
- var getTemplate = function getTemplate(companyUserConfig) {
8
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t;
9
- return JSON.stringify({
10
- hasWln: (_c = (_b = (_a = companyUserConfig === null || companyUserConfig === void 0 ? void 0 : companyUserConfig.plugins) === null || _a === void 0 ? void 0 : _a.wln) === null || _b === void 0 ? void 0 : _b.show) !== null && _c !== void 0 ? _c : false,
11
- hasWdt: (_f = (_e = (_d = companyUserConfig === null || companyUserConfig === void 0 ? void 0 : companyUserConfig.plugins) === null || _d === void 0 ? void 0 : _d.wdt) === null || _e === void 0 ? void 0 : _e.show) !== null && _f !== void 0 ? _f : false,
12
- hasBs: (_j = (_h = (_g = companyUserConfig === null || companyUserConfig === void 0 ? void 0 : companyUserConfig.plugins) === null || _g === void 0 ? void 0 : _g.bs) === null || _h === void 0 ? void 0 : _h.show) !== null && _j !== void 0 ? _j : false,
13
- hasE3: (_m = (_l = (_k = companyUserConfig === null || companyUserConfig === void 0 ? void 0 : companyUserConfig.plugins) === null || _k === void 0 ? void 0 : _k.bse3) === null || _l === void 0 ? void 0 : _l.show) !== null && _m !== void 0 ? _m : false,
14
- hasJst: (_q = (_p = (_o = companyUserConfig === null || companyUserConfig === void 0 ? void 0 : companyUserConfig.plugins) === null || _o === void 0 ? void 0 : _o.jst) === null || _p === void 0 ? void 0 : _p.show) !== null && _q !== void 0 ? _q : false,
15
- hasGy: (_t = (_s = (_r = companyUserConfig === null || companyUserConfig === void 0 ? void 0 : companyUserConfig.plugins) === null || _r === void 0 ? void 0 : _r.gy) === null || _s === void 0 ? void 0 : _s.show) !== null && _t !== void 0 ? _t : false
16
- });
17
- };
18
- function useGetHasErpData() {
19
- var companyUserConfig = react_redux_1.useSelector(toolkit_1.createSelector([function (state) {
20
- var _a, _b, _c, _d;
21
- console.log("state--useSelector", state);
22
- /**
23
- * pc main
24
- * 端 workOrder
25
- * **/
26
- return (_d = (_b = (_a = state === null || state === void 0 ? void 0 : state.main) === null || _a === void 0 ? void 0 : _a.userInfo) !== null && _b !== void 0 ? _b : (_c = state === null || state === void 0 ? void 0 : state.workOrder) === null || _c === void 0 ? void 0 : _c.userInfo) !== null && _d !== void 0 ? _d : {};
27
- }], function (state) {
28
- var _a;
29
- var companyUserConfig = (_a = state === null || state === void 0 ? void 0 : state.companyUserConfig) !== null && _a !== void 0 ? _a : {};
30
- if (typeof companyUserConfig === "string") {
31
- try {
32
- companyUserConfig = JSON.parse(companyUserConfig);
33
- } catch (e) {
34
- console.error("companyUserConfig转换异常", companyUserConfig);
35
- companyUserConfig = {};
36
- }
37
- }
38
- return companyUserConfig;
39
- }));
40
- var _a = react_1.useState(getTemplate({})),
41
- hasErpDataJson = _a[0],
42
- setHasErpDataJson = _a[1];
43
- react_1.useEffect(function () {
44
- setHasErpDataJson(getTemplate(companyUserConfig));
45
- console.log("companyUserConfig---", companyUserConfig);
46
- }, [companyUserConfig]);
47
- var hasErpData = react_1.useMemo(function () {
48
- return JSON.parse(hasErpDataJson);
49
- }, [hasErpDataJson]);
50
- return hasErpData;
51
- }
52
- exports["default"] = useGetHasErpData;
@@ -1,180 +0,0 @@
1
- "use strict";
2
-
3
- var __awaiter = this && this.__awaiter || function (thisArg, _arguments, P, generator) {
4
- function adopt(value) {
5
- return value instanceof P ? value : new P(function (resolve) {
6
- resolve(value);
7
- });
8
- }
9
- return new (P || (P = Promise))(function (resolve, reject) {
10
- function fulfilled(value) {
11
- try {
12
- step(generator.next(value));
13
- } catch (e) {
14
- reject(e);
15
- }
16
- }
17
- function rejected(value) {
18
- try {
19
- step(generator["throw"](value));
20
- } catch (e) {
21
- reject(e);
22
- }
23
- }
24
- function step(result) {
25
- result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected);
26
- }
27
- step((generator = generator.apply(thisArg, _arguments || [])).next());
28
- });
29
- };
30
- var __generator = this && this.__generator || function (thisArg, body) {
31
- var _ = {
32
- label: 0,
33
- sent: function sent() {
34
- if (t[0] & 1) throw t[1];
35
- return t[1];
36
- },
37
- trys: [],
38
- ops: []
39
- },
40
- f,
41
- y,
42
- t,
43
- g;
44
- return g = {
45
- next: verb(0),
46
- "throw": verb(1),
47
- "return": verb(2)
48
- }, typeof Symbol === "function" && (g[Symbol.iterator] = function () {
49
- return this;
50
- }), g;
51
- function verb(n) {
52
- return function (v) {
53
- return step([n, v]);
54
- };
55
- }
56
- function step(op) {
57
- if (f) throw new TypeError("Generator is already executing.");
58
- while (_) try {
59
- if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
60
- if (y = 0, t) op = [op[0] & 2, t.value];
61
- switch (op[0]) {
62
- case 0:
63
- case 1:
64
- t = op;
65
- break;
66
- case 4:
67
- _.label++;
68
- return {
69
- value: op[1],
70
- done: false
71
- };
72
- case 5:
73
- _.label++;
74
- y = op[1];
75
- op = [0];
76
- continue;
77
- case 7:
78
- op = _.ops.pop();
79
- _.trys.pop();
80
- continue;
81
- default:
82
- if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) {
83
- _ = 0;
84
- continue;
85
- }
86
- if (op[0] === 3 && (!t || op[1] > t[0] && op[1] < t[3])) {
87
- _.label = op[1];
88
- break;
89
- }
90
- if (op[0] === 6 && _.label < t[1]) {
91
- _.label = t[1];
92
- t = op;
93
- break;
94
- }
95
- if (t && _.label < t[2]) {
96
- _.label = t[2];
97
- _.ops.push(op);
98
- break;
99
- }
100
- if (t[2]) _.ops.pop();
101
- _.trys.pop();
102
- continue;
103
- }
104
- op = body.call(thisArg, _);
105
- } catch (e) {
106
- op = [6, e];
107
- y = 0;
108
- } finally {
109
- f = t = 0;
110
- }
111
- if (op[0] & 5) throw op[1];
112
- return {
113
- value: op[0] ? op[1] : void 0,
114
- done: true
115
- };
116
- }
117
- };
118
- exports.__esModule = true;
119
- var react_1 = require("react");
120
- var useGetHasErpData_1 = require("../hook/useGetHasErpData");
121
- var ahooks_1 = require("ahooks");
122
- var kmkf_utils_1 = require("@kmkf-fe-packages/kmkf-utils");
123
- function useGetErpAddressData(notJudgedErp) {
124
- var _this = this;
125
- var _a = react_1.useState("loading"),
126
- globalState = _a[0],
127
- setGlobalState = _a[1];
128
- var hasErpData = useGetHasErpData_1["default"]();
129
- ahooks_1.useUpdateEffect(function () {
130
- asyncQueryData(hasErpData, notJudgedErp);
131
- }, [hasErpData, notJudgedErp]);
132
- var asyncQueryData = function asyncQueryData(hasErpData, notJudgedErp) {
133
- return __awaiter(_this, void 0, void 0, function () {
134
- var hasBs, hasWdt, hasGy, promises, e_1;
135
- return __generator(this, function (_a) {
136
- switch (_a.label) {
137
- case 0:
138
- hasBs = hasErpData.hasBs, hasWdt = hasErpData.hasWdt, hasGy = hasErpData.hasGy;
139
- promises = [];
140
- if (hasBs || notJudgedErp) promises.push(kmkf_utils_1.servers.queryBsAddressData);
141
- if (hasWdt || notJudgedErp) promises.push(kmkf_utils_1.servers.queryWdtAddressData);
142
- if (hasGy || notJudgedErp) promises.push(kmkf_utils_1.servers.queryGyAddressData);
143
- _a.label = 1;
144
- case 1:
145
- _a.trys.push([1, 3,, 4]);
146
- return [4 /*yield*/, Promise.all(promises.map(function (promise) {
147
- return promise();
148
- }))];
149
- case 2:
150
- _a.sent();
151
- setGlobalState("success");
152
- return [3 /*break*/, 4];
153
- case 3:
154
- e_1 = _a.sent();
155
- setGlobalState("failed");
156
- return [3 /*break*/, 4];
157
- case 4:
158
- return [2 /*return*/];
159
- }
160
- });
161
- });
162
- };
163
-
164
- var onReload = function onReload() {
165
- return __awaiter(_this, void 0, void 0, function () {
166
- return __generator(this, function (_a) {
167
- switch (_a.label) {
168
- case 0:
169
- return [4 /*yield*/, asyncQueryData(hasErpData, notJudgedErp)];
170
- case 1:
171
- _a.sent();
172
- return [2 /*return*/];
173
- }
174
- });
175
- });
176
- };
177
-
178
- return [globalState, onReload];
179
- }
180
- exports["default"] = useGetErpAddressData;