Files
Central_monitoreo/lib/db/dao/sync_log_dao.dart
T
PablinuxandClaude Sonnet 4.6 21d2c20525 feat: commit inicial — Central Monitoreo v1.0.0
- OperadorLoginPage con auth WebControl 2 pasos (empresas → login)
- ShellPage: sidebar 220px + IndexedStack + header con estado API
- DashboardPage: stat cards, feed alarmas, clientes, incidentes (timer 30s)
- ApiAuthService: flujo real con email + paswd + dba → token + apiKey
- DB SQLite v1: 7 tablas + 7 DAOs completos
- theme.dart: AppColors, appHeadline (Manrope), appLabel (Inter)
- Logo app: escudo radar neón (SVG + PNG 512px) en lib/recursos/
- desplegar.sh: build release Linux + upload a siax-system.net
- agents.md: estado completo + objetivos futuros documentados

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-21 22:11:12 -05:00

25 lines
603 B
Dart

import '../database_helper.dart';
class SyncLogDao {
final _db = DatabaseHelper.instance;
Future<void> registrar({
required String tipo,
required String estado,
String? detalle,
}) async {
final db = await _db.db;
await db.insert('sync_log', {
'tipo': tipo,
'estado': estado,
'detalle': detalle,
'timestamp': DateTime.now().toIso8601String(),
});
}
Future<List<Map<String, dynamic>>> getRecientes({int limit = 20}) async {
final db = await _db.db;
return db.query('sync_log', orderBy: 'timestamp DESC', limit: limit);
}
}