forked from Public/pics
ViewPhoto: take filter into account for prev/next links
This commit is contained in:
@@ -94,8 +94,15 @@ class ViewPhotoAlbum extends HTMLController
|
||||
{
|
||||
$index = new PhotosIndex($mosaic, Registry::get('user')->isAdmin());
|
||||
$this->page->adopt($index);
|
||||
if ($id_tag > 1)
|
||||
$index->setUrlSuffix('?in=' . $id_tag);
|
||||
|
||||
$url_params = [];
|
||||
if (isset($tag) && $tag->id_parent != 0)
|
||||
$url_params['in'] = $tag->id_tag;
|
||||
if (!empty($active_filter))
|
||||
$url_params['by'] = $active_filter;
|
||||
|
||||
if (!empty($url_params))
|
||||
$index->setUrlSuffix('?' . http_build_query($url_params));
|
||||
}
|
||||
|
||||
// Make a page index as needed, while we're at it.
|
||||
|
||||
Reference in New Issue
Block a user