File size: 60,053 Bytes
931b00d 54afded 931b00d 54afded 931b00d 54afded 931b00d 54afded 931b00d 54afded 931b00d 54afded 931b00d 54afded 931b00d 54afded 931b00d 54afded 931b00d | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 | <!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> |