/// <summary> /// 授权判断,页面跳转 /// </summary> /// <param name="state"></param> /// <param name="targetUrl">目标地址</param> public void OAuth2BaseProc(Model.wx_userweixin model, string state, string targetUrl) { BLL.wx_property_info propertyBll = new BLL.wx_property_info(); Model.wx_property_info propertyEntity = propertyBll.GetModelByIName(wid, MXEnums.WXPropertyKeyName.OpenOauth.ToString()); if (propertyEntity.iContent == "0") { //关闭了网页授权 openid = MyCommFun.RequestOpenid(); } else { string code = MyCommFun.QueryString("code"); if (code == null || code.Trim() == "") { if (targetUrl == null || targetUrl.Trim() == "") { targetUrl = MyCommFun.getTotalUrl(); } //thisUrl = MyCommFun.getWebSite() + "/weixin/huodong/index.aspx"; string newUrl = OAuthApi.GetAuthorizeUrl(model.AppId, targetUrl, state, OAuthScope.snsapi_base); // WXLogs.AddLog(model.id, "OAuth授权跳转页面", "获得OAuth2BaseProc", newUrl); Response.Redirect(newUrl); } else { var result = OAuthApi.GetAccessToken(model.AppId, model.AppSecret, code); openid = result.openid; } } }
protected void Page_Load(object sender, EventArgs e) { if (!Page.IsPostBack) { openid = MyCommFun.QueryString("openid"); aid = MyCommFun.RequestInt("aid"); shopid = MyCommFun.RequestInt("shopid"); shopinfo = shopBll.GetModel(shopid); hotelName = shopinfo.hotelName; idf = MyCommFun.RequestInt("id"); if (idf != 0) { member = menberbll.GetModel(idf); name = member.memberName; phone = member.menberTel; this.note.InnerText = member.memberAddress; } categories = "{"; DataSet category1 = categorybll.GetList(shopid); if (category1.Tables[0].Rows.Count > 0) { for (int i = 0; i < category1.Tables[0].Rows.Count; i++) { categories += "\"" + category1.Tables[0].Rows[i]["id"].ToString() + "\"" + ":" + "\"" + category1.Tables[0].Rows[i]["categoryName"].ToString() + "\"" + ","; } } categories = categories.Substring(0, categories.Length - 1); categories += "}"; } }
public void ProcessRequest(HttpContext context) { context.Response.ContentType = "text/json"; string action = MXRequest.GetQueryString("myact"); if (action == "upStock") { BLL.wx_shop_product spBll = new BLL.wx_shop_product(); BLL.orders oBll = new BLL.orders(); try { string orderno = MyCommFun.QueryString("order_no"); //根据订单号得到订单 Model.orders oModel = oBll.GetModelByNo(orderno); //得到所有订购商品 List <Model.order_goods> ogList = oModel.order_goods; //根据订购商品的数量修改库存 foreach (Model.order_goods item in ogList) { Model.wx_shop_product spModel = spBll.GetModel(item.goods_id); spModel.stock = spModel.stock - item.quantity; spBll.Update(spModel); } context.Response.Write("{\"status\": 1, \"msg\": \"库存操作成功!\"}"); return; } catch (Exception) { context.Response.Write("{\"status\": 0, \"msg\": \"库存操作失败!\"}"); return; } } }
protected void Page_Load(object sender, EventArgs e) { hotelid = MyCommFun.RequestInt("hotelid"); openid = MyCommFun.QueryString("openid"); if (!Page.IsPostBack) { BLL.wx_hotel_dingdan dingdanbll = new BLL.wx_hotel_dingdan(); DataSet dr = dingdanbll.GetList(openid, hotelid); if (dr.Tables[0].Rows.Count > 0) { dingdannum = dr.Tables[0].Rows.Count; numdingdan = " <ul class=\"round\">"; numdingdan += "<li><a href=\"hotel_order.aspx?openid=" + openid + "&hotelid=" + hotelid + "\"> "; numdingdan += "<span>我的订单<em class=\"ok\">" + dr.Tables[0].Rows.Count + "</em></span></a></li>"; numdingdan += " </ul>"; } else { numdingdan = ""; } if (hotelid != 0) { hoteList(hotelid); } } }
private void RptBind(string _strWhere, string _orderby, int id) { Model.wx_userweixin weixin = GetWeiXinCode(); string typeid = MyCommFun.QueryString("typeid"); if (typeid == "all" || typeid == "") { _strWhere = "baseid=" + id + " " + _strWhere; } else { ddlProperty.SelectedValue = typeid; string status = typeid == "w" ? "0" : "2"; _strWhere = "baseid=" + id + " and [STATUS]=" + status + " " + _strWhere; } this.page = MXRequest.GetQueryInt("page", 1); txtKeywords.Text = this.keywords; DataSet ds = gbll.GetList(this.pageSize, this.page, _strWhere, _orderby, out this.totalCount); this.rptList.DataSource = ds; this.rptList.DataBind(); //绑定页码 txtPageNum.Text = this.pageSize.ToString(); string pageUrl = Utils.CombUrlTxt("manageSN.aspx", "keywords={0}&id={1}&typeid={2}&page={3}", this.keywords, id.ToString(), typeid, "__id__"); PageContent.InnerHtml = Utils.OutPageList(this.pageSize, this.page, this.totalCount, pageUrl, 8); txtKeywords.Text = keywords; }
protected void Page_Load(object sender, EventArgs e) { if (!Page.IsPostBack) { shopid = MyCommFun.RequestInt("shopid"); openid = MyCommFun.QueryString("openid"); dingdan = MyCommFun.RequestInt("dingdan"); wid = MyCommFun.RequestInt("wid"); refundCode = MyCommFun.QueryString("RefundCode"); var shopinfo = new BLL.wx_diancai_shopinfo().GetModel(shopid); RestruantName = shopinfo.hotelName; RestruantLocation = shopinfo.address; rename = shopinfo.dcRename; if (dingdan > 0) { if (shopinfo.xplace != null) { lat = Convert.ToDouble(shopinfo.xplace.Value); } if (shopinfo.yplace != null) { lng = Convert.ToDouble(shopinfo.yplace.Value); } BindOrderDetaile(); } } }
protected void save_groupbase_Click(object sender, EventArgs e) { id = MyCommFun.QueryString("id"); shopid = MyCommFun.RequestInt("shopid"); string status = ddlStatusType.SelectedItem.Value; managebll.Updatestatus(id, status); manage = managebll.GetModel(MyCommFun.Str2Int(id)); BLL.wx_diancai_member menbll = new BLL.wx_diancai_member(); if (status == "1") { menbll.Update(manage.openid); } if (status == "2") { menbll.Updatefail(manage.openid); } AddAdminLog(MXEnums.ActionEnum.Edit.ToString(), "修改支付状态,主键为" + id); //记录日志 JscriptMsg("修改成功!", "dingdan_manage.aspx?shopid=" + shopid + "", "Success"); }
protected void Page_Load(object sender, EventArgs e) { if (!Page.IsPostBack) { BLL.wx_diancai_shopinfo shopBll = new BLL.wx_diancai_shopinfo(); shopid = MyCommFun.RequestInt("shopid"); openid = MyCommFun.QueryString("openid"); shopinfo = shopBll.GetModel(shopid); hotelName = shopinfo.hotelName; rename = shopinfo.dcRename; BLL.wx_diancai_member menberbll = new BLL.wx_diancai_member(); IList <Model.wx_diancai_member> memlist = menberbll.GetModelList("shopid=" + shopid + " and openid='" + openid + "'"); if (memlist == null || memlist.Count <= 0 || memlist[0] == null) { } else { username = memlist[0].Name; usertel = memlist[0].menberTel; useraddr = memlist[0].memberAddress; } } }
protected void Page_Load(object sender, EventArgs e) { id = MyCommFun.RequestInt("hotelid"); action = MyCommFun.QueryString("action"); if (!string.IsNullOrEmpty(action) && action == MXEnums.ActionEnum.Edit.ToString()) { if (id <= 0) { JscriptMsg("传输参数不正确!", "back", "Error"); return; } if (!new BLL.wx_diancai_shopinfo().Exists(id)) { JscriptMsg("记录不存在或已被删除!", "back", "Error"); return; } } if (!IsPostBack) { if (action == MXEnums.ActionEnum.Edit.ToString()) { ShowInfo(id); } } }
/// <summary> /// 授权判断,页面跳转 /// </summary> /// <param name="state"></param> /// <param name="targetUrl">目标地址</param> public void OAuth2BaseProc(Model.wx_userweixin model, string state, string targetUrl) { var code = MyCommFun.QueryString("code"); openid = MyCommFun.QueryString("openid"); if (!string.IsNullOrEmpty(openid)) { return; } //如果不存在code,表示尚未和微信平台OAuth2 if (string.IsNullOrEmpty(code)) { if (targetUrl == null || targetUrl.Trim() == "") { targetUrl = MyCommFun.getTotalUrl(); } var newUrl = OAuthApi.GetAuthorizeUrl(model.AppId, targetUrl, state, OAuthScope.snsapi_base); Response.Redirect(newUrl); } else { var result = OAuthApi.GetAccessToken(model.AppId, model.AppSecret, code); Response.Redirect(string.Format("{0}&openid={1}", Request.Url, result.openid)); } }
public void ProcessRequest(HttpContext context) { context.Response.ContentType = "text/json"; string _action = MyCommFun.QueryString("myact"); int wid = MyCommFun.RequestInt("wid"); if (_action == "search") { Dictionary <string, string> jsonDict = new Dictionary <string, string>(); BLL.wx_my_user bll = new BLL.wx_my_user(); string name = MyCommFun.QueryString("name"); int result = bll.GetRecordCount(" username='******' and wid=" + wid); if (result > 0) { int id = bll.GetModelList(" username='******' and wid=" + wid)[0].id; jsonDict.Add("sys", "0"); jsonDict.Add("content", id.ToString() + "&wid=" + wid); context.Response.Write(MyCommFun.getJsonStr(jsonDict)); return; } jsonDict.Add("sys", "err"); jsonDict.Add("content", "此用户不存在"); context.Response.Write(MyCommFun.getJsonStr(jsonDict)); return; } if (_action == "") { Dictionary <string, string> jsonDict = new Dictionary <string, string>(); return; } }
protected void Page_Load(object sender, EventArgs e) { shopid = MyCommFun.RequestInt("shopid"); openid = MyCommFun.QueryString("openid"); dingdan = MyCommFun.QueryString("dingdan"); if (!Page.IsPostBack) { sjopmodel = shopbll.GetModel(shopid); hotelName = sjopmodel.hotelName; rename = sjopmodel.dcRename; type = MyCommFun.QueryString("type"); if (type == "delete") { if (manage.Delete(dingdan)) { contact_info.Style.Add("display", "none"); showcard.Style.Add("display", "none"); showcard.HRef = "#"; return; } else { showcard.HRef = "diancai_dingdan.aspx?dingdan=" + dingdan + "&type=delete&shopid=" + shopid + "&openid=" + openid; } } if (dingdan != "") { List(dingdan); } } }
protected void Page_Load(object sender, EventArgs e) { bll = new AppInfoService(); aBll = new WXAgentService(new AgentRepository()); adminEntity = GetAdminInfo(); //取得管理员信息 agent = aBll.GetAgentModel(adminEntity.Id); if (!Page.IsPostBack) { int id = 0; if (!int.TryParse(Request.QueryString["id"] as string, out id)) { JscriptMsg("传输参数不正确!", "back", "Error"); return; } if (!bll.Exists(id)) { JscriptMsg("记录不存在或已被删除!", "back", "Error"); return; } returnPage = "wxcodemgr.aspx"; //如果是从微用户管理里来的,还得判断下 if (MyCommFun.QueryString("fpage").Trim().Length > 0 && MyCommFun.RequestInt("uid") > 0) { returnPage = "weixin_list.aspx?id=" + MyCommFun.RequestInt("uid"); } ShowInfo(id); } }
public void ProcessRequest(HttpContext context) { context.Response.ContentType = "text/json"; string _action = MyCommFun.QueryString("myact"); int id = MyCommFun.RequestInt("id"); string openid = MyCommFun.RequestOpenid(); //得到微信用户的openid if (_action == "zf") { //转发 Dictionary <string, string> jsonDict = new Dictionary <string, string>(); BLL.wx_cards_gl countgbll = new BLL.wx_cards_gl(); Model.wx_cards_gl cardscountg = new Model.wx_cards_gl(); BLL.wx_cards gbll = new BLL.wx_cards(); gbll.update(id); //转发记录 cardscountg.cardsid = id; cardscountg.openid = MyCommFun.QueryString("openid"); countgbll.Add(cardscountg); jsonDict.Add("error", "ok"); jsonDict.Add("content", "ok"); context.Response.Write(MyCommFun.getJsonStr(jsonDict)); } }
private Model.wx_hotel_dingdan CreateOrder() { var dingdan = new Model.wx_hotel_dingdan { hotelid = Convert.ToInt32(MyCommFun.QueryString("hotelid")), roomid = Convert.ToInt32(MyCommFun.QueryString("roomid")), createDate = DateTime.Now, openid = MyCommFun.QueryString("openid"), oderName = MyCommFun.QueryString("oderName"), tel = MyCommFun.QueryString("tel"), orderStatus = 0, IdentityNumber = MyCommFun.QueryString("identityNumber"), arriveTime = Convert.ToDateTime(MyCommFun.QueryString("arriveTime")), leaveTime = Convert.ToDateTime(MyCommFun.QueryString("leaveTime")), roomType = MyCommFun.QueryString("roomType"), orderTime = DateTime.Now, orderNum = MyCommFun.RequestInt("orderNum"), isDelete = 0, price = MyCommFun.Str2Decimal(MyCommFun.QueryString("price")), yuanjia = MyCommFun.Str2Decimal(MyCommFun.QueryString("yuanjia")), remark = MyCommFun.QueryString("remark"), OrderNumber = "H" + DateTime.Now.ToString("yyyyMMddHHmmssffff") + Utils.Number(5) }; dingdan.id = new BLL.wx_hotel_dingdan().Add(dingdan); return(dingdan); }
override protected void OnInit(EventArgs e) { base.OnInit(e); if (errInitTemplates != "") { Response.Write(errInitTemplates); return; } //1获得模版基本信息 BLL.wx_module_templates tBll = new BLL.wx_module_templates(); templateFileName = tBll.GetTemplatesFileNameByWid("shop", wid); if (templateFileName == null || templateFileName.Trim() == "") { errInitTemplates = "不存在该帐号或者该帐号尚未设置模版!"; Response.Write(errInitTemplates); Response.End(); return; } string _action = MyCommFun.QueryString("myact"); if (_action == "editAddr") { EditAddr(); } serverPath = MyCommFun.GetRootPath() + "/shop/templates/" + templateFileName + "/editaddr.html"; ShopTemplateMgr template = new ShopTemplateMgr("/shop/templates/" + templateFileName, serverPath, wid); template.tType = TemplateType.editaddr; template.openid = MyCommFun.RequestOpenid(); template.OutPutHtml(wid); }
protected void Page_Load(object sender, EventArgs e) { hotelid = MyCommFun.RequestInt("hotelid"); openid = MyCommFun.QueryString("openid"); dingdanid = MyCommFun.QueryString("dingdanid"); roomid = MyCommFun.RequestInt("roomid"); if (!IsPostBack) { BLL.wx_hotels_info infobll = new BLL.wx_hotels_info(); Model.wx_hotels_info info = new Model.wx_hotels_info(); info = infobll.GetModel(hotelid); image = info.topPic; BLL.wx_hotel_dingdan dingdanbll = new BLL.wx_hotel_dingdan(); DataSet dr = dingdanbll.GetList(openid, hotelid); if (dr.Tables[0].Rows.Count > 0) { numdingdan = dr.Tables[0].Rows.Count; } else { numdingdan = 0; } this.dingdanidnum.Value = dingdanid; getdingdan(dingdanid); } }
/// <summary> /// 1 授权判断,页面跳转; /// 2 获取openid /// </summary> /// <param name="model"></param> /// <param name="state"></param> /// <param name="targetUrl">目标地址</param> public void OAuth2BaseProc(Model.wx_userweixin model, string state, string targetUrl) { string isTest = MyCommFun.getAppSettingValue("isOAuthTest"); if (isTest == "1") { openid = MyCommFun.RequestOpenid(); return; } string code = MyCommFun.QueryString("code"); if (code == null || code.Trim() == "") { if (targetUrl == null || targetUrl.Trim() == "") { targetUrl = MyCommFun.getTotalUrl(); } //thisUrl = MyCommFun.getWebSite() + "/weixin/huodong/index.aspx"; string newUrl = OAuthApi.GetAuthorizeUrl(model.AppId, targetUrl, state, OAuthScope.snsapi_base); Response.Redirect(newUrl); } else { if (MyCommFun.getCookie("cookie_openid") == "") { var result = OAuthApi.GetAccessToken(model.AppId, model.AppSecret, code); openid = result.openid; MyCommFun.setCookie("cookie_openid", openid, 100); } openid = MyCommFun.getCookie("cookie_openid"); } }
protected void Page_Load(object sender, EventArgs e) { wid = MyCommFun.RequestInt("wid"); fid = MyCommFun.RequestInt("fid"); id = MyCommFun.RequestInt("id"); int pid = MyCommFun.RequestInt("pid"); openid = MyCommFun.QueryString("openid"); if (!IsPostBack) { BLL.wx_fc_panorama pBll = new BLL.wx_fc_panorama(); Model.wx_fc_panorama pModel = null; if (pid != 0)//当页面从户型页面过来 { id = getPid(pid); pModel = pBll.GetModel(MyCommFun.Obj2Int(id)); } else//当页面从全景图页面过来 { pModel = pBll.GetModel(MyCommFun.Obj2Int(id)); } title = pModel.jdname; this.Title = title; } }
protected void Page_Load(object sender, EventArgs e) { richengid = MyCommFun.RequestInt("rcid"); bisaiid = MyCommFun.RequestInt("id"); type = MyCommFun.QueryString("type"); if (!IsPostBack) { //获取球队 Model.wx_userweixin weixin = GetWeiXinCode(); wid = weixin.id; qiudui1(); qiudui2(); if (type == "edite") { bisai = bisaibll.GetModel(bisaiid); if (bisai != null) { this.bsPic.Text = bisai.bsPic; this.bsRemark.InnerText = bisai.bsRemark; this.qd1Id.SelectedValue = bisai.qd1Id.ToString(); this.qd2Id.SelectedValue = bisai.qd2Id.ToString(); this.beginDate.Text = bisai.beginDate.ToString(); this.endDate.Text = bisai.endDate.ToString(); this.jcBeginDate.Text = bisai.jcBeginDate.ToString(); this.jcEndDate.Text = bisai.jcEndDate.ToString(); } } } }
protected void Page_Load(object sender, EventArgs e) { if (!Page.IsPostBack) { // ChkAdminLevel("site_config", MXEnums.ActionEnum.View.ToString()); //检查权限 string act = MyCommFun.QueryString("act"); lblact.Text = act; if (act == "subscribe") { lblreqestType.Text = "6"; //关注时 litNowPosition.Text = "关注时回复"; litNowPosition2.Text = "关注时回复"; } else if (act == "default") { lblreqestType.Text = "0"; //默认回复 litNowPosition.Text = "默认回复"; litNowPosition2.Text = "默认回复"; } else if (act == "canel") { lblreqestType.Text = "7"; //取消关注时 litNowPosition.Text = "取消关注时回复"; litNowPosition2.Text = "取消关注时回复"; } ShowInfo(); } }
protected void Page_Load(object sender, EventArgs e) { openid = MyCommFun.QueryString("openid"); id = MyCommFun.RequestInt("id"); status = MyCommFun.RequestInt("status"); blackName = MyCommFun.QueryString("blackName"); shopid = MyCommFun.RequestInt("shopid"); }
private void EditAddr() { string openid = MyCommFun.RequestOpenid(); //得到微信用户的openid string name = MyCommFun.QueryString("name"); int wid = MyCommFun.RequestInt("wid"); string sprovince = MyCommFun.QueryString("pvid"); string scity = MyCommFun.QueryString("ctid"); string regionId = MyCommFun.QueryString("regionId"); string address = MyCommFun.QueryString("address"); string mobile = MyCommFun.QueryString("mobile"); BLL.wx_shop_user_addr addrBll = new BLL.wx_shop_user_addr(); List <WechatBuilder.Model.wx_shop_user_addr> addrlist = addrBll.GetOpenidAddr(openid, wid); WechatBuilder.Model.wx_shop_user_addr addr = new Model.wx_shop_user_addr(); bool isAdd = true; if (addrlist == null || addrlist.Count <= 0) { //添加 isAdd = true; } else { //修改 addr = addrlist[0]; isAdd = false; } addr.addrDetail = address; addr.wid = wid; addr.openid = openid; addr.province = sprovince; addr.city = scity; addr.area = regionId; addr.tel = mobile; addr.contractPerson = name; addr.createDate = DateTime.Now; if (isAdd) { addrBll.Add(addr); } else { addrBll.Update(addr); } string frompage = MyCommFun.QueryString("frompage"); if (frompage != "") { Response.Redirect(frompage + "?wid=" + wid + "&openid=" + openid); } else { Response.Redirect("editaddr.aspx?wid=" + wid + "&openid=" + openid); } }
protected void Page_Load(object sender, EventArgs e) { if (!Page.IsPostBack) { aid = MyCommFun.RequestInt("aid"); shopid = MyCommFun.RequestInt("shopid"); openid = MyCommFun.QueryString("openid"); } }
protected void Page_Load(object sender, EventArgs e) { openid = MyCommFun.QueryString("openid"); if (!IsPostBack) { getlist(); } }
//数据绑定 private void RptBind() { BLL.wx_product_type bll = new BLL.wx_product_type(); Model.wx_userweixin weixin = GetWeiXinCode(); string keywords = MyCommFun.QueryString("keywords"); int pid = MyCommFun.RequestInt("pid"); string whereStr = "wid=" + weixin.id; if (keywords.Trim().Length > 0) { whereStr += " and tName like '%" + keywords.Trim() + "%'"; } if (pid > 0) { whereStr += " and store_id=" + pid; } DataSet ds = bll.GetList(whereStr); if (ds == null || ds.Tables.Count <= 0) { return; } DataTable dt = ds.Tables[0]; if (dt != null) { DataRow dr; for (int i = 0; i < dt.Rows.Count; i++) { dr = dt.Rows[i]; if (dr["icoPic"] != null && dr["icoPic"].ToString().Trim() != "") { if (dr["icoPic"].ToString().Contains(".")) { dr["icoPic"] = "<img src=\"" + dr["icoPic"].ToString() + "\" class=\"imgico\" />"; } else { dr["icoPic"] = "<span class=\"" + dr["icoPic"].ToString() + "\" />"; } } //链接处理,待做 if (dr["tUrl"] != null && dr["tUrl"].ToString().Trim() != "") { dr["tUrl"] = "<span class=\"lianjie_wai\">[外]</span>" + " <a href=\"javascript:;\">" + dr["tUrl"] + "</a>"; } else { dr["tUrl"] = "<span class=\"lianjie_ben\">[本]</span>" + " <a href=\"javascript:;\">" + MyCommFun.getWebSite() + "/weixin/product/index.aspx?wid=" + MyCommFun.ObjToStr(dr["wid"]) + "&tid=" + dr["id"] + "</a>"; } } } this.rptList.DataSource = dt; this.rptList.DataBind(); }
protected void Page_Load(object sender, EventArgs e) { wid = MyCommFun.RequestInt("wid"); //授权 BLL.wx_userweixin bll = new BLL.wx_userweixin(); Model.wx_userweixin wxModel = bll.GetModel(wid); string code = MyCommFun.QueryString("code"); if (code == null || code.Trim() == "") { string thisUrl = MyCommFun.getTotalUrl(); string newUrl = OAuthApi.GetAuthorizeUrl(wxModel.AppId, thisUrl, "fukuan", OAuthScope.snsapi_base); Response.Redirect(newUrl); } else { var result = OAuthApi.GetAccessToken(wxModel.AppId, wxModel.AppSecret, code); openid = result.openid; } //授权结束 // logBll.AddLog("【微支付】微信预定", "paypage.aspx Page_Load", " 授权结束openid= " + openid, 1); try { int otid = MyCommFun.RequestInt("orderid"); otid_str = otid.ToString(); rpage = "/api/payment/paypage.aspx?showwxpaytitle=1&paytype=shop&wid=" + wid + "&openid=" + openid + "&orderid=" + otid_str; if (code == null || code.Trim() == "" || openid == "" || otid == 0 || wid == 0) { return; } //expireMinute = MyCommFun.RequestInt("expireminute"); //if (expireMinute == 0) //{ // expireMinute = 30; //} //else if (expireMinute == -1) //{ //如果为-1,则有限期间为1年 // expireMinute = 60 * 12 * 365; //} BLL.orders otBll = new BLL.orders(); Model.orders orderEntity = otBll.GetModel(otid, wid); WXLogs.AddLog("【微支付】微信预定", "paypage.aspx Page_Load", "orderEntity.order_no: " + orderEntity.order_no + "|orderEntity.order_amount:" + orderEntity.order_amount, 1); litout_trade_no.Text = orderEntity.order_no; litMoney.Text = orderEntity.order_amount.ToString(); litDate.Text = orderEntity.add_time.ToString(); //WxPayData(orderEntity.order_amount, orderEntity.id.ToString(), orderEntity.order_no, code);//老的接口 WxPayDataV3(orderEntity.order_amount, orderEntity.id.ToString(), orderEntity.order_no, code); } catch (Exception ex) { WXLogs.AddLog("【微支付】微信预定", "paypage.aspx Page_Load", "ex: " + ex.Message, 1); //MessageBox.ShowAndRedirect(this, "支付有问题:" + ex.Message, "/shop/index.aspx?wid=" + wid); } }
protected void Page_Load(object sender, EventArgs e) { if (!Page.IsPostBack) { aid = MyCommFun.RequestInt("aid"); shopid = MyCommFun.RequestInt("shopid"); openid = MyCommFun.QueryString("openid"); shopinfo = shopBll.GetModel(shopid); hotelName = shopinfo.hotelName; } }
public void ProcessRequest(HttpContext context) { context.Response.ContentType = "text/json"; string _action = MyCommFun.QueryString("myact"); string openid = MyCommFun.RequestOpenid(); //得到微信用户的openid if (_action == "update") { try { #region 提交手机 /// 提交手机号码 string tel = MyCommFun.QueryString("tel"); string pwd = MyCommFun.QueryString("pwd"); string snumber = MyCommFun.QueryString("snumber"); int id = MyCommFun.RequestInt("id"); int aid = MyCommFun.RequestInt("aid"); if (aid == 0 || id == 0 || snumber == "" || tel == "" || pwd == "") { context.Response.Write("{\"msg\":\"提交出现异常!!\",\"success\":\"0\"}"); return; } BLL.wx_sTicket actBll = new BLL.wx_sTicket(); if (!actBll.ExistsPwd(aid, pwd)) { context.Response.Write("{\"msg\":\"商家兑换密码错误!!\",\"success\":\"0\"}"); return; } BLL.wx_sttAwardUser ubll = new BLL.wx_sttAwardUser(); Model.wx_sttAwardUser model = ubll.GetModel(id); if (model == null) { context.Response.Write("{\"msg\":\"提交出现异常2!!\",\"success\":\"0\"}"); return; } model.uTel = tel; model.hasLingQu = true; ubll.Update(model); context.Response.Write("{\"msg\":\"提交成功!\",\"success\":\"1\"}"); return; #endregion } catch { context.Response.Write("{\"msg\":\"提交出现异常!!\",\"success\":\"0\"}"); return; } } }
protected void Page_Load(object sender, EventArgs e) { shopid = MyCommFun.RequestInt("shopid"); openid = MyCommFun.QueryString("openid"); if (!IsPostBack) { setup = setupbll.GetModelset(shopid); zhaoshang = setup.unionManage; tel = setup.unionTel; } }