Package org.dspace.app.xmlui.wing.element

Examples of org.dspace.app.xmlui.wing.element.List


       
        // Use these fields to change the number of search fields, or change the results per page.
        query.addHidden("num_search_field").setValue(numSearchField);
        query.addHidden("results_per_page").setValue(getParameterRpp());
       
        List queryList = query.addList("search-query",List.TYPE_FORM);
       
        if (variableScope())
        {
            Select scope = queryList.addItem().addSelect("scope");
            scope.setLabel(T_search_scope);
            scope.setHelp(T_search_scope_help);
            buildScopeList(scope);
        }
       
View Full Code Here


      // Build the form that describes an item.
      Division div = body.addInteractiveDivision("submit-edit-file", actionURL, Division.METHOD_POST, "primary submission");
      div.setHead(T_submission_head);
      addSubmissionProgressList(div);
     
      List edit = div.addList("submit-edit-file", List.TYPE_FORM);
        edit.setHead(T_head);   
       
        edit.addLabel(T_file);
        edit.addItem().addXref(fileUrl, fileName);
       
        Text description = edit.addItem().addText("description");
        description.setLabel(T_description);
        description.setHelp(T_description_help);
        description.setValue(bitstream.getDescription());
       
        edit.addItem(T_info1);
        if (guessedFormat != null)
        {
          edit.addLabel(T_format_detected);
          edit.addItem(guessedFormat.getShortDescription());
        }
       
        // System supported formats
        Select format = edit.addItem().addSelect("format");
        format.setLabel(T_format_selected);
       
        format.addOption(-1,T_format_default);
        for (BitstreamFormat bitstreamFormat : bitstreamFormats)
        {
          String supportLevel = "Unknown";
          if (bitstreamFormat.getSupportLevel() == BitstreamFormat.KNOWN)
            supportLevel = "known";
          else if (bitstreamFormat.getSupportLevel() == BitstreamFormat.SUPPORTED)
            supportLevel = "Supported";
          String name = bitstreamFormat.getShortDescription()+" ("+supportLevel+")";
          int id = bitstreamFormat.getID();
      
          format.addOption(id,name);
        }
        if (currentFormat != null)
        {
          format.setOptionSelected(currentFormat.getID());
        }
        else if (guessedFormat != null)
        {
          format.setOptionSelected(guessedFormat.getID());
        }
        else
        {
          format.setOptionSelected(-1);
        }
       
        edit.addItem(T_info2);
       
        // User supplied format
        Text userFormat = edit.addItem().addText("format_description");
        userFormat.setLabel(T_format_user);
        userFormat.setHelp(T_format_user_help);
        userFormat.setValue(bitstream.getUserFormatDescription());
       
        // add ID of bitstream we're editing
        div.addHidden("bitstream_id").setValue(bitstream.getID());
       
        // Note, not standard control actions, this page just goes back to the upload step.
        org.dspace.app.xmlui.wing.element.Item actions = edit.addItem();
        actions.addButton("submit_save").setValue(T_submit_save);
    actions.addButton("submit_edit_cancel").setValue(T_submit_cancel);
       
    }
View Full Code Here

            jumpForm.addButton("submit").setValue(T_go);
        }
        else
        {
            // Create a clickable list of the alphabet
            List jumpList = jump.addList("jump-list", List.TYPE_SIMPLE, "alphabet");
            for (char c = 'A'; c <= 'Z'; c++)
            {
                Map<String, String> cQuery = new HashMap<String, String>(queryParams);
                cQuery.put(BrowseParams.STARTS_WITH, Character.toString(c));
                jumpList.addItemXref(super.generateURL(WITHDRAWN_URL_BASE, cQuery), Character
                        .toString(c));
            }

            // Create a free text field for the initial characters
            Para jumpForm = jump.addPara();
View Full Code Here

        contact.setHead(T_head);
       
        String name = ConfigurationManager.getProperty("dspace.name");
        contact.addPara(T_para1.parameterize(name));
       
        List list = contact.addList("contact");
       
        list.addLabel(T_feedback_label);
        list.addItem().addXref(contextPath+"/feedback",T_feedback_link);
       
        list.addLabel(T_email);
        String email = ConfigurationManager.getProperty("mail.admin");
        list.addItem().addXref("mailto:"+email,email);
    }
View Full Code Here

       
        feedback.setHead(T_head);
       
        feedback.addPara(T_para1);
       
        List form = feedback.addList("form",List.TYPE_FORM);
       
        Text email = form.addItem().addText("email");
        email.setLabel(T_email);
        email.setHelp(T_email_help);
        email.setValue(parameters.getParameter("email",""));
       
        TextArea comments = form.addItem().addTextArea("comments");
        comments.setLabel(T_comments);
        comments.setValue(parameters.getParameter("comments",""));
       
        form.addItem().addButton("submit").setValue(T_submit);
       
        feedback.addHidden("page").setValue(parameters.getParameter("page","unknown"));
    }
View Full Code Here

   
    // DIVISION: main
      Division main = body.addInteractiveDivision("collection-harvesting-setup",contextPath+"/admin/collection",Division.METHOD_MULTIPART,"primary administrative collection");
      main.setHead(T_main_head.parameterize(thisCollection.getMetadata("name")));  
     
      List options = main.addList("options",List.TYPE_SIMPLE,"horizontal");
      options.addItem().addXref(baseURL+"&submit_metadata",T_options_metadata);
      options.addItem().addXref(baseURL+"&submit_roles",T_options_roles);
      options.addItem().addHighlight("bold").addXref(baseURL+"&submit_harvesting",T_options_harvest);
     
     
      // The top-level, all-setting, countent source radio button
      List harvestSource = main.addList("harvestSource", "form");
     
      harvestSource.addLabel(T_label_source);
      Radio source = harvestSource.addItem().addRadio("source");
      source.addOption(hc == null, "source_normal", T_source_normal);
      source.addOption(hc != null, "source_harvested", T_source_harvested);
  
    Para buttonList = main.addPara();
      buttonList.addButton("submit_save").setValue(T_submit_save);
View Full Code Here

      Division div = body.addInteractiveDivision("submit-upload", actionURL, Division.METHOD_MULTIPART, "primary submission");
      div.setHead(T_submission_head);
      addSubmissionProgressList(div);
     
     
      List upload = null;
      if (!workflow)
      {
        // Only add the upload capabilities for new item submissions
        upload = div.addList("submit-upload-new", List.TYPE_FORM);
          upload.setHead(T_head);   
         
          File file = upload.addItem().addFile("file");
          file.setLabel(T_file);
          file.setHelp(T_file_help);
          file.setRequired();
         
          //if no files found error was thrown by processing class, display it!
          if (this.errorFlag==org.dspace.submit.step.UploadStep.STATUS_NO_FILES_ERROR)
          {
                file.addError(T_file_error);
            }

            // if an upload error was thrown by processing class, display it!
            if (this.errorFlag == org.dspace.submit.step.UploadStep.STATUS_UPLOAD_ERROR)
            {
                file.addError(T_upload_error);
            }
           
          Text description = upload.addItem().addText("description");
          description.setLabel(T_description);
          description.setHelp(T_description_help);
         
          Button uploadSubmit = upload.addItem().addButton("submit_upload");
          uploadSubmit.setValue(T_submit_upload);
      }
       
        // Part B:
        //  If the user has allready uploaded files provide a list for the user.
View Full Code Here

    public List addReviewSection(List reviewList) throws SAXException,
        WingException, UIException, SQLException, IOException,
        AuthorizeException
    {
        // Create a new list section for this step (and set its heading)
        List uploadSection = reviewList.addList("submit-review-" + this.stepAndPage, List.TYPE_FORM);
        uploadSection.setHead(T_head);
       
        //Review all uploaded files
        Item item = submission.getItem();
        Bundle[] bundles = item.getBundles("ORIGINAL");
        Bitstream[] bitstreams = new Bitstream[0];
        if (bundles.length > 0)
        {
            bitstreams = bundles[0].getBitstreams();
        }
       
        for (Bitstream bitstream : bitstreams)
        {
            BitstreamFormat bitstreamFormat = bitstream.getFormat();
           
            int id = item.getID();
            String name = bitstream.getName();
            String url = makeBitstreamLink(item, bitstream);
            String format = bitstreamFormat.getShortDescription();
            Message support = ReviewStep.T_unknown;
            if (bitstreamFormat.getSupportLevel() == BitstreamFormat.KNOWN)
                support = T_known;
            else if (bitstreamFormat.getSupportLevel() == BitstreamFormat.SUPPORTED)
                support = T_supported;
           
            org.dspace.app.xmlui.wing.element.Item file = uploadSection.addItem();
            file.addXref(url,name);
            file.addContent(" - "+ format + " ");
            file.addContent(support);
           
        }
View Full Code Here

   
    // DIVISION: main
      Division main = body.addInteractiveDivision("collection-assign-roles",contextPath+"/admin/collection",Division.METHOD_POST,"primary administrative collection");
      main.setHead(T_main_head.parameterize(thisCollection.getMetadata("name")));
     
      List options = main.addList("options", List.TYPE_SIMPLE, "horizontal");
      options.addItem().addXref(baseURL+"&submit_metadata",T_options_metadata);
      options.addItem().addHighlight("bold").addXref(baseURL+"&submit_roles",T_options_roles);
      options.addItem().addXref(baseURL+"&submit_harvesting",T_options_harvest);
           
      // The table of admin roles
      Table rolesTable = main.addTable("roles-table", 6, 5);
      Row tableRow;
     
View Full Code Here

   
    // DIVISION: eperson-actions
        Division actions = main.addDivision("epeople-actions");
        actions.setHead(T_actions_head);
       
        List actionsList = actions.addList("actions");
        actionsList.addLabel(T_actions_create);
        actionsList.addItemXref(baseURL+"&submit_add", T_actions_create_link);
        actionsList.addLabel(T_actions_browse);
        actionsList.addItemXref(baseURL+"&query&submit_search",
            T_actions_browse_link);
     
        actionsList.addLabel(T_actions_search);
        org.dspace.app.xmlui.wing.element.Item actionItem = actionsList.addItem();
        Text queryField = actionItem.addText("query");
        if (query != null)
          queryField.setValue(query);
        queryField.setHelp(T_search_help);
        actionItem.addButton("submit_search").setValue(T_go);
View Full Code Here

TOP

Related Classes of org.dspace.app.xmlui.wing.element.List

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.