mirror of
https://github.com/FreshRSS/FreshRSS.git
synced 2026-10-20 10:14:33 -04:00
Fix issue #21 - bug affichage lorsque non lus par défaut
This commit is contained in:
1 parent
0a0758995a
commit
75f8898dcd
3 files changed
+14
-4
No files matched your search
@@ -10,7 +10,16 @@ class indexController extends ActionController {
|
||||
$entryDAO = new EntryDAO ();
|
||||
$catDAO = new CategoryDAO ();
|
||||
|
||||
$mode = Session::param ('mode', $this->view->conf->defaultView ());
|
||||
$default_view = $this->view->conf->defaultView ();
|
||||
$mode = Session::param ('mode');
|
||||
if ($mode == false) {
|
||||
if ($default_view == 'not_read' && $this->view->nb_not_read < 1) {
|
||||
$mode = 'all';
|
||||
} else {
|
||||
$mode = $default_view;
|
||||
}
|
||||
}
|
||||
|
||||
$get = Request::param ('get');
|
||||
$order = $this->view->conf->sortOrder ();
|
||||
|
||||
@@ -34,6 +43,7 @@ class indexController extends ActionController {
|
||||
View::prependTitle ('Vos flux RSS - ');
|
||||
}
|
||||
$this->view->get = $get;
|
||||
$this->view->mode = $mode;
|
||||
|
||||
// Cas où on ne choisie ni catégorie ni les favoris
|
||||
// ou si la catégorie ne correspond à aucune
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
<div id="top">
|
||||
<?php if (!login_is_conf ($this->conf) || is_logged ()) { ?>
|
||||
<a class="read_all" href="<?php echo Url::display (array ('c' => 'entry', 'a' => 'read', 'params' => array ('is_read' => 1))); ?>">Tout marquer comme lu</a><?php } ?><!--
|
||||
<?php if (Session::param ('mode', 'all') == 'not_read') { ?>
|
||||
<?php if ($this->mode == 'not_read') { ?>
|
||||
--><a class="print_all" href="<?php echo Url::display (array ('a' => 'changeMode', 'params' => array ('mode' => 'all'))); ?>">Tout afficher</a>
|
||||
<?php } else { ?>
|
||||
--><a class="print_non_read" href="<?php echo Url::display (array ('a' => 'changeMode', 'params' => array ('mode' => 'not_read'))); ?>">Afficher les non lus</a>
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<?php
|
||||
return array (
|
||||
'posts_per_page' => 50,
|
||||
'default_view' => 'all',
|
||||
'posts_per_page' => 20,
|
||||
'default_view' => 'not_read',
|
||||
'display_posts' => 'no',
|
||||
'sort_order' => 'low_to_high',
|
||||
'old_entries' => 3,
|
||||
|
||||
Reference in new issue
Block a user