Package com.dotmarketing.portlets.folders.struts

Examples of com.dotmarketing.portlets.folders.struts.FolderForm


      }
    } else if(InodeUtils.isSet(f.getInode()) && !permAPI.doesUserHavePermission(f, PermissionAPI.PERMISSION_EDIT, user)){
      throw new DotSecurityException("You don't have permissions to edit this folder");
    }

    FolderForm folderForm = (FolderForm) form;
   
    HibernateUtil.startTransaction();
   
   
    try {
   
      if (InodeUtils.isSet(f.getInode()) && !folderForm.getName().equalsIgnoreCase(f.getName())) {
        if (!folderAPI.renameFolder(f,folderForm.getName(),user,false)) {
          // For messages to be displayed on messages page
          SessionMessages.add(req, "message", "message.folder.alreadyexists");
          return false;
        }
      }
     
      f.setName(folderForm.getName());
      f.setTitle(folderForm.getTitle());
      f.setFilesMasks(folderForm.getFilesMasks());
      f.setShowOnMenu(folderForm.isShowOnMenu());
      f.setSortOrder(folderForm.getSortOrder());
      f.setOwner(folderForm.getOwner());
      String defaultFileType = req.getParameter("defaultFileType");
      if(!InodeUtils.isSet(defaultFileType)){
        SessionMessages.add(req, "message", "message.folder.defaultfiletype.required");
        return false;
      }
View Full Code Here

TOP

Related Classes of com.dotmarketing.portlets.folders.struts.FolderForm

Copyright © 2018 www.massapicom. 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.