From 306ba95bc2df51c0b4589d2d41d06c13e9cd8269 Mon Sep 17 00:00:00 2001 From: adriano Date: Thu, 12 Jun 2025 18:32:27 -0300 Subject: [PATCH] chore: Solved problems in next to deploy --- frontend/components/product-management.tsx | 9 +++++---- frontend/components/transcription-table.tsx | 4 ++-- frontend/package-lock.json | 10 ++++++++++ frontend/package.json | 1 + 4 files changed, 18 insertions(+), 6 deletions(-) diff --git a/frontend/components/product-management.tsx b/frontend/components/product-management.tsx index 8288649..e771c53 100644 --- a/frontend/components/product-management.tsx +++ b/frontend/components/product-management.tsx @@ -114,6 +114,7 @@ export default function ProductManagement() { } } } catch (err) { + console.log(err) setError("Erro de conexão com o servidor") } finally { setIsLoading(false) @@ -137,8 +138,7 @@ export default function ProductManagement() { body: JSON.stringify(createForm), }) - if (response.ok) { - const result = await response.json() + if (response.ok) { setSuccess("Produto criado com sucesso!") setCreateForm({ name: "", description: "", price: 0 }) setIsCreateDialogOpen(false) @@ -153,6 +153,7 @@ export default function ProductManagement() { } } } catch (err) { + console.log(err) setError("Erro de conexão com o servidor") } finally { setIsCreating(false) @@ -183,8 +184,7 @@ export default function ProductManagement() { body: JSON.stringify(editForm), }) - if (response.ok) { - const result = await response.json() + if (response.ok) { setSuccess("Produto atualizado com sucesso!") setEditingId(null) setEditForm({}) @@ -199,6 +199,7 @@ export default function ProductManagement() { } } } catch (err) { + console.log(err) setError("Erro de conexão com o servidor") } finally { setIsUpdating(false) diff --git a/frontend/components/transcription-table.tsx b/frontend/components/transcription-table.tsx index 2d28116..a24e156 100644 --- a/frontend/components/transcription-table.tsx +++ b/frontend/components/transcription-table.tsx @@ -242,7 +242,7 @@ export default function TranscriptionTable() {