首页 > 代码库 > angular路由
angular路由
//个人中心路由
;angular.module(‘userApp‘).config([‘$stateProvider‘, ‘$urlRouterProvider‘,function ($stateProvider, $urlRouterProvider) {
$urlRouterProvider.otherwise(‘/collectRecord‘);
$stateProvider.state("collectRecord", { //收藏记录
url: "/collectRecord",
templateUrl: "collectRecord.html",
controller: ‘collectRecordController‘
}).state("pushRecord", { //推送记录
url: "/pushRecord",
templateUrl: "pushRecord.html",
controller: ‘pushRecordController‘
}).state("messageTemplateManage", { //短信模板管理
url: "/messageTemplateManage",
templateUrl: "messageTemplateManage.html",
controller: ‘messageTemplateManageController‘
}).state("postalTemplateMange", { //邮件模板管理
url: "/postalTemplateMange",
templateUrl: "postalTemplateMange.html",
controller: ‘postalTemplateMangeController‘
});
}]);
angular路由