Ejemplo n.º 1
0
        private async void AddToOrder()
        {
            if (CanAddToOrder())
            {
                await Task.Run(() =>
                {
                    serviceRepository.AddToOrder(SelectedProduct.ProductId, SelectedOrder.Id);
                });

                EventAggregator.GetEvent <OrderUpdated>().Publish(SelectedOrder.Id);
            }
        }