2013-02-17 21:48:21 -05:00
|
|
|
<div class="page-header">
|
2013-04-12 21:08:55 -04:00
|
|
|
<h2><?= t('Subscriptions') ?></h2>
|
2013-02-24 14:04:56 -05:00
|
|
|
<ul>
|
2013-04-12 21:08:55 -04:00
|
|
|
<li><a href="?action=add"><?= t('add') ?></a></li>
|
|
|
|
<li><a href="?action=import"><?= t('import') ?></a></li>
|
|
|
|
<li><a href="?action=export"><?= t('export') ?></a></li>
|
|
|
|
<li><a href="?action=refresh-all" data-action="refresh-all"><?= t('refresh all') ?></a></li>
|
2013-02-24 14:04:56 -05:00
|
|
|
</ul>
|
2013-02-17 21:48:21 -05:00
|
|
|
</div>
|
|
|
|
|
|
|
|
<?php if (empty($feeds)): ?>
|
|
|
|
|
2013-04-12 21:08:55 -04:00
|
|
|
<p class="alert alert-info"><?= t('No subscription') ?></p>
|
2013-02-17 21:48:21 -05:00
|
|
|
|
|
|
|
<?php else: ?>
|
|
|
|
|
2013-03-17 18:16:25 -04:00
|
|
|
<?php if ($nothing_to_read): ?>
|
2014-02-25 18:00:36 -05:00
|
|
|
<p class="alert"><?= tne('Nothing to read, do you want to <a href="?action=refresh-all" data-action="refresh-all">update your subscriptions?</a>') ?></p>
|
2013-03-17 18:16:25 -04:00
|
|
|
<?php endif ?>
|
|
|
|
|
2013-02-17 21:48:21 -05:00
|
|
|
<section class="items">
|
|
|
|
<?php foreach ($feeds as $feed): ?>
|
2014-12-31 13:43:05 +01:00
|
|
|
<article data-feed-id="<?= $feed['id'] ?>" <?= (! $feed['enabled']) ? 'data-feed-disabled="1"' : '' ?>>
|
|
|
|
<h2>
|
2013-08-04 15:15:12 -04:00
|
|
|
<?php if (! $feed['enabled']): ?>
|
2015-01-02 14:56:01 -02:00
|
|
|
<span title="<?= t('Subscription disabled') ?>">✖</span>
|
2013-08-04 15:15:12 -04:00
|
|
|
<?php endif ?>
|
|
|
|
|
2014-12-24 18:12:41 -05:00
|
|
|
<?= Helper\favicon($favicons, $feed['id']) ?>
|
|
|
|
|
2013-09-14 19:05:52 -04:00
|
|
|
<a href="?action=feed-items&feed_id=<?= $feed['id'] ?>" title="<?= t('Show only this subscription') ?>"><?= Helper\escape($feed['title']) ?></a>
|
2014-12-31 14:01:27 +01:00
|
|
|
‎<span class="items-count"><?= $feed['items_unread'] .'/' . $feed['items_total'] ?></span>
|
2014-02-22 19:45:02 -05:00
|
|
|
|
2013-08-04 15:37:56 -04:00
|
|
|
<?php if ($feed['enabled']): ?>
|
2013-12-15 19:24:51 -05:00
|
|
|
|
|
|
|
<br/>
|
|
|
|
|
2013-08-04 15:37:56 -04:00
|
|
|
<?php if ($feed['last_checked']): ?>
|
2014-12-31 13:43:05 +01:00
|
|
|
<time class="feed-last-checked" data-after-update="<?= t('updated just now') ?>">
|
2014-02-25 20:02:55 -05:00
|
|
|
<?= t('checked at').' '.dt('%e %B %Y %k:%M', $feed['last_checked']) ?>
|
2013-08-04 15:37:56 -04:00
|
|
|
</time>
|
|
|
|
<?php else: ?>
|
2014-12-31 13:43:05 +01:00
|
|
|
<span class="feed-last-checked" data-after-update="<?= t('updated just now') ?>">
|
2013-08-04 15:37:56 -04:00
|
|
|
<?= t('never updated after creation') ?>
|
|
|
|
</span>
|
|
|
|
<?php endif ?>
|
2013-12-15 19:24:51 -05:00
|
|
|
|
2014-12-31 13:43:05 +01:00
|
|
|
<span class="feed-parsing-error" data-after-error="<?= t('(error occurred during the last check)') ?>">
|
|
|
|
<?php if ($feed['parsing_error']): ?>
|
|
|
|
<?= t('(error occurred during the last check)') ?>
|
|
|
|
<?php endif ?>
|
|
|
|
</span>
|
2013-12-15 19:24:51 -05:00
|
|
|
|
2013-08-04 15:37:56 -04:00
|
|
|
<?php endif ?>
|
2013-02-24 14:04:56 -05:00
|
|
|
</h2>
|
2014-02-14 21:21:14 -05:00
|
|
|
<ul class="item-menu">
|
|
|
|
<li>
|
|
|
|
<a href="<?= $feed['site_url'] ?>" rel="noreferrer" target="_blank"><?= Helper\get_host_from_url($feed['site_url']) ?></a>
|
|
|
|
</li>
|
2014-02-17 22:04:49 -05:00
|
|
|
|
|
|
|
<?php if ($feed['enabled']): ?>
|
|
|
|
<li>
|
2014-12-31 13:43:05 +01:00
|
|
|
<a href="?action=refresh-feed&feed_id=<?= $feed['id'] ?>" data-action="refresh-feed"><?= t('refresh') ?></a>
|
2014-02-17 22:04:49 -05:00
|
|
|
</li>
|
|
|
|
<?php endif ?>
|
|
|
|
|
2014-10-19 19:14:33 -04:00
|
|
|
<li><a href="?action=edit-feed&feed_id=<?= $feed['id'] ?>"><?= t('edit') ?></a></li>
|
2014-02-14 21:21:14 -05:00
|
|
|
</ul>
|
2013-02-17 21:48:21 -05:00
|
|
|
</article>
|
|
|
|
<?php endforeach ?>
|
|
|
|
</section>
|
|
|
|
|
2014-02-25 12:14:25 -08:00
|
|
|
<?php endif ?>
|