Skip to content

Instantly share code, notes, and snippets.

@heidsoft
Created December 24, 2016 03:55
Show Gist options
  • Select an option

  • Save heidsoft/3bd43cfa30c84dd42a33adbfdd34743b to your computer and use it in GitHub Desktop.

Select an option

Save heidsoft/3bd43cfa30c84dd42a33adbfdd34743b to your computer and use it in GitHub Desktop.
ui-router 状态路由带参数
// .state('root', {
// url: '/home/:partyID/:partyLocation',
// controller: 'HomeController',
// templateUrl: CmdbConfig.templatePath + 'home/home.html',
// views: {
// "home": {
// templateUrl: CmdbConfig.templatePath + 'menu/menu.html',
// controller: function ($scope, $state,$stateParams,MenuServiceV2) {
// console.log("aaaaaaddddbbbbbb");
// console.log($stateParams);
// $scope.activeLeftMenu = "datacenter";
// MenuServiceV2.query({type: 'resource'}, function (response) {
// $scope.leftMenus = response;
// });
// $state.go("root.detail.datacenter");
// },
// }
// },
// // onEnter: function($stateParams) {
// // $state.go($stateParams.partyLocation);
// // }
// })
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment