public async Task<ActionResult> StartRegistration(OrderViewModel model)
        {
            if (!ModelState.IsValid)
            {
                return View(CreateViewModel());
            }

            var command = model.ToPlaceOrderCommand(this.ConferenceAlias, ConferenceQueryService);
            if (!command.Seats.Any())
            {
                ModelState.AddModelError("ConferenceCode", "You must reservation at least one seat.");
                return View(CreateViewModel());
            }

            var result = await SendCommandAsync(command);

            if (!result.IsSuccess())
            {
                ModelState.AddModelError("ConferenceCode", result.GetErrorMessage());
                return View(CreateViewModel());
            }

            return RedirectToAction("SpecifyRegistrantAndPaymentDetails", new { conferenceCode = this.ConferenceCode, orderId = command.AggregateRootId });
        }
        private OrderViewModel CreateViewModel()
        {
            var seatTypes = this.ConferenceQueryService.GetPublishedSeatTypes(this.ConferenceAlias.Id);
            var viewModel = new OrderViewModel
            {
                ConferenceId = this.ConferenceAlias.Id,
                ConferenceCode = this.ConferenceAlias.Slug,
                ConferenceName = this.ConferenceAlias.Name,
                Items = seatTypes.Select(x => new OrderItemViewModel
                {
                    SeatType = x,
                    MaxSelectionQuantity = Math.Max(Math.Min(x.AvailableQuantity, 20), 0)
                }).ToList()
            };

            return viewModel;
        }