1
0
mirror of https://github.com/kakwa/ldapcherry synced 2024-11-25 18:54:29 +01:00

adding notification for user deletion

This commit is contained in:
kakwa 2015-10-29 07:36:14 +01:00
parent 7d18934a85
commit 93cd8a40f6

View File

@ -947,9 +947,7 @@ class LdapCherry(object):
if cherrypy.request.method.upper() == 'POST': if cherrypy.request.method.upper() == 'POST':
params = self._parse_params(params) params = self._parse_params(params)
self._adduser(params) self._adduser(params)
self._add_notification( self._add_notification("User added")
"User added"
)
graph = {} graph = {}
for r in self.roles.graph: for r in self.roles.graph:
@ -993,6 +991,7 @@ class LdapCherry(object):
except: except:
referer = '/' referer = '/'
self._deleteuser(user) self._deleteuser(user)
self._add_notification('User Deleted')
raise cherrypy.HTTPRedirect(referer) raise cherrypy.HTTPRedirect(referer)
@cherrypy.expose @cherrypy.expose
@ -1005,9 +1004,7 @@ class LdapCherry(object):
if cherrypy.request.method.upper() == 'POST': if cherrypy.request.method.upper() == 'POST':
params = self._parse_params(params) params = self._parse_params(params)
self._modify(params) self._modify(params)
self._add_notification( self._add_notification("User modified")
"User modified"
)
try: try:
referer = cherrypy.request.headers['Referer'] referer = cherrypy.request.headers['Referer']
except: except: