@zat-design/sisyphus-react 3.7.3-beta.17 → 3.7.3-beta.19

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 (48) hide show
  1. package/es/ProEditTable/components/RenderField/index.js +1 -1
  2. package/es/ProForm/components/combination/ProModalSelect/index.js +23 -23
  3. package/es/ProForm/components/render/ChangedWrapper.js +5 -2
  4. package/es/ProSelect/index.js +0 -1
  5. package/lib/ProEditTable/components/RenderField/index.js +1 -1
  6. package/lib/ProForm/components/combination/ProModalSelect/index.js +22 -22
  7. package/lib/ProForm/components/render/ChangedWrapper.js +5 -2
  8. package/lib/ProSelect/index.js +0 -1
  9. package/package.json +1 -1
  10. package/coverage/lcov-report/src/.umi/core/devScripts.ts.html +0 -241
  11. package/coverage/lcov-report/src/.umi/core/history.ts.html +0 -148
  12. package/coverage/lcov-report/src/.umi/core/index.html +0 -206
  13. package/coverage/lcov-report/src/.umi/core/plugin.ts.html +0 -109
  14. package/coverage/lcov-report/src/.umi/core/pluginRegister.ts.html +0 -160
  15. package/coverage/lcov-report/src/.umi/core/polyfill.ts.html +0 -97
  16. package/coverage/lcov-report/src/.umi/core/routes.ts.html +0 -26050
  17. package/coverage/lcov-report/src/.umi/core/umiExports.ts.html +0 -112
  18. package/coverage/lcov-report/src/.umi/dumi/demos/index.html +0 -116
  19. package/coverage/lcov-report/src/.umi/dumi/demos/index.ts.html +0 -6340
  20. package/coverage/lcov-report/src/.umi/dumi/index.html +0 -116
  21. package/coverage/lcov-report/src/.umi/dumi/layout.tsx.html +0 -109
  22. package/coverage/lcov-report/src/.umi/index.html +0 -116
  23. package/coverage/lcov-report/src/.umi/plugin-antd/index.html +0 -116
  24. package/coverage/lcov-report/src/.umi/plugin-antd/runtime.tsx.html +0 -172
  25. package/coverage/lcov-report/src/.umi/plugin-helmet/exports.ts.html +0 -94
  26. package/coverage/lcov-report/src/.umi/plugin-helmet/index.html +0 -116
  27. package/coverage/lcov-report/src/.umi/plugin-initial-state/Provider.tsx.html +0 -196
  28. package/coverage/lcov-report/src/.umi/plugin-initial-state/exports.ts.html +0 -106
  29. package/coverage/lcov-report/src/.umi/plugin-initial-state/index.html +0 -146
  30. package/coverage/lcov-report/src/.umi/plugin-initial-state/models/index.html +0 -116
  31. package/coverage/lcov-report/src/.umi/plugin-initial-state/models/initialState.ts.html +0 -88
  32. package/coverage/lcov-report/src/.umi/plugin-initial-state/runtime.tsx.html +0 -124
  33. package/coverage/lcov-report/src/.umi/plugin-locale/SelectLang.tsx.html +0 -1246
  34. package/coverage/lcov-report/src/.umi/plugin-locale/index.html +0 -161
  35. package/coverage/lcov-report/src/.umi/plugin-locale/locale.tsx.html +0 -268
  36. package/coverage/lcov-report/src/.umi/plugin-locale/localeExports.ts.html +0 -778
  37. package/coverage/lcov-report/src/.umi/plugin-locale/runtime.tsx.html +0 -115
  38. package/coverage/lcov-report/src/.umi/plugin-model/Provider.tsx.html +0 -202
  39. package/coverage/lcov-report/src/.umi/plugin-model/helpers/constant.tsx.html +0 -97
  40. package/coverage/lcov-report/src/.umi/plugin-model/helpers/dispatcher.tsx.html +0 -142
  41. package/coverage/lcov-report/src/.umi/plugin-model/helpers/executor.tsx.html +0 -334
  42. package/coverage/lcov-report/src/.umi/plugin-model/helpers/index.html +0 -146
  43. package/coverage/lcov-report/src/.umi/plugin-model/index.html +0 -146
  44. package/coverage/lcov-report/src/.umi/plugin-model/runtime.tsx.html +0 -121
  45. package/coverage/lcov-report/src/.umi/plugin-model/useModel.tsx.html +0 -298
  46. package/coverage/lcov-report/src/.umi/plugin-request/index.html +0 -116
  47. package/coverage/lcov-report/src/.umi/plugin-request/request.ts.html +0 -919
  48. package/coverage/lcov-report/src/.umi/umi.ts.html +0 -268
@@ -510,7 +510,7 @@ var RenderField = function RenderField(_ref) {
510
510
  form: form,
511
511
  names: names,
512
512
  namePath: [].concat(_toConsumableArray(namePath), [index]),
513
- name: cellName,
513
+ name: originalName,
514
514
  listName: cellName,
515
515
  viewEmpty: viewEmpty,
516
516
  valueType: _valueType,
@@ -27,7 +27,7 @@ import { SearchOutlined } from '@ant-design/icons';
27
27
  import { useDeepCompareEffect, useMount, useSetState } from 'ahooks';
28
28
  import { debounce, isArray, isEqual, isFunction, omit } from 'lodash';
29
29
  import { ReactSVG } from 'react-svg';
30
- import React, { forwardRef, useEffect, useImperativeHandle, useMemo } from 'react';
30
+ import React, { forwardRef, useImperativeHandle, useMemo } from 'react';
31
31
  import { ProForm, ProDrawerForm, ProTable, useProConfig, ProSelect } from '../../../../index';
32
32
  import Container from '../../Container';
33
33
  import viewSvg from '../../../../assets/view.svg';
@@ -137,10 +137,10 @@ var ProModalSelect = function ProModalSelect(props, ref) {
137
137
  }, _objectSpread(_objectSpread({}, useRequest === null || useRequest === void 0 ? void 0 : useRequest.options), {}, {
138
138
  manual: true,
139
139
  onSuccess: function onSuccess(res) {
140
- var _res$data;
140
+ var _res$data, _ref5;
141
141
  var list = withPagination ? res === null || res === void 0 ? void 0 : (_res$data = res.data) === null || _res$data === void 0 ? void 0 : _res$data.list : res === null || res === void 0 ? void 0 : res.data;
142
142
  setState({
143
- options: transformResponse ? transformResponse(res === null || res === void 0 ? void 0 : res.data) : list
143
+ options: (_ref5 = transformResponse ? transformResponse(res === null || res === void 0 ? void 0 : res.data) : list) !== null && _ref5 !== void 0 ? _ref5 : []
144
144
  });
145
145
  }
146
146
  })),
@@ -166,9 +166,9 @@ var ProModalSelect = function ProModalSelect(props, ref) {
166
166
  };
167
167
  var handleFormat = onFormat || defaultOptionRender;
168
168
  if (showCodeName) {
169
- handleFormat = function handleFormat(_ref5) {
170
- var value = _ref5.value,
171
- label = _ref5.label;
169
+ handleFormat = function handleFormat(_ref6) {
170
+ var value = _ref6.value,
171
+ label = _ref6.label;
172
172
  return "".concat(value, "-").concat(label);
173
173
  };
174
174
  }
@@ -237,7 +237,7 @@ var ProModalSelect = function ProModalSelect(props, ref) {
237
237
  onChange(val, option);
238
238
  };
239
239
  var handleClick = /*#__PURE__*/function () {
240
- var _ref6 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
240
+ var _ref7 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
241
241
  var _yield$beforeOpen, res;
242
242
  return _regeneratorRuntime().wrap(function _callee$(_context) {
243
243
  while (1) switch (_context.prev = _context.next) {
@@ -280,7 +280,7 @@ var ProModalSelect = function ProModalSelect(props, ref) {
280
280
  }, _callee);
281
281
  }));
282
282
  return function handleClick() {
283
- return _ref6.apply(this, arguments);
283
+ return _ref7.apply(this, arguments);
284
284
  };
285
285
  }();
286
286
  var handleClose = function handleClose() {
@@ -299,7 +299,7 @@ var ProModalSelect = function ProModalSelect(props, ref) {
299
299
  }
300
300
  };
301
301
  var handleFinish = /*#__PURE__*/function () {
302
- var _ref7 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee2() {
302
+ var _ref8 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee2() {
303
303
  var _nextSelectedRows, _nextSelectedRows2, nextSelectedRows, record, flag, res;
304
304
  return _regeneratorRuntime().wrap(function _callee2$(_context2) {
305
305
  while (1) switch (_context2.prev = _context2.next) {
@@ -360,11 +360,11 @@ var ProModalSelect = function ProModalSelect(props, ref) {
360
360
  }, _callee2, null, [[0, 18]]);
361
361
  }));
362
362
  return function handleFinish() {
363
- return _ref7.apply(this, arguments);
363
+ return _ref8.apply(this, arguments);
364
364
  };
365
365
  }();
366
366
  var handleSearch = /*#__PURE__*/function () {
367
- var _ref8 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee3() {
367
+ var _ref9 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee3() {
368
368
  var values;
369
369
  return _regeneratorRuntime().wrap(function _callee3$(_context3) {
370
370
  while (1) switch (_context3.prev = _context3.next) {
@@ -383,7 +383,7 @@ var ProModalSelect = function ProModalSelect(props, ref) {
383
383
  }, _callee3);
384
384
  }));
385
385
  return function handleSearch() {
386
- return _ref8.apply(this, arguments);
386
+ return _ref9.apply(this, arguments);
387
387
  };
388
388
  }();
389
389
  var _rowSelection = _objectSpread({
@@ -437,7 +437,7 @@ var ProModalSelect = function ProModalSelect(props, ref) {
437
437
  };
438
438
  // 初始化回显,当传入initParams时,前端用来回险
439
439
  var getInitValues = /*#__PURE__*/function () {
440
- var _ref9 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee4() {
440
+ var _ref10 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee4() {
441
441
  var _contentForm$getField, _useRequest$options2, _useRequest$options3, queryBean, page, params, res, _res$data2, _list, list, _data, nextSelectRowKeys;
442
442
  return _regeneratorRuntime().wrap(function _callee4$(_context4) {
443
443
  while (1) switch (_context4.prev = _context4.next) {
@@ -495,12 +495,12 @@ var ProModalSelect = function ProModalSelect(props, ref) {
495
495
  }, _callee4);
496
496
  }));
497
497
  return function getInitValues() {
498
- return _ref9.apply(this, arguments);
498
+ return _ref10.apply(this, arguments);
499
499
  };
500
500
  }();
501
501
  // 初始化回显,当传入initParams时,前端用来回险
502
502
  var getDefaultOneValues = /*#__PURE__*/function () {
503
- var _ref10 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee5() {
503
+ var _ref11 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee5() {
504
504
  var _useRequest$options4, _useRequest$options5;
505
505
  var queryBean, page, params, res, _res$data3, _list2, list, _data2, nextSelectRowKeys;
506
506
  return _regeneratorRuntime().wrap(function _callee5$(_context5) {
@@ -548,7 +548,7 @@ var ProModalSelect = function ProModalSelect(props, ref) {
548
548
  }, _callee5);
549
549
  }));
550
550
  return function getDefaultOneValues() {
551
- return _ref10.apply(this, arguments);
551
+ return _ref11.apply(this, arguments);
552
552
  };
553
553
  }();
554
554
  useImperativeHandle(ref, function () {
@@ -579,7 +579,7 @@ var ProModalSelect = function ProModalSelect(props, ref) {
579
579
  });
580
580
  }
581
581
  });
582
- useEffect(function () {
582
+ useDeepCompareEffect(function () {
583
583
  if (onOff && !visible) {
584
584
  var _useRequest$options6;
585
585
  if ((useRequest === null || useRequest === void 0 ? void 0 : (_useRequest$options6 = useRequest.options) === null || _useRequest$options6 === void 0 ? void 0 : _useRequest$options6.manual) !== true) {
@@ -615,12 +615,12 @@ var ProModalSelect = function ProModalSelect(props, ref) {
615
615
  setState(nextState);
616
616
  }
617
617
  }, [onOff, visible, value]);
618
- useEffect(function () {
618
+ useDeepCompareEffect(function () {
619
619
  if (value && !visible && isInit && !readOnly) {
620
620
  getInitValues();
621
621
  }
622
- }, [value, visible, isInit, useRequest]);
623
- useEffect(function () {
622
+ }, [value, visible, isInit]);
623
+ useDeepCompareEffect(function () {
624
624
  if (value && !visible && readOnly) {
625
625
  var _options$some;
626
626
  var isHasValue = options === null || options === void 0 ? void 0 : (_options$some = options.some) === null || _options$some === void 0 ? void 0 : _options$some.call(options, function (item) {
@@ -647,7 +647,7 @@ var ProModalSelect = function ProModalSelect(props, ref) {
647
647
  }, 300);
648
648
  }
649
649
  }, [value, options, visible, useRequest]);
650
- useEffect(function () {
650
+ useDeepCompareEffect(function () {
651
651
  if (!value) {
652
652
  if (defaultOne) {
653
653
  getDefaultOneValues();
@@ -747,7 +747,7 @@ var ProModalSelect = function ProModalSelect(props, ref) {
747
747
  children: customRender
748
748
  });
749
749
  }
750
- useEffect(function () {
750
+ useDeepCompareEffect(function () {
751
751
  if (isTooltip && value) {
752
752
  var dom = document.getElementById(uuid);
753
753
  dom.addEventListener('mouseover', function (e) {
@@ -784,7 +784,7 @@ var ProModalSelect = function ProModalSelect(props, ref) {
784
784
  }, [value, isTooltip]);
785
785
  useDeepCompareEffect(function () {
786
786
  setState({
787
- options: tableProps === null || tableProps === void 0 ? void 0 : tableProps.dataSource
787
+ options: (tableProps === null || tableProps === void 0 ? void 0 : tableProps.dataSource) || []
788
788
  });
789
789
  }, [tableProps === null || tableProps === void 0 ? void 0 : tableProps.dataSource]);
790
790
  // 当搜索条件只有一个时,且为输入框,默认设置suffix
@@ -32,7 +32,6 @@ var ChangedWrapper = function ChangedWrapper(props) {
32
32
  changeTipColor = diffConfig.changeTipColor,
33
33
  addTipColor = diffConfig.addTipColor;
34
34
  var toolTip = (_diffConfig$toolTip = diffConfig.toolTip) !== null && _diffConfig$toolTip !== void 0 ? _diffConfig$toolTip : true;
35
- // 不渲染tooltip
36
35
  var isWatch = toolTip && !['FormList', 'ProEditTable'].includes(type);
37
36
  var originalValue = (names === null || names === void 0 ? void 0 : names.length) ? names.map(function (name) {
38
37
  return get(originalValues, name);
@@ -57,7 +56,11 @@ var ChangedWrapper = function ChangedWrapper(props) {
57
56
  }, valuePropName, originalValue))) : undefined;
58
57
  }, [originalValue, children]);
59
58
  if (!isWatch || noChange) {
60
- return /*#__PURE__*/React.isValidElement(children) && /*#__PURE__*/React.cloneElement(children, _objectSpread(_objectSpread({}, children.props), rest));
59
+ // 嵌套子组件
60
+ var isNestedField = ['ProEditTable'].includes(type);
61
+ return /*#__PURE__*/React.isValidElement(children) && /*#__PURE__*/React.cloneElement(children, _objectSpread(_objectSpread({
62
+ originalValues: isNestedField ? originalValues : undefined
63
+ }, children.props), rest));
61
64
  }
62
65
  var tipOpenCalc = function tipOpenCalc() {
63
66
  if (!toolTip) return false;
@@ -24,7 +24,6 @@ import './index.less';
24
24
  var Option = _Select.Option;
25
25
  export var ProSelect = function ProSelect(props, ref) {
26
26
  var _selectProps$showCode, _locale$ProSelect;
27
- console.log('props11: ', props);
28
27
  var _ref = useProConfig('ProSelect') || {},
29
28
  _ref$fieldNames = _ref.fieldNames,
30
29
  proSelectFieldNames = _ref$fieldNames === void 0 ? {} : _ref$fieldNames,
@@ -517,7 +517,7 @@ var RenderField = function RenderField(_ref) {
517
517
  form: form,
518
518
  names: names,
519
519
  namePath: [].concat((0, _toConsumableArray2.default)(namePath), [index]),
520
- name: cellName,
520
+ name: originalName,
521
521
  listName: cellName,
522
522
  viewEmpty: viewEmpty,
523
523
  valueType: _valueType,
@@ -132,10 +132,10 @@ var ProModalSelect = function ProModalSelect(props, ref) {
132
132
  }, (0, _objectSpread3.default)((0, _objectSpread3.default)({}, useRequest === null || useRequest === void 0 ? void 0 : useRequest.options), {}, {
133
133
  manual: true,
134
134
  onSuccess: function onSuccess(res) {
135
- var _res$data;
135
+ var _res$data, _ref5;
136
136
  var list = withPagination ? res === null || res === void 0 ? void 0 : (_res$data = res.data) === null || _res$data === void 0 ? void 0 : _res$data.list : res === null || res === void 0 ? void 0 : res.data;
137
137
  setState({
138
- options: transformResponse ? transformResponse(res === null || res === void 0 ? void 0 : res.data) : list
138
+ options: (_ref5 = transformResponse ? transformResponse(res === null || res === void 0 ? void 0 : res.data) : list) !== null && _ref5 !== void 0 ? _ref5 : []
139
139
  });
140
140
  }
141
141
  })),
@@ -161,9 +161,9 @@ var ProModalSelect = function ProModalSelect(props, ref) {
161
161
  };
162
162
  var handleFormat = onFormat || defaultOptionRender;
163
163
  if (showCodeName) {
164
- handleFormat = function handleFormat(_ref5) {
165
- var value = _ref5.value,
166
- label = _ref5.label;
164
+ handleFormat = function handleFormat(_ref6) {
165
+ var value = _ref6.value,
166
+ label = _ref6.label;
167
167
  return "".concat(value, "-").concat(label);
168
168
  };
169
169
  }
@@ -232,7 +232,7 @@ var ProModalSelect = function ProModalSelect(props, ref) {
232
232
  onChange(val, option);
233
233
  };
234
234
  var handleClick = /*#__PURE__*/function () {
235
- var _ref6 = (0, _asyncToGenerator2.default)( /*#__PURE__*/(0, _regeneratorRuntime2.default)().mark(function _callee() {
235
+ var _ref7 = (0, _asyncToGenerator2.default)( /*#__PURE__*/(0, _regeneratorRuntime2.default)().mark(function _callee() {
236
236
  var _yield$beforeOpen, res;
237
237
  return (0, _regeneratorRuntime2.default)().wrap(function _callee$(_context) {
238
238
  while (1) switch (_context.prev = _context.next) {
@@ -275,7 +275,7 @@ var ProModalSelect = function ProModalSelect(props, ref) {
275
275
  }, _callee);
276
276
  }));
277
277
  return function handleClick() {
278
- return _ref6.apply(this, arguments);
278
+ return _ref7.apply(this, arguments);
279
279
  };
280
280
  }();
281
281
  var handleClose = function handleClose() {
@@ -294,7 +294,7 @@ var ProModalSelect = function ProModalSelect(props, ref) {
294
294
  }
295
295
  };
296
296
  var handleFinish = /*#__PURE__*/function () {
297
- var _ref7 = (0, _asyncToGenerator2.default)( /*#__PURE__*/(0, _regeneratorRuntime2.default)().mark(function _callee2() {
297
+ var _ref8 = (0, _asyncToGenerator2.default)( /*#__PURE__*/(0, _regeneratorRuntime2.default)().mark(function _callee2() {
298
298
  var _nextSelectedRows, _nextSelectedRows2, nextSelectedRows, record, flag, res;
299
299
  return (0, _regeneratorRuntime2.default)().wrap(function _callee2$(_context2) {
300
300
  while (1) switch (_context2.prev = _context2.next) {
@@ -355,11 +355,11 @@ var ProModalSelect = function ProModalSelect(props, ref) {
355
355
  }, _callee2, null, [[0, 18]]);
356
356
  }));
357
357
  return function handleFinish() {
358
- return _ref7.apply(this, arguments);
358
+ return _ref8.apply(this, arguments);
359
359
  };
360
360
  }();
361
361
  var handleSearch = /*#__PURE__*/function () {
362
- var _ref8 = (0, _asyncToGenerator2.default)( /*#__PURE__*/(0, _regeneratorRuntime2.default)().mark(function _callee3() {
362
+ var _ref9 = (0, _asyncToGenerator2.default)( /*#__PURE__*/(0, _regeneratorRuntime2.default)().mark(function _callee3() {
363
363
  var values;
364
364
  return (0, _regeneratorRuntime2.default)().wrap(function _callee3$(_context3) {
365
365
  while (1) switch (_context3.prev = _context3.next) {
@@ -378,7 +378,7 @@ var ProModalSelect = function ProModalSelect(props, ref) {
378
378
  }, _callee3);
379
379
  }));
380
380
  return function handleSearch() {
381
- return _ref8.apply(this, arguments);
381
+ return _ref9.apply(this, arguments);
382
382
  };
383
383
  }();
384
384
  var _rowSelection = (0, _objectSpread3.default)({
@@ -432,7 +432,7 @@ var ProModalSelect = function ProModalSelect(props, ref) {
432
432
  };
433
433
  // 初始化回显,当传入initParams时,前端用来回险
434
434
  var getInitValues = /*#__PURE__*/function () {
435
- var _ref9 = (0, _asyncToGenerator2.default)( /*#__PURE__*/(0, _regeneratorRuntime2.default)().mark(function _callee4() {
435
+ var _ref10 = (0, _asyncToGenerator2.default)( /*#__PURE__*/(0, _regeneratorRuntime2.default)().mark(function _callee4() {
436
436
  var _contentForm$getField, _useRequest$options2, _useRequest$options3, queryBean, page, params, res, _res$data2, _list, list, _data, nextSelectRowKeys;
437
437
  return (0, _regeneratorRuntime2.default)().wrap(function _callee4$(_context4) {
438
438
  while (1) switch (_context4.prev = _context4.next) {
@@ -490,12 +490,12 @@ var ProModalSelect = function ProModalSelect(props, ref) {
490
490
  }, _callee4);
491
491
  }));
492
492
  return function getInitValues() {
493
- return _ref9.apply(this, arguments);
493
+ return _ref10.apply(this, arguments);
494
494
  };
495
495
  }();
496
496
  // 初始化回显,当传入initParams时,前端用来回险
497
497
  var getDefaultOneValues = /*#__PURE__*/function () {
498
- var _ref10 = (0, _asyncToGenerator2.default)( /*#__PURE__*/(0, _regeneratorRuntime2.default)().mark(function _callee5() {
498
+ var _ref11 = (0, _asyncToGenerator2.default)( /*#__PURE__*/(0, _regeneratorRuntime2.default)().mark(function _callee5() {
499
499
  var _useRequest$options4, _useRequest$options5;
500
500
  var queryBean, page, params, res, _res$data3, _list2, list, _data2, nextSelectRowKeys;
501
501
  return (0, _regeneratorRuntime2.default)().wrap(function _callee5$(_context5) {
@@ -543,7 +543,7 @@ var ProModalSelect = function ProModalSelect(props, ref) {
543
543
  }, _callee5);
544
544
  }));
545
545
  return function getDefaultOneValues() {
546
- return _ref10.apply(this, arguments);
546
+ return _ref11.apply(this, arguments);
547
547
  };
548
548
  }();
549
549
  (0, _react.useImperativeHandle)(ref, function () {
@@ -574,7 +574,7 @@ var ProModalSelect = function ProModalSelect(props, ref) {
574
574
  });
575
575
  }
576
576
  });
577
- (0, _react.useEffect)(function () {
577
+ (0, _ahooks.useDeepCompareEffect)(function () {
578
578
  if (onOff && !visible) {
579
579
  var _useRequest$options6;
580
580
  if ((useRequest === null || useRequest === void 0 ? void 0 : (_useRequest$options6 = useRequest.options) === null || _useRequest$options6 === void 0 ? void 0 : _useRequest$options6.manual) !== true) {
@@ -610,12 +610,12 @@ var ProModalSelect = function ProModalSelect(props, ref) {
610
610
  setState(nextState);
611
611
  }
612
612
  }, [onOff, visible, value]);
613
- (0, _react.useEffect)(function () {
613
+ (0, _ahooks.useDeepCompareEffect)(function () {
614
614
  if (value && !visible && isInit && !readOnly) {
615
615
  getInitValues();
616
616
  }
617
- }, [value, visible, isInit, useRequest]);
618
- (0, _react.useEffect)(function () {
617
+ }, [value, visible, isInit]);
618
+ (0, _ahooks.useDeepCompareEffect)(function () {
619
619
  if (value && !visible && readOnly) {
620
620
  var _options$some;
621
621
  var isHasValue = options === null || options === void 0 ? void 0 : (_options$some = options.some) === null || _options$some === void 0 ? void 0 : _options$some.call(options, function (item) {
@@ -642,7 +642,7 @@ var ProModalSelect = function ProModalSelect(props, ref) {
642
642
  }, 300);
643
643
  }
644
644
  }, [value, options, visible, useRequest]);
645
- (0, _react.useEffect)(function () {
645
+ (0, _ahooks.useDeepCompareEffect)(function () {
646
646
  if (!value) {
647
647
  if (defaultOne) {
648
648
  getDefaultOneValues();
@@ -742,7 +742,7 @@ var ProModalSelect = function ProModalSelect(props, ref) {
742
742
  children: customRender
743
743
  });
744
744
  }
745
- (0, _react.useEffect)(function () {
745
+ (0, _ahooks.useDeepCompareEffect)(function () {
746
746
  if (isTooltip && value) {
747
747
  var dom = document.getElementById(uuid);
748
748
  dom.addEventListener('mouseover', function (e) {
@@ -779,7 +779,7 @@ var ProModalSelect = function ProModalSelect(props, ref) {
779
779
  }, [value, isTooltip]);
780
780
  (0, _ahooks.useDeepCompareEffect)(function () {
781
781
  setState({
782
- options: tableProps === null || tableProps === void 0 ? void 0 : tableProps.dataSource
782
+ options: (tableProps === null || tableProps === void 0 ? void 0 : tableProps.dataSource) || []
783
783
  });
784
784
  }, [tableProps === null || tableProps === void 0 ? void 0 : tableProps.dataSource]);
785
785
  // 当搜索条件只有一个时,且为输入框,默认设置suffix
@@ -37,7 +37,6 @@ var ChangedWrapper = function ChangedWrapper(props) {
37
37
  changeTipColor = diffConfig.changeTipColor,
38
38
  addTipColor = diffConfig.addTipColor;
39
39
  var toolTip = (_diffConfig$toolTip = diffConfig.toolTip) !== null && _diffConfig$toolTip !== void 0 ? _diffConfig$toolTip : true;
40
- // 不渲染tooltip
41
40
  var isWatch = toolTip && !['FormList', 'ProEditTable'].includes(type);
42
41
  var originalValue = (names === null || names === void 0 ? void 0 : names.length) ? names.map(function (name) {
43
42
  return (0, _lodash.get)(originalValues, name);
@@ -62,7 +61,11 @@ var ChangedWrapper = function ChangedWrapper(props) {
62
61
  }, valuePropName, originalValue))) : undefined;
63
62
  }, [originalValue, children]);
64
63
  if (!isWatch || noChange) {
65
- return /*#__PURE__*/_react.default.isValidElement(children) && /*#__PURE__*/_react.default.cloneElement(children, (0, _objectSpread3.default)((0, _objectSpread3.default)({}, children.props), rest));
64
+ // 嵌套子组件
65
+ var isNestedField = ['ProEditTable'].includes(type);
66
+ return /*#__PURE__*/_react.default.isValidElement(children) && /*#__PURE__*/_react.default.cloneElement(children, (0, _objectSpread3.default)((0, _objectSpread3.default)({
67
+ originalValues: isNestedField ? originalValues : undefined
68
+ }, children.props), rest));
66
69
  }
67
70
  var tipOpenCalc = function tipOpenCalc() {
68
71
  if (!toolTip) return false;
@@ -25,7 +25,6 @@ var _excluded = ["dataSource", "defaultDisableValue", "useRequest", "fieldNames"
25
25
  var Option = _antd.Select.Option;
26
26
  var ProSelect = exports.ProSelect = function ProSelect(props, ref) {
27
27
  var _selectProps$showCode, _locale$ProSelect;
28
- console.log('props11: ', props);
29
28
  var _ref = (0, _ProConfigProvider.useProConfig)('ProSelect') || {},
30
29
  _ref$fieldNames = _ref.fieldNames,
31
30
  proSelectFieldNames = _ref$fieldNames === void 0 ? {} : _ref$fieldNames,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zat-design/sisyphus-react",
3
- "version": "3.7.3-beta.17",
3
+ "version": "3.7.3-beta.19",
4
4
  "license": "Apache-2.0",
5
5
  "main": "lib/index.js",
6
6
  "module": "es/index.js",