From 35550fe42e36868be1a3ac471bea6dc89b8b6200 Mon Sep 17 00:00:00 2001 From: Bernhard Posselt Date: Sat, 21 Mar 2015 10:09:24 +0100 Subject: fix autopaging in search --- js/build/app.js | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) (limited to 'js/build/app.js') diff --git a/js/build/app.js b/js/build/app.js index 626fb7550..bc178ff8c 100644 --- a/js/build/app.js +++ b/js/build/app.js @@ -335,8 +335,8 @@ app.controller('AppController', }; }]); app.controller('ContentController', -["Publisher", "FeedResource", "ItemResource", "SettingsResource", "data", "$route", "$routeParams", "FEED_TYPE", "ITEM_AUTO_PAGE_SIZE", "Loading", function (Publisher, FeedResource, ItemResource, SettingsResource, data, - $route, $routeParams, FEED_TYPE, ITEM_AUTO_PAGE_SIZE, Loading) { +["Publisher", "FeedResource", "ItemResource", "SettingsResource", "data", "$route", "$routeParams", "$location", "FEED_TYPE", "ITEM_AUTO_PAGE_SIZE", "Loading", function (Publisher, FeedResource, ItemResource, SettingsResource, data, + $route, $routeParams, $location, FEED_TYPE, ITEM_AUTO_PAGE_SIZE, Loading) { 'use strict'; ItemResource.clear(); @@ -479,10 +479,11 @@ app.controller('ContentController', var oldestFirst = getOrdering(); var showAll = SettingsResource.get('showAll'); var self = this; + var search = $location.search().search; Loading.setLoading('autopaging', true); - ItemResource.autoPage(type, id, oldestFirst, showAll) + ItemResource.autoPage(type, id, oldestFirst, showAll, search) .success(function (data) { Publisher.publishAll(data); @@ -1572,7 +1573,7 @@ app.factory('ItemResource', ["Resource", "$http", "BASE_URL", "ITEM_BATCH_SIZE", ItemResource.prototype.autoPage = function (type, id, oldestFirst, - showAll) { + showAll, search) { var offset; if (oldestFirst) { @@ -1590,7 +1591,8 @@ app.factory('ItemResource', ["Resource", "$http", "BASE_URL", "ITEM_BATCH_SIZE", offset: offset, limit: this.batchSize, oldestFirst: oldestFirst, - showAll: showAll + showAll: showAll, + search: search } }); }; -- cgit v1.2.3