private async Task <ProviderViewModel> GetById(Guid id, bool address, bool products)
 {
     if (address)
     {
         if (products)
         {
             return(_mapper.Map <ProviderViewModel>(await _providerRepository.FindById(id, true, true)));
         }
         return(_mapper.Map <ProviderViewModel>(await _providerRepository.FindById(id, true, false)));
     }
     return(_mapper.Map <ProviderViewModel>(await _providerRepository.FindById(id)));
 }
Esempio n. 2
0
 public async Task <Provider> FindById(Guid id, bool address, bool product)
 {
     return(await _providerRepository.FindById(id, address, product));
 }