예제 #1
0
        public ActionResult PilotReview(int memberId)
        {
            PilotReviewViewModel viewModel = new PilotReviewViewModel();
            Member member = _dataService.GetMemberWithPilotData(memberId);

            viewModel = InitializePilotReviewViewModel(member);
            if (User.IsInRole(UserRoles.Admin.ToString()))
            {
                viewModel.CanEditStageChecks = true;
            }
            else
            {
                int instructorId = ProfileCommon.GetProfile().MemberId;
                viewModel.CanEditStageChecks = _dataService.IsDesignatedForStageChecks(instructorId);
            }

            return(View(ViewNames.PilotReview, viewModel));
        }