Examples of permissionIndividually()


Examples of com.dotmarketing.business.PermissionAPI.permissionIndividually()

    Permissionable permissionable = host == null?folder:host;
    List<Permission> permissionsToSave = new ArrayList<Permission>();

    if(APILocator.getPermissionAPI().isInheritingPermissions(permissionable)){
      Permissionable parentPermissionable = permissionAPI.findParentPermissionable(permissionable);
      permissionAPI.permissionIndividually(parentPermissionable, permissionable, systemUser, respectFrontendRoles);
    }

    if(permissions.get("individual") != null) {
      int permission = Integer.parseInt(permissions.get("individual"));
      permissionsToSave.add(new Permission(PermissionAPI.INDIVIDUAL_PERMISSION_TYPE, permissionable.getPermissionId(), roleId, permission, true));
View Full Code Here

Examples of com.dotmarketing.business.PermissionAPI.permissionIndividually()

        PermissionAPI permissionAPI = APILocator.getPermissionAPI();

        //Set up a test folder
        Folder testFolder = APILocator.getFolderAPI().createFolders( "/" + new Date().getTime() + "/", defaultHost, user, false );
        permissionAPI.permissionIndividually( permissionAPI.findParentPermissionable( testFolder ), testFolder, user, false );

        //Create the structure
        Structure testStructure = new Structure();

        testStructure.setDefaultStructure( false );
View Full Code Here

Examples of com.dotmarketing.business.PermissionAPI.permissionIndividually()

        //Creating a test structure
        PermissionAPI permissionAPI = APILocator.getPermissionAPI();

        //Set up a test folder
        testFolder = APILocator.getFolderAPI().createFolders( "testSearchIndexByDateFolder", defaultHost, user, false );
        permissionAPI.permissionIndividually( permissionAPI.findParentPermissionable( testFolder ), testFolder, user, false );

        //Set up a test structure
        String structureName = "testSearchIndexByDateStructure";
        testStructure = new Structure();
        testStructure.setHost( defaultHost.getIdentifier() );
View Full Code Here

Examples of com.dotmarketing.business.PermissionAPI.permissionIndividually()

        PermissionAPI permissionAPI = APILocator.getPermissionAPI();

        //Set up a test folder
        Folder testFolder = APILocator.getFolderAPI().createFolders( "/" + new Date().getTime() + "/", defaultHost, user, false );
        permissionAPI.permissionIndividually( permissionAPI.findParentPermissionable( testFolder ), testFolder, user, false );

        //Set up a test structure
        String structureName = "ESContentletIndexAPITest_" + new Date().getTime();
        Structure testStructure = new Structure();
        testStructure.setHost( defaultHost.getIdentifier() );
View Full Code Here

Examples of com.dotmarketing.business.PermissionAPI.permissionIndividually()

          PermissionAPI permissionAPI = APILocator.getPermissionAPI();
          Permissionable asset = retrievePermissionable(assetId, languageId, user, respectFrontendRoles);
          Permissionable parentPermissionable = APILocator.getPermissionAPI().findParentPermissionable(asset);

          if(parentPermissionable!=null){
            permissionAPI.permissionIndividually(parentPermissionable, asset, user, respectFrontendRoles);
          }
          HibernateUtil.commitTransaction();
        } catch (Exception e) {
          HibernateUtil.rollbackTransaction();
          throw e;
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.