Merge branch 'master' of github.com:sagidayan/SE-Hub

This commit is contained in:
Sagi Dayan 2015-06-24 13:18:09 +03:00
commit 522a71d9c4
3 changed files with 22 additions and 7 deletions

View file

@ -22,7 +22,6 @@ angular.module('SeHub')
$scope.loadingData = false;
$location.path('/register')
}
});
$scope.isEditMode = false;

View file

@ -47,8 +47,7 @@ service.factory('apiService', ['$http', function($http) {
var url = (DEBUG ? "http://localhost:8080" : "http://se-hub.appspot.com") + "/api/courses/getAll/" + token;
req = {
method : "GET",
url : url,
data: token
url : url
};
return $http(req);
@ -71,6 +70,16 @@ service.factory('apiService', ['$http', function($http) {
};
return $http(req);
},
createMessage: function(token, payLoad){
var url = (DEBUG ? "http://localhost:8080" : "http://se-hub.appspot.com") + "/api/courses/getCourseMessages/" + token;
req = {
method : "POST",
url : url,
data: payLoad
};
return $http(req);
},
getCourseMessages: function(token, courseName){
var url = (DEBUG ? "http://localhost:8080" : "http://se-hub.appspot.com") + "/api/courses/getCourseMessages/" + token + '/' + courseName;
req = {

View file

@ -99,11 +99,18 @@
<md-button ng-click="clearAllClicked()" ng class="md-raised md-primary">Clear All</md-button>
</div>
<div class="port_spacer"></div>
<div layout-padding layout = "row">
<div flex = "60">
<md-input-container>
<label> Write Your Desired Message Here And Press Post</label>
<input type="text" minlength="1" ng-model="msg.msgToAdd" required>
<input type="text" minlength="1" ng-model="msg.msgToAdd" required></input>
</md-input-container>
</div>
<div flex = "30">
<md-select placeholder="Choose Course" ng-model="course" ng-click="chooseCourseClicked()" style="z-index: 300" class="courseDropDown"></md-select>
</div>
</div>
</div>
</md-content>
<md-content layout-padding layout-margin>