Pantalla: Reporte para Medico
Identificador: SCR-ADH-010
Modulo: MTS-ADH-001 - Motor de Adherencia
Version: 1.0.0
Fecha: 2025-12-05
Autor: MobileUxUiDrone (Eight of Eight)
Estado: Especificado
FASE: 2 - Value
| Atributo |
Valor |
| Nombre |
Reporte para Medico |
| Proposito |
Generar PDF/exportacion de adherencia para compartir con profesionales de salud |
| Tipo |
Full Screen con Preview |
| Acceso |
SCR-ADH-001 > "Generar reporte" |
| Prioridad |
Alta |
2. Wireframe ASCII
2.1. Estado: Configuracion del Reporte
+------------------------------------------+
| [<] Generar Reporte |
+------------------------------------------+
| |
| Configura tu reporte de adherencia |
| |
| ───────────────────────────────────── |
| |
| PERIODO |
| ┌─────────────────────────────────────┐ |
| │ ○ Ultima semana │ |
| │ ● Ultimo mes │ | <- Default
| │ ○ Ultimos 3 meses │ |
| │ ○ Personalizado │ |
| └─────────────────────────────────────┘ |
| |
| MEDICAMENTOS A INCLUIR |
| ┌─────────────────────────────────────┐ |
| │ [✓] Todos los medicamentos │ |
| │ ───────────────────────────────── │ |
| │ [✓] Metformina 850mg │ |
| │ [✓] Lisinopril 10mg │ |
| │ [✓] Atorvastatina 20mg │ |
| │ [✓] Omeprazol 20mg │ |
| └─────────────────────────────────────┘ |
| |
| SECCIONES A INCLUIR |
| ┌─────────────────────────────────────┐ |
| │ [✓] Resumen general │ |
| │ [✓] Adherencia por medicamento │ |
| │ [✓] Calendario visual │ |
| │ [✓] Patrones detectados │ |
| │ [ ] Anomalias reportadas │ |
| │ [✓] Graficos de tendencias │ |
| └─────────────────────────────────────┘ |
| |
| FORMATO |
| ┌─────────────────────────────────────┐ |
| │ [PDF*] [CSV] [HL7 FHIR] │ |
| └─────────────────────────────────────┘ |
| |
| +─────────────────────────────────────+ |
| │ Vista Previa │ |
| +─────────────────────────────────────+ |
| |
| +─────────────────────────────────────+ |
| │ Generar Reporte │ | <- Primary CTA
| +─────────────────────────────────────+ |
| |
+------------------------------------------+
2.2. Estado: Generando (Loading)
+------------------------------------------+
| [<] Generar Reporte |
+------------------------------------------+
| |
| |
| |
| |
| ┌─────────────┐ |
| │ │ |
| │ [=====>] │ | <- Progress
| │ │ |
| └─────────────┘ |
| |
| Generando reporte... |
| |
| Calculando metricas |
| Creando graficos |
| Formateando PDF |
| |
| |
| |
+------------------------------------------+
2.3. Estado: Vista Previa del PDF
+------------------------------------------+
| [<] Vista Previa [...] |
+------------------------------------------+
| |
| ┌─────────────────────────────────────┐ |
| │ ┌───────────────────────────────┐ │ |
| │ │ │ │ |
| │ │ REPORTE DE ADHERENCIA │ │ |
| │ │ ───────────────────── │ │ |
| │ │ │ │ |
| │ │ Paciente: Maria Lopez │ │ |
| │ │ Periodo: 1-30 Nov 2024 │ │ |
| │ │ │ │ |
| │ │ RESUMEN │ │ |
| │ │ Adherencia: 87% │ │ |
| │ │ Tomas: 112 de 128 │ │ |
| │ │ Racha max: 14 dias │ │ |
| │ │ │ │ |
| │ │ POR MEDICAMENTO │ │ |
| │ │ ════════════════ │ │ | <- Preview scrollable
| │ │ Metformina: 89% │ │ |
| │ │ Lisinopril: 94% │ │ |
| │ │ ... │ │ |
| │ │ │ │ |
| │ └───────────────────────────────┘ │ |
| │ │ |
| │ 1 / 3 paginas │ |
| │ [<] ●○○ [>] │ |
| │ │ |
| └─────────────────────────────────────┘ |
| |
| [Editar] [Compartir] |
| |
| +─────────────────────────────────────+ |
| │ Descargar PDF │ |
| +─────────────────────────────────────+ |
| |
+------------------------------------------+
2.4. Estado: Opciones de Compartir
+------------------------------------------+
| |
| Compartir Reporte |
| |
| ┌─────────────────────────────────────┐ |
| │ │ |
| │ [PDF] Reporte_Adherencia_Nov.pdf │ |
| │ 1.2 MB │ |
| │ │ |
| └─────────────────────────────────────┘ |
| |
| ┌─────────────────────────────────────┐ |
| │ 📧 Enviar por email │ |
| │ 💬 WhatsApp │ |
| │ 📎 Guardar en archivos │ |
| │ 🔗 Crear enlace temporal │ |
| │ 🖨️ Imprimir │ |
| └─────────────────────────────────────┘ |
| |
| El enlace temporal expira en: |
| [24 horas*] [7 dias] [30 dias] |
| |
| [Cancelar] |
| |
+------------------------------------------+
3. Componentes UI
3.1. Period Selector
| Propiedad |
Valor |
| Componente |
Radio button group |
| Opciones |
Semana, Mes, 3 meses, Personalizado |
| Default |
Mes |
| Personalizado |
Date range picker |
3.2. Medication Checklist
| Propiedad |
Valor |
| Componente |
CMP-INP-007 (Checkbox List) |
| "Todos" |
Toggle maestro |
| Items |
Lista de medicamentos activos |
| Min seleccion |
1 |
3.3. Section Checklist
| Propiedad |
Valor |
| Componente |
CMP-INP-007 (Checkbox List) |
| Items |
Secciones del reporte |
| Defaults |
Todas menos "Anomalias" |
| Propiedad |
Valor |
| Componente |
CMP-INP-009 (Segmented Control) |
| Opciones |
PDF, CSV, HL7 FHIR |
| Default |
PDF |
| FHIR |
Solo Pro/Perfect tier |
3.5. PDF Preview
| Propiedad |
Valor |
| Componente |
CMP-ADH-022 (PDFPreview) NUEVO |
| Render |
WebView con PDF.js |
| Paginacion |
Swipe o botones |
| Zoom |
Pinch to zoom |
3.6. Share Options
| Propiedad |
Valor |
| Componente |
Bottom sheet |
| Opciones |
Email, WhatsApp, Files, Link, Print |
| Link expiration |
Selector de duracion |
4. Comportamientos
4.1. Flujo de Generacion
flowchart TD
A[Abrir pantalla] --> B[Configurar opciones]
B --> C{Vista previa?}
C -->|Si| D[Generar preview]
C -->|No| E[Generar final]
D --> F[Mostrar PDF]
F --> G{Satisfecho?}
G -->|No| B
G -->|Si| E
E --> H[Generar archivo]
H --> I[Opciones compartir]
I -->|Email| J[Abrir mail client]
I -->|WhatsApp| K[Abrir WhatsApp]
I -->|Files| L[Guardar local]
I -->|Link| M[Crear enlace temporal]
I -->|Print| N[Dialogo impresion]
4.2. Enlace Temporal
- Genera URL unica con token
- Expiracion configurable (24h, 7d, 30d)
- Requiere autenticacion del receptor (email)
- Tracking de accesos
4.3. Validaciones
| Validacion |
Mensaje |
| Sin medicamentos |
"Selecciona al menos un medicamento" |
| Sin secciones |
"Selecciona al menos una seccion" |
| Periodo muy largo |
"Maximo 365 dias por reporte" |
| Sin datos |
"No hay datos para el periodo seleccionado" |
5. Contenido del Reporte PDF
5.1. Secciones Incluidas
| Seccion |
Contenido |
| Portada |
Logo, nombre paciente, periodo |
| Resumen |
% adherencia, tomas, racha |
| Por medicamento |
Tabla con % por medicamento |
| Calendario |
Grid mensual con colores |
| Patrones |
Lista de patrones detectados |
| Anomalias |
Lista de problemas reportados |
| Tendencias |
Grafico de linea |
| Disclaimer |
Texto legal |
{
"resourceType": "MedicationStatement",
"status": "active",
"medicationCodeableConcept": {...},
"subject": {"reference": "Patient/123"},
"effectivePeriod": {...},
"adherence": {
"code": {...},
"percentage": 87
}
}
6. Datos Requeridos
interface ReportConfigData {
// Opciones disponibles
medications: MedicationOption[];
maxPeriodDays: number; // 365
availableFormats: Format[];
userTier: 'FREE' | 'PRO' | 'PERFECT';
// Defaults
defaultPeriod: '7d' | '30d' | '90d';
defaultSections: string[];
}
interface ReportGenerationRequest {
periodStart: Date;
periodEnd: Date;
medicationIds: string[];
sections: ReportSection[];
format: 'PDF' | 'CSV' | 'FHIR';
includePatientName: boolean;
}
interface GeneratedReport {
id: string;
fileUrl: string;
fileName: string;
fileSize: number;
format: string;
generatedAt: Date;
expiresAt?: Date;
shareableLink?: string;
}
6.2. Output Events
| Evento |
Payload |
Destino |
| onPreview |
config |
Generar preview |
| onGenerate |
config |
Generar final |
| onShare |
{report_id, method} |
Compartir |
| onDownload |
report_id |
Descargar local |
7. Accesibilidad
7.1. Labels
| Elemento |
accessibilityLabel |
| Period option |
"Periodo: {option}" |
| Medication checkbox |
"{medicamento}, {seleccionado/no seleccionado}" |
| Format selector |
"Formato {formato}" |
| Preview |
"Vista previa del reporte, pagina {N} de {M}" |
7.2. Screen Reader
| Evento |
Anuncio |
| Generando |
"Generando reporte, por favor espera" |
| Listo |
"Reporte generado. {N} paginas" |
| Compartido |
"Reporte compartido via {metodo}" |
8. Metricas
8.1. Analytics Events
| Evento |
Parametros |
| screen_view |
screen_name: "report_generator" |
| report_configure |
period, medication_count, sections |
| report_preview |
- |
| report_generate |
format, pages |
| report_share |
method, format |
| report_download |
format |
9. Consideraciones de Privacidad
| Aspecto |
Implementacion |
| Datos paciente |
Nombre opcional en reporte |
| Enlace temporal |
Token seguro, expiracion obligatoria |
| Acceso enlace |
Requiere verificacion email |
| Historial |
Reportes generados se guardan 30 dias |
| FHIR |
Datos anonimizados por defecto |
10. Referencias
Documento generado por MobileUxUiDrone (Eight of Eight)