home.html 3.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="UTF-8">
  5. <meta name="viewport" content="width=device-width, initial-scale=1.0">
  6. <title>KTVManager</title>
  7. <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.5.2/css/bootstrap.min.css">
  8. <link rel="stylesheet" href="{{ url_for('static', filename='styles.css') }}" />
  9. </head>
  10. <body>
  11. <!-- Navbar -->
  12. <nav class="navbar navbar-expand-lg navbar-dark bg-dark">
  13. <a class="navbar-brand" href="/">KTVManager</a>
  14. <button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarNav" aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
  15. <span class="navbar-toggler-icon"></span>
  16. </button>
  17. <div class="collapse navbar-collapse" id="navbarNav">
  18. <ul class="navbar-nav ml-auto">
  19. <li class="nav-item">
  20. <a class="nav-link" href="/">Home</a>
  21. </li>
  22. <li class="nav-item">
  23. <a class="nav-link" href="/accounts">Accounts</a>
  24. </li>
  25. <li class="nav-item">
  26. <a class="nav-link" href="/urls">URLs</a>
  27. </li>
  28. </ul>
  29. </div>
  30. </nav>
  31. <!-- Main Content -->
  32. <main class="container mt-5">
  33. <h1>Welcome {{ username }}!</h1>
  34. <br>
  35. <h2>You have {{ accounts }} active accounts</h2>
  36. <br>
  37. {% if current_month_accounts %}
  38. <h3>Accounts Expiring This Month</h3>
  39. <table class="table table-bordered table-striped">
  40. <thead class="thead-dark">
  41. <tr>
  42. <th>Stream Name</th>
  43. <th>Username</th>
  44. <th>Expiry Date</th>
  45. </tr>
  46. </thead>
  47. <tbody>
  48. {% for account in current_month_accounts %}
  49. <tr>
  50. <td>{{ account.stream }}</td>
  51. <td>{{ account.username }}</td>
  52. <td>{{ account.expiaryDate_rendered }}</td>
  53. </tr>
  54. {% endfor %}
  55. </tbody>
  56. </table>
  57. {% endif %}
  58. {% if expired_accounts %}
  59. <h3>Expired Accounts</h3>
  60. <table class="table table-bordered table-striped">
  61. <thead class="thead-dark">
  62. <tr>
  63. <th>Stream Name</th>
  64. <th>Username</th>
  65. <th>Expiry Date</th>
  66. </tr>
  67. </thead>
  68. <tbody>
  69. {% for account in expired_accounts %}
  70. <tr>
  71. <td>{{ account.stream }}</td>
  72. <td>{{ account.username }}</td>
  73. <td>{{ account.expiaryDate_rendered }}</td>
  74. </tr>
  75. {% endfor %}
  76. </tbody>
  77. </table>
  78. {% endif %}
  79. </main>
  80. <!-- Footer -->
  81. <footer class="bg-dark text-white text-center py-3 mt-5">
  82. <p></p>
  83. </footer>
  84. <script src="https://code.jquery.com/jquery-3.5.1.slim.min.js"></script>
  85. <script src="https://cdn.jsdelivr.net/npm/@popperjs/core@2.0.7/dist/umd/popper.min.js"></script>
  86. <script src="https://stackpath.bootstrapcdn.com/bootstrap/4.5.2/js/bootstrap.min.js"></script>
  87. </body>
  88. </html>