refactored sections

This commit is contained in:
Senad Uka
2015-01-27 06:53:42 +01:00
parent c8a399b98f
commit f27c29fccf
7 changed files with 188 additions and 45 deletions

View File

@@ -11,7 +11,32 @@ var NavigationActions = {
actionType: NavigationConstants.CHANGE_URL,
url: '/artikal/' + item.get('id') +'/' + item.get('name')
});
}
},
goToSection: function(section) {
console.log("Going to item details");
AppDispatcher.handleAction({
actionType: NavigationConstants.CHANGE_URL,
url: '/sekcija/'+ section.get('id') + '/' + section.get('name')
});
},
goToCategory: function(category,section) {
console.log("Going to item details");
AppDispatcher.handleAction({
actionType: NavigationConstants.CHANGE_URL,
url: '/sekcija/' + section.get('name') +'/kategorija/'+ category.id + '/' + category.name
});
},
goToSubCategory: function(subCategory) {
// TODO: implement when ready
AppDispatcher.handleAction({
actionType: NavigationConstants.CHANGE_URL,
url: '/'
});
},
};