UNPKG

salespilot

Version:
145 lines (126 loc) 4.38 kB
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>SalesPilot Web App</title> <!-- Bootstrap CSS --> <link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css"> <!-- Custom Styles --> <style> body { background-color: #f8f9fa; } .navbar { background-color: #343a40; } .navbar-brand { color: #ffffff; font-weight: bold; } .navbar-dark .navbar-toggler-icon { background-color: #ffffff; } .navbar-nav .nav-link { color: #ffffff; } .btn-group .btn { background-color: #007bff; color: #ffffff; } .btn-group .form-control { border-color: #007bff; } .btn-primary { background-color: #28a745; border-color: #28a745; } .table th, .table td { border: 1px solid #dee2e6; } .table thead th { background-color: #007bff; color: #ffffff; border-color: #007bff; } </style> </head> <body> <!-- Navbar --> <nav class="navbar navbar-expand-lg navbar-dark bg-dark"> <a class="navbar-brand" href="#"> <img src="salespilot_logo.png" alt="SalesPilot Logo" height="30"> SalesPilot </a> <button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarNav" aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation"> <span class="navbar-toggler-icon"></span> </button> <div class="collapse navbar-collapse" id="navbarNav"> <ul class="navbar-nav"> <li class="nav-item active"> <a class="nav-link" href="#">Sales</a> </li> <!-- Add other navigation items as needed --> </ul> </div> </nav> <!-- Page Content --> <div class="container mt-3"> <!-- Interactive buttons for data fetching --> <div class="btn-group" role="group" aria-label="Data Fetching"> <button type="button" class="btn btn-secondary" onclick="fetchData('daily')">Daily</button> <button type="button" class="btn btn-secondary" onclick="fetchData('weekly')">Weekly</button> <button type="button" class="btn btn-secondary" onclick="fetchData('monthly')">Monthly</button> <button type="button" class="btn btn-secondary" onclick="fetchData('yearly')">Yearly</button> <input type="date" class="form-control" id="selectedDate"> <button type="button" class="btn btn-primary" onclick="fetchData('selectedDate')">Fetch Data</button> </div> <!-- Inventory Table --> <table class="table mt-3"> <thead> <!-- Table header remains unchanged --> <tr> <th>Product Name</th> <th>Stock Qty</th> <th>Supply Qty</th> <th>Inventory Qty</th> <th>Sales Price</th> <th>Cost Price</th> <th>Inventory Cost</th> <th>Inventory Value</th> </tr> </thead> <tbody> <!-- Populate table rows with PHP and MySQL data --> <!-- Example: --> <tr> <td>Product A</td> <td>100</td> <td>50</td> <td>150</td> <!-- Add data for daily, weekly, monthly, yearly, selected date --> <td>...</td> <td>...</td> <td>...</td> <td>...</td> </tr> </tbody> </table> </div> <!-- Bootstrap JS and dependencies --> <script src="https://code.jquery.com/jquery-3.3.1.slim.min.js"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.7/umd/popper.min.js"></script> <script src="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/js/bootstrap.min.js"></script> <!-- Your custom script for fetching data based on selected options --> <script> function fetchData(fetchType) { // Implement your logic to fetch data based on selected options // Use JavaScript to interact with PHP and MySQL backend // The 'fetchType' parameter can be 'daily', 'weekly', 'monthly', 'yearly', or 'selectedDate' // Use the value of the selected date if 'fetchType' is 'selectedDate' } </script> </body> </html>