private void AddUser() { string str = LSRequest.qq("userName").ToLower().Trim(); string str2 = "0"; string str3 = LSRequest.qq("userPassword"); string str4 = LSRequest.qq("userNicker"); string str5 = LSRequest.qq("userReport"); string str6 = LSRequest.qq("userCredit_six"); string str7 = LSRequest.qq("userRate_six"); string str8 = LSRequest.qq("userAllowSale_six"); string str9 = LSRequest.qq("userRateOwner_six"); string str10 = LSRequest.qq("userKind_six"); string str11 = LSRequest.qq("op_six"); string str12 = LSRequest.qq("userCredit_kc"); string str13 = LSRequest.qq("userRate_kc"); string str14 = LSRequest.qq("userAllowSale_kc"); string str15 = LSRequest.qq("userRateOwner_kc"); string str16 = LSRequest.qq("userKind_kc"); string str17 = LSRequest.qq("isCash_kc"); string str18 = LSRequest.qq("isCash_six"); string str19 = LSRequest.qq("op_kc"); string str20 = LSRequest.qq("isAutoBack_kc"); string message = ""; if (!base.ValidParamByUserAdd("fgs", ref message, null, this.lottrty_six, this.lottrty_kc)) { base.noRightOptMsg(message); } if (!Regexlib.IsValidPassword(str3.Trim(), base.get_GetPasswordLU())) { if (base.get_GetPasswordLU().Equals("1")) { base.noRightOptMsg("密碼要8-20位,且必需包含大寫字母、小寫字母和数字!"); } else { base.noRightOptMsg("<script>alert('密碼要8-20位,且必需包含字母、和数字!');</script>"); } } if (!str5.ToUpper().Equals("0") && !str5.ToUpper().Equals("1")) { base.Response.End(); } if (!str17.ToUpper().Equals("0") && !str17.ToUpper().Equals("1")) { base.Response.End(); } if (!str18.ToUpper().Equals("0") && !str18.ToUpper().Equals("1")) { base.Response.End(); } if (!str11.ToUpper().Equals("0") && !str11.ToUpper().Equals("1")) { base.Response.End(); } if (!str19.ToUpper().Equals("0") && !str19.ToUpper().Equals("1")) { base.Response.End(); } if (!string.IsNullOrEmpty(this.lottrty_six)) { if ((!str10.ToUpper().Equals("A") && !str10.ToUpper().Equals("B")) && (!str10.ToUpper().Equals("C") && !str10.ToUpper().Equals("0"))) { base.Response.End(); } if (!str8.ToUpper().Equals("0") && !str8.ToUpper().Equals("1")) { base.Response.End(); } if (!str9.ToUpper().Equals("0") && !str9.ToUpper().Equals("1")) { base.Response.End(); } } if (!string.IsNullOrEmpty(this.lottrty_kc)) { if ((!str16.ToUpper().Equals("A") && !str16.ToUpper().Equals("B")) && (!str16.ToUpper().Equals("C") && !str16.ToUpper().Equals("0"))) { base.Response.End(); } if (!str14.ToUpper().Equals("0") && !str14.ToUpper().Equals("1")) { base.Response.End(); } if (!str15.ToUpper().Equals("0") && !str15.ToUpper().Equals("1")) { base.Response.End(); } } int num = 100; decimal num2 = 0M; decimal num3 = 0M; if (!string.IsNullOrEmpty(this.lottrty_six)) { num = Convert.ToInt32(str7); num2 = Convert.ToDecimal(str6); num3 = Convert.ToDecimal(str6); } int num4 = 100; decimal num5 = 0M; decimal num6 = 0M; if (!string.IsNullOrEmpty(this.lottrty_kc)) { num4 = Convert.ToInt32(str13); num5 = Convert.ToDecimal(str12); num6 = Convert.ToDecimal(str12); } cz_users model = new cz_users(); model.set_u_id(Guid.NewGuid().ToString().ToUpper()); model.set_u_name(str); string ramSalt = Utils.GetRamSalt(6); model.set_u_psw(DESEncrypt.EncryptString(str3, ramSalt)); model.set_salt(ramSalt); model.set_u_nicker(str4); model.set_u_skin(base.GetUserSkin("agent")); model.set_sup_name(this.Session["user_name"].ToString()); model.set_u_type("fgs"); model.set_su_type("zj"); model.set_add_date(new DateTime?(DateTime.Now)); model.set_six_rate(new int?(num)); model.set_six_credit(new decimal?(num2)); model.set_six_usable_credit(new decimal?(num3)); model.set_six_kind(str10); model.set_a_state(new int?(Convert.ToInt32(str2))); model.set_allow_sale(new int?(Convert.ToInt32(str8))); model.set_allow_view_report(new int?(Convert.ToInt32(str5))); model.set_six_allow_maxrate(0); model.set_six_low_maxrate(0); model.set_six_rate_owner(new int?(Convert.ToInt32(str9))); model.set_six_iscash(new int?(Convert.ToInt32(str18))); model.set_allow_opt(1); model.set_is_changed(0); model.set_kc_rate(new int?(num4)); model.set_kc_credit(new decimal?(num5)); model.set_kc_usable_credit(new decimal?(num6)); model.set_kc_kind(str16); model.set_kc_allow_sale(new int?(Convert.ToInt32(str14))); model.set_kc_allow_maxrate(0); model.set_kc_low_maxrate(0); model.set_kc_rate_owner(new int?(Convert.ToInt32(str15))); model.set_kc_crash_payment(0); model.set_kc_iscash(new int?(Convert.ToInt32(str17))); model.set_six_op_odds(new int?(Convert.ToInt32(str11))); model.set_kc_op_odds(new int?(Convert.ToInt32(str19))); if (base.get_GetIsShowFgsWT().Equals("0")) { model.set_six_op_odds(0); model.set_kc_op_odds(0); } model.set_kc_isauto_back(new int?(Convert.ToInt32(str20))); cz_rate_kc _kc = new cz_rate_kc(); _kc.set_u_name(str); _kc.set_u_type("fgs"); _kc.set_dl_name(""); _kc.set_zd_name(""); _kc.set_gd_name(""); _kc.set_fgs_name(str); _kc.set_dl_rate(0); _kc.set_zd_rate(0); _kc.set_gd_rate(0); _kc.set_fgs_rate(0); _kc.set_zj_rate(new decimal?(num4)); cz_rate_six _six = new cz_rate_six(); _six.set_u_name(str); _six.set_u_type("fgs"); _six.set_dl_name(""); _six.set_zd_name(""); _six.set_gd_name(""); _six.set_fgs_name(str); _six.set_dl_rate(0); _six.set_zd_rate(0); _six.set_gd_rate(0); _six.set_fgs_rate(0); _six.set_zj_rate(new decimal?(num)); string str23 = ""; Dictionary <string, string> data = new Dictionary <string, string>(); if (CallBLL.cz_users_bll.AddUserInfoFGS(model, _kc, _six, ref str23)) { int num7 = 2; if (this.lottrty_six == "") { num7 = 1; } else if (this.lottrty_kc == "") { num7 = 0; } else if ((this.lottrty_kc != "") && (this.lottrty_six != "")) { num7 = 2; } base.user_add_fgs_log(model, num7); string text1 = "/Account/drawback.aspx?uid=" + str23 + "&isadd=1"; data.Add("uname", model.get_u_name()); data.Add("uid", model.get_u_id()); base.successOptMsg("添加分公司成功!", data); } else { base.noRightOptMsg("添加分公司失敗!"); } }
private void AddUser() { string str = LSRequest.qq("userName").ToLower().Trim(); string str2 = "0"; string str3 = LSRequest.qq("userPassword"); string str4 = LSRequest.qq("userNicker"); this.upuname = this.u_name; string str5 = LSRequest.qq("userCredit_six"); string str6 = LSRequest.qq("allowmaxrate_six"); string str7 = LSRequest.qq("lowmaxrate_six"); string str8 = LSRequest.qq("userAllowSale_six"); string str9 = LSRequest.qq("userKind_six"); if (!this.six_kind_d.Equals("0")) { str9 = this.six_kind_d; } if (string.IsNullOrEmpty(str5)) { str5 = "0"; } if (string.IsNullOrEmpty(str9)) { str9 = "0"; } string str10 = LSRequest.qq("userCredit_kc"); string str11 = LSRequest.qq("allowmaxrate_kc"); string str12 = LSRequest.qq("lowmaxrate_kc"); string str13 = LSRequest.qq("userAllowSale_kc"); string str14 = LSRequest.qq("userKind_kc"); if (!this.kc_kind_d.Equals("0")) { str14 = this.kc_kind_d; } if (string.IsNullOrEmpty(str10)) { str10 = "0"; } if (string.IsNullOrEmpty(str14)) { str14 = "0"; } string message = ""; if (!base.ValidParamByUserAdd("dl", ref message, null, this.lottrty_six, this.lottrty_kc)) { base.noRightOptMsg(message); } if (!Regexlib.IsValidPassword(str3.Trim(), base.get_GetPasswordLU())) { if (base.get_GetPasswordLU().Equals("1")) { base.noRightOptMsg("密碼要8-20位,且必需包含大寫字母、小寫字母和数字!"); } else { base.noRightOptMsg("密碼要8-20位,且必需包含字母、和数字!"); } base.Response.End(); } int num = 0; if (LSRequest.qq("sltlimithy").ToString().Trim().Equals("0")) { num = 0; } else { string str17 = LSRequest.qq("txtlimithy") ?? ""; if (!string.IsNullOrEmpty(str17)) { num = int.Parse(str17); } } if (!string.IsNullOrEmpty(this.lottrty_six)) { if ((!str9.ToUpper().Equals("A") && !str9.ToUpper().Equals("B")) && (!str9.ToUpper().Equals("C") && !str9.ToUpper().Equals("0"))) { base.Response.End(); } if (!str8.ToUpper().Equals("0") && !str8.ToUpper().Equals("1")) { base.Response.End(); } } if (!string.IsNullOrEmpty(this.lottrty_kc)) { if ((!str14.ToUpper().Equals("A") && !str14.ToUpper().Equals("B")) && (!str14.ToUpper().Equals("C") && !str14.ToUpper().Equals("0"))) { base.Response.End(); } if (!str13.ToUpper().Equals("0") && !str13.ToUpper().Equals("1")) { base.Response.End(); } } cz_rate_kc rateKCByUserName = CallBLL.cz_rate_kc_bll.GetRateKCByUserName(this.upuname); base.En_User_Lock(rateKCByUserName.get_fgs_name()); if (Convert.ToDouble(str5) > Convert.ToDouble(this.six_usable_credit_d)) { base.Un_User_Lock(rateKCByUserName.get_fgs_name()); base.noRightOptMsg("⑥合彩:‘信用額度’已超過‘上級可用餘額’,請修改!"); } string str18 = LSRequest.qq("userRate_six"); if (string.IsNullOrEmpty(str18)) { str18 = "0"; } if (Convert.ToDouble(str18) > Convert.ToDouble(this.six_rate_d)) { base.Un_User_Lock(rateKCByUserName.get_fgs_name()); base.noRightOptMsg("⑥合彩: 總代占成 不可高於" + this.six_rate_d + ",請修改!"); } if (str6.Equals("1")) { if (string.IsNullOrEmpty(str7)) { base.Un_User_Lock(rateKCByUserName.get_fgs_name()); base.noRightOptMsg("⑥合彩: ‘占成上限’ 不可為空,請修改!"); } try { int.Parse(str7); } catch { base.Un_User_Lock(rateKCByUserName.get_fgs_name()); base.noRightOptMsg("⑥合彩: ‘占成上限’只能為數字,請重新設定!"); } if (Convert.ToInt32(str7) > 100) { base.Un_User_Lock(rateKCByUserName.get_fgs_name()); base.noRightOptMsg("⑥合彩: ‘占成上限’不可高於 100%,請重新設定!"); } else if (Convert.ToInt32(str7) < 0) { base.Un_User_Lock(rateKCByUserName.get_fgs_name()); base.noRightOptMsg("⑥合彩: ‘占成上限’不可低於等於 0%,請重新設定!"); } } else { str7 = "0"; } if (Convert.ToDouble(str10) > Convert.ToDouble(this.kc_usable_credit_d)) { base.Un_User_Lock(rateKCByUserName.get_fgs_name()); base.noRightOptMsg("快彩:‘信用額度’已超過‘上級可用餘額’,請修改!"); } string str19 = LSRequest.qq("userRate_kc"); if (string.IsNullOrEmpty(str19)) { str19 = "0"; } if (Convert.ToDouble(str19) > Convert.ToDouble(this.kc_rate_d)) { base.Un_User_Lock(rateKCByUserName.get_fgs_name()); base.noRightOptMsg("快彩: 總代占成 不可高於" + this.kc_rate_d + ",請修改!"); } if (str11.Equals("1")) { if (string.IsNullOrEmpty(str12)) { base.Un_User_Lock(rateKCByUserName.get_fgs_name()); base.noRightOptMsg("快彩: ‘占成上限’ 不可為空,請修改!"); } try { int.Parse(str12); } catch { base.Un_User_Lock(rateKCByUserName.get_fgs_name()); base.noRightOptMsg("快彩: ‘占成上限’只能為數字,請重新設定!"); } if (Convert.ToInt32(str12) > 100) { base.Un_User_Lock(rateKCByUserName.get_fgs_name()); base.noRightOptMsg("快彩: ‘占成上限’不可高於 100%,請重新設定!"); } else if (Convert.ToInt32(str12) < 0) { base.Un_User_Lock(rateKCByUserName.get_fgs_name()); base.noRightOptMsg(""); } } else { str12 = "0"; } int num2 = 0; decimal num3 = 0M; decimal num4 = 0M; if (!string.IsNullOrEmpty(this.lottrty_six)) { num2 = Convert.ToInt32(str18); num3 = Convert.ToDecimal(str5); num4 = Convert.ToDecimal(str5); } int num5 = 0; decimal num6 = 0M; decimal num7 = 0M; if (!string.IsNullOrEmpty(this.lottrty_kc)) { num5 = Convert.ToInt32(str19); num6 = Convert.ToDecimal(str10); num7 = Convert.ToDecimal(str10); } cz_users model = new cz_users(); model.set_u_id(Guid.NewGuid().ToString().ToUpper()); model.set_u_name(str); string ramSalt = Utils.GetRamSalt(6); model.set_u_psw(DESEncrypt.EncryptString(str3, ramSalt)); model.set_salt(ramSalt); model.set_u_nicker(str4); model.set_u_skin(base.GetUserSkin("agent")); model.set_sup_name(this.upuname); model.set_u_type("dl"); model.set_su_type("zd"); model.set_limit_hy(new int?(num)); model.set_add_date(new DateTime?(DateTime.Now)); model.set_six_rate(new int?(num2)); model.set_six_credit(new decimal?(num3)); model.set_six_usable_credit(new decimal?(num4)); model.set_six_kind(str9); model.set_a_state(new int?(Convert.ToInt32(str2))); model.set_allow_sale(new int?(Convert.ToInt32(str8))); model.set_six_allow_maxrate(new int?(Convert.ToInt32(str6))); model.set_six_low_maxrate(new int?(Convert.ToInt32(str7))); model.set_allow_opt(1); model.set_is_changed(0); model.set_kc_rate(new int?(num5)); model.set_kc_credit(new decimal?(num6)); model.set_kc_usable_credit(new decimal?(num7)); model.set_kc_kind(str14); model.set_kc_allow_sale(new int?(Convert.ToInt32(str13))); model.set_kc_allow_maxrate(new int?(Convert.ToInt32(str11))); model.set_kc_low_maxrate(new int?(Convert.ToInt32(str12))); model.set_kc_crash_payment(0); model.set_kc_iscash(new int?(Convert.ToInt32(this.kc_iscash))); model.set_six_iscash(new int?(Convert.ToInt32(this.six_iscash))); cz_rate_kc _kc2 = new cz_rate_kc(); _kc2.set_u_name(str); _kc2.set_u_type("dl"); _kc2.set_dl_name(str); _kc2.set_zd_name(this.kc_zd_name); _kc2.set_gd_name(this.kc_gd_name); _kc2.set_fgs_name(this.kc_fgs_name); _kc2.set_dl_rate(0); _kc2.set_zd_rate(new decimal?(num5)); _kc2.set_gd_rate(new decimal?(Convert.ToDecimal(this.kc_gd_rate))); _kc2.set_fgs_rate(new decimal?(Convert.ToDecimal(this.kc_fgs_rate))); _kc2.set_zj_rate(new decimal?(Convert.ToDecimal(this.kc_zj_rate))); cz_rate_six _six = new cz_rate_six(); _six.set_u_name(str); _six.set_u_type("dl"); _six.set_dl_name(str); _six.set_zd_name(this.six_zd_name); _six.set_gd_name(this.six_gd_name); _six.set_fgs_name(this.six_fgs_name); _six.set_dl_rate(0); _six.set_zd_rate(new decimal?(num2)); _six.set_gd_rate(new decimal?(Convert.ToDecimal(this.six_gd_rate))); _six.set_fgs_rate(new decimal?(Convert.ToDecimal(this.six_fgs_rate))); _six.set_zj_rate(new decimal?(Convert.ToDecimal(this.six_zj_rate))); string str21 = ""; Dictionary <string, string> data = new Dictionary <string, string>(); if (CallBLL.cz_users_bll.AddUserInfo(model, _kc2, _six, ref str21)) { int num8 = 2; if (this.lottrty_six == "") { num8 = 1; } else if (this.lottrty_kc == "") { num8 = 0; } else if ((this.lottrty_kc != "") && (this.lottrty_six != "")) { num8 = 2; } base.user_add_agent_log(model, num8); base.Un_User_Lock(rateKCByUserName.get_fgs_name()); string text1 = "/Account/drawback.aspx?uid=" + str21 + "&isadd=1"; data.Add("uname", model.get_u_name()); data.Add("uid", model.get_u_id()); base.successOptMsg("添加代理成功!", data); } else { base.Un_User_Lock(rateKCByUserName.get_fgs_name()); base.noRightOptMsg("添加代理失敗!"); } }
private void AddUser() { string str = LSRequest.qq("userName").ToLower().Trim(); string str2 = "0"; string str3 = LSRequest.qq("userPassword"); string str4 = LSRequest.qq("userNicker"); this.upuname = this.u_name; string str5 = LSRequest.qq("userCredit_six"); string str6 = LSRequest.qq("allowmaxrate_six"); string str7 = LSRequest.qq("lowmaxrate_six"); string str8 = LSRequest.qq("userAllowSale_six"); string str9 = LSRequest.qq("userKind_six"); if (!this.six_kind_d.Equals("0")) { str9 = this.six_kind_d; } if (string.IsNullOrEmpty(str5)) { str5 = "0"; } if (string.IsNullOrEmpty(str9)) { str9 = "0"; } string str10 = LSRequest.qq("userCredit_kc"); string str11 = LSRequest.qq("allowmaxrate_kc"); string str12 = LSRequest.qq("lowmaxrate_kc"); string str13 = LSRequest.qq("userAllowSale_kc"); string str14 = LSRequest.qq("userKind_kc"); if (!this.kc_kind_d.Equals("0")) { str14 = this.kc_kind_d; } if (string.IsNullOrEmpty(str10)) { str10 = "0"; } if (string.IsNullOrEmpty(str14)) { str14 = "0"; } string message = ""; if (!base.ValidParamByUserAdd("zd", ref message, null, this.lottrty_six, this.lottrty_kc)) { base.Response.Write(base.ShowDialogBox(message, null, 400)); base.Response.End(); } if (!Regexlib.IsValidPassword(str3.Trim(), base.get_GetPasswordLU())) { if (base.get_GetPasswordLU().Equals("1")) { base.Response.Write(base.ShowDialogBox("密碼要8-20位,且必需包含大寫字母、小寫字母和数字!", null, 400)); } else { base.Response.Write(base.ShowDialogBox("密碼要8-20位,且必需包含字母、和数字!", null, 400)); } base.Response.End(); } if (!string.IsNullOrEmpty(this.lottrty_six)) { if ((!str9.ToUpper().Equals("A") && !str9.ToUpper().Equals("B")) && (!str9.ToUpper().Equals("C") && !str9.ToUpper().Equals("0"))) { base.Response.End(); } if (!str8.ToUpper().Equals("0") && !str8.ToUpper().Equals("1")) { base.Response.End(); } if ((this.six_allow_sale_d == "0") && (str8 == "1")) { base.Response.Write("<script>alert(\"(⑥合彩)補貨功能选择错误!!\");</script>"); base.Response.End(); } } if (!string.IsNullOrEmpty(this.lottrty_kc)) { if ((!str14.ToUpper().Equals("A") && !str14.ToUpper().Equals("B")) && (!str14.ToUpper().Equals("C") && !str14.ToUpper().Equals("0"))) { base.Response.End(); } if (!str13.ToUpper().Equals("0") && !str13.ToUpper().Equals("1")) { base.Response.End(); } if ((this.kc_allow_sale_d == "0") && (str13 == "1")) { base.Response.Write("<script>alert(\"(快彩)補貨功能选择错误!!\");</script>"); base.Response.End(); } } cz_rate_kc rateKCByUserName = CallBLL.cz_rate_kc_bll.GetRateKCByUserName(this.upuname); base.En_User_Lock(rateKCByUserName.get_fgs_name()); if (Convert.ToDouble(str5) > Convert.ToDouble(this.six_usable_credit_d)) { base.Un_User_Lock(rateKCByUserName.get_fgs_name()); base.Response.Write(base.ShowDialogBox("⑥合彩:‘信用額度’已超過‘上級可用餘額’,請修改!", null, 400)); base.Response.End(); } string str16 = LSRequest.qq("userRate_six"); if (string.IsNullOrEmpty(str16)) { str16 = "0"; } if (Convert.ToDouble(str16) > Convert.ToDouble(this.six_rate_d)) { base.Un_User_Lock(rateKCByUserName.get_fgs_name()); base.Response.Write(base.ShowDialogBox("⑥合彩: 股東占成 不可高於" + this.six_rate_d + ",請修改!", null, 400)); base.Response.End(); } if (str6.Equals("1")) { if (string.IsNullOrEmpty(str7)) { base.Un_User_Lock(rateKCByUserName.get_fgs_name()); base.Response.Write(base.ShowDialogBox("⑥合彩:‘占成上限’不可為空,請修改!", null, 400)); base.Response.End(); } try { int.Parse(str7); } catch { base.Un_User_Lock(rateKCByUserName.get_fgs_name()); base.Response.Write(base.ShowDialogBox("⑥合彩: ‘占成上限’只能為數字,請重新設定!", null, 400)); base.Response.End(); } if (Convert.ToInt32(str7) > 100) { base.Un_User_Lock(rateKCByUserName.get_fgs_name()); base.Response.Write(base.ShowDialogBox("⑥合彩: ‘占成上限’不可高於 100%,請重新設定!", null, 400)); base.Response.End(); } else if (Convert.ToInt32(str7) < 0) { base.Un_User_Lock(rateKCByUserName.get_fgs_name()); base.Response.Write(base.ShowDialogBox("⑥合彩: ‘占成上限’不可低於等於 0%,請重新設定!", null, 400)); base.Response.End(); } } else { str7 = "0"; } if (Convert.ToDouble(str10) > Convert.ToDouble(this.kc_usable_credit_d)) { base.Un_User_Lock(rateKCByUserName.get_fgs_name()); base.Response.Write(base.ShowDialogBox("快彩:‘信用額度’已超過‘上級可用餘額’,請修改!", null, 400)); base.Response.End(); } string str17 = LSRequest.qq("userRate_kc"); if (string.IsNullOrEmpty(str17)) { str17 = "0"; } if (Convert.ToDouble(str17) > Convert.ToDouble(this.kc_rate_d)) { base.Un_User_Lock(rateKCByUserName.get_fgs_name()); base.Response.Write(base.ShowDialogBox("快彩: 股東占成 不可高於" + this.kc_rate_d + ",請修改!", null, 400)); base.Response.End(); } if (str11.Equals("1")) { if (string.IsNullOrEmpty(str12)) { base.Un_User_Lock(rateKCByUserName.get_fgs_name()); base.Response.Write(base.ShowDialogBox("快彩:‘占成上限’不可為空,請修改!", null, 400)); base.Response.End(); } try { int.Parse(str12); } catch { base.Un_User_Lock(rateKCByUserName.get_fgs_name()); base.Response.Write(base.ShowDialogBox("快彩: ‘占成上限’只能為數字,請重新設定!", null, 400)); base.Response.End(); } if (Convert.ToInt32(str12) > 100) { base.Un_User_Lock(rateKCByUserName.get_fgs_name()); base.Response.Write(base.ShowDialogBox("快彩: ‘占成上限’不可高於 100%,請重新設定!", null, 400)); base.Response.End(); } else if (Convert.ToInt32(str12) < 0) { base.Un_User_Lock(rateKCByUserName.get_fgs_name()); base.Response.Write(base.ShowDialogBox("快彩: ‘占成上限’不可低於等於 0%,請重新設定!", null, 400)); base.Response.End(); } } else { str12 = "0"; } int num = 0; decimal num2 = 0M; decimal num3 = 0M; if (!string.IsNullOrEmpty(this.lottrty_six)) { num = Convert.ToInt32(str16); num2 = Convert.ToDecimal(str5); num3 = Convert.ToDecimal(str5); } int num4 = 0; decimal num5 = 0M; decimal num6 = 0M; if (!string.IsNullOrEmpty(this.lottrty_kc)) { num4 = Convert.ToInt32(str17); num5 = Convert.ToDecimal(str10); num6 = Convert.ToDecimal(str10); } cz_users model = new cz_users(); model.set_u_id(Guid.NewGuid().ToString().ToUpper()); model.set_u_name(str); string ramSalt = Utils.GetRamSalt(6); model.set_u_psw(DESEncrypt.EncryptString(str3, ramSalt)); model.set_salt(ramSalt); model.set_u_nicker(str4); model.set_u_skin(base.GetUserSkin("agent")); model.set_sup_name(this.upuname); model.set_u_type("zd"); model.set_su_type("gd"); model.set_add_date(new DateTime?(DateTime.Now)); model.set_six_rate(new int?(num)); model.set_six_credit(new decimal?(num2)); model.set_six_usable_credit(new decimal?(num3)); model.set_six_kind(str9); model.set_a_state(new int?(Convert.ToInt32(str2))); model.set_allow_sale(new int?(Convert.ToInt32(str8))); model.set_six_allow_maxrate(new int?(Convert.ToInt32(str6))); model.set_six_low_maxrate(new int?(Convert.ToInt32(str7))); model.set_allow_opt(1); model.set_is_changed(0); model.set_kc_rate(new int?(num4)); model.set_kc_credit(new decimal?(num5)); model.set_kc_usable_credit(new decimal?(num6)); model.set_kc_kind(str14); model.set_kc_allow_sale(new int?(Convert.ToInt32(str13))); model.set_kc_allow_maxrate(new int?(Convert.ToInt32(str11))); model.set_kc_low_maxrate(new int?(Convert.ToInt32(str12))); model.set_kc_crash_payment(0); model.set_kc_iscash(new int?(Convert.ToInt32(this.kc_iscash))); model.set_six_iscash(new int?(Convert.ToInt32(this.six_iscash))); cz_rate_kc _kc2 = new cz_rate_kc(); _kc2.set_u_name(str); _kc2.set_u_type("zd"); _kc2.set_dl_name(""); _kc2.set_zd_name(str); _kc2.set_gd_name(this.kc_gd_name); _kc2.set_fgs_name(this.kc_fgs_name); _kc2.set_dl_rate(0); _kc2.set_zd_rate(0); _kc2.set_gd_rate(new decimal?(num4)); _kc2.set_fgs_rate(new decimal?(Convert.ToDecimal(this.kc_fgs_rate))); _kc2.set_zj_rate(new decimal?(Convert.ToDecimal(this.kc_zj_rate))); cz_rate_six _six = new cz_rate_six(); _six.set_u_name(str); _six.set_u_type("zd"); _six.set_dl_name(""); _six.set_zd_name(str); _six.set_gd_name(this.six_gd_name); _six.set_fgs_name(this.six_fgs_name); _six.set_dl_rate(0); _six.set_zd_rate(0); _six.set_gd_rate(new decimal?(num)); _six.set_fgs_rate(new decimal?(Convert.ToDecimal(this.six_fgs_rate))); _six.set_zj_rate(new decimal?(Convert.ToDecimal(this.six_zj_rate))); string str19 = ""; if (CallBLL.cz_users_bll.AddUserInfo(model, _kc2, _six, ref str19)) { int?nullable = model.get_six_iscash(); int num8 = int.Parse("1"); if ((nullable.GetValueOrDefault() == num8) && nullable.HasValue) { cz_users _users2 = new cz_users(); _users2.set_u_name(model.get_u_name()); _users2.set_six_usable_credit(0); cz_users _users3 = new cz_users(); _users3.set_u_name(model.get_sup_name()); _users3.set_six_usable_credit(new decimal?(decimal.Parse(this.six_usable_credit_d))); int num9 = 1; if (base.IsMasterLotteryExist(num9.ToString())) { base.UserRecharge_six(_users2, _users3, str5); } } int?nullable2 = model.get_kc_iscash(); int num10 = int.Parse("1"); if ((nullable2.GetValueOrDefault() == num10) && nullable2.HasValue) { cz_users _users4 = new cz_users(); _users4.set_u_name(model.get_u_name()); _users4.set_kc_usable_credit(0); cz_users _users5 = new cz_users(); _users5.set_u_name(model.get_sup_name()); _users5.set_kc_usable_credit(new decimal?(decimal.Parse(this.kc_usable_credit_d))); int num11 = 2; if (base.IsMasterLotteryExist(num11.ToString())) { base.UserRecharge_kc(_users4, _users5, str10); } } int num7 = 2; if (this.lottrty_six == "") { num7 = 1; } else if (this.lottrty_kc == "") { num7 = 0; } else if ((this.lottrty_kc != "") && (this.lottrty_six != "")) { num7 = 2; } base.user_add_agent_log(model, num7); base.Un_User_Lock(rateKCByUserName.get_fgs_name()); string url = "/Account/drawback.aspx?uid=" + str19 + "&isadd=1"; base.Response.Write(base.ShowDialogBox("添加總代理成功!", url, 0)); base.Response.End(); } else { base.Un_User_Lock(rateKCByUserName.get_fgs_name()); base.Response.Write(base.ShowDialogBox("添加總代理失敗!", base.UserReturnBackUrl, 400)); base.Response.End(); } }
private void AddUser() { string str = LSRequest.qq("userName").ToLower().Trim(); string str2 = "0"; string str3 = LSRequest.qq("userPassword"); string str4 = LSRequest.qq("userNicker"); this.upuname = this.u_name; string str5 = LSRequest.qq("userCredit_six"); string str6 = LSRequest.qq("userKind_six"); if (!this.six_kind_d.Equals("0")) { str6 = this.six_kind_d; } else if (string.IsNullOrEmpty(str6) || str6.Equals("0")) { str6 = "A"; } string str7 = LSRequest.qq("sltDrawback_six"); if (string.IsNullOrEmpty(str5)) { str5 = "0"; } if (string.IsNullOrEmpty(str7)) { str7 = "0"; } switch (str7) { case "0": str7 = "0"; break; case "1": str7 = "0.1"; break; case "2": str7 = "0.2"; break; case "3": str7 = "0.3"; break; case "4": str7 = "0.4"; break; case "5": str7 = "NO"; break; case "auto": break; default: base.Response.End(); break; } if (str7.Equals("auto")) { string s = LSRequest.qq("sltDrawbackAuto_six"); try { if (double.Parse(s) < 0.0) { base.Response.Write(base.ShowDialogBox("⑥合彩: 退水設定 不能小於0!", null, 400)); base.Response.End(); } } catch { base.Response.Write(base.ShowDialogBox("⑥合彩: 退水設定 輸入錯誤!", null, 400)); base.Response.End(); } str7 = s; } string str9 = LSRequest.qq("userCredit_kc"); string str10 = LSRequest.qq("userKind_kc"); if (!this.kc_kind_d.Equals("0")) { str10 = this.kc_kind_d; } else if (string.IsNullOrEmpty(str10) || str10.Equals("0")) { str10 = "A"; } string str11 = LSRequest.qq("sltDrawback_kc"); if (string.IsNullOrEmpty(str9)) { str9 = "0"; } if (string.IsNullOrEmpty(str11)) { str11 = "0"; } switch (str11) { case "0": str11 = "0"; break; case "1": str11 = "0.1"; break; case "2": str11 = "0.2"; break; case "3": str11 = "0.3"; break; case "4": str11 = "0.4"; break; case "5": str11 = "NO"; break; case "auto": break; default: base.Response.End(); break; } if (str11.Equals("auto")) { string str12 = LSRequest.qq("sltDrawbackAuto_kc"); try { if (double.Parse(str12) < 0.0) { base.Response.Write(base.ShowDialogBox("快彩: 退水設定 不能小於0!", null, 400)); base.Response.End(); } } catch { base.Response.Write(base.ShowDialogBox("快彩: 退水設定 輸入錯誤!", null, 400)); base.Response.End(); } str11 = str12; } string message = ""; if (!base.ValidParamByUserAdd("hy", ref message, null, this.lottrty_six, this.lottrty_kc)) { base.Response.Write(base.GetAlert(message)); base.Response.End(); } if (!Regexlib.IsValidPassword(str3.Trim(), base.get_GetPasswordLU())) { if (base.get_GetPasswordLU().Equals("1")) { base.Response.Write(base.ShowDialogBox("密碼要8-20位,且必需包含大寫字母、小寫字母和数字!", null, 400)); } else { base.Response.Write(base.ShowDialogBox("密碼要8-20位,且必需包含字母、和数字!", null, 400)); } base.Response.End(); } if (!string.IsNullOrEmpty(this.lottrty_six)) { if ((!str6.ToUpper().Equals("A") && !str6.ToUpper().Equals("B")) && !str6.ToUpper().Equals("C")) { base.Response.End(); } if (string.IsNullOrEmpty(str7)) { base.Response.End(); } } if (!string.IsNullOrEmpty(this.lottrty_kc)) { if ((!str10.ToUpper().Equals("A") && !str10.ToUpper().Equals("B")) && !str10.ToUpper().Equals("C")) { base.Response.End(); } if (string.IsNullOrEmpty(str11)) { base.Response.End(); } } cz_rate_kc rateKCByUserName = CallBLL.cz_rate_kc_bll.GetRateKCByUserName(this.upuname); base.En_User_Lock(rateKCByUserName.get_fgs_name()); if (CallBLL.cz_users_bll.GetLimitHy_DL(this.upuname).Equals(-1)) { base.Un_User_Lock(rateKCByUserName.get_fgs_name()); if (this.userModel.get_u_type().Equals("dl")) { base.Response.Write(base.ShowDialogBox("下綫人數限製已經滿員,請聯繫上級!", null, 400)); } else { base.Response.Write(base.ShowDialogBox("代理【" + this.upuname + "】下綫人數限製已經滿員!", null, 400)); } base.Response.End(); } if (Convert.ToDouble(str5) > Convert.ToDouble(this.six_usable_credit_d)) { base.Un_User_Lock(rateKCByUserName.get_fgs_name()); base.Response.Write(base.ShowDialogBox("⑥合彩:‘信用額度’已超過‘上級可用餘額’,請修改!", null, 400)); base.Response.End(); } string str14 = LSRequest.qq("userRate_six"); if (string.IsNullOrEmpty(str14)) { str14 = "0"; } if (Convert.ToDouble(str14) > Convert.ToDouble(this.six_rate_d)) { base.Un_User_Lock(rateKCByUserName.get_fgs_name()); base.Response.Write(base.ShowDialogBox("⑥合彩: 代理占成 不可高於" + this.six_rate_d + ",請修改!", null, 400)); base.Response.End(); } if (Convert.ToDouble(str9) > Convert.ToDouble(this.kc_usable_credit_d)) { base.Un_User_Lock(rateKCByUserName.get_fgs_name()); base.Response.Write(base.ShowDialogBox("快彩:‘信用額度’已超過‘上級可用餘額’,請修改!", null, 400)); base.Response.End(); } string str15 = LSRequest.qq("userRate_kc"); if (string.IsNullOrEmpty(str15)) { str15 = "0"; } if (Convert.ToDouble(str15) > Convert.ToDouble(this.kc_rate_d)) { base.Un_User_Lock(rateKCByUserName.get_fgs_name()); base.Response.Write(base.ShowDialogBox("快彩: 總代占成 不可高於" + this.kc_rate_d + ",請修改!", null, 400)); base.Response.End(); } int num4 = 0; decimal num5 = 0M; decimal num6 = 0M; if (!string.IsNullOrEmpty(this.lottrty_six)) { num4 = Convert.ToInt32(str14); num5 = Convert.ToDecimal(str5); num6 = Convert.ToDecimal(str5); } int num7 = 0; decimal num8 = 0M; decimal num9 = 0M; if (!string.IsNullOrEmpty(this.lottrty_kc)) { num7 = Convert.ToInt32(str15); num8 = Convert.ToDecimal(str9); num9 = Convert.ToDecimal(str9); } cz_users model = new cz_users(); model.set_u_id(Guid.NewGuid().ToString().ToUpper()); model.set_u_name(str); string ramSalt = Utils.GetRamSalt(6); model.set_u_psw(DESEncrypt.EncryptString(str3, ramSalt)); model.set_salt(ramSalt); model.set_u_nicker(str4); model.set_u_skin(base.GetUserSkin("hy")); model.set_sup_name(this.upuname); model.set_u_type("hy"); model.set_su_type("dl"); model.set_add_date(new DateTime?(DateTime.Now)); model.set_six_rate(new int?(num4)); model.set_six_credit(new decimal?(num5)); model.set_six_usable_credit(new decimal?(num6)); model.set_six_kind(str6); model.set_a_state(new int?(Convert.ToInt32(str2))); model.set_allow_opt(1); model.set_is_changed(0); model.set_kc_rate(new int?(num7)); model.set_kc_credit(new decimal?(num8)); model.set_kc_usable_credit(new decimal?(num9)); model.set_kc_kind(str10); model.set_kc_crash_payment(0); if (!string.IsNullOrEmpty(this.kc_iscash ?? "")) { model.set_kc_iscash(new int?(int.Parse(this.kc_iscash))); } if (!string.IsNullOrEmpty(this.six_iscash ?? "")) { model.set_six_iscash(new int?(int.Parse(this.six_iscash))); } cz_rate_kc _kc2 = new cz_rate_kc(); _kc2.set_u_name(str); _kc2.set_u_type("hy"); _kc2.set_dl_name(this.kc_dl_name); _kc2.set_zd_name(this.kc_zd_name); _kc2.set_gd_name(this.kc_gd_name); _kc2.set_fgs_name(this.kc_fgs_name); _kc2.set_dl_rate(new decimal?(num7)); _kc2.set_zd_rate(new decimal?(Convert.ToDecimal(this.kc_zd_rate))); _kc2.set_gd_rate(new decimal?(Convert.ToDecimal(this.kc_gd_rate))); _kc2.set_fgs_rate(new decimal?(Convert.ToDecimal(this.kc_fgs_rate))); _kc2.set_zj_rate(new decimal?(Convert.ToDecimal(this.kc_zj_rate))); cz_rate_six _six = new cz_rate_six(); _six.set_u_name(str); _six.set_u_type("hy"); _six.set_dl_name(this.six_dl_name); _six.set_zd_name(this.six_zd_name); _six.set_gd_name(this.six_gd_name); _six.set_fgs_name(this.six_fgs_name); _six.set_dl_rate(new decimal?(num4)); _six.set_zd_rate(new decimal?(Convert.ToDecimal(this.six_zd_rate))); _six.set_gd_rate(new decimal?(Convert.ToDecimal(this.six_gd_rate))); _six.set_fgs_rate(new decimal?(Convert.ToDecimal(this.six_fgs_rate))); _six.set_zj_rate(new decimal?(Convert.ToDecimal(this.six_zj_rate))); string str17 = ""; if (CallBLL.cz_users_bll.AddUserInfoHY(model, _kc2, _six, ref str17, str7.ToUpper(), str11.ToUpper())) { int?nullable = model.get_six_iscash(); int num13 = int.Parse("1"); if ((nullable.GetValueOrDefault() == num13) && nullable.HasValue) { cz_users _users2 = new cz_users(); _users2.set_u_name(model.get_u_name()); _users2.set_six_usable_credit(0); cz_users _users3 = new cz_users(); _users3.set_u_name(model.get_sup_name()); _users3.set_six_usable_credit(new decimal?(decimal.Parse(this.six_usable_credit_d))); int num14 = 1; if (base.IsMasterLotteryExist(num14.ToString())) { base.UserRecharge_six(_users2, _users3, str5); } } int?nullable2 = model.get_kc_iscash(); int num15 = int.Parse("1"); if ((nullable2.GetValueOrDefault() == num15) && nullable2.HasValue) { cz_users _users4 = new cz_users(); _users4.set_u_name(model.get_u_name()); _users4.set_kc_usable_credit(0); cz_users _users5 = new cz_users(); _users5.set_u_name(model.get_sup_name()); _users5.set_kc_usable_credit(new decimal?(decimal.Parse(this.kc_usable_credit_d))); int num16 = 2; if (base.IsMasterLotteryExist(num16.ToString())) { base.UserRecharge_kc(_users4, _users5, str9); } } int num10 = 2; if (this.lottrty_six == "") { num10 = 1; } else if (this.lottrty_kc == "") { num10 = 0; } else if ((this.lottrty_kc != "") && (this.lottrty_six != "")) { num10 = 2; } base.user_add_hy_log(model, false, num10, str7, str11); base.Un_User_Lock(rateKCByUserName.get_fgs_name()); string url = "/Account/drawback.aspx?uid=" + str17 + "&isadd=1"; base.Response.Write(base.ShowDialogBox("添加會員成功!", url, 0)); base.Response.End(); } else { base.Un_User_Lock(rateKCByUserName.get_fgs_name()); base.Response.Write(base.ShowDialogBox("添加會員失敗!", base.UserReturnBackUrl, 400)); base.Response.End(); } }
private void AddUser() { string str = LSRequest.qq("userName").ToLower().Trim(); string str2 = "0"; LSRequest.qq("userState"); string str3 = LSRequest.qq("userPassword"); string str4 = LSRequest.qq("userNicker"); this.upuname = this.u_name; string str5 = LSRequest.qq("sltupuser"); cz_users userInfoByUID = CallBLL.cz_users_bll.GetUserInfoByUID(str5); this.upuname = userInfoByUID.get_u_name(); if (!userInfoByUID.get_u_type().ToLower().Equals(this.checkredio.ToLower())) { base.Response.End(); } if (userInfoByUID.get_u_type().ToLower().Equals("dl") || userInfoByUID.get_u_type().ToLower().Equals("zj")) { base.Response.End(); } if (!string.IsNullOrEmpty(this.upuname) && !base.IsUpperLowerLevels(this.upuname, this.userModel.get_u_type(), this.userModel.get_u_name())) { base.Response.End(); } this.GetRateInfo(userInfoByUID.get_u_id(), this.checkredio); string str6 = LSRequest.qq("userCredit_six"); string str7 = LSRequest.qq("userKind_six"); if (!this.six_kind_d.Equals("0")) { str7 = this.six_kind_d; } else if (string.IsNullOrEmpty(str7) || str7.Equals("0")) { str7 = "A"; } string str8 = LSRequest.qq("sltDrawback_six"); if (string.IsNullOrEmpty(str6)) { str6 = "0"; } if (string.IsNullOrEmpty(str8)) { str8 = "0"; } switch (str8) { case "0": str8 = "0"; break; case "1": str8 = "0.1"; break; case "2": str8 = "0.2"; break; case "3": str8 = "0.3"; break; case "4": str8 = "0.4"; break; case "5": str8 = "NO"; break; case "auto": break; default: base.Response.End(); break; } if (str8.Equals("auto")) { string s = LSRequest.qq("sltDrawbackAuto_six"); try { if (double.Parse(s) < 0.0) { base.noRightOptMsg("⑥合彩: 退水設定 不能小於0!"); } } catch { base.noRightOptMsg("⑥合彩: 退水設定 輸入錯誤!"); } str8 = s; } string str10 = LSRequest.qq("userCredit_kc"); string str11 = LSRequest.qq("userKind_kc"); if (!this.kc_kind_d.Equals("0")) { str11 = this.kc_kind_d; } else if (string.IsNullOrEmpty(str11) || str11.Equals("0")) { str11 = "A"; } string str12 = LSRequest.qq("sltDrawback_kc"); if (string.IsNullOrEmpty(str10)) { str10 = "0"; } if (string.IsNullOrEmpty(str12)) { str12 = "0"; } switch (str12) { case "0": str12 = "0"; break; case "1": str12 = "0.1"; break; case "2": str12 = "0.2"; break; case "3": str12 = "0.3"; break; case "4": str12 = "0.4"; break; case "5": str12 = "NO"; break; case "auto": break; default: base.Response.End(); break; } if (str12.Equals("auto")) { string str13 = LSRequest.qq("sltDrawbackAuto_kc"); try { if (double.Parse(str13) < 0.0) { base.noRightOptMsg("快彩: 退水設定 不能小於0!"); } } catch { base.noRightOptMsg("快彩: 退水設定 輸入錯誤!"); } str12 = str13; } string message = ""; if (!base.ValidParamByUserAdd("hydu", ref message, null, this.lottrty_six, this.lottrty_kc)) { base.noRightOptMsg(message); } if (!Regexlib.IsValidPassword(str3.Trim(), base.get_GetPasswordLU())) { if (base.get_GetPasswordLU().Equals("1")) { base.noRightOptMsg("密碼要8-20位,且必需包含大寫字母、小寫字母和数字!"); } else { base.noRightOptMsg("密碼要8-20位,且必需包含字母、和数字!"); } base.Response.End(); } if (!string.IsNullOrEmpty(this.lottrty_six)) { if ((!str7.ToUpper().Equals("A") && !str7.ToUpper().Equals("B")) && !str7.ToUpper().Equals("C")) { base.Response.End(); } if (string.IsNullOrEmpty(str8)) { base.Response.End(); } } if (!string.IsNullOrEmpty(this.lottrty_kc)) { if ((!str11.ToUpper().Equals("A") && !str11.ToUpper().Equals("B")) && !str11.ToUpper().Equals("C")) { base.Response.End(); } if (string.IsNullOrEmpty(str12)) { base.Response.End(); } } cz_rate_kc rateKCByUserName = CallBLL.cz_rate_kc_bll.GetRateKCByUserName(this.upuname); base.En_User_Lock(rateKCByUserName.get_fgs_name()); if (Convert.ToDouble(str6) > Convert.ToDouble(this.six_usable_credit_d)) { base.Un_User_Lock(rateKCByUserName.get_fgs_name()); base.noRightOptMsg("⑥合彩:‘信用額度’已超過‘上級可用餘額’,請修改!"); } string str15 = LSRequest.qq("userRate_six"); if (string.IsNullOrEmpty(str15)) { str15 = "0"; } if (Convert.ToDouble(str15) > Convert.ToDouble(this.six_rate_d)) { base.Un_User_Lock(rateKCByUserName.get_fgs_name()); base.noRightOptMsg("⑥合彩: " + this.utypeTxt + "占成 不可高於" + this.six_rate_d + ",請修改!"); } if (Convert.ToDouble(str10) > Convert.ToDouble(this.kc_usable_credit_d)) { base.Un_User_Lock(rateKCByUserName.get_fgs_name()); base.noRightOptMsg("快彩:‘信用額度’已超過‘上級可用餘額’,請修改!"); } string str16 = LSRequest.qq("userRate_kc"); if (string.IsNullOrEmpty(str16)) { str16 = "0"; } if (Convert.ToDouble(str16) > Convert.ToDouble(this.kc_rate_d)) { base.Un_User_Lock(rateKCByUserName.get_fgs_name()); base.noRightOptMsg(""); } int num3 = 0; decimal num4 = 0M; decimal num5 = 0M; if (!string.IsNullOrEmpty(this.lottrty_six)) { num3 = Convert.ToInt32(str15); num4 = Convert.ToDecimal(str6); num5 = Convert.ToDecimal(str6); } int num6 = 0; decimal num7 = 0M; decimal num8 = 0M; if (!string.IsNullOrEmpty(this.lottrty_kc)) { num6 = Convert.ToInt32(str16); num7 = Convert.ToDecimal(str10); num8 = Convert.ToDecimal(str10); } cz_users model = new cz_users(); model.set_u_id(Guid.NewGuid().ToString().ToUpper()); model.set_u_name(str); string ramSalt = Utils.GetRamSalt(6); model.set_u_psw(DESEncrypt.EncryptString(str3, ramSalt)); model.set_salt(ramSalt); model.set_u_nicker(str4); model.set_u_skin(base.GetUserSkin("hy")); model.set_sup_name(this.upuname); model.set_u_type("hy"); model.set_su_type(this.checkredio); model.set_add_date(new DateTime?(DateTime.Now)); model.set_six_rate(new int?(num3)); model.set_six_credit(new decimal?(num4)); model.set_six_usable_credit(new decimal?(num5)); model.set_six_kind(str7); model.set_kc_rate(new int?(num6)); model.set_kc_credit(new decimal?(num7)); model.set_kc_usable_credit(new decimal?(num8)); model.set_kc_kind(str11); model.set_kc_crash_payment(0); model.set_a_state(new int?(Convert.ToInt32(str2))); model.set_allow_opt(1); model.set_is_changed(0); if (!string.IsNullOrEmpty(this.kc_iscash ?? "")) { model.set_kc_iscash(new int?(int.Parse(this.kc_iscash))); } if (!string.IsNullOrEmpty(this.six_iscash ?? "")) { model.set_six_iscash(new int?(int.Parse(this.six_iscash))); } cz_rate_kc _kc2 = new cz_rate_kc(); _kc2.set_u_name(str); _kc2.set_u_type("hy"); string checkredio = this.checkredio; if (checkredio != null) { if (!(checkredio == "fgs")) { if (checkredio == "gd") { _kc2.set_dl_name(""); _kc2.set_zd_name(str); _kc2.set_gd_name(this.kc_gd_name); _kc2.set_fgs_name(this.kc_fgs_name); _kc2.set_dl_rate(0); _kc2.set_zd_rate(0); _kc2.set_gd_rate(new decimal?(num6)); _kc2.set_fgs_rate(new decimal?(Convert.ToDecimal(this.kc_fgs_rate))); _kc2.set_zj_rate(new decimal?(Convert.ToDecimal(this.kc_zj_rate))); } else if (checkredio == "zd") { _kc2.set_dl_name(str); _kc2.set_zd_name(this.kc_zd_name); _kc2.set_gd_name(this.kc_gd_name); _kc2.set_fgs_name(this.kc_fgs_name); _kc2.set_dl_rate(0); _kc2.set_zd_rate(new decimal?(num6)); _kc2.set_gd_rate(new decimal?(Convert.ToDecimal(this.kc_gd_rate))); _kc2.set_fgs_rate(new decimal?(Convert.ToDecimal(this.kc_fgs_rate))); _kc2.set_zj_rate(new decimal?(Convert.ToDecimal(this.kc_zj_rate))); } } else { _kc2.set_dl_name(""); _kc2.set_zd_name(""); _kc2.set_gd_name(str); _kc2.set_fgs_name(this.kc_fgs_name); _kc2.set_dl_rate(0); _kc2.set_zd_rate(0); _kc2.set_gd_rate(0); _kc2.set_fgs_rate(new decimal?(Convert.ToDecimal(num6))); _kc2.set_zj_rate(new decimal?(Convert.ToDecimal(this.kc_zj_rate))); } } cz_rate_six _six = new cz_rate_six(); _six.set_u_name(str); _six.set_u_type("hy"); string str22 = this.checkredio; if (str22 != null) { if (!(str22 == "fgs")) { if (str22 == "gd") { _six.set_dl_name(""); _six.set_zd_name(str); _six.set_gd_name(this.six_gd_name); _six.set_fgs_name(this.six_fgs_name); _six.set_dl_rate(0); _six.set_zd_rate(0); _six.set_gd_rate(new decimal?(num3)); _six.set_fgs_rate(new decimal?(Convert.ToDecimal(this.six_fgs_rate))); _six.set_zj_rate(new decimal?(Convert.ToDecimal(this.six_zj_rate))); } else if (str22 == "zd") { _six.set_dl_name(str); _six.set_zd_name(this.six_zd_name); _six.set_gd_name(this.six_gd_name); _six.set_fgs_name(this.six_fgs_name); _six.set_dl_rate(0); _six.set_zd_rate(new decimal?(num3)); _six.set_gd_rate(new decimal?(Convert.ToDecimal(this.six_gd_rate))); _six.set_fgs_rate(new decimal?(Convert.ToDecimal(this.six_fgs_rate))); _six.set_zj_rate(new decimal?(Convert.ToDecimal(this.six_zj_rate))); } } else { _six.set_dl_name(""); _six.set_zd_name(""); _six.set_gd_name(str); _six.set_fgs_name(this.six_fgs_name); _six.set_dl_rate(0); _six.set_zd_rate(0); _six.set_gd_rate(0); _six.set_fgs_rate(new decimal?(Convert.ToDecimal(num3))); _six.set_zj_rate(new decimal?(Convert.ToDecimal(this.six_zj_rate))); } } string str18 = ""; Dictionary <string, string> data = new Dictionary <string, string>(); if (CallBLL.cz_users_bll.AddUserInfoHY(model, _kc2, _six, ref str18, str8.ToUpper(), str12.ToUpper())) { int num9 = 2; if (this.lottrty_six == "") { num9 = 1; } else if (this.lottrty_kc == "") { num9 = 0; } else if ((this.lottrty_kc != "") && (this.lottrty_six != "")) { num9 = 2; } base.user_add_hy_log(model, true, num9, str8, str12); base.Un_User_Lock(rateKCByUserName.get_fgs_name()); string text1 = "/Account/drawback.aspx?uid=" + str18 + "&isadd=1"; data.Add("uname", model.get_u_name()); data.Add("uid", model.get_u_id()); base.successOptMsg("添加直屬會員成功!", data); } else { base.Un_User_Lock(rateKCByUserName.get_fgs_name()); base.noRightOptMsg("添加直屬會員失敗!"); } }