messere1 opened a new pull request, #1572:
URL: https://github.com/apache/rocketmq-dashboard/pull/1572
## What changed
- guard audit cleanup with an in-flight ref so repeated confirmation starts
only one request
- show the modal confirmation button in a loading state
- disable cancel, close, keyboard, and mask-close paths while cleanup is
pending
- restore all controls after success or failure
- add a regression test that double-clicks confirmation and asserts one
service call
## Why
The Audit page previously allowed repeated confirmation while the
destructive cleanup request was pending. On a slow connection this could issue
multiple concurrent deletion requests for the same retention window, and the
modal could be closed while cleanup still continued.
## Impact
The change is limited to the Audit Logs page and its test. The backend API
contract and successful refresh behavior are unchanged.
Fixes #1570
## Validation
- npx vitest run src/pages/ops/__tests__/AuditPage.test.tsx
- 5 tests passed
- npx eslint src/pages/ops/audit.tsx
src/pages/ops/__tests__/AuditPage.test.tsx
- npm run build
- TypeScript and Vite production build passed
- Husky pre-commit ESLint and Prettier checks passed
--
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]