Ejemplo n.º 1
0
 public IActionResult QuickCreate()
 {
     ViewBag.OrderSourceTypes = _orderSourceTypeRepository.OrderSourceTypes.ToList();
     ViewBag.DeliveryPartners = _deliveryPartnerRepository.DeliveryPartners.ToList();
     ViewBag.IsInBuy1Get1     = _promotionRepository.CheckPromotionBuy1Get1() ? 1 : 0;
     return(View());
 }
Ejemplo n.º 2
0
        public IActionResult GetCart(CreateOrderModel orderModel)
        {
            var order = _mapper.Map <Data.Models.Order>(orderModel);

            order.IsSpecialPromo = _promotionRepository.CheckPromotionBuy1Get1();
            _orderRepository.Normalize(order);
            return(PartialView("_Cart", order));
        }
Ejemplo n.º 3
0
        public IActionResult Index()
        {
            var model = new HomeViewModel
            {
                IsInBuy1Get1    = _promotionRepository.CheckPromotionBuy1Get1() ? 1 : 0,
                NotifyPopup     = _notifyPopupRepository.GetActiveNotifyPopup(),
                DrinkCategories = _categoryRepository.Categories.ToList()
            };

            return(View(model));
        }