@kmkf-fe-packages/basic-components 2.10.9-beta.34 → 2.10.9-beta.35

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.
package/dist/index.esm.js CHANGED
@@ -10510,6 +10510,7 @@ var SubForm = function SubForm(props) {
10510
10510
  maxCount = props.maxCount;
10511
10511
  var ref = useRef(null);
10512
10512
  var isRequest = useRef(false);
10513
+ var cursorIdRef = useRef(null);
10513
10514
  var _useState = useState(false),
10514
10515
  _useState2 = _slicedToArray(_useState, 2),
10515
10516
  open = _useState2[0],
@@ -10753,6 +10754,7 @@ var SubForm = function SubForm(props) {
10753
10754
  };
10754
10755
  var getWorkOrderList = /*#__PURE__*/function () {
10755
10756
  var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
10757
+ var _cursorIdRef$current;
10756
10758
  var _ref2,
10757
10759
  _ref2$pageNo,
10758
10760
  pageNo,
@@ -10760,9 +10762,12 @@ var SubForm = function SubForm(props) {
10760
10762
  componentList,
10761
10763
  params,
10762
10764
  queryComponents,
10765
+ cursorParams,
10766
+ queryKey,
10763
10767
  res,
10764
10768
  data,
10765
10769
  success,
10770
+ _cursorIdRef$current2,
10766
10771
  transDataSourceItem,
10767
10772
  headerKeys,
10768
10773
  newList,
@@ -10785,6 +10790,8 @@ var SubForm = function SubForm(props) {
10785
10790
  templateKey: workOrderTemplateId,
10786
10791
  needReturnRepeatValue: true,
10787
10792
  needFilterShopByPermission: needFilterShopByPermission,
10793
+ needTotal: false,
10794
+ useNext: true,
10788
10795
  queryComponents: [{
10789
10796
  key: 'flowStatus',
10790
10797
  symbol: 'in',
@@ -10803,17 +10810,39 @@ var SubForm = function SubForm(props) {
10803
10810
  value: [inputValue]
10804
10811
  });
10805
10812
  params.queryComponents = queryComponents;
10806
- params.needTotal = false;
10807
10813
  }
10808
- _context.next = 7;
10814
+ params.queryComponents = params.queryComponents.filter(function (item) {
10815
+ var _item$value;
10816
+ if (item.key === 'flowStatus' && ((_item$value = item.value) === null || _item$value === void 0 ? void 0 : _item$value.length) === 4) {
10817
+ return false;
10818
+ } else {
10819
+ return true;
10820
+ }
10821
+ });
10822
+ cursorParams = _objectSpread2({}, params);
10823
+ delete cursorParams.pageNo;
10824
+ queryKey = JSON.stringify(cursorParams);
10825
+ if (((_cursorIdRef$current = cursorIdRef.current) === null || _cursorIdRef$current === void 0 ? void 0 : _cursorIdRef$current.queryKey) === queryKey) {
10826
+ if (cursorIdRef.current.cursorId) {
10827
+ params.cursorId = cursorIdRef.current.cursorId;
10828
+ }
10829
+ } else {
10830
+ cursorIdRef.current = {
10831
+ queryKey: queryKey
10832
+ };
10833
+ }
10834
+ _context.next = 12;
10809
10835
  return extendRequest('/qy/view/workOrderListCached', {
10810
10836
  method: 'post',
10811
10837
  data: params
10812
10838
  });
10813
- case 7:
10839
+ case 12:
10814
10840
  res = _context.sent;
10815
10841
  data = res.data, success = res.success;
10816
10842
  if (success) {
10843
+ if ((data === null || data === void 0 ? void 0 : data.cursorId) && ((_cursorIdRef$current2 = cursorIdRef.current) === null || _cursorIdRef$current2 === void 0 ? void 0 : _cursorIdRef$current2.queryKey) === queryKey) {
10844
+ cursorIdRef.current.cursorId = data.cursorId;
10845
+ }
10817
10846
  transDataSourceItem = transformWorkOrderData(componentDtoList.length ? componentDtoList : componentList, 'edit');
10818
10847
  headerKeys = correlationList.map(function (t) {
10819
10848
  return t.key;
@@ -10839,7 +10868,7 @@ var SubForm = function SubForm(props) {
10839
10868
  setHasMore((data === null || data === void 0 ? void 0 : data.list.length) === pageSize);
10840
10869
  isRequest.current = false;
10841
10870
  }
10842
- case 10:
10871
+ case 15:
10843
10872
  case "end":
10844
10873
  return _context.stop();
10845
10874
  }
@@ -14569,7 +14598,6 @@ var jstGoods = function jstGoods(props) {
14569
14598
  showField = _props$showField === void 0 ? '' : _props$showField,
14570
14599
  _props$platformType = props.platformType,
14571
14600
  platformType = _props$platformType === void 0 ? 'default' : _props$platformType,
14572
- onlyShowFieldSelect = props.onlyShowFieldSelect,
14573
14601
  logisticsCompanyFormType = props.logisticsCompanyFormType,
14574
14602
  form = props.form;
14575
14603
  var _useState = useState(0),
@@ -14633,12 +14661,10 @@ var jstGoods = function jstGoods(props) {
14633
14661
  }), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("div", null, t.title), /*#__PURE__*/React.createElement("div", null, "\u7F16\u7801\uFF1A", t.skuId))));
14634
14662
  }));
14635
14663
  };
14636
- var handleSelected = function handleSelected(val, type, option, onlyShowFieldSelect) {
14664
+ var handleSelected = function handleSelected(val, type, option) {
14637
14665
  var changeOrderInfo = _objectSpread2({}, value[changeIndex]);
14638
14666
  changeOrderInfo[type] = val;
14639
- if (!onlyShowFieldSelect) {
14640
- changeOrderInfo['sendId'] = option.value;
14641
- }
14667
+ changeOrderInfo['sendId'] = option.value;
14642
14668
  if (isSelectName && type === 'sendName') {
14643
14669
  if (isSendGoodSavedId) {
14644
14670
  // 如果发货仓名称存的是id,将名称存入快照
@@ -14653,12 +14679,10 @@ var jstGoods = function jstGoods(props) {
14653
14679
  newList[changeIndex] = changeOrderInfo;
14654
14680
  onChange === null || onChange === void 0 ? void 0 : onChange(newList);
14655
14681
  };
14656
- var handleSelectedReturn = function handleSelectedReturn(val, type, option, onlyShowFieldSelect) {
14682
+ var handleSelectedReturn = function handleSelectedReturn(val, type, option) {
14657
14683
  var changeOrderInfo = _objectSpread2({}, value[changeIndex]);
14658
14684
  changeOrderInfo[type] = val;
14659
- if (!onlyShowFieldSelect) {
14660
- changeOrderInfo['returnWarehouseId'] = option.value;
14661
- }
14685
+ changeOrderInfo['returnWarehouseId'] = option.value;
14662
14686
  if (isSelectName && type === 'returnWarehouseName') {
14663
14687
  // 如果发货仓名称存的是name,将id存入快照,同时把id替换成名称
14664
14688
  changeOrderInfo['sendSnapshotId'] = option.value;
@@ -14765,7 +14789,7 @@ var jstGoods = function jstGoods(props) {
14765
14789
  filterOption: filterOption,
14766
14790
  value: ((_value$changeIndex10 = value[changeIndex]) === null || _value$changeIndex10 === void 0 ? void 0 : _value$changeIndex10.sendSnapshotId) || ((_value$changeIndex11 = value[changeIndex]) === null || _value$changeIndex11 === void 0 ? void 0 : _value$changeIndex11.sendName) || null,
14767
14791
  onChange: function onChange(value, option) {
14768
- return handleSelected(value, 'sendName', option, onlyShowFieldSelect);
14792
+ return handleSelected(value, 'sendName', option);
14769
14793
  }
14770
14794
  }) : /*#__PURE__*/React.createElement(Input, {
14771
14795
  disabled: disabled,
@@ -14800,7 +14824,7 @@ var jstGoods = function jstGoods(props) {
14800
14824
  filterOption: filterOption,
14801
14825
  value: ((_value$changeIndex15 = value[changeIndex]) === null || _value$changeIndex15 === void 0 ? void 0 : _value$changeIndex15.sendSnapshotId) || ((_value$changeIndex16 = value[changeIndex]) === null || _value$changeIndex16 === void 0 ? void 0 : _value$changeIndex16.returnWarehouseName) || null,
14802
14826
  onChange: function onChange(value, option) {
14803
- return handleSelectedReturn(value, 'returnWarehouseName', option, onlyShowFieldSelect);
14827
+ return handleSelectedReturn(value, 'returnWarehouseName', option);
14804
14828
  }
14805
14829
  }) : /*#__PURE__*/React.createElement(Input, {
14806
14830
  disabled: disabled,
@@ -23279,6 +23303,7 @@ var getColumns$5 = function getColumns() {
23279
23303
  }, {
23280
23304
  dataIndex: 'qty',
23281
23305
  title: "\u7533\u8BF7\u6570\u91CF",
23306
+ conditionTitle: "\u7533\u8BF7\u603B\u6570\u91CF",
23282
23307
  width: 150,
23283
23308
  align: 'center',
23284
23309
  ellipsis: true,
@@ -10,7 +10,7 @@ interface JstGoodsProps {
10
10
  onBlur?: (val: any) => void;
11
11
  showField: string;
12
12
  platformType?: string;
13
- onlyShowFieldSelect: boolean;
13
+ onlyShowFieldSelect?: boolean;
14
14
  expressDateInstance: InstanceType<typeof ExpressData>;
15
15
  logisticsCompanyFormType?: string;
16
16
  form?: FormInstance;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kmkf-fe-packages/basic-components",
3
- "version": "2.10.9-beta.34",
3
+ "version": "2.10.9-beta.35",
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.9-beta.34",
23
+ "@kmkf-fe-packages/kmkf-utils": "2.10.9-beta.35",
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": "50f6675508c29e033fb10ce1d240bd6f80c9dd93"
69
+ "gitHead": "5b9292c9d078538ec783852f96f41cac6a3d12e7"
70
70
  }