feat: update staff API schema and refactor admin login paths
This commit is contained in:
parent
459e25c010
commit
599a92fba3
@ -6,7 +6,8 @@ const staffSchema = z.object({
|
||||
data: z.object({
|
||||
id: z.string(),
|
||||
email: z.string(),
|
||||
username: z.string(),
|
||||
name: z.string(),
|
||||
profile_picture: z.string(),
|
||||
}),
|
||||
})
|
||||
|
||||
|
||||
@ -18,13 +18,9 @@ export const META_TITLE_CONFIG: TMetaTitleConfig = [
|
||||
title: 'Home',
|
||||
},
|
||||
{
|
||||
path: '/lg-admin/auth/login',
|
||||
path: '/lg-admin/login',
|
||||
title: 'Login',
|
||||
},
|
||||
{
|
||||
path: '/lg-admin/auth/register',
|
||||
title: 'Register',
|
||||
},
|
||||
...ADMIN_MENU.flatMap((menu) =>
|
||||
menu.items.map((item) => ({ path: item.url, title: item.title })),
|
||||
),
|
||||
|
||||
@ -33,9 +33,6 @@ export const AdminLoginPage = () => {
|
||||
setDisabled(false)
|
||||
return
|
||||
}
|
||||
|
||||
setDisabled(true)
|
||||
setError(undefined)
|
||||
// eslint-disable-next-line react-hooks/exhaustive-deps
|
||||
}, [fetcher])
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user