Below is the content of my router.js:
angular.module('app.routes', []).config(function($stateProvider, $urlRouterProvider) {
$stateProvider.state('tabsController.dashboard', {
url : '/page2',
views : {
'tab1' : {
templateUrl : 'templates/dashboard.html',
controller : 'dashboardCtrl'
}
}
}).state('tabsController.searchResults', {
url : '/page1/page3',
views : {
'tab1' : {
templateUrl : 'templates/searchResults.html',
controller : 'searchResultsCtrl'
}
}
}).state('tabsController', {
url : '/page1',
abstract : true,
templateUrl : 'templates/tabsController.html'
});
// if none of the above states are matched, use this as the fallback
$urlRouterProvider.otherwise('/page1/page2');
});
Displayed below is the structure of my routing template dashboard.html:
<ion-content class="has-header" padding="true">
<form class="list" name="myform">
<label class="item item-input" name="Language"> <i class="icon ion-search placeholder-icon"></i>
<input type="text" placeholder="Language" name="lang" ng-model="dashboardCtrl.localMovies.lang" ng-minlength=1 ng-disabled="myform.movie.$valid" required>
</label>
<span> OR </span>
<label class="item item-input" name="Movie"> <i class="icon ion-search placeholder-icon"></i>
<input type="text" placeholder="Name of Movie" name="movie" ng-model="dashboardCtrl.localMovies.movie" ng-minlength=1 ng-disabled="myform.lang.$valid" required>
</label>
</form>
<a class="button button-positive button-block " href="#/page1/page3/">Search</a>
</ion-content>
The SearchResult.html template does not load when the search button is clicked. Assistance in identifying and resolving the issue would be greatly appreciated.