Exemplo n.º 1
0
 private void AddUser()
 {
     string str = LSRequest.qq("userName").ToLower().Trim();
     string str2 = LSRequest.qq("userNicker");
     string str3 = LSRequest.qq("userKind_six");
     string message = "";
     if (!base.ValidParamByUserAdd("filluser", ref message, null, this.lottrty_six, this.lottrty_kc))
     {
         base.noRightOptMsg(message);
     }
     if ((!str3.ToUpper().Equals("A") && !str3.ToUpper().Equals("B")) && !str3.ToUpper().Equals("C"))
     {
         base.Response.End();
     }
     cz_saleset_six model = new cz_saleset_six();
     model.set_u_id(Guid.NewGuid().ToString());
     model.set_u_name(str.Trim());
     model.set_u_nicker(str2.Trim());
     model.set_six_kind(str3.Trim().ToUpper());
     model.set_add_date(new DateTime?(DateTime.Now));
     string str5 = "";
     Dictionary<string, string> data = new Dictionary<string, string>();
     if (CallBLL.cz_saleset_six_bll.AddUser(model, ref str5))
     {
         CallBLL.cz_saleset_six_bll.GetSaleSetUser();
         string str6 = "";
         str6 = str6 + "{" + "\"saleuser\": {";
         DataTable saleSetUser = CallBLL.cz_saleset_six_bll.GetSaleSetUser();
         if (saleSetUser != null)
         {
             for (int i = 0; i < saleSetUser.Rows.Count; i++)
             {
                 if (i == 0)
                 {
                     str6 = str6 + string.Format("\"{0}\": {1}", saleSetUser.Rows[i]["u_name"], saleSetUser.Rows[i]["flag"]);
                 }
                 else
                 {
                     str6 = str6 + string.Format(",\"{0}\": {1}", saleSetUser.Rows[i]["u_name"], saleSetUser.Rows[i]["flag"]);
                 }
             }
         }
         str6 = str6 + "}}";
         base.user_add_fill_log(model);
         string text1 = "/Account/filluser_drawback.aspx?uid=" + str5 + "&isadd=1";
         StringBuilder builder = new StringBuilder();
         builder.Append("<script>");
         builder.AppendFormat(" top.aAllowSaleUserName = {0};", str6);
         builder.Append("</script>");
         data.Add("uname", model.get_u_name());
         data.Add("uid", model.get_u_id());
         base.successOptMsg("添加外補會員成功!", data);
     }
     else
     {
         base.noRightOptMsg("添加外補會員失敗!");
     }
 }
Exemplo n.º 2
0
        protected void InitShortCut_SIX(string pk, cz_saleset_six cz_saleset_six_model)
        {
            DataSet drawBackList = CallBLL.cz_drawback_six_bll.GetDrawBackList(cz_saleset_six_model.get_u_name());

            if (((drawBackList != null) && (drawBackList.Tables.Count > 0)) && (drawBackList.Tables[0].Rows.Count > 0))
            {
                this.table_six = drawBackList.Tables[0];
            }
            DataRow row  = null;
            DataRow row2 = null;
            DataRow row3 = null;

            if (this.table_six != null)
            {
                row  = this.table_six.Select(" play_id=91001")[0];
                row2 = this.table_six.Select(" play_id=91003")[0];
                row3 = this.table_six.Select(" play_id=91016")[0];
            }
            if (row != null)
            {
                this.six_tm_pk_a              = row["a_drawback"].ToString();
                this.six_tm_pk_b              = row["b_drawback"].ToString();
                this.six_tm_pk_c              = row["c_drawback"].ToString();
                this.six_tm_max_amount        = row["single_max_amount"].ToString();
                this.six_tm_phase_amount      = row["single_phase_amount"].ToString();
                this.six_tm_max_amount        = string.Format("{0:F0}", Convert.ToDouble(this.six_tm_max_amount));
                this.six_tm_phase_amount      = string.Format("{0:F0}", Convert.ToDouble(this.six_tm_phase_amount));
                this.six_tm_single_min_amount = string.Format("{0:F0}", Convert.ToDouble(row["single_min_amount"].ToString()));
            }
            if (row2 != null)
            {
                this.six_lmp_pk_a              = row2["a_drawback"].ToString();
                this.six_lmp_pk_b              = row2["b_drawback"].ToString();
                this.six_lmp_pk_c              = row2["c_drawback"].ToString();
                this.six_lmp_max_amount        = row2["single_max_amount"].ToString();
                this.six_lmp_phase_amount      = row2["single_phase_amount"].ToString();
                this.six_lmp_max_amount        = string.Format("{0:F0}", Convert.ToDouble(this.six_lmp_max_amount));
                this.six_lmp_phase_amount      = string.Format("{0:F0}", Convert.ToDouble(this.six_lmp_phase_amount));
                this.six_lmp_single_min_amount = string.Format("{0:F0}", Convert.ToDouble(row2["single_min_amount"].ToString()));
            }
            if (row3 != null)
            {
                this.six_lm_pk_a              = row3["a_drawback"].ToString();
                this.six_lm_pk_b              = row3["b_drawback"].ToString();
                this.six_lm_pk_c              = row3["c_drawback"].ToString();
                this.six_lm_max_amount        = row3["single_max_amount"].ToString();
                this.six_lm_phase_amount      = row3["single_phase_amount"].ToString();
                this.six_lm_max_amount        = string.Format("{0:F0}", Convert.ToDouble(this.six_lm_max_amount));
                this.six_lm_phase_amount      = string.Format("{0:F0}", Convert.ToDouble(this.six_lm_phase_amount));
                this.six_lm_single_min_amount = string.Format("{0:F0}", Convert.ToDouble(row3["single_min_amount"].ToString()));
            }
        }
Exemplo n.º 3
0
        private void getMemberDetail(ref string strResult)
        {
            base.checkLoginByHandler(0);
            ReturnResult result = new ReturnResult();
            Dictionary <string, object> dictionary = new Dictionary <string, object>();

            new List <object>();
            string str = this.Session["user_name"].ToString();
            agent_userinfo_session _session = this.Session[str + "lottery_session_user_info"] as agent_userinfo_session;

            if (!_session.get_u_type().Trim().Equals("zj"))
            {
                base.Response.End();
            }
            base.Permission_Aspx_ZJ_Mobile("po_2_3");
            this.uid = LSRequest.qq("uid");
            string str2 = LSRequest.qq("memberId");
            string str3 = LSRequest.qq("submitType");

            if (str2 != "sales")
            {
                base.Response.End();
            }
            this.lotteryDT = base.GetLotteryList();
            DataTable table = this.lotteryDT.DefaultView.ToTable(true, new string[] { "master_id" });

            for (int i = 0; i < table.Rows.Count; i++)
            {
                if (Convert.ToInt32(table.Rows[i][0]).Equals(1))
                {
                    this.lottrty_six = table.Rows[i][0].ToString();
                }
                else if (Convert.ToInt32(table.Rows[i][0]).Equals(2))
                {
                    this.lottrty_kc = table.Rows[i][0].ToString();
                }
            }
            cz_saleset_six model = null;

            model = CallBLL.cz_saleset_six_bll.GetModel(this.uid);
            if (model == null)
            {
                base.Response.End();
            }
            switch (str3)
            {
            case "view":
            {
                Dictionary <string, object> dictionary2 = new Dictionary <string, object>();
                dictionary2.Add("name", model.get_u_name());
                dictionary2.Add("nicker", model.get_u_nicker());
                dictionary2.Add("userKind", model.get_six_kind().ToUpper());
                dictionary2.Add("date", model.get_add_date());
                dictionary2.Add("type", model.get_flag());
                dictionary = dictionary2;
                result.set_success(200);
                result.set_data(dictionary);
                strResult = base.ObjectToJson(result);
                break;
            }

            case "edit":
                this.AddUser();
                break;
            }
        }