Package org.apache.roller.business

Examples of org.apache.roller.business.UserManager.removePermissions()


        PermissionsData perm = null;
       
        // delete permissions
        perm = mgr.getPermissions(testWeblog, testUser);
        assertNotNull(perm);
        mgr.removePermissions(perm);
        TestUtils.endSession(true);
       
        // check that delete was successful
        perm = null;
        perm = mgr.getPermissions(testWeblog, testUser);
View Full Code Here


            saveErrors(request, errors);
            return view(mapping, actionForm, request, response);
        }
        RollerSession rses = RollerSession.getRollerSession(request);
        if (rses.isUserAuthorizedToAdmin(perms.getWebsite())) {
            umgr.removePermissions(perms);
            roller.flush();
            try {
                notifyInvitee(request, perms.getWebsite(), perms.getUser());
                ActionMessages msgs = new ActionMessages();
                msgs.add(ActionMessages.GLOBAL_MESSAGE,
View Full Code Here

                    && val < perms.getPermissionMask()) {
                        errors.add(null,new ActionError(
                                "memberPermissions.noSelfDemotions"));
                    } else if (val != perms.getPermissionMask()) {
                        if (val == -1) {
                            userMgr.removePermissions(perms);
                            removed++;
                        } else {
                            perms.setPermissionMask(val);
                            userMgr.savePermissions(perms);
                            changed++;
View Full Code Here

                throw new NotFoundException("ERROR: Permissions do not exist for weblog handle: " + handle + ", user name: " + username);
            }
            pds = new PermissionsData[] { pd };
           
            UserManager mgr = getRoller().getUserManager();
            mgr.removePermissions(pd);
            getRoller().flush();
           
            UserData ud = getUserData(username);
            CacheManager.invalidate(ud);
            WebsiteData wd = getWebsiteData(handle);
View Full Code Here

        UserManager userMgr = RollerFactory.getRoller().getUserManager();
        PermissionsData perms = userMgr.getPermissions(form.getInviteId());
        if (perms != null) {
            // TODO ROLLER_2.0: notify inviter that invitee has declined invitation
            // TODO EXCEPTIONS: better exception handling here
            userMgr.removePermissions(perms);
            RollerFactory.getRoller().flush();

            ActionMessages msgs = new ActionMessages();
            msgs.add(null, new ActionMessage(
                    "yourWebsites.declined", perms.getWebsite().getHandle()));
View Full Code Here

        PermissionsData perms = userMgr.getPermissions(website, user);
       
        if (perms != null) {
            // TODO ROLLER_2.0: notify website members that user has resigned
            // TODO EXCEPTIONS: better exception handling
            userMgr.removePermissions(perms);
            RollerFactory.getRoller().flush();
        }
       
        ActionMessages msgs = new ActionMessages();
        msgs.add(null, new ActionMessage(
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.