示例#1
0
 public int CreateCompany(CompanyCreateViewModel viewModel)
 {
     return _companyDal.Create(new Company
     {
         Name = viewModel.Name,
         LocationID = viewModel.LocationID,
         Description = viewModel.Description
     });
 }
示例#2
0
        public ActionResult CreateCompany(CompanyCreateViewModel companyCreate)
        {
            if (!ModelState.IsValid)
            {
                return View(companyCreate);
            }

            return new JsonResult();
        }