feat(auth): enhance password change flow and error handling
- Return response from useProfileSetting hook after password change
This commit is contained in:
@@ -34,6 +34,7 @@ import {
|
||||
ExitToApp as ExitToAppIcon
|
||||
} from '@mui/icons-material';
|
||||
import { useTeamSetting } from '@/hooks/setting-hooks';
|
||||
import { useDialog } from '@/hooks/useDialog';
|
||||
|
||||
interface TenantUser {
|
||||
id: string;
|
||||
@@ -88,8 +89,15 @@ function TeamsSetting() {
|
||||
}
|
||||
};
|
||||
|
||||
const dialog = useDialog();
|
||||
|
||||
const handleDeleteUser = async (userId: string) => {
|
||||
await deleteUser(userId);
|
||||
dialog.confirm({
|
||||
content: t('setting.sureDelete'),
|
||||
onConfirm: async () => {
|
||||
await deleteUser(userId);
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
const handleAgreeTenant = async (tenantId: string) => {
|
||||
|
||||
Reference in New Issue
Block a user