private void GetActivityViewModelList(List <Activity> activityList, string courseId, string courseName, bool isManagerRole) { foreach (var activity in activityList) { ActivityViewModel activityViewModel = new ActivityViewModel(activity); activityViewModel.CourseId = courseId; activityViewModel.CourseName = courseName; if (isManagerRole) { RawManagerActivityList.Add(activityViewModel); } else { RawParticipantActivityList.Add(activityViewModel); } } }
private void GetActivityViewModelList(List <Activity> activityList, string courseId) { foreach (var activity in activityList) { ActivityViewModel activityViewModel = new ActivityViewModel(activity); activityViewModel.CourseId = courseId; if (activity.Status == 1) { PendingActivity.Add(activityViewModel); } else if (activity.Status == 2) { OverDueActivity.Add(activityViewModel); } else if (activity.Status == 3) { CompletedActivity.Add(activityViewModel); } } }
public AssessmentSubmitViewModel(ActivityViewModel selectedActivity, ObservableCollection <AssessmentViewModel> QuestionList) { this._SelectedActivity = selectedActivity; AssessmentQuestionList = QuestionList; }
public AssessmentAttemptViewModel(ActivityViewModel selectedActivity, List <ReviewQuestion> questionList) { this._SelectedActivity = selectedActivity; GetQuestionViewModelList(questionList); }