public async Task <IEnumerable <Product> > GetProducts()
        {
            var productsUrl = new Uri($"/api/resource/products?token={Constants.UserToken}", UriKind.Relative);
            var products    = await GetProducts(productsUrl);

            return(products.Select(p => ApiResourceMapper.ToProduct(p)));
        }
Esempio n. 2
0
        public async Task <IEnumerable <ShopperHistory> > GetShopperHistory()
        {
            var shopperHistoryUrl = new Uri($"/api/resource/shopperHistory?token={Constants.UserToken}", UriKind.Relative);

            var shopperHistories = await GetShopperHistory(shopperHistoryUrl);

            return(shopperHistories.Select(s => ApiResourceMapper.ToShopperHistory(s)));
        }