public IActionResult Create(TrainingCategory TrainingCategory) { try { // TODO: Add insert logic here if (ModelState.IsValid) { _ITraining.InsertTrainingCategory(TrainingCategory); return(RedirectToAction("Index")); } return(View(TrainingCategory)); } catch { return(View()); } }