çalışmaz:sekme ve yan menü - devlete bağlantılar bu yanıta göre başvurumun yapısını inşa ettik
Uygulamamı: Yan menü ve sekmeleri birleştirerek
How to set up sidemenu with tabs in Ionic?
. böyle js dosyası görünüm: Ben urlRou ait otherwise
yöntemine rotayı ayarı tüm yolları test ederken
$stateProvider
.state('app', {
url: '/app',
abstract: true,
templateUrl: 'templates/menu.html',
controller: 'AppCtrl'
})
.state('app.tabs', {
url: '/tabs',
views: {
'menuContent': {
templateUrl: 'templates/tabs.html'
}
}
})
.state('app.tabs1.general', {
url: '/tabs1-general',
views: {
'general-tab': {
templateUrl: 'templates/general1.html',
controller: 'General1Ctrl'
}
}
})
.state('app.tabs2', {
url: '/tabs2',
views: {
'menuContent': {
templateUrl: 'templates/tabs2.html'
}
}
})
.state('app.tabs2.general', {
url: '/tabs2-general',
views: {
'general2-tab': {
templateUrl: 'templates/general2.html',
controller: 'General1Ctrl'
}
}
})
$urlRouterProvider.otherwise('/app/ofertas/ofertas-reporte');
her şey iyi çalışır Ben yan çubuğu öğeleri yolları ayarladığınızda terProvider ancak URL eşleşmiyor:
İştebenim menüsü:
<ion-content>
<ion-list class="coloredList">
<ion-item class="sap-color" menu-close href="#/app/tabs1">
<i class="ion-compose"></i> tabs1
</ion-item>
<ion-item class="sap-color" menu-close href="#/app/tabs2">
<i class="ion-android-star"></i> tabs2
</ion-item>
...
Ben de ui-sref denedim ama işe yaramış görünmüyor .
Herhangi bir öneri?
Bu demoyu inceleyin http://plnkr.co/edit/T1qr0BWWbtLfHQRJQGJf?p=preview ve aşağıdaki cevabımı görün. Bu –