Skip to content

Commit

Permalink
fix content type
Browse files Browse the repository at this point in the history
  • Loading branch information
nobodyiam committed Sep 4, 2018
1 parent 0950681 commit cc80b75
Showing 1 changed file with 17 additions and 6 deletions.
Expand Up @@ -2,7 +2,10 @@ appService.service('PermissionService', ['$resource', '$q', function ($resource,
var permission_resource = $resource('', {}, {
init_app_namespace_permission: {
method: 'POST',
url: '/apps/:appId/initPermission?namespace=:namespace'
url: '/apps/:appId/initPermission',
headers: {
'Content-Type': 'text/plain;charset=UTF-8'
}
},
has_app_permission: {
method: 'GET',
Expand Down Expand Up @@ -30,11 +33,17 @@ appService.service('PermissionService', ['$resource', '$q', function ($resource,
},
assign_namespace_role_to_user: {
method: 'POST',
url: '/apps/:appId/namespaces/:namespaceName/roles/:roleType'
url: '/apps/:appId/namespaces/:namespaceName/roles/:roleType',
headers: {
'Content-Type': 'text/plain;charset=UTF-8'
}
},
assign_namespace_env_role_to_user: {
method: 'POST',
url: '/apps/:appId/envs/:env/namespaces/:namespaceName/roles/:roleType'
url: '/apps/:appId/envs/:env/namespaces/:namespaceName/roles/:roleType',
headers: {
'Content-Type': 'text/plain;charset=UTF-8'
}
},
remove_namespace_role_from_user: {
method: 'DELETE',
Expand All @@ -50,7 +59,10 @@ appService.service('PermissionService', ['$resource', '$q', function ($resource,
},
assign_app_role_to_user: {
method: 'POST',
url: '/apps/:appId/roles/:roleType'
url: '/apps/:appId/roles/:roleType',
headers: {
'Content-Type': 'text/plain;charset=UTF-8'
}
},
remove_app_role_from_user: {
method: 'DELETE',
Expand All @@ -61,8 +73,7 @@ appService.service('PermissionService', ['$resource', '$q', function ($resource,
function initAppNamespacePermission(appId, namespace) {
var d = $q.defer();
permission_resource.init_app_namespace_permission({
appId: appId,
namespace: namespace
appId: appId
}, namespace,
function (result) {
d.resolve(result);
Expand Down

0 comments on commit cc80b75

Please sign in to comment.