public ActionResult Edit(HrCvHintVM model) { if (ModelState.IsValid) { _hrCvHintService.Update(MapFrom(model)); return(RedirectToAction("Index")); } return(View(model)); }
public HrCvHintText MapFrom(HrCvHintVM model) { return(new HrCvHintText { Id = model.Id, Field = model.Field, FieldName = model.FieldName, Language = model.Language, Text = model.Text }); }
public ActionResult Create(HrCvHintVM model) { if (ModelState.IsValid) { _hrCvHintService.Create(MapFrom(model)); return(RedirectToAction("Index")); } else { return(View(model)); } }