Display a message next to a feed when there is a parsing error
This commit is contained in:
parent
31645de31e
commit
282c1cb5ad
@ -398,6 +398,12 @@ nav .active a {
|
||||
font-weight: normal;
|
||||
}
|
||||
|
||||
.feed-parsing-error {
|
||||
color: #000;
|
||||
font-size: 0.7em;
|
||||
font-weight: normal;
|
||||
}
|
||||
|
||||
/* items listing */
|
||||
.items article {
|
||||
border: 1px dotted #ddd;
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?php
|
||||
|
||||
return array(
|
||||
'(error occurred during the last check)' => '(problème rencontré pendant la dernière vérification)',
|
||||
'The feed id is required' => 'L\'identifiant du flux est obligatoire',
|
||||
'The title is required' => 'Le titre est obligatoire',
|
||||
'The site url is required' => 'L\'URL du site web est obligatoire',
|
||||
|
@ -23,7 +23,7 @@ use PicoFeed\Reader;
|
||||
use PicoFeed\Export;
|
||||
|
||||
|
||||
const DB_VERSION = 17;
|
||||
const DB_VERSION = 18;
|
||||
const HTTP_USERAGENT = 'Miniflux - http://miniflux.net';
|
||||
const HTTP_FAKE_USERAGENT = 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_8_4) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/29.0.1547.62 Safari/537.36';
|
||||
const LIMIT_ALL = -1;
|
||||
@ -338,6 +338,8 @@ function update_feed($feed_id)
|
||||
}
|
||||
}
|
||||
|
||||
\PicoTools\singleton('db')->table('feeds')->eq('id', $feed_id)->save(array('parsing_error' => 1));
|
||||
|
||||
write_debug();
|
||||
|
||||
return false;
|
||||
|
@ -3,6 +3,12 @@
|
||||
namespace Schema;
|
||||
|
||||
|
||||
function version_18($pdo)
|
||||
{
|
||||
$pdo->exec('ALTER TABLE feeds ADD COLUMN parsing_error INTEGER DEFAULT 0');
|
||||
}
|
||||
|
||||
|
||||
function version_17($pdo)
|
||||
{
|
||||
$pdo->exec('ALTER TABLE config ADD COLUMN items_sorting_direction TEXT DEFAULT "desc"');
|
||||
|
@ -29,8 +29,10 @@
|
||||
<?php endif ?>
|
||||
|
||||
<a href="?action=feed-items&feed_id=<?= $feed['id'] ?>" title="<?= t('Show only this subscription') ?>"><?= Helper\escape($feed['title']) ?></a>
|
||||
|
||||
<?php if ($feed['enabled']): ?>
|
||||
|
||||
<br/>
|
||||
|
||||
<?php if ($feed['last_checked']): ?>
|
||||
<time class="feed-last-checked" id="last-checked-feed-<?= $feed['id'] ?>" data-after-update="<?= t('updated just now') ?>">
|
||||
<?= t('checked at').' '.dt('%e %B %Y %k:%M', $feed['last_checked']) ?>
|
||||
@ -40,6 +42,11 @@
|
||||
<?= t('never updated after creation') ?>
|
||||
</span>
|
||||
<?php endif ?>
|
||||
|
||||
<?php if ($feed['parsing_error']): ?>
|
||||
<span class="feed-parsing-error"><?= t('(error occurred during the last check)') ?></span>
|
||||
<?php endif ?>
|
||||
|
||||
<?php endif ?>
|
||||
</h2>
|
||||
<p>
|
||||
|
Loading…
Reference in New Issue
Block a user