dashboard: reimaginacao
Signed-off-by: Rodrigo B. de Sousa Martins <rodrigo.sousa.577@gmail.com>
This commit is contained in:
1 parent
9c2df341ea
commit
9160939de2
4 files changed
+5
-8
No files matched your search
@@ -19,7 +19,6 @@ export const AtendimentosDia: React.FC = () => {
|
|||||||
setError(null);
|
setError(null);
|
||||||
const res = await fetch('/api/atendimentos-dia', {
|
const res = await fetch('/api/atendimentos-dia', {
|
||||||
headers: {
|
headers: {
|
||||||
Authorization: `Bearer ${token}`,
|
|
||||||
'Content-Type': 'application/json',
|
'Content-Type': 'application/json',
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
@@ -33,7 +32,7 @@ export const AtendimentosDia: React.FC = () => {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
fetchAtendimentos();
|
fetchAtendimentos();
|
||||||
}, [token]);
|
}, []);
|
||||||
|
|
||||||
if (loading) return <div>Carregando atendimentos...</div>;
|
if (loading) return <div>Carregando atendimentos...</div>;
|
||||||
if (error) return <div className="text-red-600">{error}</div>;
|
if (error) return <div className="text-red-600">{error}</div>;
|
||||||
|
|||||||
@@ -17,7 +17,6 @@ export const BenchmarkingEscritorio: React.FC = () => {
|
|||||||
setError(null);
|
setError(null);
|
||||||
const res = await fetch('/api/benchmarking', {
|
const res = await fetch('/api/benchmarking', {
|
||||||
headers: {
|
headers: {
|
||||||
Authorization: `Bearer ${token}`,
|
|
||||||
'Content-Type': 'application/json',
|
'Content-Type': 'application/json',
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
@@ -31,7 +30,7 @@ export const BenchmarkingEscritorio: React.FC = () => {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
fetchBenchmarking();
|
fetchBenchmarking();
|
||||||
}, [token]);
|
}, []);
|
||||||
|
|
||||||
if (loading) return <div>Carregando benchmarking...</div>;
|
if (loading) return <div>Carregando benchmarking...</div>;
|
||||||
if (error) return <div className="text-red-600">{error}</div>;
|
if (error) return <div className="text-red-600">{error}</div>;
|
||||||
|
|||||||
@@ -19,7 +19,7 @@ export const CalendarioAtendimentos: React.FC = () => {
|
|||||||
setError(null);
|
setError(null);
|
||||||
const res = await fetch('/api/eventos', {
|
const res = await fetch('/api/eventos', {
|
||||||
headers: {
|
headers: {
|
||||||
Authorization: `Bearer ${token}`,
|
|
||||||
'Content-Type': 'application/json',
|
'Content-Type': 'application/json',
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
@@ -33,7 +33,7 @@ export const CalendarioAtendimentos: React.FC = () => {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
fetchEventos();
|
fetchEventos();
|
||||||
}, [token]);
|
}, []);
|
||||||
|
|
||||||
// Simulação de calendário mensal
|
// Simulação de calendário mensal
|
||||||
const diasMes = Array.from({ length: 30 }, (_, i) => i + 1);
|
const diasMes = Array.from({ length: 30 }, (_, i) => i + 1);
|
||||||
|
|||||||
@@ -18,7 +18,6 @@ export const WorkflowTarefas: React.FC = () => {
|
|||||||
setError(null);
|
setError(null);
|
||||||
const res = await fetch('/api/tarefas', {
|
const res = await fetch('/api/tarefas', {
|
||||||
headers: {
|
headers: {
|
||||||
Authorization: `Bearer ${token}`,
|
|
||||||
'Content-Type': 'application/json',
|
'Content-Type': 'application/json',
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
@@ -32,7 +31,7 @@ export const WorkflowTarefas: React.FC = () => {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
fetchTarefas();
|
fetchTarefas();
|
||||||
}, [token]);
|
}, []);
|
||||||
|
|
||||||
if (loading) return <div>Carregando tarefas...</div>;
|
if (loading) return <div>Carregando tarefas...</div>;
|
||||||
if (error) return <div className="text-red-600">{error}</div>;
|
if (error) return <div className="text-red-600">{error}</div>;
|
||||||
|
|||||||
Reference in new issue
Block a user