fix(frontend): remove duplicated keys in backend.ts
This commit is contained in:
@@ -682,31 +682,6 @@ export const HybridBackend = {
|
||||
console.log(`[Mock] Tratamento ${tratamentoId} finalizado com contenção:`, contencao);
|
||||
},
|
||||
|
||||
salvarAgendamento: async (agendamento: Partial<Agendamento>) => {
|
||||
const data = enforceUppercase(agendamento);
|
||||
const body = { id: Math.random().toString(), ...data };
|
||||
const res = await apiFetch(`${API_URL}/agendamentos`, {
|
||||
method: 'POST',
|
||||
headers: { 'Content-Type': 'application/json' },
|
||||
body: JSON.stringify(body)
|
||||
});
|
||||
return await res.json();
|
||||
},
|
||||
|
||||
atualizarAgendamento: async (id: string, agendamento: Partial<Agendamento>) => {
|
||||
const data = enforceUppercase(agendamento);
|
||||
const res = await apiFetch(`${API_URL}/agendamentos/${id}`, {
|
||||
method: 'PUT',
|
||||
headers: { 'Content-Type': 'application/json' },
|
||||
body: JSON.stringify(data)
|
||||
});
|
||||
return await res.json();
|
||||
},
|
||||
|
||||
excluirAgendamento: async (id: string) => {
|
||||
await apiFetch(`${API_URL}/agendamentos/${id}`, { method: 'DELETE' });
|
||||
},
|
||||
|
||||
// --- LEAD & NOTIFICATION METHODS ---
|
||||
|
||||
saveLead: async (lead: Partial<Lead>) => {
|
||||
|
||||
Reference in New Issue
Block a user