public ActionResult Adauga(CameraModel camera) { CameraRepository r = new CameraRepository(); r.Add(camera); return(RedirectToAction("Index")); ViewBag.TipCamere = TipCameraSelectie.Selectii(); }
public void AddCamera(Camera camera) { var cameraEntity = mapper.Map <CameraEntity>(camera); cameraRepository.Add(cameraEntity); }