dengliming opened a new issue, #626:
URL: https://github.com/apache/shenyu-dashboard/issues/626
## Description
Several list pages call `this.query` from their search-input handlers
without resetting `currentPage` to 1, so filtering from page N requests page N
of the filtered result. Several delete handlers pass `fetchValue:
this.currentQueryPayload({ pageSize: 12 })` regardless of the page size the
user selected.
## Location
(Lines refer to `master @ 83969a5`.)
Search without page reset:
- `src/routes/System/Plugin/index.js:214-224`
- `src/routes/System/NamespacePlugin/index.js:163-169`
- `src/routes/System/Instance/index.js:271-277`
- `src/routes/System/Role/index.js:120-127`
- `src/routes/System/User/index.js:152-159`
- `src/routes/System/Scale/index.js:187-202`
- `src/routes/Plugin/Common/index.js:199-203` (`searchSelector`;
`componentDidUpdate` on plugin change also reuses the old page)
Hardcoded page size on delete:
- `src/routes/System/Plugin/index.js:239-241`
- `src/routes/System/NamespacePlugin/index.js:186`
- `src/routes/System/Namespace/index.js:189-191`
## Impact
On page 3, type a name that matches two rows: the table is empty while the
pager still shows page 3. With a user-chosen page size of 50, deleting a row
reloads 12 rows for the current page index and the pager no longer matches the
data.
## Suggested fix
Set `currentPage: 1` together with the filter in the search handlers, and
use the current `pageSize` from state in delete handlers.
## Related existing
None
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]