From 11b7aef006f03a23f86a1afb82d03e5e4fc91cc4 Mon Sep 17 00:00:00 2001 From: Sagi Dayan Date: Tue, 16 Jun 2015 14:15:59 +0300 Subject: [PATCH] AngularJS: Added Home Route + Home Controller + Home View --- templates/css/theme.css | 8 +++++++- templates/js/app.js | 4 ++++ templates/js/controllers/homeController.js | 10 ++++++++++ templates/js/controllers/mainController.js | 3 +++ templates/views/home.html | 21 +++++++++++++++++++++ templates/views/index.html | 1 + 6 files changed, 46 insertions(+), 1 deletion(-) create mode 100644 templates/js/controllers/homeController.js diff --git a/templates/css/theme.css b/templates/css/theme.css index de31d1a..9e53a78 100644 --- a/templates/css/theme.css +++ b/templates/css/theme.css @@ -154,4 +154,10 @@ body.noscroll border-left: 2px black solid; border-right: 2px black solid; border-radius: 1px black solid; -}*/ \ No newline at end of file +}*/ + +.gray-font{ + color: #7f7f7f; + font-size: 300%; + text-shadow:#e0e0e0 1px 1px 0; +} \ No newline at end of file diff --git a/templates/js/app.js b/templates/js/app.js index 9b93421..76bba8f 100644 --- a/templates/js/app.js +++ b/templates/js/app.js @@ -33,6 +33,10 @@ app.config(['$routeProvider', '$locationProvider', .when('/register', { templateUrl: 'templates/views/register.html', controller: 'registerController' + }) + .when('/home', { + templateUrl: 'templates/views/home.html', + controller: 'homeController' }); } diff --git a/templates/js/controllers/homeController.js b/templates/js/controllers/homeController.js new file mode 100644 index 0000000..976e68e --- /dev/null +++ b/templates/js/controllers/homeController.js @@ -0,0 +1,10 @@ +/** + * Created by sagi on 6/16/15. + */ +angular.module('SeHub') +.controller('homeController', ['$scope', '$cookies', '$cookieStore', '$window', '$location', '$mdToast', '$mdDialog', 'apiService', '$rootScope', function ($scope, $cookies, $cookieStore, $window, $location, $mdToast, $mdDialog, apiService ,$rootScope) +{ + + + +}]); \ No newline at end of file diff --git a/templates/js/controllers/mainController.js b/templates/js/controllers/mainController.js index 9da1fa1..09cb9b5 100644 --- a/templates/js/controllers/mainController.js +++ b/templates/js/controllers/mainController.js @@ -17,7 +17,10 @@ angular.module('SeHub') $scope.isInRegisterMode = true; $scope.loadingData = false; $location.path('/register') + }else{ + $location.path('/home') } + }) $scope.loadingData = false; diff --git a/templates/views/home.html b/templates/views/home.html index 989a927..881bf23 100644 --- a/templates/views/home.html +++ b/templates/views/home.html @@ -2,4 +2,25 @@
+ + +
+
+
+

+
+
+
+
+
+
+

Welcome To SE-Hub

+

+ This Is your Home Page +

+
+
+
+
+
\ No newline at end of file diff --git a/templates/views/index.html b/templates/views/index.html index fcc374d..563c811 100644 --- a/templates/views/index.html +++ b/templates/views/index.html @@ -68,6 +68,7 @@ +