62 lines
2.0 KiB
HTML
62 lines
2.0 KiB
HTML
{% extends "base.html" %}
|
|
|
|
{% block title %}KTVManager{% endblock %}
|
|
|
|
{% block content %}
|
|
<h1>Welcome {{ username }}!</h1>
|
|
<br>
|
|
<h2>You have {{ accounts }} active accounts</h2>
|
|
<br>
|
|
|
|
{% if current_month_accounts %}
|
|
<h3>Accounts Expiring Within 30 Days</h3>
|
|
<table class="table table-bordered table-striped">
|
|
<thead class="thead-dark">
|
|
<tr>
|
|
<th>Stream Name</th>
|
|
<th>Username</th>
|
|
<th>Expiry Date</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
{% for account in current_month_accounts %}
|
|
<tr>
|
|
<td>{{ account.stream }}</td>
|
|
<td>{{ account.username }}</td>
|
|
<td>{{ account.expiaryDate_rendered }} {% if account.days_to_expiry is defined %}<span style="color: red;">({{ account.days_to_expiry }} days)</span>{% endif %}</td>
|
|
</tr>
|
|
{% endfor %}
|
|
</tbody>
|
|
</table>
|
|
{% endif %}
|
|
{% if expired_accounts %}
|
|
<h3>Expired Accounts</h3>
|
|
<table class="table table-bordered table-striped">
|
|
<thead class="thead-dark">
|
|
<tr>
|
|
<th>Stream Name</th>
|
|
<th>Username</th>
|
|
<th>Expiry Date</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
{% for account in expired_accounts %}
|
|
<tr>
|
|
<td>{{ account.stream }}</td>
|
|
<td>{{ account.username }}</td>
|
|
<td>{{ account.expiaryDate_rendered }}</td>
|
|
</tr>
|
|
{% endfor %}
|
|
</tbody>
|
|
</table>
|
|
{% endif %}
|
|
{% endblock %}
|
|
|
|
{% block scripts %}
|
|
<script>
|
|
if ('serviceWorker' in navigator) {
|
|
navigator.serviceWorker.register('{{ url_for("static", filename="service-worker.js") }}')
|
|
}
|
|
</script>
|
|
{% endblock %}
|