//uiSelectConfig.theme = 'select2'; $stateProvider.state({ name: 'backlogManage', url: '/backlogManage?{isShow}', views: { '@': { controller: ['$scope', '$stateParams', 'appTranslation', '$state', function ($scope, $stateParams, appTranslation, $state) { appTranslation.load([appTranslation.vat]); appTranslation.load([appTranslation.backlog]); $scope.state = $state; //debugger; $scope.isShow = $stateParams.isShow; }], template: '<backlog-infrastructure state="state" is-show="isShow"></backlog-infrastructure>', } }, resolve: scriptDependencyProvider.createDependenciesMap(scriptDependencyProvider.backlogManage), deepStateRedirect: false, //这里用false , 才不会记住上次路由状态 sticky: true });
deepStateRedirect:true/fasle 这个参数理解下来,表示是否记住上次路由参数和地址
在开发的时候,我跳转到这个路由下面的子路由的时候,只要点过一次有参数的路由,那么每次你从其他页面切回这个路由,都会带上之前的参数,后面吧
deepStateRedirect 设为false 就好了