国产av日韩一区二区三区精品,成人性爱视频在线观看,国产,欧美,日韩,一区,www.成色av久久成人,2222eeee成人天堂

angular.js - angular angular-ui-route裡$state.includes 寫這個不起作用
過去多啦不再A夢
過去多啦不再A夢 2017-05-15 17:13:20
0
1
770

angular 裡$state.includes 寫這篇不起作用

過去多啦不再A夢
過去多啦不再A夢

全部回覆(1)
淡淡煙草味

找到原因了,可能$scope作用域不夠,應(yīng)該用$rootScope

nameurl.controller.js

 $rootScope.nameURL = $state.includes("nameURL.**");

這句話的意思是,所有nameURL和nameURL子頁都會回傳true

index.html

<li><a ui-sref="nameurl.about" ng-class="{active: nameURL}">關(guān)于我們</a></li>
最新下載
更多>
網(wǎng)站特效
網(wǎng)站源碼
網(wǎng)站素材
前端模板