feat(user-settings): add user settings modal with username and password update

Implement user settings functionality in TopBar component with a modal dialog
that allows users to update their username and password. The modal includes
form validation and error handling, with proper password confirmation checks.
This commit is contained in:
2026-03-31 21:52:31 +08:00
parent 11245a5b7f
commit dcc2d06c8f
2 changed files with 207 additions and 8 deletions

View File

@@ -52,6 +52,8 @@ export const userApi = {
api.post('/userMgr/remove', { targetUserID }),
listUsers: () =>
api.get('/userMgr/list'),
modifyUser: (userID, username, passwd) =>
api.post(`/userMgr/modify`, { userID, username, passwd }),
modifyType: (userID, newType) =>
api.post(`/userMgr/modifyType`, { userID, newType: newType.toLowerCase() || 'visitor' })
};