public ActionResult Edit([Bind(Include = "Id,Name,Abrv,VehicleMakeId")] VehicleModelViewModel vehicleModelVM)
 {
     if (ModelState.IsValid)
     {
         VehicleModel vehicleModel = Mapper.Map <VehicleModel>(vehicleModelVM);
         vehicleModelLogic.UpdateVehicleModel(vehicleModel);
         return(RedirectToAction("Index"));
     }
     return(RedirectToAction("Index"));
 }
 public ActionResult Update([Bind(Include = "Id,MakeId,Name,Abrv")] ModelViewModel model)
 {
     try
     {
         if (ModelState.IsValid)
         {
             vehicleModelService.UpdateVehicleModel(AutoMapper.Mapper.Map <VehicleModel>(model));
             return(RedirectToAction("VehicleModelList"));
         }
     }
     catch (DataException)
     {
         ModelState.AddModelError("", "Something went wrong! Can't update VehicleModel.");
     }
     return(RedirectToAction("Update", model.Id));
 }