public ActionResult ComplexType() { var employee = new Employee { Id = 1, FirstName = "Scott", LastName = "Allen", HireDate = new DateTime(2002, 10, 1) }; return View(employee); }
public ActionResult Custom(Employee employee) { ViewBag.ShowResults = true; return View(employee); }
public ActionResult Custom() { var employee = new Employee() {FirstName = "Scott", LastName="Allen", HireDate = DateTime.Now}; return View(employee); }
public ActionResult ComplexType(Employee employee) { ViewBag.ShowResults = true; return View(employee); }
public IHttpActionResult PostComplex(Employee employee) { return Ok(employee); }