def delete_user(self, userid, REQUEST=None, RESPONSE=None): if userid: self.acl_users.userFolderDelUsers([userid]) if REQUEST is not None: ptool = getToolByName(self.context, "plone_utils") ptool.addPortalMessage(_("User has been deleted.")) portal_url = getToolByName(self.context, "portal_url")() return self.request.response.redirect(portal_url + "/@@usergroup-userprefs")
def disapprove_user(self, userid, REQUEST=None, RESPONSE=None): if userid: self.acl_users.disapproveUser(userid) if REQUEST is not None: ptool = getToolByName(self.context, "plone_utils") ptool.addPortalMessage(_("User has been disapproved.")) portal_url = getToolByName(self.context, "portal_url")() return self.request.response.redirect(portal_url + "/@@user-approval?userid=" + userid)
def disapprove_user(self, userid, REQUEST=None, RESPONSE=None): if userid: self.acl_users.disapproveUser(userid) if REQUEST is not None: referer = REQUEST.get('HTTP_REFERER') if referer: ptool = getToolByName(self.context, 'plone_utils') ptool.addPortalMessage(_('User has been disapproved.')) return self.request.response.redirect(referer)