Skip to content
Snippets Groups Projects
Verified Commit 7a146dad authored by Defendi Alberto's avatar Defendi Alberto
Browse files

Camelize data from server.

parent 9b20640b
No related branches found
No related tags found
2 merge requests!60New component to search senior (see #12). Enhance responsiveness and solve #10 and #11,!58Camelize data and insert react-hook-form in autocomplete.
......@@ -6,5 +6,8 @@ export const getSeniorListByCard = async (
card: number,
): Promise<ResponseProps[]> =>
axios
.get(`/api/web/seniors/by_member_card/${card}?fields=user,id`)
.then((res) => camelizeKeys(res.data) as ResponseProps[]);
.get(
`/api/web/seniors/by_member_card/${card}?fields=user,id,member_card_number`,
)
.then((res) => camelizeKeys(res.data) as ResponseProps[])
.catch(() => [] as ResponseProps[]);
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment