예제 #1
0
 public async Task <Prestation> GetPrestationById(int id)
 {
     try
     {
         var spec = new PrestationsWithCategoriesSpecification(id);
         return(await _unitOfWork.Prestations.GetEntityWithSpec(spec));
     }
     catch (Exception)
     {
         throw;
     }
 }
예제 #2
0
        public async Task <IEnumerable <Prestation> > GetAllPrestations(PrestationSpecParams specParam)
        {
            var spec = new PrestationsWithCategoriesSpecification(specParam);

            return(await _unitOfWork.Prestations.ListAsync(spec));
        }