Commit Graph
32 Commits
Author SHA1 Message Date
LizandroandClaude Sonnet 4.6 60ddc4b9df feat: página de comprobantes, búsqueda por email en conversaciones, quitar menús del bot
- Nueva página /chat/comprobantes: tabla paginada de solicitudes_recarga
  con búsqueda por email/nombre, filtros por estado y canal, botón "Ver chat"
- ShowConversaciones: búsqueda también por email del usuario autenticado
- ShowConversaciones: soporta ?conv=ID para abrir conversación desde comprobantes
- Nav: reemplaza "Menús del Bot" (no funcional) por "Comprobantes"
- SolicitudRecarga: relación user() agregada
- ChatController: método comprobantes() agregado

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-07-29 21:13:31 +00:00
LizandroandClaude Sonnet 4.6 77c3353213 fix: catch all exceptions in Telegram email flow + webhook global handler
- processEmail: wrap DB lookup and ChatContact create/update in try-catch
  so any exception sends an error message to the user instead of silently
  failing and leaving state stuck at await_email
- sendOtp: inform user if mail sending fails so they know to wait/retry
- TelegramWebhookController: top-level try-catch returns 200 always so
  Telegram never retries on server errors (retries caused duplicate state resets)
- ChatContact canal_id cast to string to avoid type mismatch on insert

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-07-15 04:01:53 +00:00
LizandroandClaude Sonnet 4.6 44297aa0bb Add AI usage logs for Gemini and Whisper
- Migration + AiUsageLog model with tokens, duration, time, cost fields
- GeminiIntentService and GeminiVisionService log every API call
  with input/output token counts from usageMetadata and response time
- TelegramBotService logs Whisper calls with audio duration (from Telegram)
  and calculates cost at $1/second
- Whisper voice duration now passed from TelegramWebhookController
- Free text in Telegram now tries Gemini intent detection before showing menu
- /chat/ia-logs: Livewire component with summary cards + filterable table
- Whisper connection test button in config panel
- "Logs IA" link added to Chat/Bot nav section

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-07-14 19:13:59 +00:00
LizandroandClaude Sonnet 4.6 f39f3d4045 Add Whisper voice transcription to Telegram bot
- handleVoice() downloads Telegram audio and transcribes via Whisper API
- transcribeAudio() calls Whisper with Basic Auth, handles json response
- TelegramWebhookController now routes message.voice and message.audio
- Whisper URL, token and toggle configurable from admin config panel
- Transcribed text echoed back to user then processed as normal text intent

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-07-14 19:00:57 +00:00
LizandroandClaude Sonnet 4.6 2fc2aba8a3 feat: Telegram transactional flows + role pricing + services slider
- New TelegramBotService: full OTP auth, registration, main menu with
  inline keyboards, buy plans, buy promos, recharge (MP + Bre-B),
  credentials, history, profile, agent transfer, photo receipt analysis
- TelegramWebhookController: now handles text, callback_query and photo
- Role-based pricing: tarifas filtered by user rol_id in both web chat
  and Telegram; Preferencial price overrides base tarifa valor
- Services and promos now render as horizontal scroll slider
  (cards_slider tipo_ui) instead of stacked individual cards

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-07-14 04:36:03 +00:00
Lizandro Guarnizo 9066229e3a up 2026-06-18 12:56:20 -05:00
Lizandro Guarnizo 67732fbde5 up 2026-05-12 19:50:28 -05:00
Lizandro Guarnizo f61e8005fc chatbot nuevo 2026-04-30 21:32:32 -05:00
Lizandro Guarnizo bbf34d08d0 correo 2026-04-25 14:47:20 -05:00
Lizandro Guarnizo 148fa6b9f9 up 2026-04-24 21:40:10 -05:00
Lizandro Guarnizo 03207775af up 2026-04-18 14:08:14 -05:00
Juan Felipe Duarte 36bf56b622 Normalize email input for registration and login
Trim and lowercase email before storing or attempting login to avoid mismatches from case or surrounding whitespace. Updated RegisteredUserController@store to save 'email' => strtolower(trim($request->email)) and LoginRequest@authenticate to call Auth::attempt with the normalized email input.
2026-03-02 08:43:12 -05:00
Juan Felipe Duarte a558e393f2 Add rank management feature with CRUD and UI
Introduces a new rank management system including the Rank model, migrations for the ranks table and user IP address, Livewire components for managing and displaying ranks, and related Blade views. Updates navigation and routes to include the new 'Gestión Rangos' section, and enhances the ShareCodeComponent with user data. Also adds a reusable input field component for forms.
2025-10-23 20:28:47 -05:00
Juan Felipe Duarte 5ea64cac17 Add IP test page with Livewire component
Introduces a new route and controller method for '/ip-test', rendering a new view that includes a Livewire component to display the user's IP address. Updates navigation layout for improved profile display. Adds related Blade and Livewire files.
2025-10-17 14:50:13 -05:00
Juan Felipe Duarte 0e2a7e9a20 Copy tarifas and promos on user registration
When a new user registers with a referral code, their tarifas and promos are now copied from the referring user. Also refactored Usuario_promo and Usuario_tarifa models to use fillable attributes and improved method formatting. Added Swiper CSS/JS to app layout.
2025-10-16 14:46:17 -05:00
Juan Felipe Duarte 5c04a95792 update codigo referido funcionamiento login, register y dashboard 2025-10-15 16:43:43 -05:00
Juan Felipe Duarte c7586cf6cd update 2025-07-31 15:19:22 -07:00
Juan Felipe Duarte e8050ea19f vista tarifas 2025-06-19 17:54:22 -07:00
Lizandro Guarnizo d1c5dbc90e update 2025-04-14 18:08:49 -05:00
lizandrogd ac229cdb74 cambio real 2025-04-03 22:28:20 -05:00
lizandrogd 8d419edbed upp 2025-04-02 01:15:12 -05:00
lizandrogd 8266de9d5f havinraw 2025-04-02 00:55:15 -05:00
lizandrogd c0e3284c62 historial_id 2025-02-27 15:19:52 -05:00
lizandrogd 76bd9df10e Se agrego tipo a log_general. 2025-02-27 10:55:12 -05:00
lizandrogd 31287e476f Update MenuController.php 2024-05-11 12:57:13 -05:00
lizandrogd 002b53252c Update MenuController.php 2024-05-11 12:49:23 -05:00
Felipe 80c8748182 mantenimiento 2024-04-29 18:21:04 -05:00
Felipe 6c760652f6 log historial 2024-03-01 08:05:52 -05:00
root 4506a003e8 Mensaje de commit 2023-11-07 22:43:10 +00:00
Felipe fd9afd2183 update 2023-10-23 17:09:05 -05:00
Felipe 41605dd83f log general 2023-10-07 17:31:35 -05:00
lizandrogd 8ce210f27c Initial commit 2023-07-26 08:28:13 -05:00