mirror of
https://codeberg.org/PostERG/xamxam.git
synced 2026-09-25 01:53:03 +02:00
feat(admin): cleanup page — remove 'Fichiers temporaires' level, promote sections to h2 TOC entries
This commit is contained in:
@@ -1,20 +1,19 @@
|
||||
<main id="main-content">
|
||||
<main id="main-content" class="admin-main--toc">
|
||||
<?php include APP_ROOT . '/templates/admin/partials/admin-toc.php'; ?>
|
||||
|
||||
<article style="padding-top:var(--space-m)">
|
||||
<h1 style="margin:0 0 var(--space-xl)">
|
||||
<a href="/admin/" class="admin-back-btn" title="Retour à la liste"><?= icon('arrow-left-circle') ?></a>
|
||||
Nettoyer les fichiers temporaires
|
||||
Nettoyage
|
||||
</h1>
|
||||
|
||||
<section aria-labelledby="cleanup-tmp-title">
|
||||
<h2 id="cleanup-tmp-title">Fichiers temporaires</h2>
|
||||
<div id="tmp-cleanup-stats-wrapper"
|
||||
hx-get="/admin/actions/cleanup-stats-fragment.php"
|
||||
hx-trigger="load"
|
||||
hx-swap="innerHTML"
|
||||
hx-indicator="#tmp-cleanup-stats-wrapper">
|
||||
<p class="admin-muted">Chargement…</p>
|
||||
</div>
|
||||
</section>
|
||||
<div id="tmp-cleanup-stats-wrapper"
|
||||
hx-get="/admin/actions/cleanup-stats-fragment.php"
|
||||
hx-trigger="load"
|
||||
hx-swap="innerHTML"
|
||||
hx-indicator="#tmp-cleanup-stats-wrapper">
|
||||
<p class="admin-muted">Chargement…</p>
|
||||
</div>
|
||||
|
||||
<section aria-labelledby="cleanup-peertube-title">
|
||||
<h2 id="cleanup-peertube-title">Vidéos PeerTube</h2>
|
||||
|
||||
@@ -29,11 +29,11 @@ $sortArrow = function(string $col) use ($sortCol, $sortDir): string {
|
||||
<div id="bulk-actions" class="admin-bulk-actions" style="display:none">
|
||||
<strong><span id="selected-count">0</span> TFE(s) sélectionné(s)</strong>
|
||||
<div class="admin-bulk-btns">
|
||||
<button type="button" class="btn btn--sm btn--green admin-btn-publish" onclick="confirmBulk('publish')">Publier</button>
|
||||
<button type="button" class="btn btn--sm btn--muted admin-btn-unpublish" onclick="confirmBulk('unpublish')">Dépublier</button>
|
||||
<button type="button" class="btn btn--sm" onclick="confirmExport()">Exporter CSV</button>
|
||||
<button type="button" class="btn btn--sm" onclick="confirmExportFiles()">Exporter fichiers</button>
|
||||
<button type="button" class="btn btn--sm btn--red admin-btn-delete" onclick="confirmBulk('delete')">Supprimer</button>
|
||||
<button type="button" class="btn btn--sm btn--green admin-btn-publish" data-tip="Publier les TFE sélectionnés" onclick="confirmBulk('publish')">Publier</button>
|
||||
<button type="button" class="btn btn--sm btn--muted admin-btn-unpublish" data-tip="Retirer de la publication les TFE sélectionnés" onclick="confirmBulk('unpublish')">Dépublier</button>
|
||||
<button type="button" class="btn btn--sm" data-tip="Exporter en CSV les TFE sélectionnés" onclick="confirmExport()">Exporter CSV</button>
|
||||
<button type="button" class="btn btn--sm" data-tip="Exporter en un fichier archivé les TFE sélectionnés" onclick="confirmExportFiles()">Exporter fichiers</button>
|
||||
<button type="button" class="btn btn--sm btn--red admin-btn-delete" data-tip="Déplacer les TFE sélectionnés vers la corbeille" onclick="confirmBulk('delete')">Supprimer</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -55,20 +55,21 @@
|
||||
<?php endforeach; ?>
|
||||
</select>
|
||||
<?php if ($searchQuery || $yearFilter || $orientationFilter || $apFilter): ?>
|
||||
<a href="/admin/" class="btn btn--secondary btn--sm admin-filters-reset">✕ Réinitialiser</a>
|
||||
<a href="/admin/" class="btn btn--secondary btn--sm admin-filters-reset" data-tip="Effacer tous les filtres de recherche">✕ Réinitialiser</a>
|
||||
<?php endif; ?>
|
||||
<div class="admin-btn-group">
|
||||
<a href="/admin/add.php" class="btn btn--primary btn--sm"><?= icon('plus-circle') ?> Ajouter un TFE</a>
|
||||
<a href="/admin/add.php" class="btn btn--primary btn--sm" data-tip="Créer une nouvelle fiche de TFE"><?= icon('plus-circle') ?> Ajouter un TFE</a>
|
||||
<button type="button" class="btn btn--primary btn--sm" id="import-dialog-btn"
|
||||
data-tip="Importer des TFE depuis un fichier CSV"
|
||||
onclick="document.getElementById('import-dialog').showModal(); window.XamxamInitFilePonds()">
|
||||
<?= icon('tray-arrow-up') ?> Importer
|
||||
</button>
|
||||
<?php if ($trashCount > 0): ?>
|
||||
<a href="/admin/index.php?tab=trash" class="btn btn--sm <?= $tab === 'trash' ? 'btn--primary' : 'btn--secondary' ?>">
|
||||
<a href="/admin/index.php?tab=trash" class="btn btn--sm <?= $tab === 'trash' ? 'btn--primary' : 'btn--secondary' ?>" data-tip="Afficher les TFE supprimés (<?= $trashCount ?>)">
|
||||
Corbeille (<?= $trashCount ?>)
|
||||
</a>
|
||||
<?php endif; ?>
|
||||
<a href="/admin/cleanup.php" class="btn btn--sm btn--secondary">
|
||||
<a href="/admin/cleanup.php" class="btn btn--sm btn--secondary" data-tip="Supprimer définitivement les fichiers orphelins (<?= $tmpTotalCount ?>)">
|
||||
<?= icon('trash') ?> Nettoyer<?= $tmpTotalCount > 0 ? " ($tmpTotalCount)" : '' ?>
|
||||
</a>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user