Visit this link for more information
Expected Behavior
Upon logging in, selecting a Ticker button is expected to trigger the display of matching Tags for that specific Ticker.
Actual Results
However, upon clicking a Ticker button after logging in, the entire app within the index's ui-view gets replaced by the Tags $state object.
https://i.stack.imgur.com/y6T7V.jpg
https://i.stack.imgur.com/rCMuD.jpg
The current state path of the app: login > container > tags
Functionality of the ticker button click in the Tickers component:
$scope.clickTicker = function(ticker) {
console.log(' Ticker clicked!', ticker)
$state.go('tags', { ticker: ticker });
}
app.container.html (Navigated to after login) container state
<div>
<dashboard-module></dashboard-module>
<feed-module></feed-module>
</div>
dashboard.html dashboard state
<div class="jumbotron text-center">
<h1>The Dashboard</h1>
</div>
<div class="row">
<tickers-module></tickers-module>
<tags-module></tags-module>
<view-module></view-module>
<social-module></social-module>
</div>
Full Source Code
// Container module
////////////////////////////////////////////////////////////////////////////////
var container = angular.module('container', [ 'ui.router' ])
...
... (rest of the code remains unchanged)
container.component('dashboardModule', {
templateUrl: 'dashboard.html',
controller: function($scope, $state) {
console.log('');
console.log('Dashboard component', $state.params);
}
})