public ActionResult Create(ApplicantSourceCategory applicantsourcecategory)
 {
     if (ModelState.IsValid) {
         applicantsourcecategoryRepository.InsertOrUpdate(applicantsourcecategory);
         applicantsourcecategoryRepository.Save();
         return RedirectToAction("Index");
     } else {
         return View();
     }
 }
 public void InsertOrUpdate(ApplicantSourceCategory applicantsourcecategory)
 {
     if (applicantsourcecategory.ApplicantSourceCategoryID == default(int)) {
         // New entity
         context.ApplicantSourceCategory.Add(applicantsourcecategory);
     } else {
         // Existing entity
         context.Entry(applicantsourcecategory).State = EntityState.Modified;
     }
 }
 public ViewResult Search(ApplicantSourceCategory searchApplicantSourceCategory)
 {
     if(searchApplicantSourceCategory!=null)
     {
                     }
                 return View("Index",applicantsourcecategoryRepository.All);
 }
示例#4
0
 public static string GetApplicantResumeSource(ApplicantSourceCategory applicantSource)
 {
     if (applicantSource != null)
     {
         return applicantSource.Name;
     }
     return string.Empty;
 }