예제 #1
0
 public void Handle(BuyTicketViewModel message)
 {
     if (currentUser == null)
     {
         this.SignIn();
         return;
     }
     ActivateItem(message);
 }
        public void BuyTicketTask()
        {
            CanBuyTicket = false;
            Ticket ticket = new Ticket(connectionpath.ConnectionsParts);

            foreach (var discount in discounts)
            {
                ticket.Discounts.Add(discount, discount.Count);
            }
            var model = new BuyTicketViewModel(unitOfWork, connectionpath, this, eventAggregator, currentUser, ticket, IsRandomSeats);

            CanBuyTicket = true;
            if (model.IsOK)
            {
                eventAggregator.PublishOnUIThread(model);
            }
        }