public virtual ActionResult Student01(string fpUserId) { var model = new StudentSurveyPost3ViewModel { FpUserId = fpUserId }; if (HasUserFilledOutSurvey(model.QuestionId, fpUserId)) return RedirectToAction(MVC.FillPerfect.Feedback.SurveyCompleted(GetFpCompletedSurveyCount(fpUserId))); return View(model); }
public virtual ActionResult Student01(StudentSurveyPost3ViewModel model) { if (!ModelState.IsValid) return View(model); _context.FpSurveyResponses.Add(model.CreateSurveyResponse); _context.SaveChanges(); return RedirectToAction(MVC.FillPerfect.Feedback.SurveyCompleted(GetFpCompletedSurveyCount(model.FpUserId))); }
public virtual ActionResult Student01(StudentSurveyPost3ViewModel model) { if (!ModelState.IsValid) { return(View(model)); } _context.FpSurveyResponses.Add(model.CreateSurveyResponse); _context.SaveChanges(); return(RedirectToAction(MVC.FillPerfect.Feedback.SurveyCompleted(GetFpCompletedSurveyCount(model.FpUserId)))); }
public virtual ActionResult Student01(string fpUserId) { var model = new StudentSurveyPost3ViewModel { FpUserId = fpUserId }; if (HasUserFilledOutSurvey(model.QuestionId, fpUserId)) { return(RedirectToAction(MVC.FillPerfect.Feedback.SurveyCompleted(GetFpCompletedSurveyCount(fpUserId)))); } return(View(model)); }