示例#1
0
文件: service.py 项目: ourway/auth
 def on_get(self, req, resp, client, user):
     cas = Authorization(client)
     resp.body = {'results': cas.get_user_permissions(user)}
示例#2
0
文件: service.py 项目: ourway/auth
 def on_get(self, req, resp, client, role):
     cas = Authorization(client)
     resp.body = {'results': cas.get_permissions(role)}
示例#3
0
文件: service.py 项目: ourway/auth
 def on_delete(self, req, resp, client, group, name):
     cas = Authorization(client)
     resp.body={'result':False}
     if cas.del_permission(group, name):
         resp.body={'result':True}
示例#4
0
文件: service.py 项目: ourway/auth
 def on_get(self, req, resp, client, user, name):
     cas = Authorization(client)
     resp.body={'result':False}
     if cas.user_has_permission(user,name):
         resp.body={'result':True}
示例#5
0
文件: service.py 项目: ourway/auth
 def on_delete(self, req, resp, client, group):
     cas = Authorization(client)
     resp.body={'result':False}
     if cas.del_role(group):
         resp.body={'result':True}
示例#6
0
 def on_get(self, req, resp, client, user, name):
     cas = Authorization(client)
     resp.body = {'result': False}
     if cas.user_has_permission(user, name):
         resp.body = {'result': True}
示例#7
0
 def on_get(self, req, resp, client, name):
     cas = Authorization(client)
     resp.body = {'result': cas.which_users_can(name)}
示例#8
0
文件: service.py 项目: ourway/auth
 def on_get(self, req, resp, client, name):
     cas = Authorization(client)
     resp.body = {'result':cas.which_users_can(name)}
示例#9
0
 def on_get(self, req, resp, client, user):
     cas = Authorization(client)
     resp.body = {'result': cas.get_user_roles(user)}
示例#10
0
 def on_get(self, req, resp, client):
     cas = Authorization(client)
     resp.body = {'result': cas.roles}
示例#11
0
 def on_get(self, req, resp, client, role):
     cas = Authorization(client)
     resp.body = {'result': cas.get_role_members(role)}
示例#12
0
 def on_get(self, req, resp, client, role):
     cas = Authorization(client)
     resp.body = {'results': cas.get_permissions(role)}
示例#13
0
 def on_get(self, req, resp, client, user):
     cas = Authorization(client)
     resp.body = {'results': cas.get_user_permissions(user)}
示例#14
0
文件: service.py 项目: ourway/auth
 def on_get(self, req, resp, client, role):
     cas = Authorization(client)
     resp.body = {'result': cas.get_role_members(role)}
示例#15
0
 def on_post(self, req, resp, client, role):
     cas = Authorization(client)
     resp.body = {'result': False}
     if cas.add_role(role):
         resp.body = {'result': True}
示例#16
0
文件: service.py 项目: ourway/auth
 def on_get(self, req, resp, client, user):
     cas = Authorization(client)
     resp.body = {'result': cas.get_user_roles(user)}
示例#17
0
 def on_delete(self, req, resp, client, group):
     cas = Authorization(client)
     resp.body = {'result': False}
     if cas.del_role(group):
         resp.body = {'result': True}
示例#18
0
文件: service.py 项目: ourway/auth
 def on_post(self, req, resp, client, role):
     cas = Authorization(client)
     resp.body={'result':False}
     if cas.add_role(role):
         resp.body={'result':True}
示例#19
0
 def on_delete(self, req, resp, client, user, group):
     cas = Authorization(client)
     resp.body = {'result': False}
     if cas.del_membership(user, group):
         resp.body = {'result': True}
示例#20
0
文件: service.py 项目: ourway/auth
 def on_post(self, req, resp, client, user, group):
     cas = Authorization(client)
     resp.body={'result':False}
     if cas.add_membership(user, group):
         resp.body={'result':True}
示例#21
0
 def on_delete(self, req, resp, client, group, name):
     cas = Authorization(client)
     resp.body = {'result': False}
     if cas.del_permission(group, name):
         resp.body = {'result': True}