Ejemplo n.º 1
0
        public JsonResult AjaxCreateCouponCode(int CouponSysNo)
        {
            UserAuthVM user = UserAuthHelper.GetCurrentUser();

            if (user == null)
            {
                throw new ECommerce.Utility.BusinessException();
            }
            string code = CouponService.GenerateRandomCode(10);

            return(Json(code));
        }
Ejemplo n.º 2
0
        public JsonResult AjaxBitchCreateCouponCode(int Num)
        {
            string     code = "";
            UserAuthVM user = UserAuthHelper.GetCurrentUser();

            if (user == null)
            {
                throw new ECommerce.Utility.BusinessException();
            }
            for (int i = 0; i < Num; i++)
            {
                code += CouponService.GenerateRandomCode(10) + "\n";
            }
            return(Json(code));
        }