AppController refactoring

This commit is contained in:
tmshv committed 2016-02-22 00:59:16 +03:00
1 parent a4d54f386d
commit 6115dbda8d
2 files changed
+7 -4

No files matched your search

+2 -4
View File
@@ -6,6 +6,7 @@ import Document from './components/Document';
import Award from './components/Award';
import GalleryItem from './components/GalleryItem';
import TeamMemberProfile from './components/TeamMemberProfile';
import AppController from './controllers/AppController';
import api from './api/api';
let deps = [
@@ -104,6 +105,7 @@ app.run(($location, $rootScope, $http) => {
Award,
GalleryItem,
TeamMemberProfile,
AppController,
function (app) {
app.controller('SchedulePageController', ($scope) => {
$scope.pageClass = 'page-schedule';
@@ -112,9 +114,5 @@ app.run(($location, $rootScope, $http) => {
app.controller('DocsPageController', ($scope) => {
$scope.pageClass = 'page-docs';
});
app.controller('AppController', ($scope, menu) => {
$scope.menuProvider = menu.items;
});
}
].map(i => i(app));
+5
View File
@@ -0,0 +1,5 @@
export default function (app) {
app.controller('AppController', ($scope, menu) => {
$scope.menuProvider = menu.items;
});
};