idle.phtml 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. <?php
  2. /** @var FreshRSS_View $this */
  3. $this->partial('aside_subscription');
  4. ?>
  5. <main class="post">
  6. <div class="link-back-wrapper">
  7. <a class="link-back" href="<?= _url('index', 'index') ?>"><?= _t('gen.action.back_to_rss_feeds') ?></a>
  8. </div>
  9. <h1><?= _t('admin.stats.idle') ?></h1>
  10. <?php
  11. $current_url = Minz_Url::display(
  12. array('c' => 'stats', 'a' => 'idle'),
  13. 'php', true
  14. );
  15. $nothing = true;
  16. foreach ($this->idleFeeds as $period => $feeds) {
  17. if (!empty($feeds)) {
  18. $nothing = false;
  19. ?>
  20. <div class="stat">
  21. <h2><?= _t('gen.date.' . $period) ?></h2>
  22. <form id="form-delete" method="post">
  23. <input type="hidden" name="_csrf" value="<?= FreshRSS_Auth::csrfToken() ?>" />
  24. <?php foreach ($feeds as $feed) { ?>
  25. <ul class="horizontal-list">
  26. <li class="item">
  27. <div class="stick">
  28. <a class="btn" href="<?= _url('index', 'index', 'get', 'f_' . $feed['id']) ?>"><?= _i('link') ?> <?= _t('gen.action.filter') ?></a>
  29. <a class="btn" href="<?= _url('subscription', 'index', 'id', $feed['id']) ?>"><?= _i('configure') ?> <?= _t('gen.action.manage') ?></a>
  30. <button class="btn btn-attention confirm" form="form-delete"
  31. formaction="<?= _url('feed', 'delete', 'id', $feed['id'], 'r', $current_url) ?>"><?= _t('gen.action.remove') ?></button>
  32. </div>
  33. </li>
  34. <li class="item">
  35. <span title="<?= timestamptodate($feed['last_date'], false) ?>"><?= $feed['name'] ?>
  36. (<?= _t('admin.stats.number_entries', $feed['nb_articles']) ?>)</span>
  37. </li>
  38. </ul>
  39. <?php } ?>
  40. </form>
  41. </div>
  42. <?php
  43. }
  44. }
  45. if ($nothing) {
  46. ?>
  47. <p class="alert alert-warn">
  48. <span class="alert-head"><?= _t('admin.stats.no_idle') ?></span>
  49. </p>
  50. <?php } ?>
  51. </main>