1
0
mirror of https://github.com/LaCasemate/fab-manager.git synced 2025-01-17 06:52:27 +01:00

projects/index now save in url query param if whole_network is true

This commit is contained in:
Nicolas Florentin 2016-05-02 16:18:24 +02:00
parent 12bc556038
commit d29deaad51

View File

@ -215,6 +215,7 @@ Application.Controllers.controller "ProjectsController", ["$scope", "$state", 'P
$scope.triggerSearch = ->
currentPage = parseInt($location.$$search.page) || 1
if $scope.openlab.searchOverWholeNetwork is true
updateUrlParam('whole_network', 't')
$scope.projectsPagination = new paginationService.Instance(OpenlabProject, currentPage, PROJECTS_PER_PAGE, null, { }, loadMoreOpenlabCallback)
OpenlabProject.query { q: $scope.search.q, page: currentPage, per_page: PROJECTS_PER_PAGE }, (projectsPromise)->
if projectsPromise.errors?