@kmkf-fe-packages/basic-components 2.10.4 → 2.10.6

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 (2) hide show
  1. package/dist/index.esm.js +75 -37
  2. package/package.json +3 -3
package/dist/index.esm.js CHANGED
@@ -7863,6 +7863,7 @@ var ParseLogistics = function ParseLogistics(props) {
7863
7863
  onChange === null || onChange === void 0 ? void 0 : onChange(data);
7864
7864
  }).catch(function (e) {
7865
7865
  handleAIIdentify(fullAddress);
7866
+ console.log(e);
7866
7867
  }).finally(function () {
7867
7868
  setLoading(false);
7868
7869
  });
@@ -7886,6 +7887,7 @@ var ParseLogistics = function ParseLogistics(props) {
7886
7887
  var data = res.data;
7887
7888
  onChange === null || onChange === void 0 ? void 0 : onChange(data);
7888
7889
  }).catch(function (e) {
7890
+ console.log(e);
7889
7891
  message.error('识别失败,请输入正确的信息');
7890
7892
  }).finally(function () {
7891
7893
  setAiLoading(false);
@@ -8669,6 +8671,7 @@ var processSceneStatus = function processSceneStatus(getValue) {
8669
8671
  MSG_STATUS: 'msgStatusValues',
8670
8672
  WDT_WAREHOUSING_STATUS: 'wdtInStockStatusItemList',
8671
8673
  JKY_WAREHOUSING_STATUS: 'jkyInStockStatusItemList',
8674
+ JST_WAREHOUSING_STATUS: 'jstInStockStatusItemList',
8672
8675
  WLN_WAREHOUSING_STATUS: 'wlnInStockStatusItemList'
8673
8676
  };
8674
8677
  return _defineProperty({}, nex.uniqueKey, jsonParseSecurity(getValue("".concat(nex.uniqueKey, "_").concat(STATUS_LIST_MAP[nex.workOrderComponentType])), []));
@@ -9518,6 +9521,7 @@ var transformWorkOrderData = function transformWorkOrderData(templateColumns) {
9518
9521
  WDT_WAREHOUSING_STATUS: processSceneStatus,
9519
9522
  WLN_WAREHOUSING_STATUS: processSceneStatus,
9520
9523
  JKY_WAREHOUSING_STATUS: processSceneStatus,
9524
+ JST_WAREHOUSING_STATUS: processSceneStatus,
9521
9525
  BS_LOGISTICS: processErpLogistics,
9522
9526
  WLN_LOGISTICS: processErpLogistics,
9523
9527
  WDT_LOGISTICS: processErpLogistics,
@@ -12114,7 +12118,7 @@ var Goods = function Goods(props) {
12114
12118
  return querySkus({
12115
12119
  shopId: shopId,
12116
12120
  numIids: numIid
12117
- }).catch(function () {});
12121
+ }).catch(console.debug);
12118
12122
  case 5:
12119
12123
  res = _context3.sent;
12120
12124
  data = (res === null || res === void 0 ? void 0 : res.success) && (res === null || res === void 0 ? void 0 : res.data);
@@ -12498,7 +12502,7 @@ var GoodItem = function GoodItem(props) {
12498
12502
  return querySkus({
12499
12503
  shopId: shopId,
12500
12504
  numIids: numIid
12501
- }).catch(function () {});
12505
+ }).catch(console.debug);
12502
12506
  case 5:
12503
12507
  res = _context3.sent;
12504
12508
  data = (res === null || res === void 0 ? void 0 : res.success) && (res === null || res === void 0 ? void 0 : res.data);
@@ -13440,6 +13444,7 @@ var LogisticsInterception = function LogisticsInterception(props) {
13440
13444
  });
13441
13445
  }
13442
13446
  }
13447
+ console.log('newValue', newValue);
13443
13448
  onChange === null || onChange === void 0 ? void 0 : onChange(newValue, type);
13444
13449
  };
13445
13450
  //智能识别回调
@@ -14022,14 +14027,21 @@ var LogisticsMoreTrajectory = function LogisticsMoreTrajectory(props) {
14022
14027
  }); // 1、初始值没有 传入值有请求快照
14023
14028
  // 2、初始值有 传入值有 其中有不一样的请求快照
14024
14029
  // 3、初始值有 传入值有 都一样的返回初始值
14030
+ console.log('list', initList, valueList, changeList);
14031
+ // console.log('old', initValue, value, changeValue);
14032
+ // console.log('一样', JSON.stringify(initList) !== JSON.stringify(valueList));
14033
+ // console.log(
14034
+ // '一样2',
14035
+ // JSON.stringify(changeList) !== JSON.stringify(valueList),
14036
+ // );
14025
14037
  if (!(!initList.length && !valueList.length)) {
14026
- _context.next = 7;
14038
+ _context.next = 8;
14027
14039
  break;
14028
14040
  }
14029
14041
  return _context.abrupt("return");
14030
- case 7:
14042
+ case 8:
14031
14043
  if (!(JSON.stringify(initList) === JSON.stringify(valueList))) {
14032
- _context.next = 13;
14044
+ _context.next = 14;
14033
14045
  break;
14034
14046
  }
14035
14047
  initSnapshotList = initValue.reduce(function (prv, next) {
@@ -14048,13 +14060,13 @@ var LogisticsMoreTrajectory = function LogisticsMoreTrajectory(props) {
14048
14060
  setNewValue(initValue);
14049
14061
  onChange(initValue);
14050
14062
  }
14051
- _context.next = 29;
14063
+ _context.next = 30;
14052
14064
  break;
14053
- case 13:
14065
+ case 14:
14054
14066
  if (!(
14055
14067
  //开启了物流快照才会获取快照信息
14056
14068
  hasSnapshot && JSON.stringify(initList) !== JSON.stringify(valueList) && JSON.stringify(changeList) !== JSON.stringify(valueList))) {
14057
- _context.next = 28;
14069
+ _context.next = 29;
14058
14070
  break;
14059
14071
  }
14060
14072
  hasSave.current = false;
@@ -14063,7 +14075,7 @@ var LogisticsMoreTrajectory = function LogisticsMoreTrajectory(props) {
14063
14075
  });
14064
14076
  listValue = cloneDeep(value);
14065
14077
  if (!hasValue) {
14066
- _context.next = 23;
14078
+ _context.next = 24;
14067
14079
  break;
14068
14080
  }
14069
14081
  requestList = valueList.map(function (item) {
@@ -14082,9 +14094,9 @@ var LogisticsMoreTrajectory = function LogisticsMoreTrajectory(props) {
14082
14094
  });
14083
14095
  }
14084
14096
  });
14085
- _context.next = 21;
14097
+ _context.next = 22;
14086
14098
  return Promise.allSettled(requestList);
14087
- case 21:
14099
+ case 22:
14088
14100
  requestValues = _context.sent;
14089
14101
  listValue = cloneDeep(value).map(function (item, index) {
14090
14102
  var _requestValues$index, _requestValues$index$, _requestValues$index$2;
@@ -14092,15 +14104,15 @@ var LogisticsMoreTrajectory = function LogisticsMoreTrajectory(props) {
14092
14104
  trajectorySnapshot: (_requestValues$index = requestValues[index]) === null || _requestValues$index === void 0 ? void 0 : (_requestValues$index$ = _requestValues$index.value) === null || _requestValues$index$ === void 0 ? void 0 : (_requestValues$index$2 = _requestValues$index$.data) === null || _requestValues$index$2 === void 0 ? void 0 : _requestValues$index$2.logisticsStatusDesc
14093
14105
  });
14094
14106
  });
14095
- case 23:
14107
+ case 24:
14096
14108
  setChangeValue(listValue);
14097
14109
  setNewValue(listValue);
14098
14110
  onChange(listValue);
14099
- _context.next = 29;
14111
+ _context.next = 30;
14100
14112
  break;
14101
- case 28:
14102
- setNewValue(value);
14103
14113
  case 29:
14114
+ setNewValue(value);
14115
+ case 30:
14104
14116
  case "end":
14105
14117
  return _context.stop();
14106
14118
  }
@@ -16270,7 +16282,7 @@ var GoodList = function GoodList(props, ref) {
16270
16282
  } else {
16271
16283
  reject$1(res);
16272
16284
  }
16273
- }).catch(function () {});
16285
+ }).catch(console.error);
16274
16286
  };
16275
16287
  getMore();
16276
16288
  };
@@ -18321,6 +18333,7 @@ var SearchHeader = function SearchHeader(_ref) {
18321
18333
  timeOptions = _ref.timeOptions,
18322
18334
  ShopList = _ref.ShopList,
18323
18335
  onSubmit = _ref.onSubmit;
18336
+ console.log('allFields', allFields);
18324
18337
  // const fixedFieldsOptions = useMemo(() => {
18325
18338
  // return allFields.filter(item => fixedFields?.includes(item.id));
18326
18339
  // }, [fixedFields, allFields]);
@@ -18576,7 +18589,9 @@ var WorkorderList = function WorkorderList(props, ref) {
18576
18589
  loading: false
18577
18590
  }));
18578
18591
  setWorkOrderList(newDataSource);
18579
- }).catch(function (error) {}));
18592
+ }).catch(function (error) {
18593
+ console.log('**** 获取表格数据错误', error);
18594
+ }));
18580
18595
  case 19:
18581
18596
  case "end":
18582
18597
  return _context.stop();
@@ -22895,6 +22910,7 @@ var getColumns$6 = function getColumns() {
22895
22910
  title: "\u5B9E\u9645\u8865\u53D1\u6570\u91CF",
22896
22911
  width: 100,
22897
22912
  validator: function validator(_rule, value, extraParams) {
22913
+ console.log('实际补发数量-extraParams', extraParams);
22898
22914
  if (!(extraParams === null || extraParams === void 0 ? void 0 : extraParams.quantityVerify)) return undefined;
22899
22915
  var title = '';
22900
22916
  if (((value === null || value === void 0 ? void 0 : value.kmReissueGoods) || []).some(function (goods) {
@@ -25169,7 +25185,7 @@ var SelectTradeGoods = function SelectTradeGoods(_ref) {
25169
25185
  while (1) switch (_context2.prev = _context2.next) {
25170
25186
  case 0:
25171
25187
  if (!validSystemOrderFn) {
25172
- _context2.next = 6;
25188
+ _context2.next = 7;
25173
25189
  break;
25174
25190
  }
25175
25191
  _context2.next = 3;
@@ -25177,38 +25193,39 @@ var SelectTradeGoods = function SelectTradeGoods(_ref) {
25177
25193
  case 3:
25178
25194
  flag = _context2.sent;
25179
25195
  if (!(flag === false)) {
25180
- _context2.next = 6;
25196
+ _context2.next = 7;
25181
25197
  break;
25182
25198
  }
25199
+ console.log('validSystemOrderFn校验不通过');
25183
25200
  return _context2.abrupt("return");
25184
- case 6:
25201
+ case 7:
25185
25202
  if (!validSystemOrder) {
25186
- _context2.next = 9;
25203
+ _context2.next = 10;
25187
25204
  break;
25188
25205
  }
25189
25206
  message.warning('请选择补发系统单');
25190
25207
  return _context2.abrupt("return");
25191
- case 9:
25208
+ case 10:
25192
25209
  if (!(getDataSourceAsync && (!(dataSource === null || dataSource === void 0 ? void 0 : dataSource.length) || isReloadSelectTable))) {
25193
- _context2.next = 12;
25210
+ _context2.next = 13;
25194
25211
  break;
25195
25212
  }
25196
- _context2.next = 12;
25213
+ _context2.next = 13;
25197
25214
  return getDataSourceAsync();
25198
- case 12:
25215
+ case 13:
25199
25216
  if (!['KM_GOODS', 'KM_REISSUE_GOODS', 'KM_RETURN_GOODS'].includes(type)) {
25200
- _context2.next = 15;
25217
+ _context2.next = 16;
25201
25218
  break;
25202
25219
  }
25203
- _context2.next = 15;
25220
+ _context2.next = 16;
25204
25221
  return getKmSupplier(dataSource);
25205
- case 15:
25222
+ case 16:
25206
25223
  setTradeGoodsVisible(true);
25207
25224
  // 补发直接传入的是systemNo
25208
25225
  if (isShowSelect && isReissueType) {
25209
25226
  setSelectSystemNo(selectedSystemOrders || []);
25210
25227
  }
25211
- case 17:
25228
+ case 18:
25212
25229
  case "end":
25213
25230
  return _context2.stop();
25214
25231
  }
@@ -25410,6 +25427,7 @@ var GoodItem$1 = function GoodItem(props) {
25410
25427
  var isShowSelect = type && ['WDT_GOODS', 'BS_E3_GOODS', 'GY_GOODS', 'JST_GOODS', 'WLN_GOODS', 'KM_GOODS', 'JY_GOODS', 'JY_REISSUE_GOODS', 'JKY_GOODS', 'JKY_REISSUE_GOODS', 'WLN_REISSUE_GOODS', 'GY_REISSUE_GOODS', 'KM_REISSUE_GOODS', 'KM_RETURN_GOODS', 'JST_RETURN_GOODS', 'JST_EXCHANGE_GOODS', 'BS_E3_REISSUE_GOODS', 'WDT_REISSUE_GOODS', 'JST_REISSUE_GOODS'].includes(type) || false;
25411
25428
  var isReissueType = type && ['GY_REISSUE_GOODS', 'KM_REISSUE_GOODS', 'BS_E3_REISSUE_GOODS', 'WDT_REISSUE_GOODS', 'JST_REISSUE_GOODS', 'JY_REISSUE_GOODS', 'JKY_REISSUE_GOODS', 'WLN_REISSUE_GOODS'].includes(type) || false;
25412
25429
  var refModal = useRef();
25430
+ console.debug('表格数据', value);
25413
25431
  var handleDelete = function handleDelete(record, index) {
25414
25432
  onDelete === null || onDelete === void 0 ? void 0 : onDelete(value[index]);
25415
25433
  var newList = _toConsumableArray(value).filter(function (item, i) {
@@ -26190,6 +26208,7 @@ var BsReissue = function BsReissue(props) {
26190
26208
  var _typeMap$type2;
26191
26209
  pubsub.subscribe("".concat(typeMap === null || typeMap === void 0 ? void 0 : (_typeMap$type2 = typeMap[type]) === null || _typeMap$type2 === void 0 ? void 0 : _typeMap$type2.reissueSelectList), function (_, data) {
26192
26210
  var _typeMap$type3;
26211
+ console.log('reissueSelectList', data);
26193
26212
  if (disabled) return;
26194
26213
  var newValue = _objectSpread2(_objectSpread2({}, data.goodValue), {}, {
26195
26214
  shopCode: data === null || data === void 0 ? void 0 : data.shopCode
@@ -27995,6 +28014,7 @@ var OrderSubForm = function OrderSubForm(props) {
27995
28014
  manual = props.manual,
27996
28015
  correlationList = props.subConfig.correlationList,
27997
28016
  effects = props.effects;
28017
+ console.log('effects', effects);
27998
28018
  var valueRef = useRef(value);
27999
28019
  useEffect(function () {
28000
28020
  valueRef.current = value;
@@ -28191,7 +28211,7 @@ var OrderSubForm = function OrderSubForm(props) {
28191
28211
  onChange(_objectSpread2(_objectSpread2({}, value), {}, {
28192
28212
  allOrders: allOrders
28193
28213
  }));
28194
- }).catch(function () {}) : Promise.resolve();
28214
+ }).catch(console.debug) : Promise.resolve();
28195
28215
  };
28196
28216
  var getAllTradeGoodsDetails = function getAllTradeGoodsDetails() {
28197
28217
  var goodDetails = (value === null || value === void 0 ? void 0 : value.allOrders) || [];
@@ -29426,23 +29446,29 @@ var CommonExchangeGoods = function CommonExchangeGoods(props) {
29426
29446
  var getDataSourceAsync = function getDataSourceAsync() {
29427
29447
  return new Promise(function (resolve) {
29428
29448
  pubsub.subscribeOnce(componentMap$4[compType].eventNameMap.returnGoodsSysorderBack, function (_, data) {
29429
- var _componentMap$compTyp9;
29449
+ var _componentMap$compTyp9, _componentMap$compTyp10;
29430
29450
  resolve(data);
29451
+ console.log('getDataSourceAsync---111data--', data, getGoodDetails({
29452
+ returnGoodsValue: data,
29453
+ mode: isStrict,
29454
+ isAllOrders: componentMap$4 === null || componentMap$4 === void 0 ? void 0 : (_componentMap$compTyp9 = componentMap$4[compType]) === null || _componentMap$compTyp9 === void 0 ? void 0 : _componentMap$compTyp9.isShowSelectTradeGoods
29455
+ }));
29431
29456
  setOriginDataSource(getGoodDetails({
29432
29457
  returnGoodsValue: data,
29433
- isAllOrders: componentMap$4 === null || componentMap$4 === void 0 ? void 0 : (_componentMap$compTyp9 = componentMap$4[compType]) === null || _componentMap$compTyp9 === void 0 ? void 0 : _componentMap$compTyp9.isShowSelectTradeGoods,
29458
+ isAllOrders: componentMap$4 === null || componentMap$4 === void 0 ? void 0 : (_componentMap$compTyp10 = componentMap$4[compType]) === null || _componentMap$compTyp10 === void 0 ? void 0 : _componentMap$compTyp10.isShowSelectTradeGoods,
29434
29459
  mode: isStrict
29435
29460
  }));
29436
29461
  });
29437
29462
  pubsub.publish(componentMap$4[compType].eventNameMap.returnGoodsSysorder, compType);
29438
29463
  });
29439
29464
  };
29465
+ console.log('aaa--', originDataSource);
29440
29466
  return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(GoodItem$1, _objectSpread2(_objectSpread2({
29441
29467
  key: componentMap$4[compType].type
29442
29468
  }, props), {}, {
29443
29469
  validSystemOrderFn: function validSystemOrderFn() {
29444
- var _componentMap$compTyp10, _componentMap$compTyp11;
29445
- return (_componentMap$compTyp10 = (_componentMap$compTyp11 = componentMap$4[compType]).validSystemOrderFn) === null || _componentMap$compTyp10 === void 0 ? void 0 : _componentMap$compTyp10.call(_componentMap$compTyp11, form);
29470
+ var _componentMap$compTyp11, _componentMap$compTyp12;
29471
+ return (_componentMap$compTyp11 = (_componentMap$compTyp12 = componentMap$4[compType]).validSystemOrderFn) === null || _componentMap$compTyp11 === void 0 ? void 0 : _componentMap$compTyp11.call(_componentMap$compTyp12, form);
29446
29472
  },
29447
29473
  isReloadSelectTable: componentMap$4[compType].isReloadSelectTable,
29448
29474
  disabled: disabled,
@@ -32293,13 +32319,20 @@ var IdInputSelect = function IdInputSelect(props) {
32293
32319
  tradeId = form.getFieldValue('m3ap1EvEyd');
32294
32320
  skxReturnExpressCode = (_form$getFieldValue = form.getFieldValue('4487c6516b')) === null || _form$getFieldValue === void 0 ? void 0 : (_form$getFieldValue$ = _form$getFieldValue[0]) === null || _form$getFieldValue$ === void 0 ? void 0 : _form$getFieldValue$.logisticsCode;
32295
32321
  blurFrom = form.getFieldValue('skx_return_billNo_blur_from');
32322
+ console.log('asyncQueryData---', {
32323
+ skxReturnExpressCode: skxReturnExpressCode,
32324
+ blurFrom: blurFrom,
32325
+ tradeId: tradeId,
32326
+ tradeIdRef: tradeIdRef.current,
32327
+ form: form
32328
+ });
32296
32329
  if (!(type === 'SKX_OUTBOUND_NOTICE_NO' && !tradeId || type === 'SKX_RETURN_BILL_NO' && !tradeId && !skxReturnExpressCode)) {
32297
- _context3.next = 6;
32330
+ _context3.next = 7;
32298
32331
  break;
32299
32332
  }
32300
32333
  setDataSource([]);
32301
32334
  return _context3.abrupt("return");
32302
- case 6:
32335
+ case 7:
32303
32336
  setSpinning(true);
32304
32337
  // 判断是从哪个组件失焦,若是从[SKX]退换物流信息(TH)失焦,则根据物流单号查询,若是从订单号组件失焦,则根据订单号查询
32305
32338
  typeMap$6[type].asyncGetData(type === 'SKX_RETURN_BILL_NO' && blurFrom === '4487c6516b' ? {
@@ -32313,7 +32346,7 @@ var IdInputSelect = function IdInputSelect(props) {
32313
32346
  }).finally(function () {
32314
32347
  setSpinning(false);
32315
32348
  });
32316
- case 8:
32349
+ case 9:
32317
32350
  case "end":
32318
32351
  return _context3.stop();
32319
32352
  }
@@ -32405,6 +32438,11 @@ var IdInputSelect = function IdInputSelect(props) {
32405
32438
  }))));
32406
32439
  };
32407
32440
  var handleChange = function handleChange(val, isInput) {
32441
+ console.log('handleChange---', {
32442
+ val: val,
32443
+ value: value,
32444
+ isInput: isInput
32445
+ });
32408
32446
  var isReturnBillNoChange = type === 'SKX_RETURN_BILL_NO' && form.getFieldValue('skx_return_billNo_blur_from') === '4487c6516b';
32409
32447
  onChange === null || onChange === void 0 ? void 0 : onChange(val, value !== val && (!!isInput || isReturnBillNoChange));
32410
32448
  // 如果类型是[SKX]退换货单号,则根据blurFrom判断是从[SKX]退换物流信息(TH)失焦,则调用onBlur
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kmkf-fe-packages/basic-components",
3
- "version": "2.10.4",
3
+ "version": "2.10.6",
4
4
  "description": "> TODO: description",
5
5
  "homepage": "",
6
6
  "license": "ISC",
@@ -20,7 +20,7 @@
20
20
  "watch": "nodemon --ignore dist/ --ignore node_modules/ --watch src/ -C -e ts,tsx,less --debug -x 'yarn async'"
21
21
  },
22
22
  "dependencies": {
23
- "@kmkf-fe-packages/kmkf-utils": "2.10.4",
23
+ "@kmkf-fe-packages/kmkf-utils": "2.10.6",
24
24
  "ahooks": "^3.7.4",
25
25
  "ali-react-table": "2.6.1",
26
26
  "bignumber.js": "^9.1.2",
@@ -66,5 +66,5 @@
66
66
  "publishConfig": {
67
67
  "access": "public"
68
68
  },
69
- "gitHead": "545af3d105d59a2b0b8f92cb0dd8804f4e5631f6"
69
+ "gitHead": "8e459352f1aa0e95d05e48a4bf4bb9d9d947b032"
70
70
  }