public IActionResult VerifyCandidateCode(CandidateScreeningInfoVM candidateStorageInfoVM)
        {
            if (string.IsNullOrEmpty(candidateStorageInfoVM.CandidateSignInCode))
            {
                ViewBag.InvalidCandidateCode = "Invalid SignIn Code";
                return(View("Index")); //Return invalid screeningcode error message
            }
            var candidateStorageInfo = screeningRepository.GetCandidateInfoForSignUp(candidateStorageInfoVM.CandidateSignInCode, "Y");

            if (candidateStorageInfo == null)
            {
                ViewBag.InvalidCandidateCode = "Invalid SignIn Code";
                return(View("Index"));
            }
            var lstScreeningQuestions = candidateStorageInfo.ScreeningQuestions;

            if (lstScreeningQuestions == null)
            {
                ViewBag.InvalidCandidateCode = "Invalid SignIn Code";
                return(View("Index")); //Return invalid screeningcode error message
            }
            ViewBag.InvalidCandidateCode = "";
            candidateSignInCode          = candidateStorageInfoVM.CandidateSignInCode;

            ViewBag.CandidateCode = candidateStorageInfoVM.CandidateSignInCode;

            return(View("Interview", lstScreeningQuestions));
        }
示例#2
0
        public IActionResult ReviewInterview(int candidateId, int screeningId)
        {
            var questions = this.screeningRepository.GetScreeningQuestions(candidateId, screeningId);

            var vm = new CandidateScreeningInfoVM();

            vm.CandidateId = candidateId.ToString();
            vm.ScreeningId = screeningId.ToString();

            vm.ScreeningQuestions = questions;

            return(View(vm));
        }
示例#3
0
        public CandidateScreeningInfoVM GetCandidateInfoForSignUp(string candidateSignInCode, string validateSignInCode)
        {
            var screeningCandidate = context.ScreeningCandidate.Where(x => x.CandidateSignInCode == candidateSignInCode.Trim()).FirstOrDefault();

            if (screeningCandidate == null)
            {
                return(null);
            }

            var vm = new CandidateScreeningInfoVM();

            if (validateSignInCode == "Y")
            {
                var lstScreeningQuestions = context.ScreeningQuestions.Where(x => x.ScreeningId == screeningCandidate.ScreeningId).ToList();
                vm.ScreeningQuestions = lstScreeningQuestions;
            }
            else
            {
                vm.CandidateId = screeningCandidate.CandidateId.ToString();
                vm.ScreeningId = screeningCandidate.ScreeningId.ToString();
            }
            return(vm);
        }
        public IActionResult Index()
        {
            var candidateCloudStorageInfoVM = new CandidateScreeningInfoVM();

            return(View(candidateCloudStorageInfoVM));
        }