public async Task <IActionResult> Create(CreateJobCategoryViewModel model) { if (!ModelState.IsValid) { return(View(model)); } var result = await _jobCategoryService.Add(_mapper.Map <JobCategory>(model)); if (result) { return(RedirectToAction(nameof(Index))); } return(View("NotFound")); }