Search in sources :

Example 21 with CourseDetailsBundle

use of teammates.common.datatransfer.CourseDetailsBundle in project teammates by TEAMMATES.

the class StudentHomePageAction method addPlaceholderCourse.

private void addPlaceholderCourse(List<CourseDetailsBundle> courses, String courseId, Map<FeedbackSessionAttributes, Boolean> sessionSubmissionStatusMap) {
    try {
        CourseDetailsBundle course = logic.getCourseDetails(courseId);
        courses.add(course);
        addPlaceholderFeedbackSessions(course, sessionSubmissionStatusMap);
        FeedbackSessionDetailsBundle.sortFeedbackSessionsByCreationTime(course.feedbackSessions);
    } catch (EntityDoesNotExistException e) {
        showEventualConsistencyMessage(courseId);
        statusToAdmin = Const.ACTION_RESULT_FAILURE + " :" + e.getMessage();
    }
}
Also used : CourseDetailsBundle(teammates.common.datatransfer.CourseDetailsBundle) EntityDoesNotExistException(teammates.common.exception.EntityDoesNotExistException)

Aggregations

CourseDetailsBundle (teammates.common.datatransfer.CourseDetailsBundle)21 CourseAttributes (teammates.common.datatransfer.attributes.CourseAttributes)8 EntityDoesNotExistException (teammates.common.exception.EntityDoesNotExistException)8 ArrayList (java.util.ArrayList)7 FeedbackSessionAttributes (teammates.common.datatransfer.attributes.FeedbackSessionAttributes)6 InstructorAttributes (teammates.common.datatransfer.attributes.InstructorAttributes)6 HashMap (java.util.HashMap)5 StudentAttributes (teammates.common.datatransfer.attributes.StudentAttributes)5 AccountAttributes (teammates.common.datatransfer.attributes.AccountAttributes)4 Test (org.testng.annotations.Test)3 SectionDetailsBundle (teammates.common.datatransfer.SectionDetailsBundle)3 StudentProfileAttributes (teammates.common.datatransfer.attributes.StudentProfileAttributes)3 FeedbackSessionDetailsBundle (teammates.common.datatransfer.FeedbackSessionDetailsBundle)2 TeamDetailsBundle (teammates.common.datatransfer.TeamDetailsBundle)2 StatusMessage (teammates.common.util.StatusMessage)2 InstructorCourseDetailsPageData (teammates.ui.pagedata.InstructorCourseDetailsPageData)2 StudentHomePageData (teammates.ui.pagedata.StudentHomePageData)2 CourseTable (teammates.ui.template.CourseTable)2 Text (com.google.appengine.api.datastore.Text)1 CourseEnrollmentResult (teammates.common.datatransfer.CourseEnrollmentResult)1