@zat-design/sisyphus-react 3.11.6-beta.8 → 3.11.6-beta.9

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.
@@ -117,8 +117,7 @@ function useAntdTable(service, options, useRequestOptions) {
117
117
  }, [extraParams]);
118
118
  // 调接口
119
119
  var result = useRequest(service, _objectSpread(_objectSpread({
120
- debounceWait: 300,
121
- refreshDeps: [curService, curExtraParams]
120
+ debounceWait: 300
122
121
  }, useRequestOptions), {}, {
123
122
  defaultParams: [getTransformParams()],
124
123
  onSuccess: function onSuccess(res, params) {
@@ -151,6 +150,14 @@ function useAntdTable(service, options, useRequestOptions) {
151
150
  selectedRowKeys: []
152
151
  });
153
152
  }, []);
153
+ /**
154
+ * 手动触发时,手动调用run
155
+ */
156
+ useEffect(function () {
157
+ if (!(useRequestOptions === null || useRequestOptions === void 0 ? void 0 : useRequestOptions.manual)) {
158
+ run(getTransformParams());
159
+ }
160
+ }, [useRequestOptions === null || useRequestOptions === void 0 ? void 0 : useRequestOptions.manual, curExtraParams, curService]);
154
161
  useDeepCompareEffect(function () {
155
162
  if (allSelected) {
156
163
  var filterList = data.filter(function (item) {
@@ -124,8 +124,7 @@ function useAntdTable(service, options, useRequestOptions) {
124
124
  }, [extraParams]);
125
125
  // 调接口
126
126
  var result = (0, _ahooks.useRequest)(service, (0, _objectSpread2.default)((0, _objectSpread2.default)({
127
- debounceWait: 300,
128
- refreshDeps: [curService, curExtraParams]
127
+ debounceWait: 300
129
128
  }, useRequestOptions), {}, {
130
129
  defaultParams: [getTransformParams()],
131
130
  onSuccess: function onSuccess(res, params) {
@@ -158,6 +157,14 @@ function useAntdTable(service, options, useRequestOptions) {
158
157
  selectedRowKeys: []
159
158
  });
160
159
  }, []);
160
+ /**
161
+ * 手动触发时,手动调用run
162
+ */
163
+ (0, _react.useEffect)(function () {
164
+ if (!(useRequestOptions === null || useRequestOptions === void 0 ? void 0 : useRequestOptions.manual)) {
165
+ run(getTransformParams());
166
+ }
167
+ }, [useRequestOptions === null || useRequestOptions === void 0 ? void 0 : useRequestOptions.manual, curExtraParams, curService]);
161
168
  (0, _ahooks.useDeepCompareEffect)(function () {
162
169
  if (allSelected) {
163
170
  var filterList = data.filter(function (item) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zat-design/sisyphus-react",
3
- "version": "3.11.6-beta.8",
3
+ "version": "3.11.6-beta.9",
4
4
  "license": "Apache-2.0",
5
5
  "main": "lib/index.js",
6
6
  "module": "es/index.js",