diff --git a/src/js/app-config.js b/src/js/app-config.js index d833e86..f1b7063 100644 --- a/src/js/app-config.js +++ b/src/js/app-config.js @@ -26,7 +26,28 @@ define([], function() { secure: true, port: 465, host: 'smtp.gmail.com' - } + }, + folders: [{ + type: 'Inbox', + count: undefined, + path: 'INBOX' + }, { + type: 'Sent', + count: undefined, + path: '[Gmail]/Gesendet' + }, { + type: 'Outbox', + count: undefined, + path: 'OUTBOX' + }, { + type: 'Drafts', + count: undefined, + path: '[Gmail]/Entw&APw-rfe' + }, { + type: 'Trash', + count: undefined, + path: '[Gmail]/Papierkorb' + }] } }; diff --git a/src/js/controller/navigation.js b/src/js/controller/navigation.js index b1c4e1d..a5a4882 100644 --- a/src/js/controller/navigation.js +++ b/src/js/controller/navigation.js @@ -1,29 +1,11 @@ -define(function() { +define(function(require) { 'use strict'; + var folders = require('js/app-config').config.gmail.folders; + var NavigationCtrl = function($scope) { $scope.navOpen = false; - $scope.folders = [{ - type: 'Inbox', - count: undefined, - path: 'INBOX' - }, { - type: 'Sent', - count: undefined, - path: '[Gmail]/Gesendet' - }, { - type: 'Outbox', - count: undefined, - path: 'OUTBOX' - }, { - type: 'Drafts', - count: undefined, - path: '[Gmail]/Entw&APw-rfe' - }, { - type: 'Trash', - count: undefined, - path: '[Gmail]/Papierkorb' - }]; + $scope.folders = folders; $scope.openNav = function() { $scope.navOpen = true;