feat: servicios WhatsApp, Bitácora WebControl, SQLite v4, UI y store listing

This commit is contained in:
Pablinux
2026-11-22 17:40:46 -05:00
parent 7ffb8d3c52
commit 4aaae043fe
47 changed files with 2552 additions and 361 deletions
+10
View File
@@ -10,6 +10,8 @@ class Usuario {
final bool activo;
final bool sincronizado;
final String? fotoPath;
// Teléfono móvil en formato internacional E.164 para recepción de alertas WhatsApp vía sigma-robot
final String? telefono;
const Usuario({
required this.id,
@@ -23,6 +25,7 @@ class Usuario {
this.activo = true,
this.sincronizado = false,
this.fotoPath,
this.telefono,
});
factory Usuario.fromMap(Map<String, dynamic> m) => Usuario(
@@ -37,6 +40,8 @@ class Usuario {
activo: (m['activo'] as int) == 1,
sincronizado: (m['sincronizado'] as int) == 1,
fotoPath: m['foto_path'] as String?,
// Mapeo del campo telefono desde la base de datos local SQLite
telefono: m['telefono'] as String?,
);
Map<String, dynamic> toMap() => {
@@ -51,12 +56,15 @@ class Usuario {
'activo': activo ? 1 : 0,
'sincronizado': sincronizado ? 1 : 0,
'foto_path': fotoPath,
// Persistencia del campo telefono para SQLite
'telefono': telefono,
};
Usuario copyWith({
String? nombre,
String? iniciales,
String? fotoPath,
String? telefono,
bool? sincronizado,
}) =>
Usuario(
@@ -71,5 +79,7 @@ class Usuario {
activo: activo,
sincronizado: sincronizado ?? this.sincronizado,
fotoPath: fotoPath ?? this.fotoPath,
// Preserva o actualiza el teléfono de alertas
telefono: telefono ?? this.telefono,
);
}