♻️ Migrate frontend client generation from openapi-typescript-codegen to @hey-api/openapi-ts (#1151)

This commit is contained in:
Alejandra
2024-04-03 16:40:33 -05:00
committed by GitHub
parent 7d7b31823f
commit 529a475c8d
63 changed files with 1576 additions and 1755 deletions

View File

@@ -62,7 +62,7 @@ const AddUser = ({ isOpen, onClose }: AddUserProps) => {
onClose()
},
onError: (err: ApiError) => {
const errDetail = err.body?.detail
const errDetail = (err.body as any)?.detail
showToast("Something went wrong.", `${errDetail}`, "error")
},
onSettled: () => {

View File

@@ -61,7 +61,7 @@ const EditUser = ({ user, isOpen, onClose }: EditUserProps) => {
onClose()
},
onError: (err: ApiError) => {
const errDetail = err.body?.detail
const errDetail = (err.body as any)?.detail
showToast("Something went wrong.", `${errDetail}`, "error")
},
onSettled: () => {

View File

@@ -49,7 +49,7 @@ const AddItem = ({ isOpen, onClose }: AddItemProps) => {
onClose()
},
onError: (err: ApiError) => {
const errDetail = err.body?.detail
const errDetail = (err.body as any)?.detail
showToast("Something went wrong.", `${errDetail}`, "error")
},
onSettled: () => {

View File

@@ -52,7 +52,7 @@ const EditItem = ({ item, isOpen, onClose }: EditItemProps) => {
onClose()
},
onError: (err: ApiError) => {
const errDetail = err.body?.detail
const errDetail = (err.body as any)?.detail
showToast("Something went wrong.", `${errDetail}`, "error")
},
onSettled: () => {

View File

@@ -43,7 +43,7 @@ const ChangePassword = () => {
reset()
},
onError: (err: ApiError) => {
const errDetail = err.body?.detail
const errDetail = (err.body as any)?.detail
showToast("Something went wrong.", `${errDetail}`, "error")
},
},

View File

@@ -44,7 +44,7 @@ const DeleteConfirmation = ({ isOpen, onClose }: DeleteProps) => {
onClose()
},
onError: (err: ApiError) => {
const errDetail = err.body?.detail
const errDetail = (err.body as any)?.detail
showToast("Something went wrong.", `${errDetail}`, "error")
},
onSettled: () => {

View File

@@ -57,7 +57,7 @@ const UserInformation = () => {
showToast("Success!", "User updated successfully.", "success")
},
onError: (err: ApiError) => {
const errDetail = err.body?.detail
const errDetail = (err.body as any)?.detail
showToast("Something went wrong.", `${errDetail}`, "error")
},
onSettled: () => {