Exemplo n.º 1
0
    protected void btn_OK_Click(object sender, EventArgs e)
    {
        if (CommonBizRules.IsUrlParams(HttpContext.Current.Request.Url.OriginalString))
        {
            SPID      = HttpUtility.HtmlDecode(Request.QueryString["SPID"].ToString());
            ReturnUrl = HttpUtility.HtmlDecode(Request.QueryString["ReturnUrl"].ToString());
        }

        if (!CommonUtility.ValidateValidateCode(HttpUtility.HtmlDecode(Request.Form["code"].ToString().Trim().ToUpper()), this.Context))
        {
            err_code.InnerHtml = "验证码错误,请重新输入";
            return;
        }
        OldPwd    = Request.Form["oldPasswd"].ToString().Trim();
        VerifyPwd = Request.Form["verifyPasswd"].ToString().Trim();
        if (!PassWordBO.OldPwdIsRight(CustID, OldPwd, "2", out ErrMsg))
        {
            //CommonBizRules.ErrorHappenedRedircet(-1, ErrMsg, "修改登录密码", this.Context);
            error.InnerHtml = "原始密码错误";
            return;
        }
        else
        {
            string ErrMsgSetPwd = "";
            int    Result       = PassWordBO.SetPassword(SPID, CustID, VerifyPwd, "2", "", out ErrMsgSetPwd);
            if (Result != 0)
            {
                CommonBizRules.ErrorHappenedRedircet(Result, ErrMsgSetPwd, "修改登录密码", this.Context);
            }
            CommonBizRules.SuccessRedirect(ReturnUrl, "修改登录成功", this.Context);
        }
    }
Exemplo n.º 2
0
    protected void Page_Load(object sender, EventArgs e)
    {
        if (!Page.IsPostBack)
        {
            TokenValidate.Validate();
            if (CommonBizRules.IsUrlParams(HttpContext.Current.Request.Url.OriginalString))
            {
                SPID = HttpUtility.HtmlDecode(Request.QueryString["SPID"].ToString());
               
            }
            CustID = TokenValidate.CustID;
           
            proInfoList.Items.Clear();
            DataTable dt = CustProvinceRelation.GetProvince();
            if (dt != null)
            {
                for (int i = 0; i < dt.Rows.Count; i++)
                {
                    ListItem ltem = new ListItem();
                    ltem.Value = dt.Rows[i]["ProvinceID"].ToString();
                    ltem.Text = dt.Rows[i]["ProvinceName"].ToString();
                    proInfoList.Items.Add(ltem);
                }
                proInfoList.Items.Add("请选择省份");
                proInfoList.SelectedIndex = dt.Rows.Count ;
            }
         

        }
    }
Exemplo n.º 3
0
    protected void Page_Load(object sender, EventArgs e)
    {
        if (!Page.IsPostBack)
        {
            TokenValidate.Validate();
            if (CommonBizRules.IsUrlParams(HttpContext.Current.Request.Url.OriginalString))
            {
                if (Request.QueryString["SPID"] != null)
                {
                    SPID = Request.QueryString["SPID"].ToString();
                    //  ReturnUrl = Request.QueryString["ReturnUrl"].ToString();
                }
                else
                {
                    SPID = "35000000";
                }
                //SPID = HttpUtility.HtmlDecode(Request.QueryString["SPID"].ToString());
                //ReturnUrl = HttpUtility.HtmlDecode(Request.QueryString["ReturnUrl"].ToString());
            }

            CustID = TokenValidate.CustID;
            string UserAccount = "";

            try
            {
                string ReturnUrl = HttpUtility.HtmlDecode(Request.QueryString["ReturnUrl"].ToString());
                PageUtility.SetCookie(ReturnUrl, "ReferrerUrl", this.Page);
                //string url = Page.Request.UrlReferrer.ToString();5
                //PageUtility.SetCookie(url, "ReferrerUrl", this.Page);
            }
            catch (System.Exception ex)
            { }
            int Result = CustBasicInfo.GetUserAccount(CustID, out UserAccount, out ErrMsg);
            if (Result == 0)
            {
                //判断此人时候有商旅卡号!
                this.Label1.Text    = "您已经申请过商旅卡了,你的商旅卡号为:" + UserAccount;
                this.Label1.Visible = true;
                btnlogin2.Visible   = true;
            }
            else
            {
                Response.Redirect("bizCard2.aspx?id=6&SPID=" + SPID);
            }
        }
    }
Exemplo n.º 4
0
    protected void Page_Load(object sender, EventArgs e)
    {
        error.InnerHtml    = "";
        err_code.InnerHtml = "";
        TokenValidate.Validate();
        CustID = TokenValidate.CustID;

        if (!Page.IsPostBack)
        {
            //this.CustID = "117663768";

            btn_OK.Attributes.Add("onclick", "return CheckInput('1')");
            if (CommonBizRules.IsUrlParams(HttpContext.Current.Request.Url.OriginalString))
            {
                SPID      = HttpUtility.HtmlDecode(Request.QueryString["SPID"].ToString());
                ReturnUrl = HttpUtility.HtmlDecode(Request.QueryString["ReturnUrl"].ToString());
            }
        }
    }
Exemplo n.º 5
0
    protected void Page_Load(object sender, EventArgs e)
    {
        err_code.InnerHtml = "";
        error.InnerHtml    = "";
        if (!Page.IsPostBack)
        {
            btn_OK.Attributes.Add("onclick", "return CheckInput('0')");
            TokenValidate.IsRedircet = true;
            TokenValidate.Validate();
            if (CommonBizRules.IsUrlParams(HttpContext.Current.Request.Url.OriginalString))
            {
                SPID      = HttpUtility.HtmlDecode(Request.QueryString["SPID"].ToString());
                ReturnUrl = HttpUtility.HtmlDecode(Request.QueryString["ReturnUrl"].ToString());
            }
            CustID = TokenValidate.CustID;

            //语言密码为空
            if (PassWordBO.VoicePwdIsNull(CustID, out ErrMsg))
            {
                Label1.Text     = "输入登录密码";
                error.InnerHtml = "提示:您未设置过语音密码 请输入登录密码";
            }
        }
    }
Exemplo n.º 6
0
    protected void Page_Load(object sender, EventArgs e)
    {
        err_username.InnerHtml   = "";
        err_phone_code.InnerHtml = "";
        err_page_code.InnerHtml  = "";
        err_email.InnerHtml      = "";
        err_password.InnerHtml   = "";
        Top1.Welcome             = "号码百事通用户注册";
        backCount.Value          = Convert.ToString((Convert.ToInt32(backCount.Value) - 1));

        if (!Page.IsPostBack)
        {
            //地区联动--start
            ProvinceInfoManager proInfo = new ProvinceInfoManager();
            object  ProData             = proInfo.GetProvinceData(this.Context);
            DataSet ds = (DataSet)ProData;
            this.proInfoList.DataSource     = ds;
            this.proInfoList.DataTextField  = "ProvinceName";
            this.proInfoList.DataValueField = "ProvinceID";
            this.proInfoList.DataBind();

            //PhoneAreaInfoManager areaInfo = new PhoneAreaInfoManager();
            //object areaData = areaInfo.GetPhoneAreaData(this.Context);
            //PhoneAreaData pad = (PhoneAreaData)areaData;
            //this.areaInfoList.DataSource = pad;
            //this.areaInfoList.DataTextField = "AreaName";
            //this.areaInfoList.DataValueField = "AreaID";
            //this.areaInfoList.DataBind();
            ListItem li = new ListItem("请选择", "-999");
            proInfoList.Items.Add(li);
            proInfoList.SelectedIndex = proInfoList.Items.Count - 1;



            //this.areaInfoList.Items.Add("北京");
            this.areaInfoList.Items.Add(li);
            areaInfoList.SelectedIndex = areaInfoList.Items.Count - 1;

            //地区联动--end

            if (!CommonBizRules.IsUrlParams(HttpContext.Current.Request.Url.OriginalString))
            {
                //  CommonBizRules.ErrorHappenedRedircet(-1, "URL参数不存在", "用户注册", this.Context);
            }
            //SPID = HttpUtility.HtmlDecode(Request.QueryString["SPID"].ToString());
            //ReturnUrl = HttpUtility.HtmlDecode(Request.QueryString["ReturnUrl"].ToString());
            SPID      = Request["SPID"] == null ? ConstHelper.DefaultInstance.BesttoneSPID : HttpUtility.HtmlDecode(Request["SPID"]);
            ReturnUrl = Request["ReturnUrl"] == null ? ConstHelper.DefaultInstance.BesttoneLoginPage : HttpUtility.HtmlDecode(Request["ReturnUrl"]);
            HiddenField_SPID.Value = SPID;
            HiddenField_URL.Value  = ReturnUrl;

            btn_OK.Attributes.Add("onclick", "return CheckInput();");
            CertificateType.Attributes.Add("onchange", "f_show()");
            //CertificateType.Attributes["onchange"] = "javascript:showText()";
            //RegisterStartupScript("Startup", "<script language='javascript'>function window.onload(){showText();}</" + "script>");
        }

        if (proInfoList.SelectedIndex != proInfoList.Items.Count - 1)
        {
            PhoneAreaInfoManager areaInfo = new PhoneAreaInfoManager();
            object        areaData        = areaInfo.GetPhoneAreaData(this.Context, proInfoList.Value);
            PhoneAreaData pad             = (PhoneAreaData)areaData;
            this.areaInfoList.DataSource     = pad;
            this.areaInfoList.DataTextField  = "AreaName";
            this.areaInfoList.DataValueField = "AreaID";
            this.areaInfoList.DataBind();
        }
        else
        {
            areaInfoList.Value = "请选择";
        }
    }