public async Task <RestorationType> Create(RestorationType entity) { var restorationType = _IRepositoryRestorationType.FirstOrDefault(Rt => Rt.Id == entity.Id); if (restorationType != null) { throw new UserFriendlyException("Restoration Type is already exist"); } else { return(await _IRepositoryRestorationType.InsertAsync(entity)); } }
public void Update(RestorationType entity) { _IRepositoryRestorationType.Update(entity); }