From 51397dbbe2498d7c6274fb716de0672a8acf0896 Mon Sep 17 00:00:00 2001 From: Gabriel Luiz Freitas Almeida Date: Tue, 21 Nov 2023 16:09:09 -0300 Subject: [PATCH] Add postCustomComponentUpdate API function --- src/frontend/src/controllers/API/index.ts | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/frontend/src/controllers/API/index.ts b/src/frontend/src/controllers/API/index.ts index a754d1563..9b480eff6 100644 --- a/src/frontend/src/controllers/API/index.ts +++ b/src/frontend/src/controllers/API/index.ts @@ -360,6 +360,16 @@ export async function postCustomComponent( return await api.post(`${BASE_URL_API}custom_component`, { code }); } +export async function postCustomComponentUpdate( + code: string, + field: string +): Promise> { + return await api.post(`${BASE_URL_API}custom_component/update`, { + code, + field, + }); +} + export async function onLogin(user: LoginType) { try { const response = await api.post(