예제 #1
0
        public ActionResult Index()
        {
            try
            {
                var customerId = CustomerId();
                if (customerId == 0)
                {
                    return(Redirect("/Me/JoinUs/Index"));
                }
                ViewData["CustomerName"] = CustomerName();
                ViewData["WeixinUser"]   = WeiXinUser();
                LogManager.GetLogger().Info("customerId:" + customerId);

                ViewData["CustoemrBase"] = CustomerBase.FindById(customerId);

                var customerCards = CustomerCard.FindByList(customerId: customerId);
                ViewData["CustomerCards"] = customerCards;

                var orderBases = OrderBaseInfo.FindByList(customerId: customerId);
                ViewData["OrderBases"] = orderBases;

                ViewData["CustomerBases"] = CustomerBase.FindByList(parentId: customerId);
            }
            catch (Exception ex)
            {
                LogManager.GetLogger().Error(ex);
            }
            return(View());
        }
예제 #2
0
        /// <summary>
        /// 会员卡
        /// </summary>
        /// <returns></returns>
        public ActionResult MemberCard()
        {
            try
            {
                var customerId = CustomerId();
                ViewData["CustomerName"] = CustomerName();
                ViewData["WeixinUser"]   = WeiXinUser();

                ViewData["CustomerCards"] = CustomerCard.FindByList(customerId: customerId);
                ViewData["CardEquities"]  = CardEquity.FindByList();
            }
            catch (Exception ex)
            {
                LogManager.GetLogger().Error(ex);
            }
            return(View());
        }