public string AddOrder(OrderForCreationVm order) { Order newOrder = _mapper.Map <Order>(order); int orderId = _orderRepository.AddNewOrder(newOrder); string orderConfirmation = GenerateOrderConfrimation(orderId); newOrder.OrderConfirmation = orderConfirmation; return(orderConfirmation); }
public IActionResult OrderSummary(OrderForCreationVm orderForView) { string orderConfirmation = _orderService.AddOrder(orderForView); return(View(orderConfirmation)); }