    public void fillComponents(UIContainer tofill, ViewParameters viewparams,
            ComponentChecker checker) {
        AssignmentViewParams params = (AssignmentViewParams) viewparams;
        Assignment2 assignment = assignmentLogic.getAssignmentById(params.assignmentId);
        String titleHeading = assignment.getTitle();
        if (gradebookLogic.getGradebookGradeEntryType(assignment.getContextId()) == ExternalGradebookLogic.ENTRY_BY_POINTS) {
            GradebookItem gradebookItem = gradebookLogic.getGradebookItemById(assignment.getContextId(), assignment.getGradebookItemId());
            if (gradebookItem == null) {
                throw new GradebookItemNotFoundException("No gradebook item found with id: " + assignment.getGradebookItemId());
            }
            titleHeading += " [" + gradebookItem.getPointsPossible() + "]";
        }
        UIOutput.make(tofill, "title-header", titleHeading);
        boolean anyUngradable = false;
        if (uploadBean.parsedContent != null) {
        	Set<String> submitters = assignmentPermissionLogic.getSubmittersInSite(assignment.getContextId());
            Map<String, String> displayIdUserIdMap = externalLogic.getUserDisplayIdUserIdMapForUsers(submitters);
            for (List<String> parts: uploadBean.parsedContent) {
                if (parts.size() < 4) {
                    while (parts.size() < 4) {
                        parts.add(" ");
                    }
                }
                UIBranchContainer row = UIBranchContainer.make(tofill, "student-row:");
                UIOutput.make(row, "student-id", parts.get(0));
                UIOutput.make(row, "student-name", parts.get(1));
                UIOutput.make(row, "grade", parts.get(2));
                UIOutput.make(row, "comments", parts.get(3));
                if(displayIdUserIdMap.containsKey(parts.get(0)) &&
                		!assignmentPermissionLogic.isUserAllowedToManageSubmission(null, displayIdUserIdMap.get(parts.get(0)), assignment)){
                	row.decorate(new UIFreeAttributeDecorator("class", "uploadHighlight"));
                	anyUngradable = true;
                }
            }
        }
        if(anyUngradable){
        	messages.addMessage(new TargettedMessage("assignment2.upload_grades_confirm.warning.ids_not_imported"));
        }
        makeBreadcrumbs(tofill, assignment);
        UIForm finishForm = UIForm.make(tofill, "finish-form");
        UICommand.make(finishForm, "ok-button", UIMessage.make("assignment2.upload_grades_confirm.button.ok"), "UploadBean.processUploadConfirmAndSave");
        UICommand.make(finishForm, "cancel-button", UIMessage.make("assignment2.upload_grades_confirm.button.back"), "UploadBean.processBackToUpload");
    }

    public void fillComponents(UIContainer tofill, ViewParameters viewparams,
            ComponentChecker checker) {
        AssignmentViewParams params = (AssignmentViewParams) viewparams;
        Assignment2 assignment = assignmentLogic.getAssignmentById(params.assignmentId);
        String titleHeading = assignment.getTitle();
        if (gradebookLogic.getGradebookGradeEntryType(assignment.getContextId()) == ExternalGradebookLogic.ENTRY_BY_POINTS) {
            GradebookItem gradebookItem = gradebookLogic.getGradebookItemById(assignment.getContextId(), assignment.getGradebookItemId());
            if (gradebookItem == null) {
                throw new GradebookItemNotFoundException("No gradebook item found with id: " + assignment.getGradebookItemId());
            }
            titleHeading += " [" + gradebookItem.getPointsPossible() + "]";
        }
        UIOutput.make(tofill, "title-header", titleHeading);
        boolean anyUngradable = false;
        if (uploadBean.parsedContent != null) {
        	Set<String> submitters = assignmentPermissionLogic.getSubmittersInSite(assignment.getContextId());
            Map<String, String> displayIdUserIdMap = externalLogic.getUserDisplayIdUserIdMapForUsers(submitters);
            for (List<String> parts: uploadBean.parsedContent) {
                if (parts.size() < 4) {
                    while (parts.size() < 4) {
                        parts.add("");
                    }
                }
                UIBranchContainer row = UIBranchContainer.make(tofill, "student-row:");
                UIOutput.make(row, "student-id", parts.get(0));
                UIOutput.make(row, "student-name", parts.get(1));
                UIOutput.make(row, "grade", parts.get(2));
                UIOutput.make(row, "comments", parts.get(3));
                if(displayIdUserIdMap.containsKey(parts.get(0)) &&
                		!assignmentPermissionLogic.isUserAllowedToManageSubmission(null, displayIdUserIdMap.get(parts.get(0)), assignment)){
                	row.decorate(new UIFreeAttributeDecorator("class", "uploadHighlight"));
                	anyUngradable = true;
                }
            }
        }
        if(anyUngradable){
        	messages.addMessage(new TargettedMessage("assignment2.upload_grades_confirm.warning.ids_not_imported"));
        }
        makeBreadcrumbs(tofill, assignment);
        UIForm finishForm = UIForm.make(tofill, "finish-form");
        UICommand.make(finishForm, "ok-button", UIMessage.make("assignment2.upload_grades_confirm.button.ok"), "UploadBean.processUploadConfirmAndSave");
        UICommand.make(finishForm, "cancel-button", UIMessage.make("assignment2.upload_grades_confirm.button.back"), "UploadBean.processBackToUpload");
    }
