public void UpdateBySampleID() { template_wd_ic_coverpage existing = _repository.Find(x => x.sample_id == this.sample_id).FirstOrDefault(); //this.ID = existing.ID; _repository.Edit(existing, this); }
public void Update() { template_wd_ic_coverpage existing = _repository.Find(x => x.id == this.id).FirstOrDefault(); if (existing != null) { _repository.Edit(existing, this); } else { Console.WriteLine(); } }