示例#1
0
    protected void Page_Load(object sender, EventArgs e)
    {
        UserAuthorizationModel userInfo = UserAuthorization.userLogin(this.Page);

        if (userInfo.openId == null || userInfo.openId == "")
        {
            openid = userInfo.mobile;
        }
        else
        {
            openid = userInfo.openId;
        }
        DBCLASSFORWEIXIN.Model.LocalWeixinUser SingleUserInf = new DBCLASSFORWEIXIN.DAL.LocalWeixinUser().GetModel(openid);
        this.Title = SingleUserInf.nickname + " 现金账户";
        LVWEIBA.Model.MemberList mmm = new LVWEIBA.Model.MemberList();
        mmm = new LVWEIBA.DAL.MemberList().GetModel(openid);
        if (mmm == null)
        {
            yue = "0.00";
        }
        else
        {
            yue = mmm.Money.ToString();
        }
        HUserHostAddress = Page.Request.UserHostAddress;
    }
示例#2
0
    protected void Page_Load(object sender, EventArgs e)
    {
        UserAuthorizationModel userInfo = UserAuthorization.userLogin(this.Page);

        if (userInfo.openId == null || userInfo.openId == "")
        {
            member = userInfo.mobile;
        }
        else
        {
            member = userInfo.openId;
        }
        Session["openid"] = member;
        //加载常用旅客信息
        LVWEIBA.BLL.MemberHotel          bllhotel = new LVWEIBA.BLL.MemberHotel();
        List <LVWEIBA.Model.MemberHotel> lsthotel = bllhotel.GetModelList(" member='" + member + "'");

        Literal1.Text = "";
        string strhotel = "";

        foreach (MemberHotel item in lsthotel)
        {
            strhotel += string.Format("<li id='{0}'>{1}<span>{2}</span><i class='iconfont' id='{3}'>&#xe63d;</i></li>", item.Id, item.Name, item.Card, item.Id);
        }
        Literal1.Text = strhotel;
    }
示例#3
0
    protected void Page_Load(object sender, EventArgs e)
    {
        UserAuthorizationModel userInfo = UserAuthorization.userLogin(this.Page);

        DBCLASSFORWEIXIN.Model.LocalWeixinUser SingleUserInf = new CheckUserAndUpdate().CheckUserAndInsert(userInfo.openId, "");
        Image1.ImageUrl = SingleUserInf.headimgurl;
        Label1.Text     = SingleUserInf.nickname;
    }
    protected void Page_Load(object sender, EventArgs e)
    {
        UserAuthorizationModel userInfo = UserAuthorization.userLogin(this.Page);

        if (userInfo.openId == null || userInfo.openId == "")
        {
            member = userInfo.mobile;
        }
        else
        {
            member = userInfo.openId;
        }
        ticketId = (string.IsNullOrEmpty(Request.QueryString["ticketId"]) ? 0 : int.Parse(Request.QueryString["ticketId"]));
        //预定数量
        reserverCount = (string.IsNullOrEmpty(Request.QueryString["reserverCount"]) ? 0 : int.Parse(Request.QueryString["reserverCount"]));
        if (!IsPostBack)
        {
            var bll = new LVWEIBA.DAL.ProviderSpot();
            ViewState["ticketId"] = ticketId;
            if (ticketId == 0 || reserverCount == 0)
            {
                Jscript.AlertAndRedirect("请选择合适的票数", "ticket.aspx");
            }
            else
            {
                LVWEIBA.Model.ProviderSpot providerSpot = bll.GetModel(ticketId);
                ticketTitle        = providerSpot.SpotName;
                ticketId           = providerSpot.ID;
                startDate          = Convert.ToDateTime(providerSpot.BeginTime).ToString("yyyy年MM月dd号");
                endDate            = Convert.ToDateTime(providerSpot.EndTime).ToString("yyyy年MM月dd号");
                orderPriceLbl.Text = "¥" + providerSpot.ZkPrice;
                string priceDetailStr = reserverCount + "张";
                int    maketPrice     = (int)providerSpot.TicketPrice * reserverCount;
                int    zkPrice        = (int)providerSpot.ZkPrice * reserverCount;
                string str            = string.Format(@"<p>市场价:¥{0}({1})</p>
                       <p>优惠价:¥{2}({3})</p>", maketPrice, priceDetailStr, zkPrice, priceDetailStr);
                this.priceDetailLbl.Text = str;
                this.hid_count.Value     = reserverCount.ToString();
                this.hid_price_sc.Value  = maketPrice.ToString();
                this.hid_price_yh.Value  = zkPrice.ToString();
                this.hid_ticket_id.Value = ticketId.ToString();
                this.hid_price_jj.Value  = providerSpot.SellPrice.ToString();
                HiddenFieldBZ.Value      = str.Replace("<p>", "").Replace("</p>", "");

                LVWEIBA.BLL.MemberHotel          bllhotel = new LVWEIBA.BLL.MemberHotel();
                List <LVWEIBA.Model.MemberHotel> lsthotel = bllhotel.GetModelList(" member='" + userInfo.mobile + "' or member='" + userInfo.openId + "'");
                string strhotel = "";
                foreach (MemberHotel item in lsthotel)
                {
                    strhotel += string.Format(" <input id='Checkbox1' name='hotel' class='hotel' type='checkbox' value='{0}' />{1}", item.Id, item.Name);
                }
                contactPersonsLiteral.Text = strhotel;
            }
        }
    }
示例#5
0
    protected void Page_Load(object sender, EventArgs e)
    {
        UserAuthorizationModel userInfo = UserAuthorization.userLogin(this.Page);

        if (userInfo.openId == null || userInfo.openId == "")
        {
            openid = userInfo.mobile;
        }
        else
        {
            openid = userInfo.openId;
        }

        OnQuery();
    }
示例#6
0
    protected void Page_Load(object sender, EventArgs e)
    {
        UserAuthorizationModel userInfo = UserAuthorization.userLogin(this.Page);

        if (userInfo.openId == null || userInfo.openId == "")
        {
            openid = userInfo.mobile;
        }
        else
        {
            openid = userInfo.openId;
        }
        uid.Value = openid;
        if (!IsPostBack)
        {
            ShowInfo(openid);
        }
    }
示例#7
0
    protected void Page_Load(object sender, EventArgs e)
    {
        UserAuthorizationModel userInfo = UserAuthorization.userLogin(this.Page);

        if (userInfo.openId == null || userInfo.openId == "")
        {
            openid = userInfo.mobile;
        }
        else
        {
            openid = userInfo.openId;
        }
        if (!IsPostBack)
        {
            orderId = Request.QueryString["order_id"];
            //赋值
            showDetailInfo(orderId);
            GetNumbers(orderId);
        }
    }
示例#8
0
    //protected string openid = "";
    protected void Page_Load(object sender, EventArgs e)
    {
        if (Request.QueryString["code"] != null)
        {
            //微信渠道登陆
            UserAuthorizationModel userInfo = UserAuthorization.userLogin(this.Page);
        }
        string  s  = "select top 10 * ,(1000*adultzkPrice/adultTicketPrice) as zk from View_LvLines where enddate >getdate()  order by zk  ";
        DataSet ds = DBCLASSFORWEIXIN.DAL.DbHelperSQL.Query(s, null);

        Repeater1.DataSource = ds.Tables[0];
        Repeater1.DataBind();

        //最新通知
        BaseClass.Model.App_Notices am = new BaseClass.Dal.App_Notices().GetLastModel();
        LabelNotice.Text = am.Title;

        //绑定广告幻灯片
        //DataSet dss = new BaseClass.Dal.App_Ad().GetList("");

        //Repeater2.DataSource = dss.Tables[0];
        //Repeater2.DataBind();
    }
示例#9
0
    protected void Page_Load(object sender, EventArgs e)
    {
        if (!IsPostBack)
        {
            UserAuthorizationModel userInfo = UserAuthorization.userLogin(this.Page);
            if (userInfo.openId == null || userInfo.openId == "")
            {
                openid = userInfo.mobile;
            }
            else
            {
                openid = userInfo.openId;
            }
            Session["openid"] = openid;

            DBCLASSFORWEIXIN.Model.LocalWeixinUser wxmdl = new CheckUserAndUpdate().CheckUserAndInsert(openid, "");

            LVWEIBA.Model.MemberList mmm = new LVWEIBA.Model.MemberList();
            mmm = new LVWEIBA.DAL.MemberList().GetModel(openid);
            if (mmm == null)
            {
                nickname = wxmdl.nickname;
                Tel      = wxmdl.Tel;
                ddl_sex.SelectedValue = wxmdl.sex.ToString();
            }
            else
            {
                nickname              = wxmdl.nickname;
                Tel                   = wxmdl.Tel;
                MemberName            = mmm.MemberName;
                ddl_sex.SelectedValue = wxmdl.sex.ToString();
                Card                  = mmm.Card;
                Mail                  = mmm.Mail;
                Pwd                   = mmm.UserPwd;
            }
        }
    }
示例#10
0
    protected void Page_Load(object sender, EventArgs e)
    {
        UserAuthorizationModel userInfo = UserAuthorization.userLogin(this.Page);

        if (userInfo.openId == null || userInfo.openId == "")
        {
            openid = userInfo.mobile;
        }
        else
        {
            openid = userInfo.openId;
        }
        this.Title = userInfo.name + " 现金账户";
        LVWEIBA.Model.MemberList mmm = new LVWEIBA.Model.MemberList();
        mmm = new LVWEIBA.DAL.MemberList().GetModel(openid);
        if (mmm == null)
        {
            yue = "0.00";
        }
        else
        {
            yue = mmm.Money.ToString();
        }
    }
    protected void Page_Load(object sender, EventArgs e)
    {
        UserAuthorizationModel userInfo = UserAuthorization.userLogin(this.Page);

        if (userInfo.openId == null || userInfo.openId == "")
        {
            openid = userInfo.mobile;
        }
        else
        {
            openid = userInfo.openId;
        }
        Session["openid"] = openid;

        if (IsPostBack)
        {
            string mobile = Request.Form["tel"];
            string code   = Request.Form["code"];

            object codeCache = HttpContext.Current.Cache.Get("code" + mobile);
            if (codeCache == null)
            {
                Jscript.NorefLocation(this.Page, "验证码失效请重新获取!手机号为:" + mobile + "code is:" + code, "CouponForOneThousand.aspx");
            }
            else
            {
                if (code != codeCache.ToString())
                {
                    Jscript.NorefLocation(this.Page, "验证码不正确!", "CouponForOneThousand.aspx");
                }
                else
                {
                    var member = new LVWEIBA.BLL.MemberInfo().GetModel(openid);
                    if (member != null)
                    {
                        if (member.Tel == "" || member.Tel == null)
                        {
                            //更新用户信息
                            var bll = new LVWEIBA.BLL.MemberInfo();
                            member.Tel = mobile.Trim();
                            bll.Update(member);
                            //发放礼券(500一张,300元一张,50元2张,20元5张)
                            LVWEIBA.BLL.MemberCoupon bllCoupon = new LVWEIBA.BLL.MemberCoupon();
                            //20元
                            for (int i = 0; i < 5; i++)
                            {
                                List <LVWEIBA.Model.MemberCoupon> list = new List <LVWEIBA.Model.MemberCoupon>();
                                LVWEIBA.Model.MemberCoupon        mdl  = new LVWEIBA.Model.MemberCoupon();
                                mdl.CouponID = "0020160604000001KBW1";
                                mdl.Userid   = openid;
                                mdl.ZT       = "0";
                                mdl.Count    = 5;
                                mdl.Sj       = DateTime.Now;
                                mdl.Order_Id = "";
                                list.Add(mdl);
                                bllCoupon.SendCouton(list, "0020160604000001KBW1", 1);
                            }
                            //50元
                            for (int i = 0; i < 2; i++)
                            {
                                List <LVWEIBA.Model.MemberCoupon> listForFifty = new List <LVWEIBA.Model.MemberCoupon>();
                                LVWEIBA.Model.MemberCoupon        mdlForFifty  = new LVWEIBA.Model.MemberCoupon();
                                mdlForFifty.CouponID = "0020160604000001L511";
                                mdlForFifty.Userid   = openid;
                                mdlForFifty.ZT       = "0";
                                mdlForFifty.Count    = 2;
                                mdlForFifty.Sj       = DateTime.Now;
                                mdlForFifty.Order_Id = "";
                                listForFifty.Add(mdlForFifty);
                                bllCoupon.SendCouton(listForFifty, "0020160604000001L511", 1);
                            }
                            //300元
                            List <LVWEIBA.Model.MemberCoupon> listForThreeHundred = new List <LVWEIBA.Model.MemberCoupon>();
                            LVWEIBA.Model.MemberCoupon        mdlForThreeHundred  = new LVWEIBA.Model.MemberCoupon();
                            mdlForThreeHundred.CouponID = "002016060400000164Q5";
                            mdlForThreeHundred.Userid   = openid;
                            mdlForThreeHundred.ZT       = "0";
                            mdlForThreeHundred.Count    = 1;
                            mdlForThreeHundred.Sj       = DateTime.Now;
                            mdlForThreeHundred.Order_Id = "";
                            listForThreeHundred.Add(mdlForThreeHundred);
                            bllCoupon.SendCouton(listForThreeHundred, "002016060400000164Q5", 1);
                            //500元
                            List <LVWEIBA.Model.MemberCoupon> listForFiveHundred = new List <LVWEIBA.Model.MemberCoupon>();
                            LVWEIBA.Model.MemberCoupon        mdlForFiveHundred  = new LVWEIBA.Model.MemberCoupon();
                            mdlForFiveHundred.CouponID = "00201606200000011KA9";
                            mdlForFiveHundred.Userid   = openid;
                            mdlForFiveHundred.ZT       = "0";
                            mdlForFiveHundred.Count    = 1;
                            mdlForFiveHundred.Sj       = DateTime.Now;
                            mdlForFiveHundred.Order_Id = "";
                            listForFiveHundred.Add(mdlForFiveHundred);
                            bllCoupon.SendCouton(listForFiveHundred, "00201606200000011KA9", 1);

                            //删除缓存
                            HttpContext.Current.Cache.Remove("code" + mobile);
                            Jscript.NorefLocation(this.Page, "领取成功!", "Coupon.aspx");
                        }
                        else
                        {
                            //删除缓存
                            HttpContext.Current.Cache.Remove("code" + mobile);
                            Jscript.NorefLocation(this.Page, "请先验证手机!", "bindPhone.aspx");
                        }
                    }
                }
            }
        }
    }
示例#12
0
    protected void Page_Load(object sender, EventArgs e)
    {
        UserAuthorizationModel userInfo = UserAuthorization.userLogin(this.Page);

        if (userInfo.openId == null || userInfo.openId == "")
        {
            openid_db = userInfo.mobile;
        }
        else
        {
            openid_db = userInfo.openId;
        }
        //Session["openid"] = openid;

        if (string.IsNullOrEmpty(Request.QueryString["code"]))
        {
            Response.Redirect("https://open.weixin.qq.com/connect/oauth2/authorize?appid=" + GetWeiXinInf.appid + "&redirect_uri=http://wx.lvwei8.com/index/CouponForNinety.aspx&response_type=code&scope=snsapi_base&state=123#wechat_redirect");
        }

        else
        {
            string code = Request.QueryString["code"];
            openid_wx = new WEIxinUserApi().GetUserOpenid(code);
            //Session["openid"] = openid;

            if (openid_wx.Length < 10)
            {
                Response.Redirect("https://open.weixin.qq.com/connect/oauth2/authorize?appid=" + GetWeiXinInf.appid + "&redirect_uri=http://wx.lvwei8.com/index/CouponForNinety.aspx&response_type=code&scope=snsapi_base&state=123#wechat_redirect");
            }
            else
            {
            }
        }

        if (IsPostBack)
        {
            string mobile = Request.Form["tel"];
            string code   = Request.Form["code"];

            object codeCache = HttpContext.Current.Cache.Get("code" + mobile);
            if (codeCache == null)
            {
                Jscript.NorefLocation(this.Page, "验证码失效请重新获取!手机号为:" + mobile + "code is:" + code, "CouponForNinety.aspx");
            }
            else
            {
                if (code != codeCache.ToString())
                {
                    Jscript.NorefLocation(this.Page, "验证码不正确!", "CouponForNinety.aspx");
                }
                else
                {
                    var member = new LVWEIBA.BLL.MemberInfo().GetModel(openid_db);
                    if (member != null)
                    {
                        if (member.Tel == "" || member.Tel == null || openid_db != openid_wx)
                        {
                            //更新用户信息
                            var bll = new LVWEIBA.BLL.MemberInfo();
                            member.Tel    = mobile.Trim();
                            member.openid = openid_wx;
                            bll.Update(member);
                            //发放礼券(50元一张,20元俩张)
                            LVWEIBA.BLL.MemberCoupon bllCoupon = new LVWEIBA.BLL.MemberCoupon();
                            for (int i = 0; i < 2; i++)
                            {
                                List <LVWEIBA.Model.MemberCoupon> list = new List <LVWEIBA.Model.MemberCoupon>();
                                LVWEIBA.Model.MemberCoupon        mdl  = new LVWEIBA.Model.MemberCoupon();
                                mdl.CouponID = "0020160604000001KBW1";
                                mdl.Userid   = openid_wx;
                                mdl.ZT       = "0";
                                mdl.Count    = 2;
                                mdl.Sj       = DateTime.Now;
                                mdl.Order_Id = "";
                                list.Add(mdl);
                                bllCoupon.SendCouton(list, "0020160604000001KBW1", 1);
                            }
                            //50元
                            List <LVWEIBA.Model.MemberCoupon> listForFifty = new List <LVWEIBA.Model.MemberCoupon>();
                            LVWEIBA.Model.MemberCoupon        mdlForFifty  = new LVWEIBA.Model.MemberCoupon();
                            mdlForFifty.CouponID = "0020160604000001L511";
                            mdlForFifty.Userid   = openid_wx;
                            mdlForFifty.ZT       = "0";
                            mdlForFifty.Count    = 1;
                            mdlForFifty.Sj       = DateTime.Now;
                            mdlForFifty.Order_Id = "";
                            listForFifty.Add(mdlForFifty);
                            bllCoupon.SendCouton(listForFifty, "0020160604000001L511", 1);
                            //删除缓存
                            HttpContext.Current.Cache.Remove("code" + mobile);
                            Jscript.NorefLocation(this.Page, "领取成功!", "Coupon.aspx");
                        }
                        else
                        {
                            //删除缓存
                            HttpContext.Current.Cache.Remove("code" + mobile);
                            Jscript.NorefLocation(this.Page, "该手机号已经验证过!", "CouponForNinety.aspx");
                        }
                    }
                }
            }
        }
    }
示例#13
0
    protected void Page_Load(object sender, EventArgs e)
    {
        int lineid = (string.IsNullOrEmpty(Request.QueryString["lineid"]) ? 0 : int.Parse(Request.QueryString["lineid"]));
        UserAuthorizationModel userInfo = UserAuthorization.userLogin(this.Page);

        if (userInfo.openId == null || userInfo.openId == "")
        {
            openid = userInfo.mobile;
        }
        else
        {
            openid = userInfo.openId;
        }

        string oid = Request.QueryString["ddbm"];

        log4netHelper.WriteDebugLog(typeof(index_indent_pay), "indent_pay", "进入支付 orderid is:" + oid + "用户Id:" + openid);
        LVWEIBA.Model.order_list oom = new LVWEIBA.Model.order_list();
        oom = new LVWEIBA.DAL.order_list().GetModel(oid);
        LVWEIBA.Model.order_Mx omm = new LVWEIBA.DAL.order_Mx().GetModel(oid);
        string typeObject          = omm.ProType;

        if (!String.IsNullOrEmpty(typeObject))
        {
            if (typeObject.Equals("DZP"))
            {
                type = "mp";
            }
            else
            {
                type = "wd";
            }
        }
        //BaseClass.Common.LoggerUtil.printLog("type is:" + type);
        shichangjia = omm.market_price.ToString();
        youhuijia   = omm.Transaction_price.ToString();
        LVWEIBA.Model.MemberList mmm = new LVWEIBA.Model.MemberList();
        mmm = new LVWEIBA.DAL.MemberList().GetModel(openid);
        if (mmm == null)
        {
            moneyLeft = "0.00";
        }
        else
        {
            moneyLeft = mmm.Money.ToString();
        }
        LVWEIBA.DAL.LvULines   dallines = new LVWEIBA.DAL.LvULines();
        LVWEIBA.Model.LvULines mlines   = dallines.GetModel(omm.productNum);           //根据订单明细的线路编号获取线路的类别
        if ((mlines != null && mlines.Kindof.Equals("jianhang")) || type.Equals("mp")) //建行分期或门票
        {
            HiddenFieldchctt.Value = omm.Transaction_price.ToString().Replace(".", "");
            Label1.Text            = omm.Transaction_price.ToString();//优惠价
            lbl_scsm.Text          = "";
            lbl_yhsm.Text          = "(支付时直接按优惠价价支付)";
            type = "jh";
        }
        else
        {
            lbl_scsm.Text          = "(支付时按市场价支付)";
            lbl_yhsm.Text          = "(返还差价之后的实际成交价)";
            lbl_zyts.Text          = @"          重要提示:该产品按市场价支付,旅行结束后48小时内
驴尾巴网将差价返还至会员现金账户,会员可自由选择提现
或二次消费。";
            HiddenFieldchctt.Value = omm.market_price.ToString().Replace(".", "");
            Label1.Text            = omm.market_price.ToString();//市场价
        }
        if (type == null)
        {
            type = "default";
        }
        HUserHostAddress = Page.Request.UserHostAddress;
        //HiddenFieldchctt.Value = omm.Transaction_price.ToString().Replace(".", "");
        //Label1.Text = omm.Transaction_price.ToString();
        this.hid_order_id.Value   = oid;
        this.hid_order_type.Value = type;
    }
示例#14
0
    protected void Page_Load(object sender, EventArgs e)
    {
        UserAuthorizationModel userInfo = UserAuthorization.userLogin(this.Page);
        //if (userInfo.openId == null || userInfo.openId == "")
        //{
        //    member = userInfo.mobile;
        //}
        //else
        //{
        //    member = userInfo.openId;
        //}
        //int adult = (string.IsNullOrEmpty(Request.QueryString["adult"]) ? 0 : int.Parse(Request.QueryString["adult"]));
        //int children = (string.IsNullOrEmpty(Request.QueryString["children"]) ? 0 : int.Parse(Request.QueryString["children"]));
        //lineid = (string.IsNullOrEmpty(Request.QueryString["lineid"]) ? 0 : int.Parse(Request.QueryString["lineid"]));
        //adultCount = adult;
        //puppyCount = children;
        //if (!IsPostBack)
        //{
        //    LVWEIBA.BLL.LvULines bll = new LVWEIBA.BLL.LvULines();
        //    LVWEIBA.Model.LvULines model = bll.GetModel(lineid);
        //    ViewState["lineid"] = lineid;
        //    if (model != null)
        //    {
        //        // DataTable dtlb = LVWEIBA.DAL.Common.GetCplb();
        //        //DataRow[] drlb= dtlb.Select("bm='" + model.Kindof + "'");
        //        //hid_lb.Value = drlb[0]["value"].ToString();
        //        hid_pronum.Value = model.ProNumCode;
        //        this.lbl_ProName.Text = model.TTl;
        //        this.lbl_ProNum.Text = model.ProNumCode;
        //        string ydrs = "";
        //        string scine = "";
        //        string yhine = "";
        //        int scPrice = 0;
        //        int yhPrice = 0;
        //        int jjPrice = 0;
        //        if (adult > 0)
        //        {
        //            scine += "成人¥" + model.adultTicketPrice + "x" + adult + ";";
        //            yhine += "成人¥" + model.adultzkPrice + "x" + adult + ";";
        //            ydrs += " 成人*" + adult;
        //            scPrice += Convert.ToInt32(model.adultTicketPrice) * adult;
        //            yhPrice += Convert.ToInt32(model.adultzkPrice) * adult;
        //            jjPrice += Convert.ToInt32(model.adultSellPrice) * adult;
        //        }
        //        if (children > 0)
        //        {
        //            scine += "儿童¥" + model.puppyTicketPrice + "x" + children + ";";
        //            yhine += "儿童¥" + model.puppyzkCount + "x" + children + ";";
        //            ydrs += " 儿童*" + children;
        //            scPrice += Convert.ToInt32(model.puppyTicketPrice) * children;
        //            yhPrice += Convert.ToInt32(model.puppyzkCount) * children;
        //            jjPrice += Convert.ToInt32(model.puppySellPrice) * adult;
        //        }
        //        this.lbl_Ydrs.Text = ydrs;
        //        this.lbl_Cfcity.Text = model.Splace;
        //        this.lbl_Cfdate.Text = Convert.ToDateTime(model.Sdate).ToString("yyyy-MM-dd");
        //        string str = string.Format(@"<p>市场价:¥{0}({1})</p>
        //               <p>优惠价:¥{2}({3})</p>", scPrice, scine, yhPrice, yhine);

        //        this.hid_price_sc.Value = scPrice.ToString();
        //        this.hid_price_yh.Value = yhPrice.ToString();
        //        this.hid_price_jj.Value = jjPrice.ToString();
        //        this.hid_count.Value = (adult + children).ToString();
        //        this.li_jine.Text = str;
        //        lbl_DDjE.Text = "¥" + yhPrice;
        //        HiddenFieldBZ.Value = str.Replace("<p>", "").Replace("</p>", "");
        //        LVWEIBA.BLL.MemberHotel bllhotel = new LVWEIBA.BLL.MemberHotel();
        //        List<LVWEIBA.Model.MemberHotel> lsthotel = bllhotel.GetModelList(" member='" + member + "'");
        //        string strhotel = "";
        //        foreach (MemberHotel item in lsthotel)
        //        {
        //            strhotel += string.Format(" <input id='Checkbox1' name='hotel' class='hotel' type='checkbox' value='{0}' />{1}", item.Id, item.Name);
        //        }
        //       // Literal1.Text = strhotel;

        //    }

        //}
        //Label1.Text = "";
        //Label1.Text = Request.ServerVariables["HTTP_HOST"] + Request.ServerVariables["SCRIPT_NAME"];
    }
示例#15
0
    protected void Page_Load(object sender, EventArgs e)
    {
        UserAuthorizationModel userInfo = UserAuthorization.userLogin(this.Page);

        if (userInfo.openId == null || userInfo.openId == "")
        {
            openId = userInfo.mobile;
        }
        else
        {
            openId = userInfo.openId;
        }
        //商户订单号,商户网站订单系统中唯一订单号,必填
        string out_trade_no = Request.QueryString["orderid"].Trim();

        //付款金额,必填
        string total_fee = Request.QueryString["feee"].Trim();

        //收银台页面上,商品展示的超链接,必填
        string show_url = "http://lvwei8.com/index/showline.aspx?code=160928113527452356B&lineid=656";

        //商品描述,可空
        string jinbi        = Request.QueryString["jinbi"].Trim();
        string couponId     = Request.QueryString["couponid"].Trim();
        string useMoneyLeft = Request.QueryString["usemoneyleft"].Trim();


        Response.ContentType = "text/html;charset=utf-8";
        moneyFreeze(useMoneyLeft, out_trade_no, openId);
        //使用优惠券(加入订单号)
        if (couponId != "0")
        {
            LVWEIBA.BLL.MemberCoupon coupon = new LVWEIBA.BLL.MemberCoupon();
            int id = int.Parse(couponId);
            LVWEIBA.Model.MemberCoupon couponModel = coupon.GetModel(id);
            couponModel.Order_Id = out_trade_no;
            couponModel.ZT       = "1";//变为已使用
            coupon.Update(couponModel);
        }
        try
        {
            //把请求参数打包成数组
            SortedDictionary <string, string> sParaTemp = new SortedDictionary <string, string>();
            sParaTemp.Add("partner", Config.partner);
            sParaTemp.Add("seller_id", Config.seller_id);
            sParaTemp.Add("_input_charset", Config.input_charset.ToLower());
            sParaTemp.Add("service", Config.service);
            sParaTemp.Add("payment_type", Config.payment_type);
            sParaTemp.Add("notify_url", Config.notify_url);
            sParaTemp.Add("return_url", Config.return_url);
            sParaTemp.Add("out_trade_no", out_trade_no);
            sParaTemp.Add("subject", "驴尾巴商品");
            sParaTemp.Add("total_fee", total_fee);
            sParaTemp.Add("show_url", show_url);
            //sParaTemp.Add("app_pay","Y");//启用此参数可唤起钱包APP支付。
            sParaTemp.Add("body", openId);
            //其他业务参数根据在线开发文档,添加参数.文档地址:https://doc.open.alipay.com/doc2/detail.htm?spm=a219a.7629140.0.0.2Z6TSk&treeId=60&articleId=103693&docType=1
            //如sParaTemp.Add("参数名","参数值");
            //建立请求
            log4netHelper.WriteDebugLog(typeof(index_control_AliPayHandler), "index_control_AliPayHandler", "orderid is:" + out_trade_no + "total_fee:" + total_fee + "paramters: " + sParaTemp.ToString());
            submitLit.Text = Submit.BuildRequest(sParaTemp, "get", "确认");
        }
        catch (Exception ex)
        {
            log4netHelper.WriteExceptionLog(typeof(index_control_AliPayHandler), "index_control_AliPayHandler Error", ex);
        }
    }