Spaces:
Running

dashboard / index.html
LHSS's picture
o menu esta sobrepondo o dashboard - Follow Up Deployment
54afded verified
Raw History Blame Contribute Delete
60.1 kB
<!DOCTYPE html> <html lang="pt-BR"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>Restaurant Management Dashboard</title> <script src="https://cdn.tailwindcss.com"></script> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css"> <script> tailwind.config = { theme: { extend: { colors: { primary: '#2C3E50', secondary: '#5DADE2', light: '#ECF0F1', accent: '#3498DB', success: '#2ECC71', warning: '#F39C12', danger: '#E74C3C', info: '#3498DB' }, fontFamily: { sans: ['Inter', 'sans-serif'], } } } } </script> <style> @import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap'); body { font-family: 'Inter', sans-serif; background-color: #F8F9FA; } .dashboard-card { box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05); border-radius: 10px; transition: transform 0.3s ease; position: relative; z-index: 10; } .dashboard-card:hover { transform: translateY(-3px); box-shadow: 0 8px 15px rgba(0, 0, 0, 0.08); } .order-status-pendente { background-color: #F39C12; color: white; } .order-status-producao { background-color: #3498DB; color: white; } .order-status-entrega { background-color: #9B59B6; color: white; } .order-status-entregue { background-color: #2ECC71; color: white; } .order-status-cancelado { background-color: #E74C3C; color: white; } .progress-bar { height: 5px; background-color: #e0e0e0; border-radius: 2.5px; } .progress-value { height: 100%; border-radius: 2.5px; background-color: #3498DB; } .modal-overlay { background-color: rgba(0, 0, 0, 0.5); z-index: 40; } .ticket-format { width: 80mm; font-family: monospace; } @media (max-width: 768px) { .ticket-format { width: 100%; } } </style> </head> <body class="bg-gray-50"> <!-- Login Container --> <div id="login-container" class="min-h-screen flex items-center justify-center p-4"> <div class="w-full max-w-md bg-white shadow-xl rounded-2xl overflow-hidden dashboard-card"> <div class="bg-primary py-6 text-center"> <img id="developer-logo" src="https://storage.googleapis.com/hostinger-horizons-assets-prod/5c29d94d-dcdf-4fd4-9ee6-e92bcee26348/6b958ee43f948b225fa53b776779bde2.png" class="w-32 mx-auto" alt="Developer Logo"> <h2 class="text-2xl font-bold text-white mt-4">RESTAURANT DASHBOARD</h2> </div> <div id="login-form" class="p-8"> <!-- Tab Navigation --> <div class="flex mb-6 border-b"> <button id="btn-restaurante" class="flex-1 py-2 font-medium text-center border-b-2 border-primary text-primary transition-colors duration-200"> Restaurante </button> <button id="btn-tecnico" class="flex-1 py-2 font-medium text-center text-gray-500 hover:text-primary transition-colors duration-200"> Técnico </button> </div> <div id="restaurante-login" class="mb-6"> <div class="mb-5"> <label class="block text-gray-700 text-sm font-medium mb-1">Restaurante</label> <select class="w-full px-4 py-2 border rounded-lg focus:ring focus:ring-secondary focus:border-secondary"> <option>Restaurante Delícia</option> <option>Cozinha Mineira</option> <option>Pizzaria Italiana</option> </select> </div> <div class="mb-5"> <label class="block text-gray-700 text-sm font-medium mb-1">Usuário</label> <input type="text" class="w-full px-4 py-2 border rounded-lg focus:ring focus:ring-secondary focus:border-secondary"> </div> <div class="mb-6"> <label class="block text-gray-700 text-sm font-medium mb-1">Senha</label> <input type="password" class="w-full px-4 py-2 border rounded-lg focus:ring focus:ring-secondary focus:border-secondary"> </div> <button id="login-btn" class="w-full bg-primary text-white py-2.5 rounded-lg font-medium hover:bg-primary/90 transition">Acessar Dashboard</button> </div> <div id="tecnico-login" class="hidden mb-6"> <div class="mb-5"> <label class="block text-gray-700 text-sm font-medium mb-1">Login Técnico</label> <input type="text" class="w-full px-4 py-2 border rounded-lg focus:ring focus:ring-secondary focus:border-secondary" value="admin"> </div> <div class="mb-6"> <label class="block text-gray-700 text-sm font-medium mb-1">Senha</label> <input type="password" class="w-full px-4 py-2 border rounded-lg focus:ring focus:ring-secondary focus:border-secondary" placeholder="Senha padrão: 190329"> </div> <div class="flex items-center mb-4"> <input id="password-change" type="checkbox" class="rounded border-gray-300 text-primary focus:ring-primary"> <label for="password-change" class="ml-2 text-sm text-gray-700">É seu primeiro acesso? Alterar senha padrão</label> </div> <div id="new-password-fields" class="hidden"> <div class="mb-4"> <label class="block text-gray-700 text-sm font-medium mb-1">Nova Senha</label> <input type="password" class="w-full px-4 py-2 border rounded-lg focus:ring focus:ring-secondary focus:border-secondary"> </div> <div class="mb-6"> <label class="block text-gray-700 text-sm font-medium mb-1">Confirmar Nova Senha</label> <input type="password" class="w-full px-4 py-2 border rounded-lg focus:ring focus:ring-secondary focus:border-secondary"> </div> </div> <button class="w-full bg-primary text-white py-2.5 rounded-lg font-medium hover:bg-primary/90 transition">Acessar Área Técnica</button> </div> <div class="text-center mt-6"> <a id="forgot-password-btn" class="text-sm text-secondary font-medium hover:underline cursor-pointer">Esqueceu sua senha?</a> </div> </div> </div> </div> <!-- Forgot Password Modal --> <div id="forgot-password-modal" class="hidden fixed inset-0 bg-black bg-opacity-50 flex items-center justify-center p-4 z-50"> <div class="bg-white rounded-lg w-full max-w-md p-6"> <div class="flex justify-between items-center mb-4"> <h3 class="text-xl font-bold">Recuperação de Senha</h3> <button id="close-forgot-modal" class="text-gray-500 hover:text-gray-700"> <i class="fas fa-times"></i> </button> </div> <p class="text-sm text-gray-600 mb-4">Digite seu e-mail ou telefone cadastrado para receber instruções de recuperação de senha.</p> <div class="mb-4"> <label class="block text-gray-700 text-sm font-medium mb-1">E-mail ou Telefone</label> <input type="text" id="recovery-contact" class="w-full px-4 py-2 border rounded-lg focus:ring focus:ring-secondary"> </div> <button id="send-recovery-btn" class="w-full bg-primary text-white py-2.5 rounded-lg font-medium hover:bg-primary/90 transition"> Enviar Instruções </button> <div id="recovery-success" class="hidden mt-4 p-3 bg-green-100 text-green-800 rounded-lg text-sm"> <i class="fas fa-check-circle mr-1"></i> Instruções enviadas com sucesso! Verifique seu e-mail ou SMS. </div> </div> </div> <!-- Dashboard Container (hidden initially) --> <div id="dashboard-container" class="hidden min-h-screen"> <!-- Top Navigation - Always visible when logged in --> <header class="bg-white shadow-sm fixed top-0 left-0 right-0 z-30"> <div class="flex items-center justify-between p-4 max-w-7xl mx-auto"> <div class="flex items-center"> <div class="flex items-center"> <img id="client-logo" src="https://via.placeholder.com/150" class="h-10" alt="Client Logo"> <div class="ml-3"> <h1 class="font-bold text-xl text-gray-800">Restaurante Delícia</h1> <p class="text-xs text-gray-500">Dashboard de Gestão</p> </div> </div> <nav class="hidden md:flex ml-10 space-x-4"> <a href="#" id="pedidos-link" class="px-3 py-2 rounded-lg text-white bg-primary font-medium">Pedidos</a> <a href="#crm-section" id="crm-link" class="px-3 py-2 rounded-lg text-gray-700 hover:bg-gray-100 font-medium">Clientes</a> <a href="#relatorios-section" id="relatorios-link" class="px-3 py-2 rounded-lg text-gray-700 hover:bg-gray-100 font-medium">Relatórios</a> <a href="#config-section" id="config-link" class="px-3 py-2 rounded-lg text-gray-700 hover:bg-gray-100 font-medium">Configurações</a> </nav> </div> <div class="flex items-center space-x-4"> <button class="p-2 rounded-full hover:bg-gray-100 relative"> <i class="fas fa-bell text-gray-500 text-lg"></i> <span class="absolute top-0 right-0 w-2.5 h-2.5 bg-danger rounded-full"></span> </button> <div class="flex items-center"> <div class="h-8 w-8 rounded-full bg-primary flex items-center justify-center"> <span class="text-white font-medium text-xs">AD</span> </div> <span class="ml-2 font-medium text-gray-700 hidden md:block">Admin User</span> <button id="logout-btn" class="ml-3 text-gray-500 hover:text-gray-700"> <i class="fas fa-sign-out-alt"></i> </button> </div> </div> </div> </header> <!-- Dashboard Main Content --> <main class="max-w-7xl mx-auto p-4 sm:p-6 pt-24"> <!-- Metrics Summary --> <div class="grid grid-cols-1 md:grid-cols-4 gap-5 mb-6"> <div class="bg-white dashboard-card p-5"> <div class="flex justify-between items-center"> <div> <h3 class="text-gray-500 text-sm font-medium mb-1">Total de Pedidos</h3> <p class="text-2xl font-bold">142</p> </div> <div class="p-3 rounded-lg bg-secondary/20"> <i class="fas fa-shopping-cart text-secondary text-xl"></i> </div> </div> <p class="text-xs text-gray-500 mt-2"><span class="text-success">+12%</span> em relação ao mês passado</p> </div> <div class="bg-white dashboard-card p-5"> <div class="flex justify-between items-center"> <div> <h3 class="text-gray-500 text-sm font-medium mb-1">Clientes Ativos</h3> <p class="text-2xl font-bold">48</p> </div> <div class="p-3 rounded-lg bg-primary/20"> <i class="fas fa-users text-primary text-xl"></i> </div> </div> <p class="text-xs text-gray-500 mt-2"><span class="text-success">+3</span> novos essa semana</p> </div> <div class="bg-white dashboard-card p-5"> <div class="flex justify-between items-center"> <div> <h3 class="text-gray-500 text-sm font-medium mb-1">Ticket Médio</h3> <p class="text-2xl font-bold">R$ 38,90</p> </div> <div class="p-3 rounded-lg bg-warning/20"> <i class="fas fa-chart-line text-warning text-xl"></i> </div> </div> <p class="text-xs text-gray-500 mt-2"><span class="text-success">+8%</span> crescimento</p> </div> <div class="bg-white dashboard-card p-5"> <div class="flex justify-between items-center"> <div> <h3 class="text-gray-500 text-sm font-medium mb-1">Conversas Ativas</h3> <p class="text-2xl font-bold">12</p> </div> <div class="p-3 rounded-lg bg-info/20"> <i class="fas fa-comments text-info text-xl"></i> </div> </div> <p class="text-xs text-gray-500 mt-2"><span class="text-danger">-2</span> desde ontem</p> </div> </div> <!-- Order Management Section --> <div class="grid grid-cols-1 lg:grid-cols-3 gap-6"> <!-- Order List --> <div class="lg:col-span-2 bg-white dashboard-card"> <div class="border-b border-gray-200 py-4 px-6 flex justify-between items-center"> <h2 class="text-lg font-bold text-gray-800">Gestão de Pedidos</h2> <div class="flex items-center gap-2"> <div class="relative"> <i class="fas fa-search absolute left-3 top-2.5 text-gray-400"></i> <input type="text" placeholder="Pesquisar..." class="pl-10 px-3 py-1.5 border rounded-lg text-sm w-40 focus:ring focus:ring-secondary"> </div> <select class="px-3 py-1.5 border rounded-lg text-sm"> <option value="">Todos Status</option> <option value="pendente">Pendente</option> <option value="producao">Em Produção</option> <option value="entrega">Saiu para Entrega</option> <option value="entregue">Entregue</option> <option value="cancelado">Cancelado</option> </select> </div> </div> <div class="divide-y"> <!-- Order Item 1 --> <div class="p-4"> <div class="flex justify-between items-start mb-2"> <div> <span class="text-xs bg-primary text-white py-0.5 px-2 rounded order-status-pendente">Pedido Pendente</span> <h3 class="font-medium text-lg mt-1">#PED-00123</h3> <p class="text-sm text-gray-500">João Silva | 10/05/2023 19:30</p> </div> <span class="text-lg font-bold">R$ 57,90</span> </div> <div class="flex flex-wrap gap-2 mt-3"> <button class="px-3 py-1.5 bg-gray-200 text-gray-700 rounded-lg text-sm hover:bg-gray-300"> <i class="fas fa-info-circle mr-1"></i> Detalhes </button> <button class="px-3 py-1.5 bg-primary text-white rounded-lg text-sm hover:bg-primary/90"> <i class="fas fa-print mr-1"></i> Imprimir Comanda </button> <button class="px-3 py-1.5 bg-danger text-white rounded-lg text-sm hover:bg-danger/90"> <i class="fas fa-times mr-1"></i> Cancelar </button> </div> </div> <!-- Order Item 2 --> <div class="p-4 bg-gray-50"> <div class="flex justify-between items-start mb-2"> <div> <span class="text-xs bg-blue-600 text-white py-0.5 px-2 rounded order-status-producao">Em Produção</span> <h3 class="font-medium text-lg mt-1">#PED-00124</h3> <p class="text-sm text-gray-500">Ana Santos | 10/05/2023 19:45</p> </div> <span class="text-lg font-bold">R$ 82,50</span> </div> <div class="flex flex-wrap gap-2 mt-3"> <button class="px-3 py-1.5 bg-gray-200 text-gray-700 rounded-lg text-sm hover:bg-gray-300"> <i class="fas fa-info-circle mr-1"></i> Detalhes </button> <button class="px-3 py-1.5 bg-success text-white rounded-lg text-sm hover:bg-success/90"> <i class="fas fa-shipping-fast mr-1"></i> Saiu para Entrega </button> <button class="px-3 py-1.5 bg-danger text-white rounded-lg text-sm hover:bg-danger/90"> <i class="fas fa-times mr-1"></i> Cancelar </button> </div> </div> <!-- Order Item 3 --> <div class="p-4"> <div class="flex justify-between items-start mb-2"> <div> <span class="text-xs bg-purple-600 text-white py-0.5 px-2 rounded order-status-entrega">Saiu para Entrega</span> <h3 class="font-medium text-lg mt-1">#PED-00122</h3> <p class="text-sm text-gray-500">Carlos Oliveira | 10/05/2023 19:20</p> </div> <span class="text-lg font-bold">R$ 42,00</span> </div> <div class="flex flex-wrap gap-2 mt-3"> <button class="px-3 py-1.5 bg-gray-200 text-gray-700 rounded-lg text-sm hover:bg-gray-300"> <i class="fas fa-info-circle mr-1"></i> Detalhes </button> <button class="px-3 py-1.5 bg-success text-white rounded-lg text-sm hover:bg-success/90"> <i class="fas fa-check mr-1"></i> Marcar Entregue </button> <button class="px-3 py-1.5 bg-danger text-white rounded-lg text-sm hover:bg-danger/90"> <i class="fas fa-times mr-1"></i> Cancelar </button> </div> </div> </div> </div> <!-- Stats Section --> <div class="bg-white dashboard-card"> <div class="border-b border-gray-200 py-4 px-6"> <h2 class="text-lg font-bold text-gray-800">Status de Pedidos</h2> </div> <div class="p-5 space-y-5"> <div> <div class="flex justify-between mb-1 text-sm"> <span class="text-gray-600">Pedidos Pendentes</span> <span class="font-medium">8</span> </div> <div class="progress-bar"> <div class="progress-value bg-warning" style="width: 35%"></div> </div> </div> <div> <div class="flex justify-between mb-1 text-sm"> <span class="text-gray-600">Em Produção</span> <span class="font-medium">4</span> </div> <div class="progress-bar"> <div class="progress-value bg-info" style="width: 20%"></div> </div> </div> <div> <div class="flex justify-between mb-1 text-sm"> <span class="text-gray-600">Saiu para Entrega</span> <span class="font-medium">5</span> </div> <div class="progress-bar"> <div class="progress-value bg-secondary" style="width: 25%"></div> </div> </div> <div> <div class="flex justify-between mb-1 text-sm"> <span class="text-gray-600">Entregues</span> <span class="font-medium">125</span> </div> <div class="progress-bar"> <div class="progress-value bg-success" style="width: 60%"></div> </div> </div> <div class="mt-8"> <h3 class="font-medium mb-3">Atividade Recente</h3> <ul class="space-y-3 text-sm"> <li class="flex"> <span class="text-success mr-2">•</span> Pedido #PED-00124 atualizado para "Em Produção" </li> <li class="flex"> <span class="text-success mr-2">•</span> Novo pedido #PED-00123 criado por João Silva </li> <li class="flex"> <span class="text-primary mr-2">•</span> Conversa iniciada com Ana Santos via WhatsApp </li> <li class="flex"> <span class="text-success mr-2">•</span> Pedido #PED-00122 saiu para entrega </li> </ul> </div> </div> </div> </div> </main> </div> <!-- CRM Section (now Clientes) --> <section id="crm-section" class="hidden max-w-7xl mx-auto p-4 sm:p-6 pt-20"> <div class="bg-white dashboard-card p-6"> <h2 class="text-2xl font-bold mb-6">Clientes e Comunicação</h2> <!-- Added CRM Communication Section --> <div class="dashboard-card mb-6"> <div class="border-b border-gray-200 py-4 px-6 flex justify-between items-center"> <h2 class="text-lg font-bold text-gray-800">Comunicação com Clientes</h2> <button class="flex items-center text-primary font-medium"> <i class="fas fa-plus mr-1"></i> Nova Conversa </button> </div> <div class="p-4"> <div class="flex flex-col md:flex-row mb-4 gap-3"> <div class="relative w-full"> <i class="fas fa-search absolute left-3 top-3 text-gray-400"></i> <input type="text" placeholder="Pesquisar cliente ou pedido..." class="pl-10 w-full px-4 py-2 border rounded-lg focus:ring focus:ring-secondary focus:border-secondary"> </div> <div class="flex gap-2 flex-wrap"> <select class="px-3 py-2 border rounded-lg text-sm"> <option>Todos Status</option> <option>Aberto</option> <option>Pendente</option> <option>Fechado</option> </select> <select class="px-3 py-2 border rounded-lg text-sm"> <option>Todos Atendentes</option> <option>Maria</option> <option>João</option> <option>Ana</option> </select> <select class="px-3 py-2 border rounded-lg text-sm"> <option>Todos Canais</option> <option>WhatsApp</option> <option>Telefone</option> <option>E-mail</option> </select> <button class="px-3 py-2 bg-primary text-white rounded-lg text-sm">Filtrar</button> </div> </div> <div class="overflow-x-auto"> <table class="w-full text-sm text-left"> <thead class="text-xs text-gray-700 uppercase bg-gray-50"> <tr> <th class="px-4 py-3">Cliente</th> <th class="px-4 py-3">Canal</th> <th class="px-4 py-3">Última Interação</th> <th class="px-4 py-3">Status</th> <th class="px-4 py-3">Atribuído</th> <th class="px-4 py-3">Ações</th> </tr> </thead> <tbody> <tr class="bg-white border-b hover:bg-gray-50"> <td class="px-4 py-3 font-medium text-gray-900">João Silva</td> <td class="px-4 py-3"><span class="px-2 py-1 bg-green-100 text-green-800 rounded-full text-xs">WhatsApp</span></td> <td class="px-4 py-3">há 10 minutos</td> <td class="px-4 py-3"><span class="px-2 py-1 bg-primary text-white rounded-full text-xs">Aberto</span></td> <td class="px-4 py-3"> <div class="flex items-center"> <div class="h-6 w-6 rounded-full bg-info flex items-center justify-center"> <span class="text-white text-xs">M</span> </div> <span class="ml-2">Maria</span> </div> </td> <td class="px-4 py-3"> <button class="px-3 py-1 bg-secondary text-white rounded-lg text-sm mr-1">Atender</button> <button class="px-3 py-1 bg-gray-200 text-gray-700 rounded-lg text-sm">Histórico</button> </td> </tr> <tr class="bg-white border-b hover:bg-gray-50"> <td class="px-4 py-3 font-medium text-gray-900">Ana Santos</td> <td class="px-4 py-3"><span class="px-2 py-1 bg-blue-100 text-blue-800 rounded-full text-xs">Telefone</span></td> <td class="px-4 py-3">ontem, 15:22</td> <td class="px-4 py-3"><span class="px-2 py-1 bg-warning text-white rounded-full text-xs">Pendente</span></td> <td class="px-4 py-3"> <div class="flex items-center"> <div class="h-6 w-6 rounded-full bg-success flex items-center justify-center"> <span class="text-white text-xs">J</span> </div> <span class="ml-2">João</span> </div> </td> <td class="px-4 py-3"> <button class="px-3 py-1 bg-secondary text-white rounded-lg text-sm mr-1">Atender</button> <button class="px-3 py-1 bg-gray-200 text-gray-700 rounded-lg text-sm">Histórico</button> </td> </tr> <tr class="bg-white border-b hover:bg-gray-50"> <td class="px-4 py-3 font-medium text-gray-900">Pedro Almeida</td> <td class="px-4 py-3"><span class="px-2 py-1 bg-purple-100 text-purple-800 rounded-full text-xs">E-mail</span></td> <td class="px-4 py-3">há 2 dias</td> <td class="px-4 py-3"><span class="px-2 py-1 bg-success text-white rounded-full text-xs">Fechado</span></td> <td class="px-4 py-3"> <div class="flex items-center"> <div class="h-6 w-6 rounded-full bg-danger flex items-center justify-center"> <span class="text-white text-xs">A</span> </div> <span class="ml-2">Ana</span> </div> </td> <td class="px-4 py-3"> <button class="px-3 py-1 bg-secondary text-white rounded-lg text-sm mr-1">Ver</button> <button class="px-3 py-1 bg-gray-200 text-gray-700 rounded-lg text-sm">Histórico</button> </td> </tr> </tbody> </table> </div> </div> </div> <!-- Client Management Overview --> <div class="grid md:grid-cols-4 gap-6 mb-8"> <div class="border rounded-lg p-4"> <h3 class="text-lg font-medium mb-2">Clientes Ativos</h3> <p class="text-3xl font-bold text-primary">248</p> </div> <div class="border rounded-lg p-4"> <h3 class="text-lg font-medium mb-2">Frequência Média</h3> <p class="text-3xl font-bold text-secondary">1.8x/mês</p> </div> <div class="border rounded-lg p-4"> <h3 class="text-lg font-medium mb-2">Inativos (30 dias)</h3> <p class="text-3xl font-bold text-warning">42</p> </div> <div class="border rounded-lg p-4"> <h3 class="text-lg font-medium mb-2">Fidelizados</h3> <p class="text-3xl font-bold text-success">156</p> </div> </div> <div class="flex justify-between mb-4"> <div class="relative w-64"> <i class="fas fa-search absolute left-3 top-3 text-gray-400"></i> <input type="text" placeholder="Buscar cliente..." class="pl-10 w-full px-4 py-2 border rounded-lg focus:ring focus:ring-secondary"> </div> <button class="bg-primary text-white px-4 py-2 rounded-lg"> <i class="fas fa-plus mr-2"></i>Novo Cliente </button> </div> <div class="overflow-x-auto"> <table class="w-full"> <thead class="bg-gray-50"> <tr> <th class="px-4 py-3 text-left">Nome</th> <th class="px-4 py-3 text-left">Telefone</th> <th class="px-4 py-3 text-left">Email</th> <th class="px-4 py-3 text-left">Pedidos</th> <th class="px-4 py-3 text-left">Status</th> <th class="px-4 py-3 text-left">Ações</th> </tr> </thead> <tbody class="divide-y"> <tr> <td class="px-4 py-3">João Silva</td> <td class="px-4 py-3">(11) 98765-4321</td> <td class="px-4 py-3">joao@email.com</td> <td class="px-4 py-3">12</td> <td class="px-4 py-3"><span class="px-2 py-1 bg-green-100 text-green-800 rounded-full">Ativo</span></td> <td class="px-4 py-3"> <button class="text-primary hover:text-secondary mx-1"> <i class="fas fa-edit"></i> </button> <button class="text-info hover:text-blue-700 mx-1"> <i class="fas fa-eye"></i> </button> </td> </tr> <!-- More client rows would be added here --> </tbody> </table> </div> </div> </section> <!-- Reports Section --> <section id="relatorios-section" class="hidden max-w-7xl mx-auto p-4 sm:p-6 pt-20"> <div class="bg-white dashboard-card p-6"> <h2 class="text-2xl font-bold mb-6">Relatórios e Análises</h2> <div class="grid md:grid-cols-3 gap-6 mb-6"> <div class="border rounded-lg p-4"> <h3 class="font-medium mb-3">Relatório Diário</h3> <button class="w-full bg-primary text-white py-2 rounded-lg">Gerar</button> </div> <div class="border rounded-lg p-4"> <h3 class="font-medium mb-3">Relatório Semanal</h3> <button class="w-full bg-success text-white py-2 rounded-lg">Gerar</button> </div> <div class="border rounded-lg p-4"> <h3 class="font-medium mb-3">Relatório Mensal</h3> <button class="w-full bg-secondary text-white py-2 rounded-lg">Gerar</button> </div> </div> <div class="border rounded-lg p-4 mb-6"> <h3 class="font-medium mb-3">Filtros</h3> <div class="grid md:grid-cols-4 gap-3"> <div> <label class="block text-sm mb-1">Período</label> <select class="w-full border rounded-lg p-2"> <option>Últimos 7 dias</option> <option>Este mês</option> <option>Mês passado</option> </select> </div> <div> <label class="block text-sm mb-1">Tipo</label> <select class="w-full border rounded-lg p-2"> <option>Faturamento</option> <option>Pedidos</option> <option>Clientes</option> </select> </div> <div> <label class="block text-sm mb-1">Formato</label> <select class="w-full border rounded-lg p-2"> <option>PDF</option> <option>Excel</option> <option>HTML</option> </select> </div> <div class="flex items-end"> <button class="w-full bg-primary text-white py-2 rounded-lg">Aplicar</button> </div> </div> </div> <div class="border rounded-lg p-4"> <div class="flex justify-between"> <h3 class="font-medium">Faturamento Mensal</h3> <select class="border rounded-lg p-1 text-sm"> <option>2023</option> <option>2022</option> </select> </div> <div class="h-64 mt-4"> <!-- This would be filled with chart data via JavaScript --> <div class="h-full flex items-center justify-center bg-gray-100 rounded-lg"> <p class="text-gray-500">Gráfico de faturamento será exibido aqui</p> </div> </div> </div> </div> </section> <!-- Config Section --> <section id="config-section" class="hidden max-w-7xl mx-auto p-4 sm:p-6 pt-10"> <div class="bg-white dashboard-card p-6"> <h2 class="text-2xl font-bold mb-6">Configurações do Sistema</h2> <div class="grid md:grid-cols-3 gap-6"> <div class="border rounded-lg p-4 hover:shadow-md transition-colors hover:bg-gray-50"> <div class="text-primary text-2xl mb-2"> <i class="fas fa-store"></i> </div> <h3 class="font-medium mb-2">Dados do Restaurante</h3> <p class="text-sm text-gray-600 mb-3">Configure nome, endereço e outras informações básicas</p> <button class="text-sm text-primary hover:text-secondary font-medium flex items-center gap-1"> Gerenciar <i class="fas fa-chevron-right text-xs mt-0.5"></i> </button> </div> <div class="border rounded-lg p-4 hover:shadow-md transition-colors hover:bg-gray-50"> <div class="text-secondary text-2xl mb-2"> <i class="fas fa-users-cog"></i> </div> <h3 class="font-medium mb-2">Usuários e Acessos</h3> <p class="text-sm text-gray-600 mb-3">Gerencie contas de usuários e permissões</p> <button class="text-sm text-primary hover:text-secondary font-medium flex items-center gap-1"> Gerenciar <i class="fas fa-chevron-right text-xs mt-0.5"></i> </button> </div> <div class="border rounded-lg p-4 hover:shadow-md transition-colors hover:bg-gray-50"> <div class="text-success text-2xl mb-2"> <i class="fas fa-utensils"></i> </div> <h3 class="font-medium mb-2">Cardápio</h3> <p class="text-sm text-gray-600 mb-3">Configure produtos, categorias e preços</p> <button class="text-sm text-primary hover:text-secondary font-medium flex items-center gap-1"> Gerenciar <i class="fas fa-chevron-right text-xs mt-0.5"></i> </button> </div> <div class="border rounded-lg p-4 hover:shadow-md transition-colors hover:bg-gray-50"> <div class="text-warning text-2xl mb-2"> <i class="fas fa-credit-card"></i> </div> <h3 class="font-medium mb-2">Formas de Pagamento</h3> <p class="text-sm text-gray-600 mb-3">Configure opções de pagamento aceitas</p> <button class="text-sm text-primary hover:text-secondary font-medium flex items-center gap-1"> Gerenciar <i class="fas fa-chevron-right text-xs mt-0.5"></i> </button> </div> <div class="border rounded-lg p-4 hover:shadow-md transition-colors hover:bg-gray-50"> <div class="text-danger text-2xl mb-2"> <i class="fas fa-truck"></i> </div> <h3 class="font-medium mb-2">Entregas</h3> <p class="text-sm text-gray-600 mb-3">Configure zonas e taxas de entrega</p> <button class="text-sm text-primary hover:text-secondary font-medium flex items-center gap-1"> Gerenciar <i class="fas fa-chevron-right text-xs mt-0.5"></i> </button> </div> <div class="border rounded-lg p-4 hover:shadow-md transition-colors hover:bg-gray-50"> <div class="text-info text-2xl mb-2"> <i class="fas fa-bell"></i> </div> <h3 class="font-medium mb-2">Notificações</h3> <p class="text-sm text-gray-600 mb-3">Configure alertas e notificações</p> <button class="text-sm text-primary hover:text-secondary font-medium flex items-center gap-1"> Gerenciar <i class="fas fa-chevron-right text-xs mt-0.5"></i> </button> </div> </div> </div> </section> <!-- Print Preview Modal --> <div id="print-modal" class="fixed inset-0 z-50 hidden items-center justify-center p-4 bg-black bg-opacity-50"> <div class="bg-white rounded-xl w-full max-w-2xl max-h-[90vh] overflow-auto"> <div class="border-b p-4 flex justify-between items-center"> <h3 class="text-lg font-bold">Comanda para Impressão</h3> <button id="close-print-modal" class="text-gray-400 hover:text-gray-600"> <i class="fas fa-times"></i> </button> </div> <div class="p-6"> <div class="ticket-format mx-auto bg-white shadow-none"> <div class="text-center border-b border-dashed pb-3 mb-3"> <img id="print-client-logo" src="https://via.placeholder.com/150" class="h-16 mx-auto mb-2"> <h1 class="text-2xl font-bold uppercase">Restaurante Delícia</h1> <p class="text-sm">Rua das Flores, 123 • Jardim Paulista • São Paulo/SP</p> <p class="text-sm">Telefone: (11) 4321-5678</p> </div> <div class="text-center mb-4"> <div class="bg-gray-200 py-1 inline-block px-4 rounded-lg"> <p class="text-sm font-bold">PEDIDO: #PED-00123</p> </div> <p class="text-xs">Data: 10/05/2023 • Hora: 19:30</p> </div> <div class="border-b border-dashed pb-3 mb-3"> <h3 class="font-bold uppercase text-sm">Cliente</h3> <p class="font-bold">João Silva</p> <p class="text-sm">Rua das Acácias, 45 • Vila Nova • São Paulo/SP</p> <p class="text-sm">Ponto de Referência: Próximo à padaria</p> <p class="text-sm">Telefone: (11) 98765-4321</p> </div> <div class="border-b border-dashed pb-3 mb-3"> <h3 class="font-bold uppercase text-sm mb-2">Itens do Pedido</h3> <div class="text-sm"> <div class="flex justify-between mb-1"> <span class="font-bold">1x Pizza Calabresa</span> <span>R$ 45,00</span> </div> <p class="text-xs pl-2 mb-2">Obs: Sem cebola, borda recheada</p> <div class="flex justify-between mb-1"> <span class="font-bold">2x Refrigerante 2L</span> <span>R$ 12,90</span> </div> <p class="text-xs pl-2">1 Coca-Cola, 1 Guaraná</p> </div> </div> <div class="mb-4"> <div class="flex justify-between mb-1"> <span class="font-bold">Valor dos Itens:</span> <span>R$ 57,90</span> </div> <div class="flex justify-between mb-1"> <span class="font-bold">Taxa de Entrega:</span> <span>R$ 5,00</span> </div> <div class="flex justify-between font-bold text-lg mt-3"> <span>TOTAL:</span> <span>R$ 62,90</span> </div> <div class="mt-3"> <p><span class="font-bold">Forma de Pagamento:</span> Cartão de Crédito</p> <p class="mt-1"><span class="font-bold">Troco para:</span> Não necessário</p> </div> </div> <div class="text-center text-xs py-4 border-t border-dashed"> <p>Agradecemos pela preferência!</p> <p class="mt-1">Pedido sujeito à confirmação</p> </div> </div> <div class="mt-6 text-center"> <button id="print-btn" class="px-5 py-2.5 bg-primary text-white rounded-lg font-medium hover:bg-primary/90 transition"> <i class="fas fa-print mr-2"></i> Imprimir Comanda </button> </div> </div> </div> </div> <script> // ========== Login Functionality ========== document.getElementById('btn-restaurante').addEventListener('click', function() { this.classList.add('border-primary', 'text-primary'); this.classList.remove('text-gray-500'); document.getElementById('btn-tecnico').classList.add('text-gray-500'); document.getElementById('btn-tecnico').classList.remove('border-primary', 'text-primary'); document.getElementById('restaurante-login').classList.remove('hidden'); document.getElementById('tecnico-login').classList.add('hidden'); }); document.getElementById('btn-tecnico').addEventListener('click', function() { this.classList.add('border-primary', 'text-primary'); this.classList.remove('text-gray-500'); document.getElementById('btn-restaurante').classList.add('text-gray-500'); document.getElementById('btn-restaurante').classList.remove('border-primary', 'text-primary'); document.getElementById('tecnico-login').classList.remove('hidden'); document.getElementById('restaurante-login').classList.add('hidden'); }); // Enhanced password change toggle const passwordToggle = document.getElementById('password-change'); if (passwordToggle) { passwordToggle.addEventListener('change', function() { const newPasswordFields = document.getElementById('new-password-fields'); newPasswordFields.classList.toggle('hidden', !this.checked); // Reset fields when hidden if (!this.checked) { newPasswordFields.querySelectorAll('input').forEach(input => { input.value = ''; }); } }); } // Login and switch to dashboard document.getElementById('login-btn').addEventListener('click', function() { document.getElementById('login-container').classList.add('hidden'); document.getElementById('dashboard-container').classList.remove('hidden'); }); // Navigation between sections function setupNavigation(linkId, sectionToShow) { document.getElementById(linkId).addEventListener('click', function(e) { e.preventDefault(); // Hide the main content sections document.querySelector('main').classList.add('hidden'); document.getElementById('crm-section').classList.add('hidden'); document.getElementById('relatorios-section').classList.add('hidden'); document.getElementById('config-section').classList.add('hidden'); // Show the selected section (keep header visible) if (sectionToShow === 'dashboard-container') { document.querySelector('main').classList.remove('hidden'); } else { document.getElementById(sectionToShow).classList.remove('hidden'); } // Update active state for navigation buttons const navLinks = ['pedidos-link', 'crm-link', 'relatorios-link', 'config-link']; navLinks.forEach(id => { const link = document.getElementById(id); if (id === linkId) { link.classList.add('bg-primary', 'text-white'); link.classList.remove('text-gray-700', 'hover:bg-gray-100'); } else { link.classList.remove('bg-primary', 'text-white'); link.classList.add('text-gray-700', 'hover:bg-gray-100'); } }); }); } // Set up navigation setupNavigation('pedidos-link', 'dashboard-container'); setupNavigation('crm-link', 'crm-section'); setupNavigation('relatorios-link', 'relatorios-section'); setupNavigation('config-link', 'config-section'); // Also set up navigation for dropdown menu items document.querySelectorAll('.group a').forEach(link => { link.addEventListener('click', function(e) { e.preventDefault(); // Here you would add logic to handle what happens when submenu items are clicked console.log('Clicked on:', this.textContent); // You could filter content based on the selection, etc. }); }); // Enhanced logout button const logoutBtn = document.getElementById('logout-btn'); if (logoutBtn) { logoutBtn.addEventListener('click', function(e) { e.preventDefault(); // Show confirmation dialog if (confirm('Deseja realmente sair do sistema?')) { document.getElementById('dashboard-container').classList.add('hidden'); document.getElementById('login-container').classList.remove('hidden'); // Reset login form const loginForm = document.getElementById('restaurante-login'); if (loginForm) { loginForm.querySelectorAll('input').forEach(input => { input.value = ''; }); } } }); } // Forgot Password Modal const forgotPasswordBtn = document.getElementById('forgot-password-btn'); const forgotPasswordModal = document.getElementById('forgot-password-modal'); const closeForgotModal = document.getElementById('close-forgot-modal'); const sendRecoveryBtn = document.getElementById('send-recovery-btn'); const recoverySuccess = document.getElementById('recovery-success'); if (forgotPasswordBtn && forgotPasswordModal) { forgotPasswordBtn.addEventListener('click', function(e) { e.preventDefault(); forgotPasswordModal.classList.remove('hidden'); }); closeForgotModal.addEventListener('click', function() { forgotPasswordModal.classList.add('hidden'); recoverySuccess.classList.add('hidden'); }); sendRecoveryBtn.addEventListener('click', function() { const contactValue = document.getElementById('recovery-contact').value; if (contactValue) { // Simulate sending recovery instructions setTimeout(() => { recoverySuccess.classList.remove('hidden'); document.getElementById('recovery-contact').value = ''; // Hide modal after 3 seconds setTimeout(() => { forgotPasswordModal.classList.add('hidden'); recoverySuccess.classList.add('hidden'); }, 3000); }, 1000); } }); // Close modal when clicking outside forgotPasswordModal.addEventListener('click', function(e) { if (e.target === forgotPasswordModal) { forgotPasswordModal.classList.add('hidden'); recoverySuccess.classList.add('hidden'); } }); } // Print Modal controls document.querySelectorAll('.dashboard-card button').forEach(button => { button.addEventListener('click', function() { if (this.textContent.includes('Imprimir Comanda') || this.innerHTML.includes('fa-print')) { document.getElementById('print-modal').classList.remove('hidden'); } }); }); // Enhanced print modal controls const closeModalBtn = document.getElementById('close-print-modal'); if (closeModalBtn) { closeModalBtn.addEventListener('click', function() { document.getElementById('print-modal').classList.add('hidden'); }); } const printBtn = document.getElementById('print-btn'); if (printBtn) { printBtn.addEventListener('click', function() { window.print(); // Actually triggers browser print dialog document.getElementById('print-modal').classList.add('hidden'); // Find the order status in the dashboard and update it const orderStatus = document.querySelector('.order-status-pendente'); if (orderStatus) { orderStatus.textContent = 'Em Produção'; orderStatus.classList.remove('order-status-pendente'); orderStatus.classList.add('order-status-producao'); orderStatus.classList.add('bg-blue-600'); } }); } // Add focus for search fields document.querySelectorAll('input[type="text"]').forEach(input => { input.addEventListener('focus', function() { this.parentElement.classList.add('ring', 'ring-secondary'); }); input.addEventListener('blur', function() { this.parentElement.classList.remove('ring', 'ring-secondary'); }); }); </script> <p style="border-radius: 8px; text-align: center; font-size: 12px; color: #fff; margin-top: 16px;position: fixed; left: 8px; bottom: 8px; z-index: 10; background: rgba(0, 0, 0, 0.8); padding: 4px 8px;">Made with <img src="https://enzostvs-deepsite.hf.space/logo.svg" alt="DeepSite Logo" style="width: 16px; height: 16px; vertical-align: middle;display:inline-block;margin-right:3px;filter:brightness(0) invert(1);"><a href="https://enzostvs-deepsite.hf.space" style="color: #fff;text-decoration: underline;" target="_blank" >DeepSite</a> - 🧬 <a href="https://enzostvs-deepsite.hf.space?remix=LHSS/dashboard" style="color: #fff;text-decoration: underline;" target="_blank" >Remix</a></p></body> </html>
<!DOCTYPE html>
<html lang="pt-BR">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Restaurant Management Dashboard</title>
<script src="https://cdn.tailwindcss.com"></script>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
<script>
tailwind.config = {
theme: {
extend: {
colors: {
primary: '#2C3E50',
secondary: '#5DADE2',
light: '#ECF0F1',
accent: '#3498DB',
success: '#2ECC71',
warning: '#F39C12',
danger: '#E74C3C',
info: '#3498DB'
},
fontFamily: {
sans: ['Inter', 'sans-serif'],
}
}
}
}
</script>
<style>
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');
body {
font-family: 'Inter', sans-serif;
background-color: #F8F9FA;
}
.dashboard-card {
box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
border-radius: 10px;
transition: transform 0.3s ease;
position: relative;
z-index: 10;
}
.dashboard-card:hover {
transform: translateY(-3px);
box-shadow: 0 8px 15px rgba(0, 0, 0, 0.08);
}
.order-status-pendente {
background-color: #F39C12;
color: white;
}
.order-status-producao {
background-color: #3498DB;
color: white;
}
.order-status-entrega {
background-color: #9B59B6;
color: white;
}
.order-status-entregue {
background-color: #2ECC71;
color: white;
}
.order-status-cancelado {
background-color: #E74C3C;
color: white;
}
.progress-bar {
height: 5px;
background-color: #e0e0e0;
border-radius: 2.5px;
}
.progress-value {
height: 100%;
border-radius: 2.5px;
background-color: #3498DB;
}
.modal-overlay {
background-color: rgba(0, 0, 0, 0.5);
z-index: 40;
}
.ticket-format {
width: 80mm;
font-family: monospace;
}
@media (max-width: 768px) {
.ticket-format {
width: 100%;