示例#1
0
 public ActionResult Create(ProjectViewModel model, HttpPostedFileBase upload)
 {
     if (!ModelState.IsValid)
     {
         //var availableCustomers = Mapper.Map<IEnumerable<SelectListItem>>(_customerService.GetCustomers());
         //model.AvailableCustomers = availableCustomers;
         //return View(model);
     }
     _projectService.CreateProject(Mapper.Map<Project>(model));
     return RedirectToAction("Index");
 }
示例#2
0
 public ActionResult Create()
 {
     var model = new ProjectViewModel();
     return View(model);
 }