public ActionResult Create(Product product) { if (!ModelState.IsValid) { return(View(product)); } else { context.Insert(product); context.Commit(); return(RedirectToAction("Index")); } }
public void Update(Shot shot) { t_shot entity = _sqlRepository.Find(_ => _.ShotId == shot.ShotId).Single(); entity.UpdateEntity(shot); _sqlRepository.Commit(); }
public void Update(ShooterCollection shooterCollection) { t_shootercollection entity = _sqlRepository.Find(_ => _.ShooterCollectionId == shooterCollection.ShooterCollectionId).Single(); entity.UpdateEntity(shooterCollection); _sqlRepository.Commit(); }
public void Update(Shooter shooter) { t_shooter entity = _sqlRepository.Find(_ => _.ShooterId == shooter.ShooterId).Single(); entity.UpdateEntity(shooter); _sqlRepository.Commit(); }
public void Update(Session session) { t_session entity = _sqlRepository.Find(_ => _.SessionId == session.SessionId).Single(); entity.UpdateEntity(session); _sqlRepository.Commit(); }
public void Update(CollectionShooter collectionShooter) { t_collectionshooter entity = _sqlRepository.Find(_ => _.CollectionShooterId == collectionShooter.CollectionShooterId).Single(); entity.UpdateEntity(collectionShooter); _sqlRepository.Commit(); }
public void Update(Person person) { t_person entity = _sqlRepository.Find(_ => _.PersonId == person.PersonId).Single(); entity.UpdateEntity(person); _sqlRepository.Commit(); }
public void Update(SubSession sessionSubtotal) { t_sessionsubtotal entity = _sqlRepository.Find(_ => _.SessionSubtotalId == sessionSubtotal.SessionSubtotalId).Single(); entity.UpdateEntity(sessionSubtotal); _sqlRepository.Commit(); }
public void Update(ShooterNumberConfig shooterNumberConfig) { t_shooternumberconfig entity = _sqlRepository.Find(_ => _.ShooterNumberConfigId == shooterNumberConfig.ShooterNumberConfigId).Single(); entity.UpdateEntity(shooterNumberConfig); _sqlRepository.Commit(); }
internal virtual int Commit() { return(Repository.Commit()); }