protected void Button1_Click(object sender, EventArgs e) { StringBuilder strLog = new StringBuilder(); try { //checkCode = Request["checkCode"]; BesttoneAccount = Request["mobile"]; //strLog.AppendFormat(String.Format("重置密码页面验证码:{0}", checkCode)); //判断手机验证码 //if (checkCode != null && !"".Equals(checkCode)) //{ // Result = PhoneBO.SelSendSMSMassage("", BesttoneAccount, checkCode, out ErrMsg); // if (Result != 0) // { // hintCode.InnerHtml = "手机验证码错误,请重新输入"; // 这里如何控制样式 // return; // } //} //else //{ // hintCode.InnerHtml = "手机验证不能为空,请重新输入"; // 这里如何控制样式 // return; //} Linkage.BestTone.Interface.Rule.CustInfo custinfo = new Linkage.BestTone.Interface.Rule.CustInfo(); Result = BesttoneAccountHelper.QueryCustInfo(BesttoneAccount, out custinfo, out ErrMsg); if (Result == 0) { if (custinfo != null) { int ret = BesttoneAccountHelper.ResetBesttoneAccountPayPassword(BesttoneAccount, custinfo.IdType, custinfo.IdNo, custinfo.CustomerName, out ErrMsg); if (ret == 0) { //提示密码重置成功 success = "0"; sendmsg = "支付密码已发送至" + BesttoneAccount; //Response.Redirect(ReturnUrl); } else { Response.Redirect("ErrorInfo.aspx?ErrorInfo=" + ErrMsg); } } } else { Response.Redirect("ErrorInfo.aspx?ErrorInfo=" + ErrMsg); } } catch (System.Exception ex) { log(ex.ToString()); } finally { log(strLog.ToString()); } }
protected void Page_Load(object sender, EventArgs e) { StringBuilder strLog = new StringBuilder(); try { if (!IsPostBack) { strLog.AppendFormat("BesttoneAccountMain"); ParseSPTokenRequest(); if (Result == 0) { CreateSPTokenRequest(); //int QueryResult = 0; strLog.AppendFormat("CustID:{0},SPID{1},HeadFooter{2}", CustID, SPID, HeadFooter); if ("yes".Equals(HeadFooter)) { this.header.Visible = true; this.footer.Visible = true; } else { this.header.Visible = false; this.footer.Visible = false; } //PhoneRecord[] phones = CustBasicInfo.getPhoneRecord(CustID, out QueryResult, out ErrMsg); String qryPhone = ""; //if (QueryResult == 0 && phones != null && phones.Length > 0) { // strLog.AppendFormat("getPhoneRecord成功!"); // phoneNum = phones[0].Phone; // strLog.AppendFormat("根据CustID获得手机号:CustID:{0},phoneNum:{1}", CustID, phoneNum); string BindedBestpayAccount = ""; IsBesttoneAccountBindV5Result = CIP2BizRules.IsBesttoneAccountBindV5(CustID, out BindedBestpayAccount, out CreateTime, out ErrMsg); strLog.AppendFormat("IsBesttoneAccountBindV5Result:{0},ErrMsg:{1},CustID:{2},CreateTime:{3},BindedBestpayAccount:{4}", IsBesttoneAccountBindV5Result, ErrMsg, CustID, CreateTime, BindedBestpayAccount); // 0 代表 绑定 if (IsBesttoneAccountBindV5Result == 0) { AccountItem ai = new AccountItem(); BesttoneAccount = phoneNum; BesttoneAccount = ai.AccountName; if (!String.IsNullOrEmpty(BindedBestpayAccount)) { qryPhone = BindedBestpayAccount; } else { qryPhone = phoneNum; } String ResponseCode = ""; int QueryBesttoneAccountResult = BesttoneAccountHelper.BesttoneAccountInfoQuery(qryPhone, out ai, out ResponseCode, out ErrMsg); Linkage.BestTone.Interface.Rule.CustInfo custInfo = new Linkage.BestTone.Interface.Rule.CustInfo(); int resultQuerycustInfo = BesttoneAccountHelper.QueryCustInfo(qryPhone, out custInfo, out ErrMsg); if (resultQuerycustInfo == 0) { BesttoneAccount = custInfo.CustomerName; } if (QueryBesttoneAccountResult == 0) { if (ai != null) { //页面赋值 if ("0".Equals(ai.AccountStatus)) { //this.AccountStatus.InnerText = "未激活"; BesttoneAccountStatus = "未激活"; } else if ("1".Equals(ai.AccountStatus)) { //this.AccountStatus.InnerText = "正常"; BesttoneAccountStatus = "正常"; } else if ("2".Equals(ai.AccountStatus)) { //this.AccountStatus.InnerText = "挂失"; BesttoneAccountStatus = "挂失"; } else if ("3".Equals(ai.AccountStatus)) { //this.AccountStatus.InnerText = "冻结"; BesttoneAccountStatus = "冻结"; } else if ("4".Equals(ai.AccountStatus)) { //this.AccountStatus.InnerText = "锁定"; BesttoneAccountStatus = "锁定"; } else if ("9".Equals(ai.AccountStatus)) { //this.AccountStatus.InnerText = "已销户"; BesttoneAccountStatus = "已销户"; } else { //this.AccountStatus.InnerText = ""; BesttoneAccountStatus = ""; } BesttoneAccountBalance = BesttoneAccountHelper.ConvertAmountToYuan(ai.AccountBalance); } else { } } else { if ("200010".Equals(ResponseCode)) { BesttoneAccountStatus = "账户未开通"; BesttoneAccountBalance = "0.00"; } } } Int64 balance = 0; // 最近交易查询 String txnType = ""; // 121020充值 //131010消费 //131030退费 String txnChannel = "02"; //WEB int maxReturnRecord = 30; int startRecord = 1; //int QueryAllTypeTxnResult = BesttoneAccountHelper.QueryAllTypeTxn(phoneNum, txnType, txnChannel, out txnItemList, out ErrMsg); int QueryChargeResult = CIP2BizRules.QueryBestPayAllTxn(qryPhone, txnType, txnChannel, maxReturnRecord, startRecord, out txnItemList, out ErrMsg); //txnType = "131090"; //} // custphone query end //else // custphone query end //{ // strLog.AppendFormat("ErrMsg:{0}", ErrMsg); //} // custphone query end } else { Response.Redirect("ErrorInfo.aspx?ErrorInfo=" + ErrMsg); } } } catch (System.Exception ex) { log(ex.ToString()); } finally { log(strLog.ToString()); } }