Fixed new search kept page number

This commit is contained in:
Marcin Kurczewski 2014-11-04 18:57:06 +01:00
parent 253cac4cc1
commit 26d4686795
2 changed files with 2 additions and 0 deletions

View file

@ -223,6 +223,7 @@ App.Presenters.PostListPresenter = function(
function updateSearch() { function updateSearch() {
$searchInput.blur(); $searchInput.blur();
params.query.query = $searchInput.val().trim(); params.query.query = $searchInput.val().trim();
params.query.page = 1;
pagerPresenter.setQuery(params.query); pagerPresenter.setQuery(params.query);
} }

View file

@ -103,6 +103,7 @@ App.Presenters.TagListPresenter = function(
function updateSearch() { function updateSearch() {
$searchInput.blur(); $searchInput.blur();
params.query.query = $searchInput.val().trim(); params.query.query = $searchInput.val().trim();
params.query.page = 1;
pagerPresenter.setQuery(params.query); pagerPresenter.setQuery(params.query);
} }