Beispiel #1
0
        public async Task <Result <List <Good> > > GetGoods()
        {
            var resultFromClient = await goodsClient.GetGoodsAsync();

            return(new Result <List <Good> >
            {
                IsSuccess = resultFromClient.IsSuccess,
                Message = resultFromClient.Message,
                Value = resultFromClient.IsSuccess
                    ? resultFromClient.Value.Select(g => GoodConverter.FromDto(g)).ToList()
                    : null
            });
        }
Beispiel #2
0
 public async Task <PagedResultOfGoodsDto> GetGoodsAsync(GoodsQueryDto queryDto)
 {
     return(await _goodsClient.GetGoodsAsync(queryDto));
 }