diff --git a/templates/js/controllers/homeController.js b/templates/js/controllers/homeController.js
index 0d3031b..2e1b19d 100644
--- a/templates/js/controllers/homeController.js
+++ b/templates/js/controllers/homeController.js
@@ -1,6 +1,7 @@
angular.module('SeHub')
.controller('homeController', ['$scope', '$cookies', '$cookieStore', '$window', '$location', '$mdToast', '$mdDialog', 'apiService', '$rootScope', function ($scope, $cookies, $cookieStore, $window, $location, $mdToast, $mdDialog, apiService ,$rootScope)
{
+ $scope.isStudent = false;
$scope.addMsg = false;
$scope.msgToPost = "";
$scope.oldText = "";
@@ -13,58 +14,18 @@ angular.module('SeHub')
if($scope.user.isLecturer)
{
+ $scope.isStudent = false;
console.log("Lecturer Mode!");
- $scope.messages = [
- {
- face : imagePath,
- what: 'Let me tell you a secret',
- who: 'Sagi Dayan',
- when: '4:15PM',
- notes: " I am S'ein"
- },
- {
- face : imagePath,
- what: 'Listen to this!',
- who: 'Aran Zaiger',
- when: '6:15PM',
- notes: " I am gaylord ultima!!"
- },
- {
- face : imagePath,
- what: 'Hi?',
- who: 'Etye Meyer',
- when: '7:45AM',
- notes: " I am mega gaylord ultima"
- }
- ];
-
- $scope.tasks = [
- {
- ExNum: '1',
- dueDate: '23/06/15',
- notes: " Build A Game: Scrabble"
- },
- {
- ExNum: '3',
- dueDate: '30/06/15',
- notes: " Static Array"
- },
- {
- ExNum: '4',
- dueDate: '07/07/15',
- notes: " Dynamic Array"
- },
- ];
}
else
{
+ $scope.isStudent = true;
console.log("Student Mode!");
}
$scope.addMessageClicked = function()
{
$scope.addMsg = true; // Reveal the "POST" Button
-
}
$scope.postMessageClicked = function(msg) // Posting the message itself
@@ -76,10 +37,8 @@ angular.module('SeHub')
$scope.prevText += "
";
document.getElementById("bindText").innerHTML += $scope.prevText;
}
- $scope.prevText = '';
- document.getElementById("bindText").value = '';
document.getElementById("msg").value = '';
-
+ $scope.prevText = '';
}
$scope.clearAllClicked = function() // Clear Screen from text
diff --git a/templates/views/home.html b/templates/views/home.html
index 5cb0ca3..cd2fc49 100644
--- a/templates/views/home.html
+++ b/templates/views/home.html
@@ -22,7 +22,6 @@
-