fix(admin): nav issues and blank screens fix

This commit is contained in:
2026-02-26 16:20:59 -05:00
parent 10cb37c866
commit 34a73f0f94
8 changed files with 57 additions and 15 deletions

View File

@ -399,14 +399,16 @@ async function loadData() {
isLoading.value = true
try {
// Load drivers from Supabase
const { data: drivers } = await supabase.from('users').select('*, driver_profiles(*)').eq('role', 'DRIVER')
const { data: drivers, error: errorDrivers } = await supabase.from('users').select('*, driver_profiles(*)').eq('role', 'DRIVER')
if (errorDrivers) throw errorDrivers
activeDrivers.value = drivers || []
// Load taxis from Supabase
const { data: taxisData } = await supabase.from('taxis').select('*').order('owner_name')
const { data: taxisData, error: errorTaxis } = await supabase.from('taxis').select('*').order('owner_name')
if (errorTaxis) throw errorTaxis
taxis.value = taxisData || []
} catch (e) {
console.error(e)
console.error('Error cargando datos:', e)
} finally {
isLoading.value = false
}