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; }
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))); }