コード例 #1
0
 public ActionResult Addemployee(EmployeeModel staff)
 {
     TryValidateModel(staff);
     if (!ModelState.IsValid) return PartialView(staff);
     staffService.AddEmployee(new EmployeeDto(staff));
     return PartialView("Success");
 }
コード例 #2
0
 public ActionResult Editemployee(EmployeeModel staff)
 {
     if (!ModelState.IsValid) return PartialView(staff);
     staffService.EditEmployee(new EmployeeDto(staff));
     return PartialView("Success");
 }