示例#1
0
 public ActionResult DeleteConfirmed(int id)
 {
     var request = new Employee { Id = id };
     var result = EmployeeService.Delete(request);
     //validate result
     return RedirectToAction("Index");
 }
示例#2
0
        //
        // GET: /Employee/Delete/5
        public ActionResult Delete(int id = 0)
        {
            var request = new Employee { Id = id };

            var employee = EmployeeService.Get(request).Employee.Translate();

            if (employee == null)
            {
                return HttpNotFound();
            }
            return View(employee);
        }