public bool DeleteDonor(Donor donor) { if (donor == null) return false; _unitOfWork.DonorRepository.Delete(donor); _unitOfWork.Save(); return true; }
private Donor BindDonor(DonorModel model) { if (model == null) return null; var donor = new Donor() { DonorID = model.DonorID, DonorCode = model.DonorCode, Name = model.Name, IsResponsibleDonor = model.IsResponsibleDonor, IsSourceDonor = model.IsResponsibleDonor, LongName = model.LongName }; return donor; }
public bool EditDonor(Donor donor) { _unitOfWork.DonorRepository.Edit(donor); _unitOfWork.Save(); return true; }
public bool AddDonor(Donor donor) { _unitOfWork.DonorRepository.Add(donor); _unitOfWork.Save(); return true; }