| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539 |
- REGISTER_MAIL = {
- "subject": "Bienvenido a Pedidos Express - Confirma tu registro",
- "body": """
- <html>
- <head>
- <meta charset="UTF-8">
- <meta name="viewport" content="width=device-width, initial-scale=1.0">
- <title>¡Bienvenido a {app_name}!</title>
- <style>
- body {{
- margin: 0;
- padding: 0;
- font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
- background-color: #f3f4f6;
- }}
-
- .email-container {{
- max-width: 600px;
- margin: 0 auto;
- background-color: #ffffff;
- border-radius: 12px;
- box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
- overflow: hidden;
- }}
-
- .header {{
- background-color: #101419;
- color: white;
- padding: 32px;
- text-align: center;
- }}
-
- .header h1 {{
- margin: 0;
- font-size: 28px;
- font-weight: bold;
- }}
-
- .header p {{
- margin: 8px 0 0 0;
- font-size: 16px;
- opacity: 0.9;
- }}
-
- .content {{
- padding: 32px;
- }}
-
- .welcome-message {{
- text-align: center;
- margin-bottom: 32px;
- }}
-
- .welcome-message h2 {{
- color: #101419;
- font-size: 24px;
- margin: 0 0 12px 0;
- font-weight: bold;
- }}
-
- .welcome-message p {{
- color: #6b7280;
- font-size: 16px;
- line-height: 1.6;
- margin: 0;
- }}
-
- .benefits-section {{
- background-color: #f9fafb;
- border-radius: 8px;
- padding: 24px;
- margin: 24px 0;
- }}
-
- .benefits-title {{
- color: #101419;
- font-size: 18px;
- font-weight: 600;
- margin: 0 0 16px 0;
- text-align: center;
- }}
-
- .benefits-list {{
- list-style: none;
- padding: 0;
- margin: 0;
- }}
-
- .benefits-list li {{
- color: #374151;
- font-size: 14px;
- line-height: 1.5;
- margin-bottom: 8px;
- padding-left: 20px;
- position: relative;
- }}
-
- .benefits-list li:before {{
- content: "✓";
- color: #10b981;
- font-weight: bold;
- position: absolute;
- left: 0;
- }}
-
- .verification-section {{
- background: linear-gradient(135deg, #101419 0%, #37404a 100%);
- border-radius: 12px;
- padding: 32px;
- text-align: center;
- margin: 32px 0;
- color: white;
- }}
-
- .verification-icon {{
- font-size: 48px;
- margin: 16px 0;
- border: 3px solid white;
- border-radius: 50%;
- padding: 20px;
- display: inline-block;
- width: 80px;
- height: 80px;
- line-height: 80px;
- }}
-
- .verification-description {{
- font-size: 18px;
- margin: 16px 0;
- opacity: 0.95;
- }}
-
- .cta-button {{
- background-color: white;
- color: #101419;
- padding: 16px 32px;
- border-radius: 8px;
- text-decoration: none;
- font-weight: 600;
- font-size: 16px;
- display: inline-block;
- margin-top: 16px;
- transition: all 0.2s ease;
- }}
-
- .cta-button:hover {{
- background-color: #f3f4f6;
- transform: translateY(-1px);
- }}
-
- .security-note {{
- background-color: #fef3c7;
- border: 1px solid #f59e0b;
- border-radius: 8px;
- padding: 16px;
- margin: 24px 0;
- text-align: center;
- }}
-
- .security-note p {{
- color: #92400e;
- font-size: 14px;
- margin: 0;
- font-weight: 500;
- }}
-
- .website-section {{
- text-align: center;
- margin: 32px 0;
- padding: 24px;
- background-color: #f9fafb;
- border-radius: 8px;
- }}
-
- .website-url {{
- color: #101419;
- font-size: 20px;
- font-weight: 600;
- text-decoration: none;
- border-bottom: 2px solid #101419;
- padding-bottom: 4px;
- }}
-
- .footer {{
- background-color: #f9fafb;
- padding: 24px 32px;
- text-align: center;
- border-top: 1px solid #e5e7eb;
- }}
-
- .footer p {{
- color: #6b7280;
- font-size: 14px;
- margin: 0;
- line-height: 1.5;
- }}
-
- @media (max-width: 600px) {{
- .email-container {{
- margin: 0;
- border-radius: 0;
- }}
-
- .header, .content {{
- padding: 24px 16px;
- }}
-
- .verification-icon {{
- font-size: 36px;
- padding: 16px;
- width: 60px;
- height: 60px;
- line-height: 60px;
- }}
- }}
- </style>
- </head>
- <body>
- <div style="padding: 20px;">
- <div class="email-container">
- <!-- Header -->
- <div class="header">
- <h1>¡Hola {name}!</h1>
- <p>Bienvenido a {app_name}</p>
- </div>
-
- <!-- Content -->
- <div class="content">
- <!-- Welcome Message -->
- <div class="welcome-message">
- <h2>Te damos la bienvenida a {app_name}</h2>
- <p>Tu registro ha sido exitoso. <br>Estamos emocionados de tenerte con nosotros. Para completar tu registro, necesitas crear tu PIN de seguridad.</p>
- </div>
-
- <!-- Benefits Section -->
- <div class="benefits-section">
- <h3 class="benefits-title">¿Qué puedes hacer con {app_name}?</h3>
- <ul class="benefits-list">
- <li>Realizar pedidos de forma rápida y sencilla</li>
- <li>Acceder a promociones exclusivas</li>
- <li>Disfrutar de una experiencia personalizada</li>
- <li>Usar nuestra inteligencia artificial</li>
- </ul>
- </div>
-
- <!-- Verification Section -->
- <div class="verification-section">
- <div class="verification-description">¡Solo falta un paso más!</div>
- <div class="verification-icon">🔐</div>
- <div class="verification-description">Crea tu PIN de seguridad para comenzar</div>
- <div class="verification-description">Vence en <strong>1 hora</strong></div>
- <a href="http://10.10.10.2:6001/verify?q={verification_code}" class="cta-button">Crear mi PIN ahora</a>
- </div>
-
- <!-- Security Note -->
- <div class="security-note">
- <p>🔒 Tu PIN será tu clave personal para acceder de forma segura a {app_name}</p>
- </div>
-
- <!-- Website Section -->
- <div class="website-section">
- <p style="color: #6b7280; margin-bottom: 12px;">También puedes acceder desde:</p>
- <a href="https://www.expressklein.com" class="website-url">www.expressklein.com</a>
- </div>
- </div>
-
- <!-- Footer -->
- <div class="footer">
- <p>
- <strong>Express Klein</strong> - Tu aplicación de pedidos favorita<br>
- Si tienes alguna pregunta, no dudes en contactarnos.<br>
- © 2025 Express Klein. Todos los derechos reservados.
- </p>
- </div>
- </div>
- </div>
- </body>
- </html>
- """
- }
- PRINTER_DISCONNECTED_MAIL = {
- "subject": "Printer Disconnected",
- "body": """
- <!DOCTYPE html>
- <html>
- <head>
- <meta charset="UTF-8">
- <meta name="viewport" content="width=device-width, initial-scale=1.0">
- <title>Alerta: Impresora Desconectada - KlowApp</title>
- </head>
- <body style="margin: 0; padding: 0; font-family: Arial, sans-serif; background-color: #f3f4f6;">
- <table width="100%" cellpadding="0" cellspacing="0" style="background-color: #f3f4f6; padding: 20px;">
- <tr>
- <td align="center">
- <table width="600" cellpadding="0" cellspacing="0" style="max-width: 600px; background-color: #ffffff; border-radius: 12px; overflow: hidden; box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);">
-
- <!-- Header -->
- <tr>
- <td style="background-color: #dc2626; color: white; padding: 32px; text-align: center;">
- <h1 style="margin: 0; font-size: 28px; font-weight: bold;">🚨 Alerta del Sistema</h1>
- <p style="margin: 8px 0 0 0; font-size: 16px; opacity: 0.9;">Notificación para Desarrolladores</p>
- </td>
- </tr>
-
- <!-- Content -->
- <tr>
- <td style="padding: 32px;">
-
- <!-- Alert Message -->
- <table width="100%" cellpadding="0" cellspacing="0">
- <tr>
- <td style="text-align: center; margin-bottom: 32px;">
- <h2 style="color: #dc2626; font-size: 24px; margin: 0 0 12px 0; font-weight: bold;">Impresora Desconectada</h2>
- <p style="color: #6b7280; font-size: 16px; line-height: 1.6; margin: 0;">Se ha detectado una desconexión en el sistema de impresión de {restaurant_name}.</p>
- </td>
- </tr>
- </table>
-
- <!-- Alert Details -->
- <table width="100%" cellpadding="0" cellspacing="0" style="margin: 24px 0;">
- <tr>
- <td style="background-color: #fef2f2; border-radius: 8px; padding: 24px; border-left: 4px solid #dc2626;">
- <h3 style="color: #dc2626; font-size: 18px; font-weight: 600; margin: 0 0 16px 0;">Detalles del Problema</h3>
- <ul style="list-style: none; padding: 0; margin: 0;">
- <li style="color: #374151; font-size: 14px; line-height: 1.5; margin-bottom: 8px; padding-left: 20px; position: relative;">
- <span style="color: #dc2626; font-weight: bold; position: absolute; left: 0;">🖨️</span>
- <strong>Impresora:</strong> {printer_name}
- </li>
- <li style="color: #374151; font-size: 14px; line-height: 1.5; margin-bottom: 8px; padding-left: 20px; position: relative;">
- <span style="color: #dc2626; font-weight: bold; position: absolute; left: 0;">⏰</span>
- <strong>Hora de desconexión:</strong> {timestamp}
- </li>
- </ul>
- </td>
- </tr>
- </table>
-
- <!-- Priority Section -->
- <table width="100%" cellpadding="0" cellspacing="0">
- <tr>
- <td style="background: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%); border-radius: 12px; padding: 32px; text-align: center; margin: 32px 0; color: white;">
- <p style="font-size: 18px; margin: 0 0 16px 0; opacity: 0.95;">Estado del Sistema</p>
- <div style="font-size: 32px; font-weight: bold; margin: 16px 0; border: 3px solid white; border-radius: 8px; padding: 16px; display: inline-block; min-width: 200px; background-color: rgba(255,255,255,0.1);">
- 🔴 CRÍTICO
- </div>
- <p style="font-size: 16px; margin: 16px 0 0 0; opacity: 0.9;">Requiere atención inmediata</p>
- </td>
- </tr>
- </table>
-
- <!-- Impact Assessment -->
- <table width="100%" cellpadding="0" cellspacing="0" style="margin: 32px 0;">
- <tr>
- <td style="background-color: #fff7ed; border-radius: 8px; padding: 24px; border-left: 4px solid #f59e0b;">
- <h3 style="color: #92400e; font-size: 16px; font-weight: 600; margin: 0 0 12px 0;">Impacto Potencial</h3>
- <p style="color: #374151; font-size: 14px; line-height: 1.5; margin: 0;">
- ⚠️ Los pedidos no se están imprimiendo automáticamente<br>
- ⚠️ El restaurante puede estar perdiendo órdenes<br>
- ⚠️ Se requiere intervención manual inmediata<br>
- ⚠️ Posible pérdida de ingresos y experiencia del cliente
- </p>
- </td>
- </tr>
- </table>
-
- <!-- Action Items -->
- <table width="100%" cellpadding="0" cellspacing="0" style="margin: 32px 0;">
- <tr>
- <td style="background-color: #f0f9ff; border-radius: 8px; padding: 24px; border-left: 4px solid #3b82f6;">
- <h3 style="color: #1e40af; font-size: 16px; font-weight: 600; margin: 0 0 12px 0;">Acciones Requeridas</h3>
- <p style="color: #374151; font-size: 14px; line-height: 1.5; margin: 0;">
- 1. <strong>Verificar</strong> la conexión de red de la impresora<br>
- 2. <strong>Contactar</strong> al restaurante para confirmar el estado<br>
- 3. <strong>Reiniciar</strong> el servicio de impresión si es necesario<br>
- 4. <strong>Monitorear</strong> la reconexión y funcionalidad<br>
- 5. <strong>Documentar</strong> la resolución en el sistema
- </p>
- </td>
- </tr>
- </table>
-
- </td>
- </tr>
-
- <!-- Footer -->
- <tr>
- <td style="background-color: #f9fafb; padding: 24px 32px; text-align: center; border-top: 1px solid #e5e7eb;">
- <p style="color: #6b7280; font-size: 14px; margin: 0; line-height: 1.5;">
- <strong>Express Klein - Sistema de Monitoreo</strong><br>
- Alerta automática generada el {timestamp}<br>
- Este es un email automático del sistema de monitoreo.<br>
- © 2025 Express Klein. Todos los derechos reservados.
- </p>
- </td>
- </tr>
-
- </table>
- </td>
- </tr>
- </table>
- </body>
- </html>
- """
- }
- PIN_RECOVERY_MAIL = {
- "subject": "Recuperación de PIN | Pedidos Express",
- "body": """
- <!DOCTYPE html>
- <html>
- <head>
- <meta charset="UTF-8">
- <meta name="viewport" content="width=device-width, initial-scale=1.0">
- <title>Recupera tu PIN </title>
- </head>
- <body style="margin: 0; padding: 0; font-family: Arial, sans-serif; background-color: #f3f4f6;">
- <table width="100%" cellpadding="0" cellspacing="0" style="background-color: #f3f4f6; padding: 20px;">
- <tr>
- <td align="center">
- <table width="600" cellpadding="0" cellspacing="0" style="max-width: 600px; background-color: #ffffff; border-radius: 12px; overflow: hidden; box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);">
-
- <!-- Header -->
- <tr>
- <td style="background-color: #101419; color: white; padding: 32px; text-align: center;">
- <h1 style="margin: 0; font-size: 28px; font-weight: bold;">¡Hola {name}!</h1>
- <p style="margin: 8px 0 0 0; font-size: 16px; opacity: 0.9;">Recuperación de PIN</p>
- </td>
- </tr>
-
- <!-- Content -->
- <tr>
- <td style="padding: 32px;">
-
- <!-- Welcome Message -->
- <table width="100%" cellpadding="0" cellspacing="0">
- <tr>
- <td style="text-align: center; margin-bottom: 32px;">
- <h2 style="color: #101419; font-size: 24px; margin: 0 0 12px 0; font-weight: bold;">¿Olvidaste tu PIN?</h2>
- <p style="color: #6b7280; font-size: 16px; line-height: 1.6; margin: 0;">No te preocupes, puedes crear un nuevo PIN de acceso a {app_name}.</p>
- </td>
- </tr>
- </table>
-
- <!-- Security Info -->
- <table width="100%" cellpadding="0" cellspacing="0" style="margin: 24px 0;">
- <tr>
- <td style="background-color: #f9fafb; border-radius: 8px; padding: 24px;">
- <h3 style="color: #101419; font-size: 18px; font-weight: 600; margin: 0 0 16px 0; text-align: center;">Información Importante</h3>
- <ul style="list-style: none; padding: 0; margin: 0;">
- <li style="color: #374151; font-size: 14px; line-height: 1.5; margin-bottom: 8px; padding-left: 20px; position: relative;">
- <span style="color: #10b981; font-weight: bold; position: absolute; left: 0;">✓</span>
- Este enlace es válido por 24 horas
- </li>
- <li style="color: #374151; font-size: 14px; line-height: 1.5; margin-bottom: 8px; padding-left: 20px; position: relative;">
- <span style="color: #10b981; font-weight: bold; position: absolute; left: 0;">✓</span>
- Podrás elegir tu nuevo PIN
- </li>
- <li style="color: #374151; font-size: 14px; line-height: 1.5; margin-bottom: 8px; padding-left: 20px; position: relative;">
- <span style="color: #10b981; font-weight: bold; position: absolute; left: 0;">✓</span>
- Si no solicitaste este cambio, ignora este correo
- </li>
- </ul>
- </td>
- </tr>
- </table>
-
- <!-- Reset PIN Section -->
- <table width="100%" cellpadding="0" cellspacing="0">
- <tr>
- <td style="background: linear-gradient(135deg, #101419 0%, #37404a 100%); border-radius: 12px; padding: 32px; text-align: center; margin: 32px 0; color: white;">
- <p style="font-size: 18px; margin: 0 0 16px 0; opacity: 0.95;">Haz clic en el botón para crear tu nuevo PIN</p>
- <div style="font-size: 24px; font-weight: bold; margin: 16px 0; border: 3px solid white; border-radius: 8px; padding: 16px; display: inline-block; min-width: 200px; background-color: rgba(255,255,255,0.1);">
- 🔐 Restablecer PIN
- </div>
- <p style="font-size: 16px; margin: 16px 0 0 0; opacity: 0.9;">Podrás elegir un nuevo PIN de tu preferencia</p>
- <table width="100%" cellpadding="0" cellspacing="0" style="margin-top: 20px;">
- <tr>
- <td align="center">
- <a href="{reset_pin_url}" style="background-color: white; color: #101419; padding: 16px 32px; border-radius: 8px; text-decoration: none; font-weight: 600; font-size: 16px; display: inline-block;">
- Crear Nuevo PIN
- </a>
- </td>
- </tr>
- </table>
- </td>
- </tr>
- </table>
-
- <!-- Next Steps -->
- <table width="100%" cellpadding="0" cellspacing="0" style="margin: 32px 0;">
- <tr>
- <td style="background-color: #f0f9ff; border-radius: 8px; padding: 24px; border-left: 4px solid #3b82f6;">
- <h3 style="color: #101419; font-size: 16px; font-weight: 600; margin: 0 0 12px 0;">¿Qué sigue?</h3>
- <p style="color: #374151; font-size: 14px; line-height: 1.5; margin: 0;">
- 1. Haz clic en "Crear Nuevo PIN"<br>
- 2. Elige un PIN fácil de recordar pero seguro<br>
- 3. Ingresa a {app_name} con tu nuevo PIN<br>
- 4. ¡Disfruta de todos nuestros beneficios!
- </p>
- </td>
- </tr>
- </table>
-
- <!-- Website Section -->
- <table width="100%" cellpadding="0" cellspacing="0">
- <tr>
- <td style="text-align: center; margin: 32px 0; padding: 24px; background-color: #f9fafb; border-radius: 8px;">
- <p style="color: #6b7280; margin: 0 0 12px 0;">Visita nuestra plataforma:</p>
- <a href="https://www.expressklein.com" style="color: #101419; font-size: 20px; font-weight: 600; text-decoration: none; border-bottom: 2px solid #101419; padding-bottom: 4px;">
- www.expressklein.com
- </a>
- </td>
- </tr>
- </table>
-
- </td>
- </tr>
-
- <!-- Footer -->
- <tr>
- <td style="background-color: #f9fafb; padding: 24px 32px; text-align: center; border-top: 1px solid #e5e7eb;">
- <p style="color: #6b7280; font-size: 14px; margin: 0; line-height: 1.5;">
- <strong>Express Klein</strong> - Tu aplicación de pedidos favorita<br>
- Este enlace de restablecimiento expira en 24 horas.<br>
- Si no solicitaste este cambio, puedes ignorar este correo.<br>
- © 2025 Express Klein. Todos los derechos reservados.
- </p>
- </td>
- </tr>
-
- </table>
- </td>
- </tr>
- </table>
- </body>
- </html>
- """
- }
|