feat: fix profile viewing and implement real user login state
All checks were successful
Build and Deploy / build-and-push (push) Successful in 2m47s

This commit is contained in:
Cauê Faleiros
2026-02-25 11:04:51 -03:00
parent a175315437
commit 456f13c930
6 changed files with 66 additions and 37 deletions

View File

@@ -40,10 +40,11 @@ export const Dashboard: React.FC = () => {
const fetchData = async () => {
setLoading(true);
try {
const tenantId = localStorage.getItem('ctms_tenant_id') || CURRENT_TENANT_ID;
// Fetch users and attendances in parallel
const [fetchedUsers, fetchedData] = await Promise.all([
getUsers(CURRENT_TENANT_ID),
getAttendances(CURRENT_TENANT_ID, filters)
getUsers(tenantId),
getAttendances(tenantId, filters)
]);
setUsers(fetchedUsers);