コード例 #1
0
        private async void GetOrders()
        {
            IsBusy = true;
            //async
            //var c = await _orderServiceClient.GetAllOrders();
            var b = await _orderServiceClient.GetOrdersByFilter(Filter);

            OrdersCollection = new ObservableCollection <OrderItemViewModel>(b.Select(x => new OrderItemViewModel(x)));

            IsBusy = false;
        }
コード例 #2
0
        public async void  GetOrdersByCustomer()
        {
            if (Item.Id == Guid.Empty)
            {
                return;
            }
            var filter = new OrderFilterDTO {
                Customer = Item
            };
            var c = await _orderService.GetOrdersByFilter(filter);

            OrdersFilteredCollection = new ObservableCollection <OrderItemViewModel>(c.Select(x => new OrderItemViewModel(x)));
        }