2016-04-13 12:55:05 +02:00
|
|
|
(function() {
|
|
|
|
|
|
|
|
'use strict';
|
|
|
|
|
|
|
|
angular
|
2016-04-21 12:19:51 +02:00
|
|
|
.module('harbor.services.project.member')
|
2016-04-13 12:55:05 +02:00
|
|
|
.factory('EditProjectMemberService', EditProjectMemberService);
|
|
|
|
|
|
|
|
EditProjectMemberService.$inject = ['$http', '$log'];
|
|
|
|
|
|
|
|
function EditProjectMemberService($http, $log) {
|
|
|
|
|
|
|
|
return EditProjectMember;
|
|
|
|
|
2016-04-26 12:23:34 +02:00
|
|
|
function EditProjectMember(projectId, userId, roleId) {
|
|
|
|
return $http
|
|
|
|
.put('/api/projects/' + projectId + '/members/' + userId, {
|
|
|
|
'roles' : [ Number(roleId) ]
|
|
|
|
});
|
2016-04-13 12:55:05 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
})();
|