02744f6654
- beets_service: filter params now use truthy checks instead of `is not None`, since a real <select> left on "(any)" submits an empty string, not an absent param -- the filter form silently matched zero rows for any real submission. Also match grouping tokens within "; "-joined multi-playlist values instead of requiring an exact string match. - dashboard: credential status renders as compact dot indicators instead of badge+text chips, so long scope names (telegram) stay on one line. - credentials page: two-column grid layout instead of one long column. - find-fuzzy-dupes.py: add --json/--only-paths flags matching dedup-library.sh's convention, so it can plug into the same review queue. - dedup_review_service: add scan_fuzzy() and route confirm_and_apply() to the correct underlying script (dedup-library.sh vs find-fuzzy-dupes.py) per candidate's pass_name, since tag-based passes miss duplicates whose tags differ even when the audio is identical (e.g. a remix credited to different artists between two copies). - dedup page: add a "Scan for audio duplicates" trigger alongside the existing tag-based scan. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
73 lines
2.9 KiB
HTML
73 lines
2.9 KiB
HTML
{% extends "base.html" %}
|
|
{% block title %}Dashboard — alembic{% endblock %}
|
|
{% block content %}
|
|
<div class="page-header">
|
|
<div>
|
|
<h1>Welcome back, {{ user.name or user.email }}</h1>
|
|
<p class="subtitle muted">Distilling Spotify playlists into a tuned, tagged library.</p>
|
|
</div>
|
|
<div class="actions">
|
|
<a class="btn btn-primary" href="/playlists">Manage playlists</a>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="stat-grid">
|
|
<div class="stat-card">
|
|
<div class="stat-value chrome-text">{{ stats.total_tracks }}</div>
|
|
<div class="stat-label">Tracks in library{% if not stats.db_exists %} <span class="muted">(beets db not found)</span>{% endif %}</div>
|
|
</div>
|
|
<div class="stat-card">
|
|
<div class="stat-value">{{ active_playlist_count }}<span class="muted"> / {{ playlist_count }}</span></div>
|
|
<div class="stat-label">Playlists active</div>
|
|
</div>
|
|
<div class="stat-card">
|
|
<div class="stat-value">{{ stats.groupings | length }}</div>
|
|
<div class="stat-label">Distinct groupings</div>
|
|
</div>
|
|
<div class="stat-card">
|
|
<div class="stat-value">{{ total_size_human }}</div>
|
|
<div class="stat-label">Approx. library size</div>
|
|
</div>
|
|
</div>
|
|
|
|
<h2>File formats</h2>
|
|
{% if stats.formats %}
|
|
<ul class="chip-list">
|
|
{% for f in stats.formats %}
|
|
<li>{{ f.format }} <span class="muted">× {{ f.count }}</span></li>
|
|
{% endfor %}
|
|
</ul>
|
|
{% else %}
|
|
<p class="muted">No format data yet.</p>
|
|
{% endif %}
|
|
|
|
<h2>Credential status</h2>
|
|
<ul class="chip-list auth-chip-list">
|
|
{% for a in auth_states %}
|
|
<li title="{{ a.scope }}: {{ 'configured' if a.configured else 'not configured' }}{% if a.days_left is defined %}, cookie expires in {{ a.days_left }}d{% endif %}"><span class="status-dot {{ 'status-dot-success' if a.configured else 'status-dot-muted' }}{% if a.days_left is defined and a.days_left < 14 %} status-dot-warning{% endif %}"></span>{{ a.scope }}{% if a.days_left is defined %}<span class="muted"> {{ a.days_left }}d</span>{% endif %}</li>
|
|
{% endfor %}
|
|
</ul>
|
|
<p><a href="/settings/credentials">Manage credentials →</a></p>
|
|
|
|
<h2>Recent job runs</h2>
|
|
<div class="table-wrap scroll">
|
|
<table>
|
|
<thead><tr><th>Job</th><th>Status</th><th>Triggered by</th><th>Summary</th></tr></thead>
|
|
<tbody>
|
|
{% set status_badge = {"running": "badge-info badge-pulse", "success": "badge-success", "failed": "badge-danger", "skipped_lock": "badge-muted"} %}
|
|
{% for run in recent_runs %}
|
|
<tr>
|
|
<td>{{ run.job_key }}</td>
|
|
<td><span class="badge {{ status_badge.get(run.status, 'badge-muted') }}">{{ run.status }}</span></td>
|
|
<td class="muted">{{ run.triggered_by }}</td>
|
|
<td>{{ run.summary or "—" }}</td>
|
|
</tr>
|
|
{% else %}
|
|
<tr class="empty-row"><td colspan="4" class="muted">No job runs yet.</td></tr>
|
|
{% endfor %}
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
<p><a href="/jobs">See all jobs →</a></p>
|
|
{% endblock %}
|