🟡 Pendientes de hoy
✅ Completados hoy
➕ Nueva orden de carga
📋 Crear varias órdenes a la vez ▼
👷 Choferes registrados
Añadir chofer
☁️ Conectar Supabase — datos en la nube
Con esto los datos se guardan en internet. Si un móvil se rompe o un chofer se va, no se pierde nada. Acceso desde cualquier dispositivo.
- Ve a supabase.com → crea cuenta gratis → "New project"
- Pon nombre camporuta, elige región Europa
- Ve a SQL Editor y ejecuta el SQL de abajo
- Ve a Settings → API, copia la URL y la anon key
- Pégalas aquí y pulsa Conectar
CREATE TABLE choferes ( id text PRIMARY KEY, nombre text NOT NULL, telefono text UNIQUE NOT NULL, activo boolean DEFAULT true, created_at timestamptz DEFAULT now() ); CREATE TABLE viajes ( id text PRIMARY KEY, finca text, municipio text, producto text, kg_estimados numeric, kg_reales numeric, albaran_num text, fecha date, hora text, estado text DEFAULT 'pendiente', chofer_id text, chofer_nombre text, hora_completado text, lat numeric, lng numeric, foto_data text, notas text, notas_chofer text, created_at timestamptz DEFAULT now() ); ALTER TABLE choferes ENABLE ROW LEVEL SECURITY; ALTER TABLE viajes ENABLE ROW LEVEL SECURITY; CREATE POLICY "allow_all" ON choferes FOR ALL USING (true) WITH CHECK (true); CREATE POLICY "allow_all" ON viajes FOR ALL USING (true) WITH CHECK (true);
🔗 Credenciales
🔒 Garantía de datos
☁️ Nube activa: cada viaje y acción se guarda en Supabase al instante. Móvil roto = datos a salvo.
💾 Solo local: datos en este navegador. Si se borra o se rompe el dispositivo, se pierden.
⚠️ Plan gratuito Supabase: se pausa si no hay actividad 1 semana. Entra al dashboard 1 vez/semana en temporada baja.
✅ Recomendación: conecta la nube antes de empezar la temporada. Tarda 5 minutos.