This is an automated email from the git hooks/post-receive script. New commit to branch develop in repository pollen. See http://git.chorem.org/pollen.git commit dc01d2de1eb5e782efbb325e12ccb2eae8e36142 Author: Adrien Garandel <a.garandel@dralagen.fr> Date: Mon Jul 28 14:18:01 2014 +0200 Improve set tab in change page in poll part --- pollen-ui-angular/src/main/webapp/js/controllers/pollCtrl.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/pollen-ui-angular/src/main/webapp/js/controllers/pollCtrl.js b/pollen-ui-angular/src/main/webapp/js/controllers/pollCtrl.js index ca432f5..0e44e0c 100644 --- a/pollen-ui-angular/src/main/webapp/js/controllers/pollCtrl.js +++ b/pollen-ui-angular/src/main/webapp/js/controllers/pollCtrl.js @@ -30,8 +30,8 @@ angular.module('pollControllers', ['ngRoute', 'pollenServices', 'pascalprecht.tr ['$scope', '$rootScope', '$controller', '$sce', '$timeout', '$routeParams', '$location', 'SessionStorage', '$translate', '$route', '$q', 'Poll', 'PollenResource', 'Page', 'DateFormat', function ( $scope, $rootScope, $controller, $sce, $timeout, $routeParams, $location, SessionStorage, $translate, $route, $q, Poll, PollenResource, Page, DateFormat) { $scope.setTab = function (defaultValue) { - if (angular.isDefined($routeParams.tab)) { - return $routeParams.tab; + if (angular.isDefined($route.current.params.tab)) { + return $route.current.params.tab; } if (angular.isDefined($route.current)) { @@ -186,6 +186,7 @@ angular.module('pollControllers', ['ngRoute', 'pollenServices', 'pascalprecht.tr $timeout(function() { $scope.$on('$locationChangeSuccess', function(event) { if (lastRoute.$$route.controller == $route.current.$$route.controller) { + $scope.tab = $scope.setTab(); $route.current = lastRoute; } }); -- To stop receiving notification emails like this one, please contact chorem.org SCM administrator <admin+scm@chorem.org>.