mirror of
https://github.com/moparisthebest/wallabag
synced 2024-12-18 05:32:23 -05:00
[add] routing for archive
This commit is contained in:
parent
969a9fdf2e
commit
99c6d290c6
@ -6,7 +6,7 @@ use Symfony\Component\HttpFoundation\Request;
|
|||||||
$front = $app['controllers_factory'];
|
$front = $app['controllers_factory'];
|
||||||
$front->get('/', function () use ($app) {
|
$front->get('/', function () use ($app) {
|
||||||
|
|
||||||
$entries = $app['entry_api']->getEntries();
|
$entries = $app['entry_api']->getEntries('unread');
|
||||||
|
|
||||||
return $app['twig']->render('index.twig', array('entries' => $entries));
|
return $app['twig']->render('index.twig', array('entries' => $entries));
|
||||||
});
|
});
|
||||||
@ -49,4 +49,11 @@ $front->match('/add', function (Request $request) use ($app) {
|
|||||||
})
|
})
|
||||||
->bind('add');
|
->bind('add');
|
||||||
|
|
||||||
|
$front->get('/archive', function () use ($app) {
|
||||||
|
|
||||||
|
$entries = $app['entry_api']->getEntries('read');
|
||||||
|
|
||||||
|
return $app['twig']->render('archive.twig', array('entries' => $entries));
|
||||||
|
});
|
||||||
|
|
||||||
return $front;
|
return $front;
|
||||||
|
Loading…
Reference in New Issue
Block a user