mirror of
https://github.com/rzmk/learnhouse.git
synced 2025-12-19 04:19:25 +00:00
feat: enhance user account management with password and profile updates
- Added validation for user profile and password update forms using Yup. - Implemented user feedback for successful profile and password updates, including prompts to re-login. - Improved UI for profile editing and password change sections, enhancing user experience. - Updated password update service to include response metadata handling.
This commit is contained in:
parent
943ceff813
commit
79a31dd8ec
4 changed files with 352 additions and 132 deletions
|
|
@ -2,6 +2,7 @@ import { getAPIUrl } from '@services/config/config'
|
|||
import {
|
||||
RequestBodyWithAuthHeader,
|
||||
errorHandling,
|
||||
getResponseMetadata,
|
||||
} from '@services/utils/ts/requests'
|
||||
|
||||
/*
|
||||
|
|
@ -18,6 +19,6 @@ export async function updatePassword(
|
|||
`${getAPIUrl()}users/change_password/` + user_id,
|
||||
RequestBodyWithAuthHeader('PUT', data, null, access_token)
|
||||
)
|
||||
const res = await errorHandling(result)
|
||||
const res = await getResponseMetadata(result)
|
||||
return res
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue