mirror of
https://github.com/DeviceFarmer/stf.git
synced 2026-04-18 16:13:24 +02:00
Show only Web/Native when controlling.
This commit is contained in:
@@ -1,7 +1,11 @@
|
|||||||
module.exports = function MenuCtrl($scope, $rootScope, SettingsService) {
|
module.exports = function MenuCtrl($scope, $rootScope, SettingsService, $location) {
|
||||||
$rootScope.platform = 'native'
|
$rootScope.platform = 'native'
|
||||||
SettingsService.bind($rootScope, {
|
SettingsService.bind($rootScope, {
|
||||||
key: 'platform',
|
key: 'platform',
|
||||||
storeName: 'Platform'
|
storeName: 'Platform'
|
||||||
})
|
})
|
||||||
|
|
||||||
|
$scope.$on('$routeChangeSuccess', function () {
|
||||||
|
$scope.isControlRoute = $location.path().search('/control') !== -1
|
||||||
|
})
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -13,7 +13,7 @@
|
|||||||
span.fa.fa-gears
|
span.fa.fa-gears
|
||||||
| {{ !$root.basicMode ? "Settings" : '' | translate }}
|
| {{ !$root.basicMode ? "Settings" : '' | translate }}
|
||||||
ul.nav.stf-nav.stf-feedback.pull-right(ng-cloak)
|
ul.nav.stf-nav.stf-feedback.pull-right(ng-cloak)
|
||||||
li.stf-nav-web-native-button(ng-if='!$root.basicMode')
|
li.stf-nav-web-native-button(ng-if='!$root.basicMode && isControlRoute')
|
||||||
.btn-group
|
.btn-group
|
||||||
button(type='button', ng-model='$root.platform', btn-radio="'web'", translate).btn.btn-sm.btn-default-outline Web
|
button(type='button', ng-model='$root.platform', btn-radio="'web'", translate).btn.btn-sm.btn-default-outline Web
|
||||||
button(type='button', ng-model='$root.platform', btn-radio="'native'", translate).btn.btn-sm.btn-default-outline Native
|
button(type='button', ng-model='$root.platform', btn-radio="'native'", translate).btn.btn-sm.btn-default-outline Native
|
||||||
|
|||||||
Reference in New Issue
Block a user