Example #1
0
    private void OpenSavePage()
    {
        int id     = int.Parse(Utils.GetRequest("id", "post", 2, @"^[1-9]\d*$", "ID错误"));
        int WinNum = int.Parse(Utils.GetRequest("WinNum", "post", 2, @"^[1-9]$|^[1-4]([0-9])?$", "开出数字限1-" + ub.GetSub("BallSysNum", xmlPath) + ""));

        if (WinNum < 1 || WinNum > Utils.ParseInt(ub.GetSub("BallSysNum", xmlPath)))
        {
            Utils.Error("下注数字限1-" + ub.GetSub("BallSysNum", xmlPath) + "", "");
        }
        if (!new BCW.BLL.Game.Balllist().Exists(id))
        {
            Utils.Error("不存在的记录", "");
        }

        //记录日志
        if (Utils.GetDomain().Contains("kubao") || Utils.GetDomain().Contains("tuhao") || Utils.GetDomain().Contains("th") || Utils.GetDomain().Contains("kb288"))
        {
            int    ManageId     = new BCW.User.Manage().IsManageLogin();
            String sLogFilePath = System.AppDomain.CurrentDomain.BaseDirectory.ToString() + "/logstr/" + DateTime.Now.ToString("MM-dd") + ".txt";
            LogHelper.Write(sLogFilePath, "操作管理员:" + ManageId + "号/彩球开奖|期数:" + id + "/开奖数字:" + WinNum + "");
        }

        new BCW.User.Ball().BallPage(id, WinNum);
        Utils.Success("第" + id + "期开奖", "第" + id + "期开奖成功..", Utils.getUrl("ball.aspx"), "1");
    }
Example #2
0
    private void DelPage()
    {
        int ManageId = new BCW.User.Manage().IsManageLogin();

        if (ManageId != 1 && ManageId != 9)
        {
            Utils.Error("权限不足", "");
        }
        string info = Utils.GetRequest("info", "all", 1, "", "");
        int    id   = int.Parse(Utils.GetRequest("id", "get", 2, @"^[1-9]\d*$", "ID错误"));

        if (info == "")
        {
            Master.Title = "删除掷骰";
            builder.Append(Out.Tab("<div class=\"title\">", ""));
            builder.Append("确定删除该记录吗");
            builder.Append(Out.Tab("</div>", "<br />"));
            builder.Append(Out.Tab("<div>", ""));
            builder.Append("<a href=\"" + Utils.getUrl("dxdice.aspx?info=ok&amp;act=del&amp;id=" + id + "&amp;backurl=" + Utils.getPage(0) + "") + "\">确定删除</a><br />");
            builder.Append("<a href=\"" + Utils.getUrl("dxdice.aspx?act=edit&amp;id=" + id + "&amp;backurl=" + Utils.getPage(0) + "") + "\">先留着吧..</a>");
            builder.Append(Out.Tab("</div>", "<br />"));
        }
        else
        {
            if (!new BCW.BLL.Game.Dxdice().Exists(id))
            {
                Utils.Error("不存在的记录", "");
            }
            new BCW.BLL.Game.Dxdice().Delete(id);
            Utils.Success("删除掷骰", "删除成功..", Utils.getPage("dxdice.aspx"), "1");
        }
    }
Example #3
0
    private void EditSavePage()
    {
        int ManageId = new BCW.User.Manage().IsManageLogin();

        if (ManageId != 1 && ManageId != 9)
        {
            Utils.Error("权限不足", "");
        }
        int      id       = int.Parse(Utils.GetRequest("id", "post", 2, @"^[1-9]\d*$", "ID错误"));
        string   OpenText = Utils.GetRequest("OpenText", "post", 2, @"^[^\^]{2,5}$", "开出结果填写错误");
        DateTime EndTime  = Utils.ParseTime(Utils.GetRequest("EndTime", "post", 2, DT.RegexTime, "开奖时间格式填写出错,正确格式如" + DT.FormatDate(DateTime.Now, 0) + ""));

        if (!new BCW.BLL.Game.Applelist().Exists(id))
        {
            Utils.Error("不存在的记录", "");
        }

        //记录日志
        if (Utils.GetDomain().Contains("kubao") || Utils.GetDomain().Contains("tuhao") || Utils.GetDomain().Contains("th") || Utils.GetDomain().Contains("kb288"))
        {
            String sLogFilePath = System.AppDomain.CurrentDomain.BaseDirectory.ToString() + "/logstr/" + DateTime.Now.ToString("MM-dd") + ".txt";
            LogHelper.Write(sLogFilePath, "操作管理员:" + ManageId + "号/编辑苹果机期数:" + id + "|是否预设:" + OpenText + "");
        }

        BCW.Model.Game.Applelist model = new BCW.Model.Game.Applelist();
        model.ID       = id;
        model.EndTime  = EndTime;
        model.OpenText = OpenText;
        new BCW.BLL.Game.Applelist().Update(model);
        Utils.Success("编辑第" + id + "期", "编辑第" + id + "期成功..", Utils.getUrl("apple.aspx?act=edit&amp;id=" + id + "&amp;backurl=" + Utils.getPage(0) + ""), "1");
    }
Example #4
0
    private void ClearPage()
    {
        int ManageId = new BCW.User.Manage().IsManageLogin();

        if (ManageId != 1 && ManageId != 9)
        {
            Utils.Error("权限不足", "");
        }
        string info = Utils.GetRequest("info", "all", 1, "", "");

        if (info == "")
        {
            Master.Title = "清空下注记录";
            builder.Append(Out.Tab("<div class=\"title\">", ""));
            builder.Append("确定清空下注记录吗,清空下注记录将清空排行榜与赢利分析");
            builder.Append(Out.Tab("</div>", "<br />"));
            builder.Append(Out.Tab("<div>", ""));
            builder.Append("<a href=\"" + Utils.getUrl("bigsmall.aspx?info=ok&amp;act=clear") + "\">确定清空</a><br />");
            builder.Append("<a href=\"" + Utils.getUrl("bigsmall.aspx") + "\">再看看吧..</a>");
            builder.Append(Out.Tab("</div>", "<br />"));
        }
        else
        {
            new BCW.Data.SqlUp().ClearTable("tb_Bspay");
            Utils.Success("清空下注", "清空下注记录成功..", Utils.getUrl("bigsmall.aspx"), "1");
        }
    }
Example #5
0
    private void EditPage()
    {
        int ManageId = new BCW.User.Manage().IsManageLogin();

        if (ManageId != 1 && ManageId != 9)
        {
            Utils.Error("权限不足", "");
        }
        int id = int.Parse(Utils.GetRequest("id", "get", 2, @"^[1-9]\d*$", "大小庄ID错误"));

        Master.Title = "编辑大小庄";
        builder.Append(Out.Tab("<div class=\"title\">", ""));
        builder.Append("编辑大小庄");
        builder.Append(Out.Tab("</div>", ""));
        BCW.Model.Game.Bslist model = new BCW.BLL.Game.Bslist().GetBslist(id);
        if (model == null)
        {
            Utils.Error("不存在的记录", "");
        }
        string strText = "庄名:/,最小下注:/,最大下注:/,用户ID:/,用户昵称:/,人气:/,创建时间:/,,,";
        string strName = "Title,SmallPay,BigPay,UsID,UsName,Click,AddTime,id,act,backurl";
        string strType = "text,num,num,num,text,num,date,hidden,hidden,hidden";
        string strValu = "" + model.Title + "'" + model.SmallPay + "'" + model.BigPay + "'" + model.UsID + "'" + model.UsName + "'" + model.Click + "'" + model.AddTime + "'" + id + "'editsave'" + Utils.getPage(0) + "";
        string strEmpt = "false,false,false,false,false,false,false,false,false,false";
        string strIdea = "/";
        string strOthe = "确定编辑|reset,bigsmall.aspx,post,1,red|blue";

        builder.Append(Out.wapform(strText, strName, strType, strValu, strEmpt, strIdea, strOthe));
        builder.Append(Out.Tab("<div class=\"hr\"></div>", Out.Hr()));
        builder.Append(Out.Tab("<div>", ""));
        builder.Append("<a href=\"" + Utils.getPage("bigsmall.aspx") + "\">返回上一级</a><br />");
        builder.Append("<a href=\"" + Utils.getUrl("bigsmall.aspx?act=del&amp;id=" + id + "&amp;backurl=" + Utils.getPage(0) + "") + "\">删除记录</a><br />");
        builder.Append(Out.Tab("</div><div class=\"title\"><a href=\"" + Utils.getUrl("../default.aspx") + "\">返回管理中心</a>", "<a href=\"" + Utils.getUrl("../default.aspx") + "\">返回管理中心</a>"));
        builder.Append(Out.Tab("</div>", "<br />"));
    }
Example #6
0
    private void ResetPage()
    {
        int ManageId = new BCW.User.Manage().IsManageLogin();

        if (ManageId != 1 && ManageId != 9)
        {
            Utils.Error("权限不足", "");
        }
        string info = Utils.GetRequest("info", "all", 1, "", "");

        if (info == "")
        {
            Master.Title = "重置游戏";
            builder.Append(Out.Tab("<div class=\"title\">", ""));
            builder.Append("确定重置苹果机游戏吗,重置后,将重新从第一期开始,所有记录将会期数和下注记录全被删除");
            builder.Append(Out.Tab("</div>", "<br />"));
            builder.Append(Out.Tab("<div>", ""));
            builder.Append("<a href=\"" + Utils.getUrl("apple.aspx?info=ok&amp;act=reset") + "\">确定重置</a><br />");
            builder.Append("<a href=\"" + Utils.getUrl("apple.aspx") + "\">再看看吧..</a>");
            builder.Append(Out.Tab("</div>", "<br />"));
        }
        else
        {
            new BCW.Data.SqlUp().ClearTable("tb_Applelist");
            new BCW.Data.SqlUp().ClearTable("tb_Applepay");
            Utils.Success("重置游戏", "重置游戏成功..", Utils.getUrl("apple.aspx"), "1");
        }
    }
Example #7
0
    private void EditPage()
    {
        int ManageId = new BCW.User.Manage().IsManageLogin();

        if (Utils.GetTopDomain().Contains("tuhao") || Utils.GetTopDomain().Contains("th"))
        {
            if (ManageId != 1 && ManageId != 2)
            {
                Utils.Error("权限不足", "");
            }
        }
        else if (Utils.GetTopDomain().Contains("kb288.net"))
        {
            if (ManageId != 1 && ManageId != 3 && ManageId != 4 && ManageId != 5)
            {
                Utils.Error("权限不足", "");
            }
        }
        else
        {
            if (ManageId != 1 && ManageId != 9)
            {
                Utils.Error("权限不足", "");
            }
        }
        int id = int.Parse(Utils.GetRequest("id", "get", 2, @"^[1-9]\d*$", "跑马ID错误"));

        Master.Title = "编辑跑马";
        builder.Append(Out.Tab("<div class=\"title\">", ""));
        builder.Append("编辑第" + id + "局跑马");
        builder.Append(Out.Tab("</div>", ""));
        BCW.Model.Game.Horselist model = new BCW.BLL.Game.Horselist().GetHorselist(id);
        if (model == null)
        {
            Utils.Error("不存在的记录", "");
        }
        if (model.State == 0)
        {
            builder.Append(Out.Tab("<div class=\"text\">", "<br />"));
            builder.Append("当开出数字非0时,开奖时则使用该数字作为开奖结果");
            builder.Append(Out.Tab("</div>", ""));
        }
        string strText = "开出数字(如填写12即开出[1-2]):/,开盘时间:/,开奖时间:/,,,";
        string strName = "WinNum,BeginTime,EndTime,id,act,backurl";
        string strType = "num,date,date,hidden,hidden,hidden";
        string strValu = "" + model.WinNum + "'" + model.BeginTime + "'" + model.EndTime + "'" + id + "'editsave'" + Utils.getPage(0) + "";
        string strEmpt = "false,false,false,false,false,false";
        string strIdea = "/";
        string strOthe = "确定编辑|reset,horse.aspx,post,1,red|blue";

        builder.Append(Out.wapform(strText, strName, strType, strValu, strEmpt, strIdea, strOthe));
        builder.Append(Out.Tab("<div class=\"hr\"></div>", Out.Hr()));
        builder.Append(Out.Tab("<div>", ""));
        builder.Append("<a href=\"" + Utils.getPage("horse.aspx") + "\">返回上一级</a><br />");
        builder.Append("<a href=\"" + Utils.getUrl("horse.aspx?act=del&amp;id=" + id + "&amp;backurl=" + Utils.getPage(0) + "") + "\">删除本局</a><br />");
        builder.Append(Out.Tab("</div><div class=\"title\"><a href=\"" + Utils.getUrl("../default.aspx") + "\">返回管理中心</a>", "<a href=\"" + Utils.getUrl("../default.aspx") + "\">返回管理中心</a>"));
        builder.Append(Out.Tab("</div>", "<br />"));
    }
Example #8
0
    private void DelPage()
    {
        int ManageId = new BCW.User.Manage().IsManageLogin();

        if (Utils.GetTopDomain().Contains("tuhao") || Utils.GetTopDomain().Contains("th"))
        {
            if (ManageId != 1 && ManageId != 2)
            {
                Utils.Error("权限不足", "");
            }
        }
        else if (Utils.GetTopDomain().Contains("kb288.net"))
        {
            if (ManageId != 1 && ManageId != 3 && ManageId != 4 && ManageId != 5)
            {
                Utils.Error("权限不足", "");
            }
        }
        else
        {
            if (ManageId != 1 && ManageId != 9)
            {
                Utils.Error("权限不足", "");
            }
        }
        string info = Utils.GetRequest("info", "all", 1, "", "");
        int    id   = int.Parse(Utils.GetRequest("id", "get", 2, @"^[1-9]\d*$", "ID错误"));

        if (info == "")
        {
            Master.Title = "删除第" + id + "局";
            builder.Append(Out.Tab("<div class=\"title\">", ""));
            builder.Append("确定第" + id + "局记录吗.删除同时将会删除该局的下注记录.");
            builder.Append(Out.Tab("</div>", "<br />"));
            builder.Append(Out.Tab("<div>", ""));
            builder.Append("<a href=\"" + Utils.getUrl("horse.aspx?info=ok&amp;act=del&amp;id=" + id + "&amp;backurl=" + Utils.getPage(0) + "") + "\">确定删除</a><br />");
            builder.Append("<a href=\"" + Utils.getUrl("horse.aspx?act=edit&amp;id=" + id + "&amp;backurl=" + Utils.getPage(0) + "") + "\">先留着吧..</a>");
            builder.Append(Out.Tab("</div>", "<br />"));
        }
        else
        {
            if (!new BCW.BLL.Game.Horselist().Exists(id))
            {
                Utils.Error("不存在的记录", "");
            }

            //记录日志
            if (Utils.GetDomain().Contains("kubao") || Utils.GetDomain().Contains("tuhao") || Utils.GetDomain().Contains("th") || Utils.GetDomain().Contains("kb288"))
            {
                String sLogFilePath = System.AppDomain.CurrentDomain.BaseDirectory.ToString() + "/logstr/" + DateTime.Now.ToString("MM-dd") + ".txt";
                LogHelper.Write(sLogFilePath, "操作管理员:" + ManageId + "号/删除跑马期数:" + id + "");
            }

            new BCW.BLL.Game.Horselist().Delete(id);
            new BCW.BLL.Game.Horsepay().Delete("HorseId=" + id + "");
            Utils.Success("删除第" + id + "局", "删除第" + id + "局成功..", Utils.getPage("horse.aspx"), "1");
        }
    }
Example #9
0
    protected void Page_Load(object sender, EventArgs e)
    {
        Master.Title = "认证手机号列表";
        int ManageId = new BCW.User.Manage().IsManageLogin();

        if (ManageId != 1)
        {
            Utils.Error("权限不足", "");
        }
        int ptype = int.Parse(Utils.GetRequest("ptype", "get", 1, @"^[1-3]$", "0"));

        if (ptype > 0)
        {
            DataSet ds = new BCW.BLL.User().GetList("mobile", "IsVerify=1 and mobile<>'15107583999' and mobile<>'15107583888' and mobile<>'15107582999' order by regtime desc");
            if (ds != null && ds.Tables[0].Rows.Count > 0)
            {
                for (int i = 0; i < ds.Tables[0].Rows.Count; i++)
                {
                    string Mobile = ds.Tables[0].Rows[i]["mobile"].ToString();

                    if (ptype == 1)
                    {
                        builder.Append(Mobile + "<br />");
                    }
                    else if (ptype == 2)
                    {
                        builder.Append(Mobile + "#");
                    }
                    else if (ptype == 3)
                    {
                        builder.Append(Mobile + ",");
                    }
                }
            }
        }
        else
        {
            builder.Append(Out.Tab("<div>", ""));
            builder.Append("使用IE浏览器查看才可以浏览完全");
            builder.Append(Out.Tab("</div>", "<br />"));
            builder.Append(Out.Tab("<div>", ""));
            builder.Append("<a href=\"" + Utils.getUrl("rzmobile.aspx?ptype=1") + "\">换行查看</a><br />");
            builder.Append("<a href=\"" + Utils.getUrl("rzmobile.aspx?ptype=2") + "\">#分开查看</a><br />");
            builder.Append("<a href=\"" + Utils.getUrl("rzmobile.aspx?ptype=3") + "\">,分开查看</a>");
            builder.Append(Out.Tab("</div>", ""));
        }
        builder.Append(Out.Tab("<div class=\"hr\"></div>", Out.Hr()));
        builder.Append(Out.Tab("<div>", ""));
        builder.Append("<a href=\"" + Utils.getUrl("default.aspx") + "\">系统服务中心</a><br />");
        builder.Append(Out.Tab("</div><div class=\"title\"><a href=\"" + Utils.getUrl("../default.aspx") + "\">返回管理中心</a>", "<a href=\"" + Utils.getUrl("../default.aspx") + "\">返回管理中心</a>"));
        builder.Append(Out.Tab("</div>", "<br />"));
    }
Example #10
0
    private void BackSavePage(string act)
    {
        int ManageId = new BCW.User.Manage().IsManageLogin();

        if (ManageId != 1)
        {
            Utils.Error("权限不足", "");
        }

        int iTar   = Utils.ParseInt(Utils.GetRequest("iTar", "post", 2, @"^[0-9]\d*$", "千分比填写错误"));
        int iPrice = Utils.ParseInt(Utils.GetRequest("iPrice", "post", 2, @"^[0-9]\d*$", "至少多少币才返填写错误"));

        if (act == "backsave")
        {
            DataSet ds = new BCW.BLL.Toplist().GetList("UsID,sum(WinGold + PutGold) as WinCents", "Types=9 group by UsID order by sum(WinGold + PutGold) desc");
            for (int i = 0; i < ds.Tables[0].Rows.Count; i++)
            {
                long Cents = Convert.ToInt64(ds.Tables[0].Rows[i]["WinCents"]);
                if (Cents > 0 && Cents >= iPrice)
                {
                    int  usid = Convert.ToInt32(ds.Tables[0].Rows[i]["UsID"]);
                    long cent = Convert.ToInt64(Cents * (iTar * 0.001));
                    new BCW.BLL.User().UpdateiGold(usid, cent, "大小庄返赢");
                    //发内线
                    string strLog = "根据你上期大小庄排行榜上的赢利情况,系统自动返还了" + cent + "" + ub.Get("SiteBz") + "[url=/bbs/game/bigsmall.aspx]进入大小庄[/url]";

                    new BCW.BLL.Guest().Add(0, usid, new BCW.BLL.User().GetUsName(usid), strLog);
                }
            }

            Utils.Success("返赢操作", "返赢操作成功", Utils.getUrl("bigsmall.aspx"), "1");
        }
        else
        {
            DataSet ds = new BCW.BLL.Toplist().GetList("UsID,sum(WinGold + PutGold) as WinCents", "Types=9 group by UsID order by sum(WinGold + PutGold) desc");
            for (int i = 0; i < ds.Tables[0].Rows.Count; i++)
            {
                long Cents = Convert.ToInt64(ds.Tables[0].Rows[i]["WinCents"]);
                if (Cents < 0 && Cents < (-iPrice))
                {
                    int  usid = Convert.ToInt32(ds.Tables[0].Rows[i]["UsID"]);
                    long cent = Convert.ToInt64((-Cents) * (iTar * 0.001));
                    new BCW.BLL.User().UpdateiGold(usid, cent, "大小庄返负");
                    //发内线
                    string strLog = "根据你上期大小庄排行榜上的亏损情况,系统自动返还了" + cent + "" + ub.Get("SiteBz") + "[url=/bbs/game/bigsmall.aspx]进入大小庄[/url]";
                    new BCW.BLL.Guest().Add(0, usid, new BCW.BLL.User().GetUsName(usid), strLog);
                }
            }

            Utils.Success("返负操作", "返负操作成功", Utils.getUrl("bigsmall.aspx"), "1");
        }
    }
Example #11
0
    private void delPage()
    {
        int ManageId = new BCW.User.Manage().IsManageLogin();

        if (ManageId != 1 && ManageId != 26 && ManageId != 9)
        {
            Utils.Error("只有系统管理员1号、9号、26号才可以进行此操作", "");
        }
        string info = Utils.GetRequest("info", "all", 1, "", "");

        if (info == "")
        {
            int ID = int.Parse(Utils.GetRequest("ID", "all", 2, @"^[1-9]\d*$", "ID错误"));
            if (new BCW.BLL.User().Exists(ID))
            {
                DataSet ds = new BCW.BLL.User().GetList("IsSpier", "ID=" + ID + "");
                if (int.Parse(ds.Tables[0].Rows[0]["IsSpier"].ToString()) == 0)
                {
                    Utils.Error("该ID已不是系统号,不用重复操作.", "");
                }
                else
                {
                    Master.Title = "删除该ID为系统号吗";
                    builder.Append(Out.Tab("<div class=\"title\">", ""));
                    builder.Append("删除该ID为系统号吗");
                    builder.Append(Out.Tab("</div>", "<br />"));
                    builder.Append(Out.Tab("<div>", ""));
                    builder.Append("<a href=\"" + Utils.getUrl("robotset.aspx?info=ok&amp;act=del&amp;id=" + ID + "") + "\">确定删除</a><br />");
                    builder.Append("<a href=\"" + Utils.getUrl("robotset.aspx?act=select&amp;id=" + ID + "") + "\">先留着吧..</a>");
                    builder.Append(Out.Tab("</div>", "<br />"));
                }
            }
            else
            {
                Utils.Error("不存在的会员.操作失败.", "");
            }
        }
        else
        {
            int ID = int.Parse(Utils.GetRequest("ID", "get", 2, @"^[1-9]\d*$", "ID错误"));
            new BCW.BLL.User().update_ziduan("IsSpier=0", "ID=" + ID + "");
            BCW.Model.xitonghao aa = new BCW.Model.xitonghao();
            aa.UsID    = ManageId;
            aa.caoID   = ID;
            aa.AddTime = DateTime.Now;
            aa.IP      = Utils.GetUsIP();
            aa.type    = 1;
            new BCW.BLL.xitonghao().Add(aa);
            Utils.Success("删除", "删除系统号成功..", Utils.getPage("robotset.aspx?act=select&amp;ID=" + ID + ""), "1");
        }
    }
Example #12
0
    private void EditSavePage()
    {
        int ManageId = new BCW.User.Manage().IsManageLogin();

        if (Utils.GetTopDomain().Contains("tuhao") || Utils.GetTopDomain().Contains("th"))
        {
            if (ManageId != 1 && ManageId != 2)
            {
                Utils.Error("权限不足", "");
            }
        }
        else if (Utils.GetTopDomain().Contains("kb288.net"))
        {
            if (ManageId != 1 && ManageId != 3 && ManageId != 4 && ManageId != 5)
            {
                Utils.Error("权限不足", "");
            }
        }
        else
        {
            if (ManageId != 1 && ManageId != 9)
            {
                Utils.Error("权限不足", "");
            }
        }
        int      id        = int.Parse(Utils.GetRequest("id", "post", 2, @"^[1-9]\d*$", "ID错误"));
        int      WinNum    = int.Parse(Utils.GetRequest("WinNum", "post", 2, @"^[0-9]\d*$", "开出数字填写错误"));
        DateTime BeginTime = Utils.ParseTime(Utils.GetRequest("BeginTime", "post", 2, DT.RegexTime, "开盘时间格式填写出错,正确格式如" + DT.FormatDate(DateTime.Now, 0) + ""));
        DateTime EndTime   = Utils.ParseTime(Utils.GetRequest("EndTime", "post", 2, DT.RegexTime, "开奖时间格式填写出错,正确格式如" + DT.FormatDate(DateTime.Now, 0) + ""));

        if (!new BCW.BLL.Game.Horselist().Exists(id))
        {
            Utils.Error("不存在的记录", "");
        }

        //记录日志
        if (Utils.GetDomain().Contains("kubao") || Utils.GetDomain().Contains("tuhao") || Utils.GetDomain().Contains("th") || Utils.GetDomain().Contains("kb288"))
        {
            String sLogFilePath = System.AppDomain.CurrentDomain.BaseDirectory.ToString() + "/logstr/" + DateTime.Now.ToString("MM-dd") + ".txt";
            LogHelper.Write(sLogFilePath, "操作管理员:" + ManageId + "号/编辑跑马期数:" + id + "|是否预设:" + WinNum + "");
        }

        BCW.Model.Game.Horselist model = new BCW.Model.Game.Horselist();
        model.ID        = id;
        model.WinNum    = WinNum;
        model.BeginTime = BeginTime;
        model.EndTime   = EndTime;
        new BCW.BLL.Game.Horselist().Update(model);
        Utils.Success("编辑第" + id + "局", "编辑第" + id + "局成功..", Utils.getUrl("horse.aspx?act=edit&amp;id=" + id + "&amp;backurl=" + Utils.getPage(0) + ""), "1");
    }
Example #13
0
    private void BackSavePage()
    {
        int    gid     = Utils.ParseInt(Utils.GetRequest("gid", "post", 2, @"^[0-9]\d*$", "竞猜ID无效"));
        int    id      = Utils.ParseInt(Utils.GetRequest("id", "post", 2, @"^[0-9]\d*$", "ID无效"));
        string Content = Utils.GetRequest("Content", "all", 3, @"^[\s\S]{1,200}$", "原因限200字内,可以留空");

        if (!new TPR3.BLL.guess.BaList().Exists(gid))
        {
            Utils.Error("不存在的记录", "");
        }

        TPR3.Model.guess.BaPay model = new TPR3.BLL.guess.BaPay().GetModelIsCase(id);
        if (model == null)
        {
            Utils.Error("不存在的记录", "");
        }

        //游戏日志记录
        int ManageId = new BCW.User.Manage().IsManageLogin();

        string[] p_pageArr = { "ac", "gid", "id", "act", "backurl" };
        BCW.User.GameLog.GameLogPage(8, Utils.getPageUrl(), p_pageArr, "后台管理员" + ManageId + "号撤销押注并退回本金" + model.payview + "(" + gid + "_" + id + ")", gid);

        string Msgtxt = string.Empty;

        if (Content == "")
        {
            Msgtxt = model.payview + "竞猜失败已作退回本金处理";
        }
        else
        {
            Msgtxt = model.payview + "竞猜失败已作退回本金处理," + Content + "";
        }

        new BCW.BLL.Guest().Add(Convert.ToInt32(model.payusid), model.payusname, Msgtxt);
        //退本金
        if (model.Types == 0)
        {
            new BCW.BLL.User().UpdateiGold(Convert.ToInt32(model.payusid), model.payusname, Convert.ToInt64(model.payCent), model.payview + "系统撤销押注并退回本金");
        }
        else
        {
            new BCW.BLL.User().UpdateiMoney(Convert.ToInt32(model.payusid), model.payusname, Convert.ToInt64(model.payCent), model.payview + "系统撤销押注并退回本金");
        }

        //删除处理
        new TPR3.BLL.guess.BaPay().Delete(id);
        Utils.Success("撤销押注", "撤销押注并退回本金成功...", Utils.getPage("showguess.aspx?gid=" + gid + ""), "1");
    }
Example #14
0
    private void GetCheckManage()
    {
        int ManageId = new BCW.User.Manage().IsManageLogin();

        if (ManageId != 1)
        {
            Utils.Error("以你的权限还不能进行此设置", "");
        }

        Master.Title = "后台登录设置";
        string ac  = Utils.GetRequest("ac", "all", 1, "", "");
        ub     xml = new ub();

        Application.Remove("xml_wap"); //清缓存
        xml.Reload();                  //加载网站配置
        if (Utils.ToSChinese(ac) == "确定修改")
        {
            string LoginExpir = Utils.GetRequest("LoginExpir", "post", 2, @"^[0-9]\d*$", "超时时间填写错误");
            string VerifyIP   = Utils.GetRequest("VerifyIP", "post", 2, @"^[0-1]$", "启用IP异常选择错误");
            xml.ds["SiteLoginExpir"] = LoginExpir;
            xml.ds["SiteVerifyIP"]   = VerifyIP;
            System.IO.File.WriteAllText(Server.MapPath("~/Controls/wap.xml"), xml.Post(xml.ds), System.Text.Encoding.UTF8);
            Utils.Success("后台登录设置", "登录设置成功,正在返回..", Utils.getUrl("manage.aspx?act=check"), "1");
        }
        else
        {
            builder.Append(Out.Div("title", "后台登录设置"));

            string strText = "超时时间(分钟):/,启用IP异常:/,";
            string strName = "LoginExpir,VerifyIP,act";
            string strType = "num,select,hidden";
            string strValu = "" + xml.ds["SiteLoginExpir"] + "'" + xml.ds["SiteVerifyIP"] + "'check";
            string strEmpt = "false,0|不启用|1|启用,false";
            string strIdea = "/";
            string strOthe = "确定修改|reset,manage.aspx,post,1,red|blue";
            builder.Append(Out.wapform(strText, strName, strType, strValu, strEmpt, strIdea, strOthe));
            builder.Append(Out.Tab("<div>", "<br />"));
            builder.Append("温馨提示:<br />当后台管理员登录后超出设置的时间则需输入密码继续管理,不启用请填0<br />启用IP异常则使用不同IP登录时需重新登录,非常安全");
            builder.Append(Out.Tab("</div>", ""));
            builder.Append(Out.Tab("<div class=\"hr\"></div>", Out.Hr()));
            builder.Append(Out.Tab("<div>", ""));
            builder.Append("<a href=\"" + Utils.getUrl("manage.aspx") + "\">帐号管理</a><br />");
            builder.Append(Out.Tab("</div><div class=\"title\"><a href=\"" + Utils.getUrl("default.aspx") + "\">返回管理中心</a>", "<a href=\"" + Utils.getUrl("default.aspx") + "\">返回管理中心</a>"));
            builder.Append(Out.Tab("</div>", "<br />"));
        }
    }
Example #15
0
    private void ResetPage()
    {
        int ManageId = new BCW.User.Manage().IsManageLogin();

        if (Utils.GetTopDomain().Contains("tuhao") || Utils.GetTopDomain().Contains("th"))
        {
            if (ManageId != 1 && ManageId != 2)
            {
                Utils.Error("权限不足", "");
            }
        }
        else if (Utils.GetTopDomain().Contains("kb288.net"))
        {
            if (ManageId != 1 && ManageId != 3 && ManageId != 4 && ManageId != 5)
            {
                Utils.Error("权限不足", "");
            }
        }
        else
        {
            if (ManageId != 1 && ManageId != 9)
            {
                Utils.Error("权限不足", "");
            }
        }
        string info = Utils.GetRequest("info", "all", 1, "", "");

        if (info == "")
        {
            Master.Title = "重置游戏";
            builder.Append(Out.Tab("<div class=\"title\">", ""));
            builder.Append("确定重置跑马游戏吗,重置后,将重新从第一局开始,所有记录(局数和下注记录)将会全被删除");
            builder.Append(Out.Tab("</div>", "<br />"));
            builder.Append(Out.Tab("<div>", ""));
            builder.Append("<a href=\"" + Utils.getUrl("horse.aspx?info=ok&amp;act=reset") + "\">确定重置</a><br />");
            builder.Append("<a href=\"" + Utils.getUrl("horse.aspx") + "\">再看看吧..</a>");
            builder.Append(Out.Tab("</div>", "<br />"));
        }
        else
        {
            new BCW.Data.SqlUp().ClearTable("tb_Horselist");
            new BCW.Data.SqlUp().ClearTable("tb_Horsepay");
            Utils.Success("重置游戏", "重置游戏成功..", Utils.getUrl("horse.aspx"), "1");
        }
    }
Example #16
0
    private void EditSavePage()
    {
        int ManageId = new BCW.User.Manage().IsManageLogin();

        if (ManageId != 1 && ManageId != 9)
        {
            Utils.Error("权限不足", "");
        }
        int      id         = int.Parse(Utils.GetRequest("id", "post", 2, @"^[1-9]\d*$", "ID错误"));
        int      WinNum     = int.Parse(Utils.GetRequest("WinNum", "post", 2, @"^[0-9]\d*$", "开出数字填写错误"));
        DateTime BeginTime  = Utils.ParseTime(Utils.GetRequest("BeginTime", "post", 2, DT.RegexTime, "开盘时间格式填写出错,正确格式如" + DT.FormatDate(DateTime.Now, 0) + ""));
        DateTime EndTime    = Utils.ParseTime(Utils.GetRequest("EndTime", "post", 2, DT.RegexTime, "开奖时间格式填写出错,正确格式如" + DT.FormatDate(DateTime.Now, 0) + ""));
        int      OutNum     = int.Parse(Utils.GetRequest("OutNum", "post", 2, @"^[0-9]\d*$", "可购买份数填写错误"));
        int      AddNum     = int.Parse(Utils.GetRequest("AddNum", "post", 2, @"^[0-9]\d*$", "已购买份数填写错误"));
        int      iCent      = int.Parse(Utils.GetRequest("iCent", "post", 2, @"^[0-9]\d*$", "每份价格填写错误"));
        int      Odds       = int.Parse(Utils.GetRequest("Odds", "post", 2, @"^[0-9]\d*$", "本期赔率填写错误"));
        long     Pool       = Int64.Parse(Utils.GetRequest("Pool", "post", 4, @"^[0-9]\d*$", "奖池额填写错误"));
        long     BeforePool = Int64.Parse(Utils.GetRequest("BeforePool", "post", 4, @"^[0-9]\d*$", "上期奖池额填写错误"));

        if (!new BCW.BLL.Game.Balllist().Exists(id))
        {
            Utils.Error("不存在的记录", "");
        }

        //记录日志
        if (Utils.GetDomain().Contains("kubao") || Utils.GetDomain().Contains("tuhao") || Utils.GetDomain().Contains("th") || Utils.GetDomain().Contains("kb288"))
        {
            String sLogFilePath = System.AppDomain.CurrentDomain.BaseDirectory.ToString() + "/logstr/" + DateTime.Now.ToString("MM-dd") + ".txt";
            LogHelper.Write(sLogFilePath, "操作管理员:" + ManageId + "号/编辑彩球期数:" + id + "|是否预设:" + WinNum + "");
        }

        BCW.Model.Game.Balllist model = new BCW.Model.Game.Balllist();
        model.ID         = id;
        model.WinNum     = WinNum;
        model.BeginTime  = BeginTime;
        model.EndTime    = EndTime;
        model.OutNum     = OutNum;
        model.AddNum     = AddNum;
        model.iCent      = iCent;
        model.Odds       = Odds;
        model.Pool       = Pool;
        model.BeforePool = BeforePool;
        new BCW.BLL.Game.Balllist().Update(model);
        Utils.Success("编辑第" + id + "期", "编辑第" + id + "期成功..", Utils.getUrl("ball.aspx?act=edit&amp;id=" + id + "&amp;backurl=" + Utils.getPage(0) + ""), "1");
    }
Example #17
0
    private void EditPage()
    {
        int ManageId = new BCW.User.Manage().IsManageLogin();

        if (ManageId != 1 && ManageId != 9)
        {
            Utils.Error("权限不足", "");
        }
        int id = int.Parse(Utils.GetRequest("id", "get", 2, @"^[1-9]\d*$", "苹果机ID错误"));

        Master.Title = "编辑苹果机";
        builder.Append(Out.Tab("<div class=\"title\">", ""));
        builder.Append("编辑第" + id + "期苹果机");
        builder.Append(Out.Tab("</div>", ""));
        BCW.Model.Game.Applelist model = new BCW.BLL.Game.Applelist().GetApplelist(id);
        if (model == null)
        {
            Utils.Error("不存在的记录", "");
        }
        if (model.State == 0)
        {
            builder.Append(Out.Tab("<div class=\"text\">", "<br />"));
            builder.Append("当开出结果非空时,开奖时则使用该结果作为开奖");
            builder.Append(Out.Tab("</div>", ""));
        }
        string strText = "开出结果:/,开奖时间:/,,,";
        string strName = "OpenText,EndTime,id,act,backurl";
        string strType = "text,date,hidden,hidden,hidden";
        string strValu = "" + model.OpenText + "'" + model.EndTime + "'" + id + "'editsave'" + Utils.getPage(0) + "";
        string strEmpt = "false,false,false,false,false";
        string strIdea = "/";
        string strOthe = "确定编辑|reset,apple.aspx,post,1,red|blue";

        builder.Append(Out.wapform(strText, strName, strType, strValu, strEmpt, strIdea, strOthe));
        builder.Append(Out.Tab("<div class=\"text\">", "<br />"));
        builder.Append("开出结果格式:“苹果”或“苹果[小]”");
        builder.Append(Out.Tab("</div>", ""));
        builder.Append(Out.Tab("<div class=\"hr\"></div>", Out.Hr()));
        builder.Append(Out.Tab("<div>", ""));
        builder.Append("<a href=\"" + Utils.getPage("apple.aspx") + "\">返回上一级</a><br />");
        builder.Append("<a href=\"" + Utils.getUrl("apple.aspx?act=del&amp;id=" + id + "&amp;backurl=" + Utils.getPage(0) + "") + "\">删除本期</a><br />");
        builder.Append(Out.Tab("</div><div class=\"title\"><a href=\"" + Utils.getUrl("../default.aspx") + "\">返回管理中心</a>", "<a href=\"" + Utils.getUrl("../default.aspx") + "\">返回管理中心</a>"));
        builder.Append(Out.Tab("</div>", "<br />"));
    }
Example #18
0
    protected void Page_Load(object sender, EventArgs e)
    {
        Master.Title = "" + ub.Get("SiteBz") + "转帐ID设置";
        builder.Append(Out.Tab("", ""));
        int ManageId = new BCW.User.Manage().IsManageLogin();

        if (ManageId != 1 && ManageId != 11)
        {
            Utils.Error("只有系统管理员1号才可以进行此操作", "");
        }
        string ac      = Utils.GetRequest("ac", "all", 1, "", "");
        ub     xml     = new ub();
        string xmlPath = "/Controls/finance.xml";

        Application.Remove(xmlPath); //清缓存
        xml.ReloadSub(xmlPath);      //加载配置
        if (Utils.ToSChinese(ac) == "确定修改")
        {
            string SysID  = Utils.GetRequest("SysID", "post", 3, @"^[^\#]{1,50}(?:\#[^\#]{1,50}){0,500}$", "内部互转ID请用#分隔,可以留空");
            string SysID2 = Utils.GetRequest("SysID2", "post", 3, @"^[^\#]{1,50}(?:\#[^\#]{1,50}){0,500}$", "内部禁转ID请用#分隔,可以留空");
            xml.dss["FinanceSysID"]  = SysID;
            xml.dss["FinanceSysID2"] = SysID2;
            System.IO.File.WriteAllText(Server.MapPath(xmlPath), xml.Post(xml.dss), System.Text.Encoding.UTF8);
            Utils.Success("设置", "设置成功,正在返回..", Utils.getUrl("centrole.aspx"), "1");
        }
        else
        {
            builder.Append(Out.Div("title", "" + ub.Get("SiteBz") + "转帐ID设置"));

            string strText = "内部互转ID(多个用#分隔|对外限20000一天):/,内部禁转ID(多个用#分隔):/";
            string strName = "SysID,SysID2";
            string strType = "big,big";
            string strValu = "" + xml.dss["FinanceSysID"] + "'" + xml.dss["FinanceSysID2"] + "";
            string strEmpt = "true,true";
            string strIdea = "/";
            string strOthe = "确定修改|reset,centrole.aspx,post,1,red|blue";
            builder.Append(Out.wapform(strText, strName, strType, strValu, strEmpt, strIdea, strOthe));
            builder.Append(Out.Tab("<div class=\"hr\"></div>", Out.Hr()));
            builder.Append(Out.Tab("<div>", ""));
            builder.Append("<a href=\"" + Utils.getUrl("default.aspx") + "\">配置中心</a><br />");
            builder.Append(Out.Tab("</div><div class=\"title\"><a href=\"" + Utils.getUrl("../default.aspx") + "\">返回管理中心</a>", "<a href=\"" + Utils.getUrl("../default.aspx") + "\">返回管理中心</a>"));
            builder.Append(Out.Tab("</div>", "<br />"));
        }
    }
Example #19
0
    private void EditSavePage()
    {
        int ManageId = new BCW.User.Manage().IsManageLogin();

        if (ManageId != 1 && ManageId != 9)
        {
            Utils.Error("权限不足", "");
        }
        int      id       = int.Parse(Utils.GetRequest("id", "post", 2, @"^[1-9]\d*$", "ID错误"));
        string   Title    = Utils.GetRequest("Title", "post", 2, @"^[\s\S]{1,15}$", "庄名限1-15个字符");
        long     SmallPay = Int64.Parse(Utils.GetRequest("SmallPay", "post", 4, @"^[1-9]\d*$", "最小下注填写错误"));
        long     BigPay   = Int64.Parse(Utils.GetRequest("BigPay", "post", 4, @"^[1-9]\d*$", "最大下注填写错误"));
        int      UsID     = int.Parse(Utils.GetRequest("UsID", "post", 2, @"^[1-9]\d*$", "用户ID错误"));
        string   UsName   = Utils.GetRequest("UsName", "post", 2, @"^[\s\S]{1,10}$", "昵称限1-10个字符");
        int      Click    = int.Parse(Utils.GetRequest("Click", "post", 2, @"^[1-9]\d*$", "用户ID错误"));
        DateTime AddTime  = Utils.ParseTime(Utils.GetRequest("AddTime", "post", 2, DT.RegexTime, "创建时间格式填写出错,正确格式如" + DT.FormatDate(DateTime.Now, 0) + ""));

        if (BigPay < SmallPay)
        {
            Utils.Error("最小下注不能大于最大下注", "");
        }
        if (!new BCW.BLL.Game.Bslist().Exists(id))
        {
            Utils.Error("不存在的记录", "");
        }
        if (!new BCW.BLL.User().Exists(UsID))
        {
            Utils.Error("不存在的会员记录", "");
        }

        BCW.Model.Game.Bslist model = new BCW.Model.Game.Bslist();
        model.ID       = id;
        model.Title    = Title;
        model.SmallPay = SmallPay;
        model.BigPay   = BigPay;
        model.UsID     = UsID;
        model.UsName   = UsName;
        model.Click    = Click;
        model.AddTime  = AddTime;
        new BCW.BLL.Game.Bslist().Update(model);
        Utils.Success("编辑大小庄", "编辑大小庄成功..", Utils.getUrl("bigsmall.aspx?act=edit&amp;id=" + id + "&amp;backurl=" + Utils.getPage(0) + ""), "1");
    }
Example #20
0
    private void DelPage()
    {
        int gid = Utils.ParseInt(Utils.GetRequest("gid", "all", 2, @"^[0-9]*$", "竞猜ID无效"));

        TPR2.Model.guess.BaListMe model = new TPR2.BLL.guess.BaListMe().GetModel(gid);
        if (model == null)
        {
            Utils.Error("不存在的记录", "");
        }
        Master.Title = "删除记录";
        string info = Utils.GetRequest("info", "get", 1, "", "");

        if (info != "ok")
        {
            long getMaxNum = new TPR2.BLL.guess.BaPayMe().GetBaPayMeCent(gid, Convert.ToInt32(model.p_type));

            builder.Append(Out.Tab("<div class=\"title\">", ""));
            if (getMaxNum > 0)
            {
                builder.Append("存在下注记录,");
            }
            builder.Append("确定要删除吗");
            builder.Append(Out.Tab("</div>", "<br />"));
            builder.Append(Out.Tab("<div>", ""));
            builder.Append(Out.waplink(Utils.getUrl("kzlist.aspx?info=ok&amp;act=del&amp;gid=" + gid + ""), "确定删除") + "<br />");
            builder.Append(Out.waplink(Utils.getUrl("kzlist.aspx?act=view&amp;gid=" + gid + ""), "先留着吧.."));
            builder.Append(Out.Tab("</div>", "<br />"));
        }
        else
        {
            //游戏日志记录
            int      ManageId  = new BCW.User.Manage().IsManageLogin();
            string[] p_pageArr = { "act", "gid", "info" };
            BCW.User.GameLog.GameLogGetPage(1, Utils.getPageUrl(), p_pageArr, "后台管理员" + ManageId + "号删除个人庄赛事" + model.p_one + "VS" + model.p_two + "(" + gid + ")", gid);


            new TPR2.BLL.guess.BaListMe().Delete(gid);
            new TPR2.BLL.guess.BaPayMe().DeleteStr("bcid=" + gid + "");
            Utils.Success("删除", "删除赛事成功..", Utils.getUrl("kzlist.aspx"), "1");
        }
    }
Example #21
0
    private void EditPage()
    {
        int ManageId = new BCW.User.Manage().IsManageLogin();

        if (ManageId != 1 && ManageId != 9)
        {
            Utils.Error("权限不足", "");
        }
        int id = int.Parse(Utils.GetRequest("id", "get", 2, @"^[1-9]\d*$", "疯狂彩球ID错误"));

        Master.Title = "编辑疯狂彩球";
        builder.Append(Out.Tab("<div class=\"title\">", ""));
        builder.Append("编辑第" + id + "期疯狂彩球");
        builder.Append(Out.Tab("</div>", ""));
        BCW.Model.Game.Balllist model = new BCW.BLL.Game.Balllist().GetBalllist(id);
        if (model == null)
        {
            Utils.Error("不存在的记录", "");
        }
        if (model.State == 0)
        {
            builder.Append(Out.Tab("<div class=\"text\">", "<br />"));
            builder.Append("当开出数字非0时,开奖时则使用该数字作为开奖结果");
            builder.Append(Out.Tab("</div>", ""));
        }
        string strText = "开出数字:/,开盘时间:/,开奖时间:/,本期可购买份数:/,已购买份数:/,每份价格:/,本期赔率:/,奖池额:/,上期奖池额:/,,,";
        string strName = "WinNum,BeginTime,EndTime,OutNum,AddNum,iCent,Odds,Pool,BeforePool,id,act,backurl";
        string strType = "num,date,date,num,num,num,num,num,num,hidden,hidden,hidden";
        string strValu = "" + model.WinNum + "'" + model.BeginTime + "'" + model.EndTime + "'" + model.OutNum + "'" + model.AddNum + "'" + model.iCent + "'" + model.Odds + "'" + model.Pool + "'" + model.BeforePool + "'" + id + "'editsave'" + Utils.getPage(0) + "";
        string strEmpt = "false,false,false,false,false,false,false,false,false,false,false,false";
        string strIdea = "/";
        string strOthe = "确定编辑|reset,ball.aspx,post,1,red|blue";

        builder.Append(Out.wapform(strText, strName, strType, strValu, strEmpt, strIdea, strOthe));
        builder.Append(Out.Tab("<div class=\"hr\"></div>", Out.Hr()));
        builder.Append(Out.Tab("<div>", ""));
        builder.Append("<a href=\"" + Utils.getPage("ball.aspx") + "\">返回上一级</a><br />");
        builder.Append("<a href=\"" + Utils.getUrl("ball.aspx?act=del&amp;id=" + id + "&amp;backurl=" + Utils.getPage(0) + "") + "\">删除本期</a><br />");
        builder.Append(Out.Tab("</div><div class=\"title\"><a href=\"" + Utils.getUrl("../default.aspx") + "\">返回管理中心</a>", "<a href=\"" + Utils.getUrl("../default.aspx") + "\">返回管理中心</a>"));
        builder.Append(Out.Tab("</div>", "<br />"));
    }
Example #22
0
    private void addPage()
    {
        int ManageId = new BCW.User.Manage().IsManageLogin();

        if (ManageId != 1 && ManageId != 26 && ManageId != 9)
        {
            Utils.Error("只有系统管理员1号、9号、26号才可以进行此操作", "");
        }

        int ID = Utils.ParseInt(Utils.GetRequest("ID", "all", 2, @"^[1-9]\d*$", "输入用户ID无效"));

        if (new BCW.BLL.User().Exists(ID))
        {
            DataSet ds = new BCW.BLL.User().GetList("IsSpier", "ID=" + ID + "");
            if (int.Parse(ds.Tables[0].Rows[0]["IsSpier"].ToString()) == 0)
            {
                new BCW.BLL.User().update_ziduan("IsSpier=1", "ID=" + ID + "");
                BCW.Model.xitonghao aa = new BCW.Model.xitonghao();
                aa.UsID    = ManageId;
                aa.caoID   = ID;
                aa.AddTime = DateTime.Now;
                aa.IP      = Utils.GetUsIP();
                aa.type    = 0;
                new BCW.BLL.xitonghao().Add(aa);
                Utils.Success("设置", "设置成功,正在返回.....", Utils.getUrl("robotset.aspx"), "1");
            }
            else
            {
                Utils.Success("设置", "该ID已为系统号,不用重复设置,正在返回.....", Utils.getUrl("robotset.aspx"), "2");
            }
        }
        else
        {
            Utils.Error("不存在的会员.添加失败.", "");
        }
    }
Example #23
0
    protected void Page_Load(object sender, EventArgs e)
    {
        int gid = Utils.ParseInt(Utils.GetRequest("gid", "all", 2, @"^[0-9]*$", "竞猜ID无效"));

        TPR3.BLL.guess.BaList bll = new TPR3.BLL.guess.BaList();

        TPR3.Model.guess.BaList model = bll.GetModel(gid);
        if (model == null)
        {
            Utils.Error("不存在的记录", "");
        }
        Master.Title = "修改赛事" + model.p_one + "VS" + model.p_two;

        int    ptype = Utils.ParseInt(Utils.GetRequest("ptype", "all", 1, @"^[1-2]$", "1"));
        string ac    = Utils.GetRequest("ac", "all", 1, "", "");

        if (ac == "确定修改" || ac == Utils.ToTChinese("确定修改"))
        {
            string   p_title   = Out.UBB(Utils.GetRequest("p_title", "post", 2, @"^[\u4e00-\u9fa5A-Za-z0-9]+$", "请正确填写联赛名称"));
            DateTime p_TPRtime = Utils.ParseTime(Utils.GetRequest("p_TPRtime", "post", 2, DT.RegexTime, "请正确填写联赛时间"));
            string   p_one     = Out.UBB(Utils.GetRequest("p_one", "post", 2, @"^[\u4e00-\u9fa5A-Za-z0-9]+$", "请正确填写上盘名称"));
            string   p_two     = Out.UBB(Utils.GetRequest("p_two", "post", 2, @"^[\u4e00-\u9fa5A-Za-z0-9]+$", "请正确填写下盘名称"));
            decimal  p_one_lu  = Convert.ToDecimal(Utils.GetRequest("p_one_lu", "post", 2, @"^(\d)*(\.(\d){1,2})?$", "请正确填写上盘赔率,小数点后保留1-2位"));
            decimal  p_two_lu  = Convert.ToDecimal(Utils.GetRequest("p_two_lu", "post", 2, @"^(\d)*(\.(\d){1,2})?$", "请正确填写下盘赔率,小数点后保留1-2位"));

            decimal p_big_lu   = Convert.ToDecimal(Utils.GetRequest("p_big_lu", "post", 2, @"^-1$|^(\d)*(\.(\d){1,2})?$", "请正确填写大盘赔率,小数点后保留1-2位"));
            decimal p_small_lu = Convert.ToDecimal(Utils.GetRequest("p_small_lu", "post", 2, @"^-1$|^(\d)*(\.(\d){1,2})?$", "请正确填写小盘赔率,小数点后保留1-2位"));
            decimal p_d_lu     = Convert.ToDecimal(Utils.GetRequest("p_d_lu", "post", 1, @"^-1$|^(\d)*(\.(\d){1,2})?$", "-1"));
            decimal p_s_lu     = Convert.ToDecimal(Utils.GetRequest("p_s_lu", "post", 1, @"^-1$|^(\d)*(\.(\d){1,2})?$", "-1"));
            if (p_one_lu > 4 || p_two_lu > 4 || p_big_lu > 4 || p_small_lu > 4)
            {
                Utils.Error("请检查让球、大小盘赔率,不能大于4", "");
            }

            int     p_pn     = 0;
            decimal p_pk     = 0;
            decimal p_dx_pk  = 0;
            decimal p_bzs_lu = 0;
            decimal p_bzp_lu = 0;
            decimal p_bzx_lu = 0;
            if (ptype == 1)
            {//足球特征
                p_pn    = Utils.ParseInt(Utils.GetRequest("p_pn", "post", 2, @"^[1-2]$", "请正确选择让球类型"));
                p_pk    = Convert.ToDecimal(Utils.GetRequest("p_pk", "post", 2, @"^[0-9]{1,21}$", "请正确选择上下盘口"));
                p_dx_pk = Convert.ToDecimal(Utils.GetRequest("p_dx_pk", "post", 2, @"^[0-9]{1,19}$", "请正确选择大小盘口"));
                if (Request["p_bzs_lu"] != "")
                {
                    p_bzs_lu = Convert.ToDecimal(Utils.GetRequest("p_bzs_lu", "post", 2, @"^-1$|^(\d)*(\.(\d){1,2})?$", "请正确填写主胜赔率,小数点后保留1-2位"));
                    p_bzp_lu = Convert.ToDecimal(Utils.GetRequest("p_bzp_lu", "post", 2, @"^-1$|^(\d)*(\.(\d){1,2})?$", "请正确填写平手赔率,小数点后保留1-2位"));
                    p_bzx_lu = Convert.ToDecimal(Utils.GetRequest("p_bzx_lu", "post", 2, @"^-1$|^(\d)*(\.(\d){1,2})?$", "请正确填写客胜赔率,小数点后保留1-2位"));
                    if (p_bzs_lu > 50 || p_bzp_lu > 50 || p_bzx_lu > 50)
                    {
                        Utils.Error("请检查标准盘赔率,不能大于50", "");
                    }
                }
                else
                {
                    p_bzs_lu = 0;
                    p_bzp_lu = 0;
                    p_bzx_lu = 0;
                }
            }
            else
            {//篮球特征
                p_pk    = Convert.ToDecimal(Utils.GetRequest("p_pk", "post", 2, @"^(-)?(\d)*(\.(\d){1})?$", "请正确填写上下盘口"));
                p_dx_pk = Convert.ToDecimal(Utils.GetRequest("p_dx_pk", "post", 2, @"^(-)?(\d)*(\.(\d){1})?$", "请正确填写大小盘口"));
            }
            int p_ison = Convert.ToInt32(Utils.GetRequest("p_ison", "post", 1, @"^[0-1]$", "0"));

            //游戏日志记录
            int      ManageId  = new BCW.User.Manage().IsManageLogin();
            string[] p_pageArr = { "ac", "gid", "p_title", "ptype", "p_one", "p_two", "p_pk", "p_dx_pk", "p_pn", "p_one_lu", "p_two_lu", "p_big_lu", "p_small_lu", "p_bzs_lu", "p_bzp_lu", "p_bzx_lu", "p_d_lu", "p_s_lu", "p_TPRtime", "p_ison" };
            BCW.User.GameLog.GameLogPage(8, Utils.getPageUrl(), p_pageArr, "后台管理员" + ManageId + "号修改赛事" + model.p_one + "VS" + model.p_two + "(" + gid + ")", gid);


            //更新数据
            model.ID         = gid;
            model.p_title    = p_title;
            model.p_type     = ptype;
            model.p_one      = p_one;
            model.p_two      = p_two;
            model.p_pk       = p_pk;
            model.p_dx_pk    = p_dx_pk;
            model.p_pn       = p_pn;
            model.p_one_lu   = p_one_lu;
            model.p_two_lu   = p_two_lu;
            model.p_big_lu   = p_big_lu;
            model.p_small_lu = p_small_lu;
            model.p_bzs_lu   = p_bzs_lu;
            model.p_bzp_lu   = p_bzp_lu;
            model.p_bzx_lu   = p_bzx_lu;
            model.p_d_lu     = p_d_lu;
            model.p_s_lu     = p_s_lu;
            model.p_addtime  = DateTime.Now;
            model.p_TPRtime  = p_TPRtime;
            model.p_ison     = p_ison;
            bll.Update(model);

            Utils.Success("修改赛事", "修改赛事成功..", Utils.getPage("showGuess.aspx?gid=" + gid + ""), "1");
        }
        else
        {
            builder.Append(Out.Tab("<div class=\"title\">", ""));
            builder.Append("修改赛事" + model.p_one + "VS" + model.p_two);
            builder.Append(Out.Tab("</div>", ""));
            if (model.p_type == 1)
            {
                string strText = "联赛名称,联赛时间,上盘名称,上盘赔率,下盘名称,下盘赔率,让球类型,上下盘口,大盘赔率,小盘赔率,大小盘口,标准主胜,标准平手,标准客胜,单数赔率:,双数赔率:,是否开走地,,,";
                string strName = "p_title,p_TPRtime,p_one,p_one_lu,p_two,p_two_lu,p_pn,p_pk,p_big_lu,p_small_lu,p_dx_pk,p_bzs_lu,p_bzp_lu,p_bzx_lu,p_d_lu,p_s_lu,p_ison,ptype,gid,backurl";
                string strType = "text,date,text,text,text,text,select,select,text,text,select,text,text,text,text,text,select,hidden,hidden,hidden";
                string strValu = "" + model.p_title + "'" + DT.FormatDate(Convert.ToDateTime(model.p_TPRtime), 0) + "'" + model.p_one + "'" + Convert.ToDouble(model.p_one_lu) + "'" + model.p_two + "'" + Convert.ToDouble(model.p_two_lu) + "'" + model.p_pn + "'" + Convert.ToDouble(model.p_pk) + "'" + Convert.ToDouble(model.p_big_lu) + "'" + Convert.ToDouble(model.p_small_lu) + "'" + Convert.ToDouble(model.p_dx_pk) + "'" + Convert.ToDouble(model.p_bzs_lu) + "'" + Convert.ToDouble(model.p_bzp_lu) + "'" + Convert.ToDouble(model.p_bzx_lu) + "'" + Convert.ToDouble(model.p_d_lu) + "'" + Convert.ToDouble(model.p_s_lu) + "'" + model.p_ison + "'" + model.p_type + "'" + gid + "'" + Utils.getPage(0) + "";
                string strEmpt = "flase,false,false,false,false,false,1|让球|2|受让,1|平手|2|平手/半球|3|半球|4|半球/一球|5|一球|6|一球/球半|7|球半|8|球半/二球|9|二球|10|二球/二球半|11|二球半|12|二球半/三球|13|三球|14|三球/三球半|15|三球半|16|三球半/四球|17|四球|18|四球/四球半|19|四球半|20|四球半/五球|21|五球,true,true,20|0.5|21|0.5/1.0|22|1.0|23|1.0/1.5|1|1.5|2|1.5/2.0|3|2.0|4|2/2.5|5|2.5|6|2.5/3.0|7|3.0|8|3/3.5|9|3.5|10|3.5/4.0|11|4.0|12|4/4.5|13|4.5|14|4.5/5.0|15|5.0|16|5/5.5|17|5.5|18|5.5/6.0|19|6.0|24|6.0/6.5|25|6.5|26|6.5/7.0|27|7.0|28|7.0/7.5|29|7.5|30|7.5/8.0|31|8.0|32|8.0/8.5|33|8.5|34|8.5/9.0|35|9.0|36|9.0/9.5|37|9.5|38|9.5/10.0|39|10.0,true,true,true,true,true,0|否|1|是,true,true,false";
                string strIdea = "/联赛时间格式:" + DT.FormatDate(Convert.ToDateTime(DateTime.Now.AddHours(5)), 0) + "/";
                string strOthe = "确定修改,editGuess.aspx,post,1,red";

                builder.Append(Out.wapform(strText, strName, strType, strValu, strEmpt, strIdea, strOthe));
                builder.Append(Out.Tab("<div>", "<br />"));
                builder.Append("大小盘赔率与标准盘填写-1可隐藏,即不可下注大小盘与标准盘!");
                builder.Append(Out.Tab("</div>", ""));
            }
            else
            {
                string strText = "联赛名称,联赛时间,上盘名称,上盘赔率,下盘名称,下盘赔率,上下盘口,大盘赔率,小盘赔率,大小盘口,单数赔率:,双数赔率:,是否开走地,,,";
                string strName = "p_title,p_TPRtime,p_one,p_one_lu,p_two,p_two_lu,p_pk,p_big_lu,p_small_lu,p_dx_pk,p_d_pk,p_s_pk,p_ison,ptype,gid,backurl";
                string strType = "text,date,text,text,text,text,text,text,text,text,text,text,select,hidden,hidden,hidden";
                string strValu = "" + model.p_title + "'" + DT.FormatDate(Convert.ToDateTime(model.p_TPRtime), 0) + "'" + model.p_one + "'" + Convert.ToDouble(model.p_one_lu) + "'" + model.p_two + "'" + Convert.ToDouble(model.p_two_lu) + "'" + Convert.ToDouble(model.p_pk) + "'" + Convert.ToDouble(model.p_big_lu) + "'" + Convert.ToDouble(model.p_small_lu) + "'" + Convert.ToDouble(model.p_dx_pk) + "'" + Convert.ToDouble(model.p_d_lu) + "'" + Convert.ToDouble(model.p_s_lu) + "'" + model.p_ison + "'" + model.p_type + "'" + gid + "'" + Utils.getPage(0) + "";
                string strEmpt = "flase,false,false,false,false,false,false,true,true,true,true,true,0|否|1|是,true,false,false";
                string strIdea = "/联赛时间格式:" + DT.FormatDate(Convert.ToDateTime(DateTime.Now.AddHours(5)), 0) + "/";
                string strOthe = "确定修改,editGuess.aspx,post,1,red";

                builder.Append(Out.wapform(strText, strName, strType, strValu, strEmpt, strIdea, strOthe));
                builder.Append(Out.Tab("<div>", "<br />"));
                builder.Append("大小盘赔率填写-1可隐藏大小盘,即不可下注大小盘!");
                builder.Append(Out.Tab("</div>", ""));
            }
        }

        builder.Append(Out.Tab("<div class=\"hr\"></div>", Out.Hr()));
        builder.Append(Out.Tab("<div>", ""));
        builder.Append(Out.waplink(Utils.getUrl("showGuess.aspx?gid=" + gid + ""), "返回上一级"));
        builder.Append(Out.Tab("</div>", ""));
        builder.Append(Out.Tab("<div class=\"title\">", "<br />"));
        builder.Append("<a href=\"" + Utils.getUrl("../default.aspx") + "\">返回管理中心</a>");
        builder.Append(Out.Tab("</div>", "<br />"));
    }
Example #24
0
    protected void Page_Load(object sender, EventArgs e)
    {
        Master.Title = "清空记录";
        string act = Utils.GetRequest("act", "all", 1, "", "");

        if (act == "actopok")
        {
            int ManageId = new BCW.User.Manage().IsManageLogin();
            if (ManageId != 1 && ManageId != 11)
            {
                Utils.Error("你的权限不足", "");
            }
            DateTime sTime    = Utils.ParseTime(Utils.GetRequest("sTime", "post", 2, DT.RegexTime, "开始时间填写无效"));
            DateTime oTime    = Utils.ParseTime(Utils.GetRequest("oTime", "post", 2, DT.RegexTime, "结束时间填写无效"));
            int      iTar     = Utils.ParseInt(Utils.GetRequest("iTar", "post", 2, @"^[0-9]\d*$", "返负千分比填写错误"));
            int      iPrice   = Utils.ParseInt(Utils.GetRequest("iPrice", "post", 2, @"^[0-9]\d*$", "至少输多少币才返填写错误"));
            int      MaxCount = Utils.ParseInt(Utils.GetRequest("MaxCount", "post", 2, @"^[0-9]\d*$", "返负人数填写错误"));
            string   Msgtxt   = Utils.GetRequest("Msgtxt", "post", 3, @"^[\s\S]{1,300}$", "消息内容限300字内");

            string TopWhe = "";
            if (MaxCount > 0)
            {
                TopWhe = " TOP " + MaxCount + " ";
            }

            DataSet ds = new TPR3.BLL.guess.BaPay().GetBaPayList("" + TopWhe + "payusid,sum(p_getMoney-payCent) as payCents", "paytimes>='" + sTime + "'and paytimes<'" + oTime + "' and Types=0 group by payusid");
            for (int i = 0; i < ds.Tables[0].Rows.Count; i++)
            {
                long Cents = Convert.ToInt64(ds.Tables[0].Rows[i]["payCents"]);
                if (Cents < 0 && Cents < (-iPrice))
                {
                    int  usid = Convert.ToInt32(ds.Tables[0].Rows[i]["payusid"]);
                    long cent = Convert.ToInt64((-Cents) * (iTar * 0.001));
                    new BCW.BLL.User().UpdateiGold(usid, cent, "竞猜返负");
                    //发内线
                    string strLog = "根据你上期竞猜排行榜上的亏损情况,系统自动返还了" + cent + "" + ub.Get("SiteBz") + "[url=/bbs/guess2/default.aspx]进入球彩竞猜[/url]";
                    if (Msgtxt != "")
                    {
                        strLog = Msgtxt;
                    }

                    new BCW.BLL.Guest().Add(0, usid, new BCW.BLL.User().GetUsName(usid), strLog);
                }
            }

            Utils.Success("返负操作", "返负操作成功", Utils.getUrl("clear.aspx"), "1");
        }
        else if (act == "actopok2")
        {
            int ManageId = new BCW.User.Manage().IsManageLogin();
            if (ManageId != 1 && ManageId != 11)
            {
                Utils.Error("你的权限不足", "");
            }
            DateTime sTime    = Utils.ParseTime(Utils.GetRequest("sTime", "post", 2, DT.RegexTime, "开始时间填写无效"));
            DateTime oTime    = Utils.ParseTime(Utils.GetRequest("oTime", "post", 2, DT.RegexTime, "结束时间填写无效"));
            int      iTar     = Utils.ParseInt(Utils.GetRequest("iTar", "post", 2, @"^[0-9]\d*$", "返赢千分比填写错误"));
            int      iPrice   = Utils.ParseInt(Utils.GetRequest("iPrice", "post", 2, @"^[0-9]\d*$", "至少赢多少币才返填写错误"));
            int      MaxCount = Utils.ParseInt(Utils.GetRequest("MaxCount", "post", 2, @"^[0-9]\d*$", "返赢人数填写错误"));
            string   Msgtxt   = Utils.GetRequest("Msgtxt", "post", 3, @"^[\s\S]{1,300}$", "消息内容限300字内");

            string TopWhe = "";
            if (MaxCount > 0)
            {
                TopWhe = " TOP " + MaxCount + " ";
            }

            DataSet ds = new TPR3.BLL.guess.BaPay().GetBaPayList("" + TopWhe + "payusid,sum(p_getMoney-payCent) as payCents", "paytimes>='" + sTime + "'and paytimes<'" + oTime + "' and Types=0 group by payusid");
            for (int i = 0; i < ds.Tables[0].Rows.Count; i++)
            {
                long Cents = Convert.ToInt64(ds.Tables[0].Rows[i]["payCents"]);
                if (Cents > 0 && Cents >= iPrice)
                {
                    int  usid = Convert.ToInt32(ds.Tables[0].Rows[i]["payusid"]);
                    long cent = Convert.ToInt64(Cents * (iTar * 0.001));
                    new BCW.BLL.User().UpdateiGold(usid, cent, "竞猜返赢");
                    //发内线
                    string strLog = "根据你上期竞猜排行榜上的赢利情况,系统自动返还了" + cent + "" + ub.Get("SiteBz") + "[url=/bbs/guess2/default.aspx]进入球彩竞猜[/url]";
                    if (Msgtxt != "")
                    {
                        strLog = Msgtxt;
                    }

                    new BCW.BLL.Guest().Add(0, usid, new BCW.BLL.User().GetUsName(usid), strLog);
                }
            }

            Utils.Success("返赢操作", "返赢操作成功", Utils.getUrl("clear.aspx"), "1");
        }
        else if (act == "actspaceguess")//清空已截止的、无投注记录的赛事
        {
            int     k  = 0;
            DataSet ds = BCW.Data.SqlHelper.Query("select ID from tb_zbalist where p_TPRTime<'" + DateTime.Now + "' and p_active=0");
            if (ds != null && ds.Tables[0].Rows.Count > 0)
            {
                for (int i = 0; i < ds.Tables[0].Rows.Count; i++)
                {
                    int ID = int.Parse(ds.Tables[0].Rows[i]["ID"].ToString());

                    int pCount = new TPR3.BLL.guess.BaPay().GetBaPayCount("bcid=" + ID + "");
                    if (pCount == 0)
                    {
                        new TPR3.BLL.guess.BaList().Delete(ID);
                        k++;
                    }
                }
            }
            Utils.Success("清空记录", "清空无投注赛事成功", Utils.getUrl("default.aspx"), "1");
        }
        else
        {
            string ac   = Utils.GetRequest("ac", "post", 1, "", "");
            string Info = Utils.GetRequest("Info", "post", 1, "", "");
            if (ac == "清空记录" || ac == Utils.ToTChinese("清空记录"))
            {
                int    Ptype, Ltype, Ttype, iTset;
                string sTime = "";
                string oTime = "";
                Ptype = Utils.ParseInt(Utils.GetRequest("Ptype", "post", 2, @"^[0-2]$", "球类选择无效"));
                Ltype = Utils.ParseInt(Utils.GetRequest("Ltype", "post", 2, @"^[1-9]$", "类型选择无效"));
                Ttype = Utils.ParseInt(Utils.GetRequest("Ttype", "post", 2, @"^[1-5]+$", "限制选择无效"));
                iTset = Utils.ParseInt(Utils.GetRequest("iTset", "post", 2, @"^[1-3]+$", "局域选择无效"));
                if (Ttype == 4)
                {
                    sTime = Utils.GetRequest("sTime", "post", 2, DT.RegexTime, "开始时间填写无效");
                    oTime = Utils.GetRequest("oTime", "post", 2, DT.RegexTime, "结束时间填写无效");
                }

                if (Info == "ok")
                {
                    string cText = string.Empty;
                    if (Ltype == 1)
                    {
                        cText = "清空竞猜排行榜";
                    }
                    else if (Ltype == 2)
                    {
                        cText = "清空竞猜投注记录";
                    }
                    else if (Ltype == 3)
                    {
                        cText = "清空竞猜赛事记录";
                    }
                    //游戏日志记录
                    int      ManageId  = new BCW.User.Manage().IsManageLogin();
                    int      gid       = new TPR3.BLL.guess.BaList().GetMaxId();
                    string[] p_pageArr = { "ac", "Ltype", "Ptype", "Ttype", "sTime", "oTime", "iTset", "Info" };
                    BCW.User.GameLog.GameLogPage(8, Utils.getPageUrl(), p_pageArr, "后台管理员" + ManageId + "号" + cText + "", gid);

                    //组合条件查询
                    string strWhere = "";

                    if (Ltype == 1)//排行榜记录
                    {
                        ////------------------------返负彩
                        //if (Convert.ToInt32(ub.GetSub("SiteLostPrice", xmlPath)) > 0)
                        //{
                        //    DataSet ds = new TPR3.BLL.guess.BaOrder().GetBaOrderList("orderusid,orderusname,orderjbnum", "Orderjbnum < 0 and Orderjbnum <= " + (-Convert.ToInt32(ub.GetSub("SiteLostPrice", xmlPath))) + "");
                        //    for (int i = 0; i < ds.Tables[0].Rows.Count; i++)
                        //    {
                        //        int cent = Convert.ToInt32((-Convert.ToInt32(ds.Tables[0].Rows[i]["orderjbnum"])) * (Convert.ToDouble(ub.GetSub("SiteLostPL", xmlPath)) * 0.01));

                        //        //操作币
                        //        new BCW.BLL.User().UpdateiGold(Convert.ToInt32(ds.Tables[0].Rows[i]["orderusid"]), cent, "");
                        //        //发内线
                        //        string strLog = "根据你上期竞猜排行榜上的盈利情况,系统自动返还了" + cent + "" + ub.Get("SiteBz") + "[url=/bbs/guess/default.aspx]进入球彩竞猜[/url]";

                        //        new BCW.BLL.Guest().Add(0, Convert.ToInt32(ds.Tables[0].Rows[i]["orderusid"]), ds.Tables[0].Rows[i]["orderusname"].ToString(), strLog);
                        //    }
                        //}
                        ////------------------------返负彩
                        new TPR3.BLL.guess.BaOrder().DeleteStr();
                    }
                    else if (Ltype == 2)//投注记录
                    {
                        if (Ptype != 0)
                        {
                            strWhere += "pType=" + Ptype + " ";
                        }
                        else
                        {
                            strWhere += "pType>0 ";
                        }

                        if (Ttype == 1)
                        {
                            strWhere += "and paytimes='" + DateTime.Now.ToLongDateString() + "'";
                        }
                        else if (Ttype == 2)
                        {
                            strWhere += "and paytimes>='" + DateTime.Now.AddDays(-7) + "'";
                        }
                        else if (Ttype == 3)
                        {
                            strWhere += "and paytimes>='" + DateTime.Now.AddDays(-30) + "'";
                        }
                        else if (Ttype == 4)
                        {
                            if (iTset == 1)
                            {
                                strWhere += "and paytimes>='" + sTime + "' and paytimes<='" + oTime + "'";
                            }
                            else if (iTset == 2)
                            {
                                strWhere += "and paytimes>'" + sTime + "' and paytimes<'" + oTime + "'";
                            }
                            else if (iTset == 3)
                            {
                                strWhere += "and paytimes NOT BETWEEN '" + sTime + "' and '" + oTime + "'";
                            }
                        }
                        new TPR3.BLL.guess.BaPay().DeleteStr(strWhere);
                    }
                    else if (Ltype == 3)//赛事记录
                    {
                        if (Ptype != 0)
                        {
                            strWhere += "p_type=" + Ptype + " ";
                        }
                        else
                        {
                            strWhere += "p_type>0 ";
                        }

                        if (Ttype == 1)
                        {
                            strWhere += "and p_addtime='" + DateTime.Now.ToLongDateString() + "'";
                        }
                        else if (Ttype == 2)
                        {
                            strWhere += "and p_addtime>='" + DateTime.Now.AddDays(-7) + "'";
                        }
                        else if (Ttype == 3)
                        {
                            strWhere += "and p_addtime>='" + DateTime.Now.AddDays(-30) + "'";
                        }
                        else if (Ttype == 4)
                        {
                            if (iTset == 1)
                            {
                                strWhere += "and p_addtime>='" + sTime + "' and p_addtime<='" + oTime + "'";
                            }
                            else if (iTset == 2)
                            {
                                strWhere += "and p_addtime>'" + sTime + "' and p_addtime<'" + oTime + "'";
                            }
                            else if (iTset == 3)
                            {
                                strWhere += "and p_addtime NOT BETWEEN '" + sTime + "' and '" + oTime + "'";
                            }
                        }

                        new TPR3.BLL.guess.BaList().DeleteStr(strWhere);
                    }
                    Utils.Success("清空记录", "清空记录成功", Utils.getUrl("clear.aspx"), "1");
                }
                else
                {
                    builder.Append(Out.Tab("<div class=\"title\">", ""));
                    if (Ltype == 1)
                    {
                        builder.Append("请确认清空排行榜,清空的同时将返负彩,负彩相关设置请在系统参数中配置");
                    }
                    else if (Ltype == 2)
                    {
                        builder.Append("请确认清空投注记录");
                    }
                    else if (Ltype == 3)
                    {
                        builder.Append("请确认清空赛事记录");
                    }

                    builder.Append(Out.Tab("</div>", "<br />"));
                    string strName = "Ltype,Ptype,Ttype,sTime,oTime,iTset,Info";
                    string strValu = "" + Ltype + "'" + Ptype + "'" + Ttype + "'" + sTime + "'" + oTime + "'" + iTset + "'ok";
                    string strOthe = "清空记录,clear.aspx,post,1,red";

                    builder.Append(Out.wapform(strName, strValu, strOthe));
                    builder.Append(Out.Tab("<div>", "<br />"));
                    builder.Append(Out.waplink(Utils.getUrl("clear.aspx"), "先留着吧.."));
                    builder.Append(Out.Tab("</div>", "<br />"));
                }
            }
            else if (act == "actop")
            {
                Master.Title = "返负点";
                builder.Append(Out.Tab("<div class=\"title\">", ""));
                builder.Append("返负点操作");
                builder.Append(Out.Tab("</div>", ""));
                string strText = "开始时间:,结束时间:,返负千分比:,至少输多少才返:,返负人数(填0则不限):,消息通知:,";
                string strName = "sTime,oTime,iTar,iPrice,MaxCount,Msgtxt,act";
                string strType = "date,date,num,num,num,textarea,hidden";
                string strValu = "" + DT.FormatDate(DateTime.Now.AddDays(-10), 0) + "'" + DT.FormatDate(DateTime.Now, 0) + "'''0''actopok";
                string strEmpt = "false,false,false,false,false,false,false";
                string strIdea = "/";
                string strOthe = "马上返负,clear.aspx,post,1,red";

                builder.Append(Out.wapform(strText, strName, strType, strValu, strEmpt, strIdea, strOthe));
                builder.Append(Out.Tab("<div class=\"hr\"></div>", Out.Hr()));
                builder.Append(Out.Tab("<div>", ""));
                builder.Append(Out.waplink(Utils.getUrl("default.aspx"), "返回上一级"));
                builder.Append(Out.Tab("</div>", ""));
                builder.Append(Out.Tab("<div class=\"title\">", "<br />"));
                builder.Append("<a href=\"" + Utils.getUrl("../default.aspx") + "\">返回管理中心</a>");
                builder.Append(Out.Tab("</div>", "<br />"));
            }
            else if (act == "actop2")
            {
                Master.Title = "返赢点";
                builder.Append(Out.Tab("<div class=\"title\">", ""));
                builder.Append("返赢点操作");
                builder.Append(Out.Tab("</div>", ""));
                string strText = "开始时间:,结束时间:,返赢千分比:,至少赢多少才返:,返赢人数(填0则不限):,消息通知:,";
                string strName = "sTime,oTime,iTar,iPrice,MaxCount,Msgtxt,act";
                string strType = "date,date,num,num,num,textarea,hidden";
                string strValu = "" + DT.FormatDate(DateTime.Now.AddDays(-10), 0) + "'" + DT.FormatDate(DateTime.Now, 0) + "'''0''actopok2";
                string strEmpt = "false,false,false,false,false,false,false";
                string strIdea = "/";
                string strOthe = "马上返赢,clear.aspx,post,1,red";

                builder.Append(Out.wapform(strText, strName, strType, strValu, strEmpt, strIdea, strOthe));
                builder.Append(Out.Tab("<div class=\"hr\"></div>", Out.Hr()));
                builder.Append(Out.Tab("<div>", ""));
                builder.Append(Out.waplink(Utils.getUrl("default.aspx"), "返回上一级"));
                builder.Append(Out.Tab("</div>", ""));
                builder.Append(Out.Tab("<div class=\"title\">", "<br />"));
                builder.Append("<a href=\"" + Utils.getUrl("../default.aspx") + "\">返回管理中心</a>");
                builder.Append(Out.Tab("</div>", "<br />"));
            }
            else
            {
                builder.Append(Out.Tab("<div class=\"title\">", ""));
                builder.Append("清空历史记录");
                builder.Append(Out.Tab("</div>", ""));
                string strText = "*选择清空内容:/,球类:,限制:,开始时间:,结束时间:,时间局域:";
                string strName = "Ltype,Ptype,Ttype,sTime,oTime,iTset";
                string strType = "select,select,select,date,date,select";
                string strValu = "1'0'5'" + DT.FormatDate(DateTime.Now.AddDays(-10), 0) + "'" + DT.FormatDate(DateTime.Now, 0) + "'1";
                string strEmpt = "2|投注记录|3|赛事记录,0|全部|1|足球|2|篮球,1|今天所有|2|一个星期|3|一个月内|4|指定时间|5|所有时间,true,true,1|=&lt;&gt;=两者之间|2|&lt;&gt;介负于两者|3|=&gt;&lt;=两者之外";
                string strIdea = "/温馨提示:选择限定时间需填写时间类型;/排行榜记录不用选择时间限制;/闲聊、消费记录不用选择球类/";
                string strOthe = "清空记录,clear.aspx,post,1,red";

                builder.Append(Out.wapform(strText, strName, strType, strValu, strEmpt, strIdea, strOthe));
                builder.Append(Out.Tab("<div class=\"hr\"></div>", Out.Hr()));
                builder.Append(Out.Tab("<div>", ""));
                builder.Append(Out.waplink(Utils.getUrl("default.aspx"), "返回上一级"));
                builder.Append(Out.Tab("</div>", ""));
                builder.Append(Out.Tab("<div class=\"title\">", "<br />"));
                builder.Append("<a href=\"" + Utils.getUrl("../default.aspx") + "\">返回管理中心</a>");
                builder.Append(Out.Tab("</div>", "<br />"));
            }
        }
    }
Example #25
0
    protected void Page_Load(object sender, EventArgs e)
    {
        Master.Title = "大小庄游戏设置";
        builder.Append(Out.Tab("", ""));

        string ac      = Utils.GetRequest("ac", "all", 1, "", "");
        ub     xml     = new ub();
        string xmlPath = "/Controls/bigsmall.xml";

        Application.Remove(xmlPath); //清缓存
        xml.ReloadSub(xmlPath);      //加载配置
        if (Utils.ToSChinese(ac) == "确定修改")
        {
            string Name     = Utils.GetRequest("Name", "post", 2, @"^[^\^]{1,20}$", "系统名称限1-20字内");
            string Notes    = Utils.GetRequest("Notes", "post", 3, @"^[^\^]{1,2000}$", "口号限2000字内");
            string Logo     = Utils.GetRequest("Logo", "post", 3, @"^[^\^]{1,200}$", "Logo地址限200字内");
            string Status   = Utils.GetRequest("Status", "post", 2, @"^[0-1]$", "系统状态选择出错");
            string SmallPay = Utils.GetRequest("SmallPay", "post", 4, @"^[1-9]\d*$", "开庄最小" + ub.Get("SiteBz") + "填写错误");
            string BigPay   = Utils.GetRequest("BigPay", "post", 4, @"^[1-9]\d*$", "开庄最大" + ub.Get("SiteBz") + "填写错误");
            string vMoney   = Utils.GetRequest("vMoney", "post", 4, @"^[1-9]\d*$", "达多少" + ub.Get("SiteBz") + "显示填写错误");
            string Odds     = Utils.GetRequest("Odds", "post", 2, @"^[1-9]\d*$", "赔率填写错误");
            string ZTar     = Utils.GetRequest("ZTar", "post", 2, @"^(\d)*(\.(\d){0,1})?$", "庄胜手续费填写错误");
            string XTar     = Utils.GetRequest("XTar", "post", 2, @"^(\d)*(\.(\d){0,1})?$", "闲胜手续费填写错误");
            string Foot     = Utils.GetRequest("Foot", "post", 3, @"^[\s\S]{1,2000}$", "底部Ubb限2000字内");
            string Expir    = Utils.GetRequest("Expir", "post", 2, @"^[0-9]\d*$", "防刷秒数填写错误");
            string IsBot    = Utils.GetRequest("IsBot", "post", 2, @"^[0-1]$", "机器人选择出错");

            xml.dss["BsName"]     = Name;
            xml.dss["BsNotes"]    = Notes;
            xml.dss["BsLogo"]     = Logo;
            xml.dss["BsStatus"]   = Status;
            xml.dss["BsSmallPay"] = SmallPay;
            xml.dss["BsBigPay"]   = BigPay;
            xml.dss["BsvMoney"]   = vMoney;

            string SmallPay2 = Utils.GetRequest("SmallPay2", "post", 4, @"^[1-9]\d*$", "开庄最小" + ub.Get("SiteBz2") + "填写错误");
            string BigPay2   = Utils.GetRequest("BigPay2", "post", 4, @"^[1-9]\d*$", "开庄最大" + ub.Get("SiteBz2") + "填写错误");
            string vMoney2   = Utils.GetRequest("vMoney2", "post", 4, @"^[1-9]\d*$", "达多少" + ub.Get("SiteBz2") + "显示填写错误");
            string sCent     = Utils.GetRequest("sCent", "post", 4, @"^[1-9]\d*$", "最小下注下限" + ub.Get("SiteBz") + "填写错误");
            string bCent     = Utils.GetRequest("bCent", "post", 4, @"^[1-9]\d*$", "最大下注上限" + ub.Get("SiteBz") + "填写错误");
            string sCent2    = Utils.GetRequest("sCent2", "post", 4, @"^[1-9]\d*$", "最小下注下限" + ub.Get("SiteBz2") + "填写错误");
            string bCent2    = Utils.GetRequest("bCent2", "post", 4, @"^[1-9]\d*$", "最大下注上限" + ub.Get("SiteBz2") + "填写错误");
            xml.dss["BsSmallPay2"] = SmallPay2;
            xml.dss["BsBigPay2"]   = BigPay2;
            xml.dss["BssCent"]     = sCent;
            xml.dss["BsbCent"]     = bCent;
            xml.dss["BssCent2"]    = sCent2;
            xml.dss["BsbCent2"]    = bCent2;
            xml.dss["BsvMoney2"]   = vMoney2;

            xml.dss["BsOdds"]    = Odds;
            xml.dss["BsZTar"]    = ZTar;
            xml.dss["BsXTar"]    = XTar;
            xml.dss["BsFoot"]    = Foot;
            xml.dss["BsExpir"]   = Expir;
            xml.dss["BsIsBot"]   = IsBot;
            xml.dss["BsBotTime"] = DT.FormatDate(DateTime.Now, 0);
            System.IO.File.WriteAllText(Server.MapPath(xmlPath), xml.Post(xml.dss), System.Text.Encoding.UTF8);
            Utils.Success("大小庄游戏设置", "设置成功,正在返回..", Utils.getUrl("bigsmallset.aspx?backurl=" + Utils.getPage(0) + ""), "1");
        }
        else if (Utils.ToSChinese(ac) == "确定设置")
        {
            int ManageId = new BCW.User.Manage().IsManageLogin();
            if (ManageId != 1 && ManageId != 11)
            {
                Utils.Error("不存在的页面", "");
            }
            string WinID    = Utils.GetRequest("WinID", "post", 3, @"^[^\#]{1,50}(?:\#[^\#]{1,50}){0,500}$", "多个ID请用#分隔,可以留空");
            string LostID   = Utils.GetRequest("LostID", "post", 3, @"^[^\#]{1,50}(?:\#[^\#]{1,50}){0,500}$", "多个ID请用#分隔,可以留空");
            string ZWinID   = Utils.GetRequest("ZWinID", "post", 3, @"^[^\#]{1,50}(?:\#[^\#]{1,50}){0,500}$", "多个ID请用#分隔,可以留空");
            string ZLostID  = Utils.GetRequest("ZLostID", "post", 3, @"^[^\#]{1,50}(?:\#[^\#]{1,50}){0,500}$", "多个ID请用#分隔,可以留空");
            string IsWinBot = Utils.GetRequest("IsWinBot", "post", 2, @"^[0-1]$", "机器人选择出错");
            xml.dss["BsWinID"]    = WinID;
            xml.dss["BsLostID"]   = LostID;
            xml.dss["BsZWinID"]   = ZWinID;
            xml.dss["BsZLostID"]  = ZLostID;
            xml.dss["BsIsWinBot"] = IsWinBot;
            System.IO.File.WriteAllText(Server.MapPath(xmlPath), xml.Post(xml.dss), System.Text.Encoding.UTF8);
            Utils.Success("大小庄游戏设置", "设置成功,正在返回..", Utils.getUrl("bigsmallset.aspx?act=ok&amp;backurl=" + Utils.getPage(0) + ""), "1");
        }
        else
        {
            if (Request["act"] == "ok")
            {
                int ManageId = new BCW.User.Manage().IsManageLogin();
                if (ManageId != 1 && ManageId != 11)
                {
                    Utils.Error("不存在的页面", "");
                }
                builder.Append(Out.Div("title", "大小庄游戏设置"));
                string strText = "闲家上帝ID(多个用#分开):/,闲家地狱ID(多个用#分开):/,庄家上帝ID(多个用#分开):/,庄家地狱ID(多个用#分开):/,机器人上帝:/,";
                string strName = "WinID,LostID,ZWinID,ZLostID,IsWinBot,backurl";
                string strType = "textarea,textarea,textarea,textarea,select,hidden";
                string strValu = "" + xml.dss["BsWinID"] + "'" + xml.dss["BsLostID"] + "'" + xml.dss["BsZWinID"] + "'" + xml.dss["BsZLostID"] + "'" + xml.dss["BsIsWinBot"] + "'" + Utils.getPage(0) + "";
                string strEmpt = "true,true,true,true,0|开|1|关,false";
                string strIdea = "/";
                string strOthe = "确定设置|reset,bigsmallset.aspx,post,1,red|blue";
                builder.Append(Out.wapform(strText, strName, strType, strValu, strEmpt, strIdea, strOthe));
            }
            else
            {
                builder.Append(Out.Div("title", "大小庄游戏设置"));
                builder.Append(Out.Tab("<div class=\"text\">", "<br />"));
                builder.Append("大小庄设置|<a href=\"" + Utils.getUrl("spkadminset.aspx?ptype=13&amp;backurl=" + Utils.PostPage(true) + "") + "\">管理员</a>");
                builder.Append(Out.Tab("</div>", ""));

                string strText = "游戏名称:/,游戏口号(可留空):/,游戏Logo(可留空):/,游戏状态:/,开庄最小启动" + ub.Get("SiteBz") + ":/,开庄最大启动" + ub.Get("SiteBz") + ":/,达多少" + ub.Get("SiteBz") + "显示:/,开庄最小启动" + ub.Get("SiteBz2") + ":/,开庄最大启动" + ub.Get("SiteBz2") + ":/,达多少" + ub.Get("SiteBz2") + "显示:/,赔率1赔多少:/,庄胜手续费(%):/,闲胜手续费(%):/,底部Ubb:/,下注防刷(秒):/,机器人:/,最小下注下限" + ub.Get("SiteBz") + ":/,最大下注上限" + ub.Get("SiteBz") + ":/,最小下注下限" + ub.Get("SiteBz2") + ":/,最大下注上限" + ub.Get("SiteBz2") + ":/,";
                string strName = "Name,Notes,Logo,Status,SmallPay,BigPay,vMoney,SmallPay2,BigPay2,vMoney2,Odds,ZTar,XTar,Foot,Expir,IsBot,sCent,bCent,sCent2,bCent2,backurl";
                string strType = "text,text,text,select,num,num,num,num,num,num,num,text,text,textarea,num,select,num,num,num,num,hidden";
                string strValu = "" + xml.dss["BsName"] + "'" + xml.dss["BsNotes"] + "'" + xml.dss["BsLogo"] + "'" + xml.dss["BsStatus"] + "'" + xml.dss["BsSmallPay"] + "'" + xml.dss["BsBigPay"] + "'" + xml.dss["BsvMoney"] + "'" + xml.dss["BsSmallPay2"] + "'" + xml.dss["BsBigPay2"] + "'" + xml.dss["BsvMoney2"] + "'" + xml.dss["BsOdds"] + "'" + xml.dss["BsZTar"] + "'" + xml.dss["BsXTar"] + "'" + xml.dss["BsFoot"] + "'" + xml.dss["BsExpir"] + "'" + xml.dss["BsIsBot"] + "'" + xml.dss["BssCent"] + "'" + xml.dss["BsbCent"] + "'" + xml.dss["BssCent2"] + "'" + xml.dss["BsbCent2"] + "'" + Utils.getPage(0) + "";
                string strEmpt = "false,true,true,0|正常|1|维护,false,false,false,false,false,false,false,false,false,true,false,0|关闭|1|开启,true,true,true,true,false";
                string strIdea = "/";
                string strOthe = "确定修改|reset,bigsmallset.aspx,post,1,red|blue";
                builder.Append(Out.wapform(strText, strName, strType, strValu, strEmpt, strIdea, strOthe));
            }
            builder.Append(Out.Tab("<div class=\"hr\"></div>", Out.Hr()));
            builder.Append(Out.Tab("<div>", ""));
            builder.Append("<a href=\"" + Utils.getPage("game.aspx") + "\">返回上级</a><br />");
            builder.Append("<a href=\"" + Utils.getUrl("default.aspx") + "\">配置中心</a><br />");
            builder.Append(Out.Tab("</div><div class=\"title\"><a href=\"" + Utils.getUrl("../default.aspx") + "\">返回管理中心</a>", "<a href=\"" + Utils.getUrl("../default.aspx") + "\">返回管理中心</a>"));
            builder.Append(Out.Tab("</div>", "<br />"));
        }
    }
Example #26
0
    private void ViewPage()
    {
        int id    = int.Parse(Utils.GetRequest("id", "get", 2, @"^[1-9]\d*$", "ID错误"));
        int ptype = int.Parse(Utils.GetRequest("ptype", "get", 1, @"^[1-2]\d*$", "1"));

        BCW.Model.Game.Dxdice model = new BCW.BLL.Game.Dxdice().GetDxdice(id);
        if (model == null)
        {
            Utils.Error("不存在的记录", "");
        }
        Master.Title = "查看掷骰";
        builder.Append(Out.Tab("<div class=\"title\">", ""));
        builder.Append("查看掷骰");
        builder.Append(Out.Tab("</div>", "<br />"));


        int    zDiceNum = (Utils.ParseInt(Utils.Left(model.DxdiceA, 1)) + Utils.ParseInt(Utils.Right(model.DxdiceA, 1)));
        int    kDiceNum = (Utils.ParseInt(Utils.Left(model.DxdiceB, 1)) + Utils.ParseInt(Utils.Right(model.DxdiceB, 1)));
        string bzText   = string.Empty;

        if (model.BzType == 0)
        {
            bzText = ub.Get("SiteBz");
        }
        else
        {
            bzText = ub.Get("SiteBz2");
        }

        bool IsSeen = true;

        if (Utils.GetDomain().Contains("kubao") || Utils.GetDomain().Contains("tuhao") || Utils.GetDomain().Contains("th") || Utils.GetDomain().Contains("kb288"))
        {
            if (model.State == 0)
            {
                int ManageId = new BCW.User.Manage().IsManageLogin();
                if (ManageId != 1 && ManageId != 11)
                {
                    IsSeen = false;
                }
            }
        }

        builder.Append(Out.Tab("<div>", ""));
        builder.Append(DT.FormatDate(model.AddTime, 0) + "<br />");
        builder.Append("庄家:<a href=\"" + Utils.getUrl("/bbs/uinfo.aspx?uid=" + model.UsID + "&amp;backurl=" + Utils.PostPage(1) + "") + "\">" + model.UsName + "(" + model.UsID + ")</a><br />");
        if (IsSeen == true)
        {
            builder.Append("庄家掷骰:" + zDiceNum + "点(" + model.DxdiceA + ")<br />");
        }
        else
        {
            builder.Append("庄家掷骰:xx点(xx,xx)<br />");
        }

        builder.Append("掷骰:" + model.Price + "" + bzText + "<br />");

        if (model.ReID > 0 && model.State != 4)
        {
            builder.Append("闲家:<a href=\"" + Utils.getUrl("/bbs/uinfo.aspx?uid=" + model.ReID + "&amp;backurl=" + Utils.PostPage(1) + "") + "\">" + model.ReName + "(" + model.ReID + ")</a><br />");
            builder.Append("闲家掷骰:" + kDiceNum + "点(" + model.DxdiceB + ")");
        }
        else
        {
            builder.Append("闲家:等待挑战<br />");
            builder.Append("闲家掷骰:庄家掷骰:xx点(xx,xx)");
        }
        if (model.State == 1 || model.State == 2)
        {
            builder.Append("开奖结果:");
            int iWin = GetiWin(model.DxdiceA, model.DxdiceB);
            if (iWin == 1)
            {
                builder.Append("庄家全赢");
            }
            else if (iWin == 2)
            {
                builder.Append("双方打和");
            }
            else if (iWin == 3)
            {
                builder.Append("闲家全赢");
            }
        }
        else if (model.State == 3)
        {
            builder.Append("状态:过期返还" + model.Price + "" + bzText + "");
        }
        else if (model.State == 4)
        {
            builder.Append("状态:已经撤销");
        }
        builder.Append(Out.Tab("</div>", "<br />"));

        builder.Append(Out.Tab("<div>", ""));
        builder.Append("<a href=\"" + Utils.getUrl("dxdice.aspx?act=del&amp;id=" + id + "&amp;backurl=" + Utils.getPage(0) + "") + "\">删除掷骰</a><br />");
        builder.Append("<a href=\"" + Utils.getPage("dxdice.aspx") + "\">返回上一级</a>");
        builder.Append(Out.Tab("</div>", "<br />"));
        builder.Append(Out.Tab("<div class=\"title\">", ""));
        builder.Append("<a href=\"" + Utils.getUrl("../default.aspx") + "\">返回管理中心</a>");
        builder.Append(Out.Tab("</div>", "<br />"));
    }
Example #27
0
    private void OpenPage()
    {
        int    gid  = Utils.ParseInt(Utils.GetRequest("gid", "all", 2, @"^[0-9]*$", "竞猜ID无效"));
        int    pid  = Utils.ParseInt(Utils.GetRequest("pid", "all", 2, @"^[0-9]*$", "ID无效"));
        string ac   = Utils.GetRequest("ac", "all", 1, "", "");
        string info = Utils.GetRequest("info", "all", 1, "", "");

        TPR2.BLL.guess.BaListMe   bll   = new TPR2.BLL.guess.BaListMe();
        TPR2.Model.guess.BaListMe model = bll.GetModel(gid);
        if (model == null)
        {
            Utils.Error("不存在的记录", "");
        }

        Master.Title = "开奖赛事" + model.p_one + "VS" + model.p_two + "-记录" + pid + "";

        if (ac == "确定开奖" || ac == Utils.ToTChinese("确定开奖"))
        {
            int    opentype  = Utils.ParseInt(Utils.GetRequest("opentype", "post", 2, @"^[0-2]$", "开奖类型错误"));
            int    resultone = Utils.ParseInt(Utils.GetRequest("resultone", "post", 2, @"^[0-9]*$", "请正确输入比分"));
            int    resulttwo = Utils.ParseInt(Utils.GetRequest("resulttwo", "post", 2, @"^[0-9]*$", "请正确输入比分"));
            string jietime   = "";
            if (opentype == 1)
            {
                DateTime jietime2 = Utils.ParseTime(Utils.GetRequest("jietime", "post", 2, DT.RegexTime, "请正确填写截止时间"));
                jietime = jietime2.ToString();
            }
            if (info == "ok")
            {
                //游戏日志记录
                int      ManageId  = new BCW.User.Manage().IsManageLogin();
                string[] p_pageArr = { "act", "ac", "opentype", "resultone", "resulttwo", "jietime", "gid", "pid", "info" };
                BCW.User.GameLog.GameLogPage(1, Utils.getPageUrl(), p_pageArr, "后台管理员开奖个人庄赛事" + model.p_one + "VS" + model.p_two + "-记录" + gid + "_" + pid + "", gid);


                //之前比分
                int oldresultone = Convert.ToInt32(model.p_result_one);
                int oldresulttwo = Convert.ToInt32(model.p_result_two);

                //更新比分
                model.p_result_one = resultone;
                model.p_result_two = resulttwo;

                if (opentype == 3)
                {
                    model.p_active = 2;//平盘标识
                }
                else
                {
                    model.p_active = 1;
                }

                //bll.UpdateResult(model);

                if (model.p_ison == 1)
                {
                    if (opentype == 1)
                    {
                        UpdateCaseOnce(resultone, resulttwo, gid, Convert.ToInt32(model.p_type), model.usid, jietime, pid);
                        UpdateCasePP(resultone, resulttwo, gid, Convert.ToInt32(model.p_type), model.usid, jietime, pid);
                    }
                    else if (opentype == 2)
                    {
                        UpdateCasePP(resultone, resulttwo, gid, Convert.ToInt32(model.p_type), model.usid, "", pid);
                    }
                    else
                    {
                        UpdateCaseOnce(resultone, resulttwo, gid, Convert.ToInt32(model.p_type), model.usid, jietime, pid);
                    }
                }
                else
                {
                    if (opentype == 1)
                    {
                        UpdateCase(resultone, resulttwo, gid, Convert.ToInt32(model.p_type), model.usid, jietime, pid);
                        UpdateCasePP(resultone, resulttwo, gid, Convert.ToInt32(model.p_type), model.usid, jietime, pid);
                    }
                    else if (opentype == 2)
                    {
                        UpdateCasePP(resultone, resulttwo, gid, Convert.ToInt32(model.p_type), model.usid, "", pid);
                    }
                    else
                    {
                        UpdateCase(resultone, resulttwo, gid, Convert.ToInt32(model.p_type), model.usid, jietime, pid);
                    }
                }
                //发送内线
                string strLog = "管理员对个人庄纠纷《" + model.p_title + ":" + model.p_two + "VS" + model.p_two + "》进行重开奖,原开奖比分" + oldresultone + ":" + oldresulttwo + ",重新开奖比分:" + resultone + ":" + resulttwo + "[url=/bbs/guess2/kzcaseGuess.aspx]马上兑奖[/url]";
                new BCW.BLL.Guest().Add(1, model.usid, new BCW.BLL.User().GetUsName(model.usid), strLog);

                Utils.Success("开奖", "开奖" + resultone + ":" + resulttwo + "成功..", Utils.getUrl("kzbother.aspx"), "1");
            }
            else
            {
                builder.Append(Out.Tab("<div>", ""));
                if (opentype == 0)
                {
                    builder.Append("请确认比分" + resultone + ":" + resulttwo + "");
                }
                else if (opentype == 1)
                {
                    builder.Append("请确认比分" + resultone + ":" + resulttwo + "|截时时间:" + jietime + "<br />温馨提示;截时时间");
                }
                else
                {
                    builder.Append("请确定平盘");
                }

                builder.Append(Out.Tab("</div>", "<br />"));
                string strName = "resultone,resulttwo,opentype,jietime,gid,pid,info,act";
                string strValu = "" + resultone + "'" + resulttwo + "'" + opentype + "'" + jietime + "'" + gid + "'" + pid + "'ok'open";
                string strOthe = "确定开奖,kzbother.aspx,post,0,red";

                builder.Append(Out.wapform(strName, strValu, strOthe));
                builder.Append(Out.Tab("<div class=\"hr\"></div>", Out.Hr()));
                builder.Append(Out.Tab("<div>", ""));
                builder.Append(Out.waplink(Utils.getUrl("kzbother.aspx"), "返回上一级"));
                builder.Append(Out.Tab("</div>", ""));
                builder.Append(Out.Tab("<div class=\"title\">", "<br />"));
                builder.Append("<a href=\"" + Utils.getUrl("../default.aspx") + "\">返回管理中心</a>");
                builder.Append(Out.Tab("</div>", "<br />"));
            }
        }
        else
        {
            builder.Append(Out.Tab("<div class=\"title\">", ""));
            builder.Append("开奖赛事" + model.p_one + "VS" + model.p_two + "-记录" + pid + "");
            builder.Append(Out.Tab("</div>", "<br />"));

            builder.Append(Out.Tab("<div class=\"text\">", ""));
            builder.Append("开赛:" + DT.FormatDate(Convert.ToDateTime(model.p_TPRtime), 0));
            builder.Append(Out.Tab("</div>", ""));

            string strText = string.Empty;
            string strName = string.Empty;
            string strType = string.Empty;
            string strValu = string.Empty;
            string strEmpt = string.Empty;

            strText = "*填写比分/,比/,开奖方式:/,截时时间(选择截时开奖时生效):/,,,";
            strName = "resultone,resulttwo,opentype,jietime,gid,pid,act";
            strType = "num,num,select,date,hidden,hidden,hidden";
            strValu = "0'0'0'" + DT.FormatDate(DateTime.Now, 0) + "'" + gid + "'" + pid + "'open";
            strEmpt = "false,false,0|正常开奖|1|截时开奖|2|平盘开奖,false,false,false";

            string strIdea = "/";
            string strOthe = "确定开奖,kzbother.aspx,post,1,red";

            builder.Append(Out.wapform(strText, strName, strType, strValu, strEmpt, strIdea, strOthe));

            builder.Append(Out.Tab("<div class=\"hr\"></div>", Out.Hr()));
            builder.Append(Out.Tab("<div>", ""));
            builder.Append(Out.waplink(Utils.getUrl("kzbother.aspx"), "返回上一级"));
            builder.Append(Out.Tab("</div>", ""));
            builder.Append(Out.Tab("<div class=\"title\">", "<br />"));
            builder.Append("<a href=\"" + Utils.getUrl("../default.aspx") + "\">返回管理中心</a>");
            builder.Append(Out.Tab("</div>", "<br />"));
        }
    }
Example #28
0
    private void ReloadPage()
    {
        Master.Title = "掷骰管理";
        builder.Append(Out.Tab("<div class=\"title\">", ""));
        builder.Append("<a href=\"" + Utils.getUrl("default.aspx") + "\">游戏</a>&gt;");
        builder.Append("掷骰");
        builder.Append(Out.Tab("</div>", "<br />"));
        string ac  = Utils.GetRequest("ac", "all", 1, "", "");
        int    uid = int.Parse(Utils.GetRequest("uid", "all", 1, @"^[1-9]\d*$", "0"));
        int    pageIndex;
        int    recordCount;
        int    pageSize = Convert.ToInt32(ub.Get("SiteListNo"));
        string strWhere = string.Empty;

        if (uid > 0)
        {
            if (Utils.ToSChinese(ac) == "应战")
            {
                strWhere += "reid=" + uid + "";
            }
            else
            {
                strWhere += "usid=" + uid + "";
            }
        }
        string[] pageValUrl = { "ac", "act", "uid", "backurl" };
        pageIndex = Utils.ParseInt(Request.QueryString["page"]);
        if (pageIndex == 0)
        {
            pageIndex = 1;
        }

        // 开始读取列表
        IList <BCW.Model.Game.Dxdice> listDxdice = new BCW.BLL.Game.Dxdice().GetDxdices(pageIndex, pageSize, strWhere, out recordCount);

        if (listDxdice.Count > 0)
        {
            int k = 1;
            foreach (BCW.Model.Game.Dxdice n in listDxdice)
            {
                if (k % 2 == 0)
                {
                    builder.Append(Out.Tab("<div class=\"text\">", "<br />"));
                }
                else
                {
                    if (k == 1)
                    {
                        builder.Append(Out.Tab("<div>", ""));
                    }
                    else
                    {
                        builder.Append(Out.Tab("<div>", "<br />"));
                    }
                }
                string bzText = string.Empty;
                if (n.BzType == 0)
                {
                    bzText = ub.Get("SiteBz");
                }
                else
                {
                    bzText = ub.Get("SiteBz2");
                }
                string TrueText = string.Empty;
                if (Utils.GetDomain().Contains("kubao") || Utils.GetDomain().Contains("tuhao") || Utils.GetDomain().Contains("th") || Utils.GetDomain().Contains("kb288"))
                {
                    int ManageId = new BCW.User.Manage().IsManageLogin();
                    if (ManageId == 1)
                    {
                        TrueText = "/庄" + n.DxdiceA + "/闲" + ((n.DxdiceB == "") ? "xx" : n.DxdiceB) + "";
                    }
                }
                else
                {
                    TrueText = "/庄" + n.DxdiceA + "/闲" + ((n.DxdiceB == "") ? "xx" : n.DxdiceB) + "";
                }
                builder.Append("<a href=\"" + Utils.getUrl("dxdice.aspx?act=del&amp;id=" + n.ID + "&amp;backurl=" + Utils.PostPage(1) + "") + "\">[删]&gt;</a>");
                builder.Append("" + ((pageIndex - 1) * pageSize + k) + ".<a href=\"" + Utils.getUrl("dxdice.aspx?act=view&amp;id=" + n.ID + "&amp;backurl=" + Utils.PostPage(1) + "") + "\">" + n.UsName + "</a>(" + n.Price + "" + bzText + "" + TrueText + ")");
                k++;
                builder.Append(Out.Tab("</div>", ""));
            }

            // 分页
            builder.Append(BasePage.MultiPage(pageIndex, pageSize, recordCount, Utils.getPageUrl(), pageValUrl, "page", 0));
        }
        else
        {
            builder.Append(Out.Div("div", "没有相关记录.."));
        }
        string strText = "输入用户ID:/,";
        string strName = "uid,backurl";
        string strType = "num,hidden";
        string strValu = "'" + Utils.getPage(0) + "";
        string strEmpt = "true,false";
        string strIdea = "/";
        string strOthe = "搜掷骰|应战,dxdice.aspx,post,1,red|blue";

        builder.Append(Out.wapform(strText, strName, strType, strValu, strEmpt, strIdea, strOthe));

        builder.Append(Out.Tab("<div class=\"hr\"></div>", Out.Hr()));
        builder.Append(Out.Tab("<div>", ""));
        builder.Append("<a href=\"" + Utils.getUrl("dxdice.aspx?act=stat") + "\">赢利分析</a><br />");
        builder.Append("<a href=\"" + Utils.getUrl("dxdice.aspx?act=reset") + "\">重置游戏</a><br />");
        builder.Append("<a href=\"" + Utils.getUrl("../xml/dxdiceset.aspx?backurl=" + Utils.PostPage(1) + "") + "\">游戏配置</a><br />");
        builder.Append("<a href=\"" + Utils.getUrl("../toplist.aspx?act=top&amp;ptype=10&amp;backurl=" + Utils.PostPage(1) + "") + "\">排行榜单</a>");
        builder.Append(Out.Tab("</div>", "<br />"));
        builder.Append(Out.Tab("<div class=\"title\">", ""));
        builder.Append("<a href=\"" + Utils.getUrl("../default.aspx") + "\">返回管理中心</a>");
        builder.Append(Out.Tab("</div>", "<br />"));
    }
Example #29
0
    protected void Page_Load(object sender, EventArgs e)
    {
        int    ManageId = new BCW.User.Manage().IsManageLogin();
        int    gid      = Utils.ParseInt(Utils.GetRequest("gid", "all", 2, @"^[0-9]*$", "竞猜ID无效"));
        string act      = Utils.GetRequest("act", "all", 1, "", "");
        ///抓取更新标记
        string jc = Utils.GetRequest("jc", "get", 1, "", "");
        ///开奖状态更新标记
        string dr = Utils.GetRequest("dr", "get", 1, "", "");

        TPR2.BLL.guess.BaList   bll = new TPR2.BLL.guess.BaList();
        TPR2.Model.guess.BaList st  = bll.GetModel(gid);
        if (st == null)
        {
            Utils.Error("不存在的记录", "");
        }

        #region 立即更新水位 访问8bo

        string bo = "";
        //-----------------------------立即更新水位---------------------------------
        if (st.p_active == 0)
        {
            //读取SiteViewStatus 等于0时采用即时刷新,其他值时,通过刷新机刷新
            //黄国军 20160223
            if (ub.GetSub("SiteUpdateOpen", "/Controls/guess2.xml") == "" || ub.GetSub("SiteUpdateOpen", "/Controls/guess2.xml") == "0")
            {
                #region 进入旧版更新
                if (st.p_basketve == 0)
                {
                    if (st.p_type == 1)
                    {
                        if (st.p_ison == 1)
                        {
                            bo = new TPR2.Collec.Footbo().GetBoView_kb_old(Convert.ToInt32(st.p_id), true);
                        }
                        else
                        {
                            bo = new TPR2.Collec.Footbo().GetBoView_kb_old(Convert.ToInt32(st.p_id), false);
                            //进行波胆更新
                            if (st.p_score != "")
                            {
                                bo = new TPR2.Collec.Footbd().FootbdPageHtml_kb_old(Convert.ToInt32(st.p_id));
                            }
                        }
                    }
                    else
                    {
                        if (st.p_ison == 1)
                        {
                            bo = new TPR2.Collec.Basketbo().GetBoView_kb_old(Convert.ToInt32(st.p_id), true);
                        }
                        else
                        {
                            bo = new TPR2.Collec.Basketbo().GetBoView_kb_old(Convert.ToInt32(st.p_id), false);
                        }
                    }
                }
                else if (st.p_basketve == 9)
                {
                    //载入页面更新足球上半场
                    if (st.p_type == 1)
                    {
                        string s = "";
                        if (st.p_ison == 1)
                        {
                            bo = new TPR2.Collec.Footbo().GetBoView_kb_old(Convert.ToInt32(st.p_id), true);
                            bo = new TPR2.Collec.FootFalf().FootFalfPageHtml_kb_old(Convert.ToInt32(st.p_id), true, ref s);
                        }
                        else
                        {
                            bo = new TPR2.Collec.FootFalf().FootFalfPageHtml_kb_old(Convert.ToInt32(st.p_id), false, ref s);
                        }
                    }
                }
                #endregion
            }
            else
            {
                #region 进入新版更新
                if (st.p_basketve == 0)
                {
                    if (st.p_type == 1)
                    {
                        if (st.p_ison == 1)
                        {
                            bo = new TPR2.Collec.Footbo().GetBoView1(Convert.ToInt32(st.p_id), true);
                        }
                        else
                        {
                            bo = new TPR2.Collec.Footbo().GetBoView1(Convert.ToInt32(st.p_id), false);
                            //进行波胆更新
                            if (st.p_score != "")
                            {
                                new TPR2.Collec.Footbd().FootbdPageHtml(Convert.ToInt32(st.p_id));
                            }
                        }
                    }
                    else
                    {
                        if (st.p_ison == 1)
                        {
                            bo = new TPR2.Collec.Basketbo().GetBoView1(Convert.ToInt32(st.p_id), true);
                        }
                        else
                        {
                            bo = new TPR2.Collec.Basketbo().GetBoView1(Convert.ToInt32(st.p_id), false);
                        }
                    }
                }
                else if (st.p_basketve == 9)
                {
                    //载入页面更新足球上半场
                    if (st.p_type == 1)
                    {
                        string s = "";
                        if (st.p_ison == 1)
                        {
                            bo = new TPR2.Collec.FootFalf().FootFalfPageHtml1(Convert.ToInt32(st.p_id), true, ref s);
                        }
                        else
                        {
                            bo = new TPR2.Collec.FootFalf().FootFalfPageHtml1(Convert.ToInt32(st.p_id), false, ref s);
                        }
                    }
                }

                #endregion
            }
            //篮球半场和单节
            if (st.p_basketve == 1 || st.p_basketve == 3)
            {
                bo = "1";
            }
        }
        #endregion

        //更新封盘不封盘

        if (act == "luck1")
        {
            new TPR2.BLL.guess.BaList().Updatep_isluck2(gid, 1, 1);
        }
        else if (act == "luck2")
        {
            new TPR2.BLL.guess.BaList().Updatep_isluck2(gid, 1, 2);
        }
        else if (act == "luck3")
        {
            new TPR2.BLL.guess.BaList().Updatep_isluck2(gid, 1, 3);
        }
        else if (act == "noluck1")
        {
            new TPR2.BLL.guess.BaList().Updatep_isluck2(gid, 0, 1);
        }
        else if (act == "noluck2")
        {
            new TPR2.BLL.guess.BaList().Updatep_isluck2(gid, 0, 2);
        }
        else if (act == "noluck3")
        {
            new TPR2.BLL.guess.BaList().Updatep_isluck2(gid, 0, 3);
        }


        TPR2.Model.guess.BaList model = bll.GetModel(gid);

        Master.Title = model.p_one + "VS" + model.p_two;

        #region 更新隐藏与显示
        //更新隐藏与显示
        if (act == "yes")
        {
            //游戏日志记录
            string[] p_pageArr = { "act", "gid" };
            BCW.User.GameLog.GameLogGetPage(1, Utils.getPageUrl(), p_pageArr, "后台管理员" + ManageId + "号将赛事" + model.p_one + "VS" + model.p_two + "(" + gid + ")开放显示", gid);
            model.p_del = 0;
            new TPR2.BLL.guess.BaList().Updatep_del(model);
        }
        else if (act == "no")
        {
            //游戏日志记录
            string[] p_pageArr = { "act", "gid" };
            BCW.User.GameLog.GameLogGetPage(1, Utils.getPageUrl(), p_pageArr, "后台管理员" + ManageId + "号将赛事" + model.p_one + "VS" + model.p_two + "(" + gid + ")隐藏显示", gid);
            model.p_del = 1;
            new TPR2.BLL.guess.BaList().Updatep_del(model);
        }
        #endregion

        #region 更新抓取与不抓取
        //更新抓取与不抓取
        if (jc == "yes")
        {
            //游戏日志记录
            string[] p_pageArr = { "jc", "gid" };
            BCW.User.GameLog.GameLogGetPage(1, Utils.getPageUrl(), p_pageArr, "后台管理员" + ManageId + "号将赛事" + model.p_one + "VS" + model.p_two + "(" + gid + ")开启抓取", gid);
            model.p_jc = 0;
            new TPR2.BLL.guess.BaList().Updatep_jc(model);
        }
        else if (jc == "no")
        {
            //游戏日志记录
            string[] p_pageArr = { "jc", "gid" };
            BCW.User.GameLog.GameLogGetPage(1, Utils.getPageUrl(), p_pageArr, "后台管理员" + ManageId + "号将赛事" + model.p_one + "VS" + model.p_two + "(" + gid + ")关闭抓取", gid);
            model.p_jc = 1;
            new TPR2.BLL.guess.BaList().Updatep_jc(model);
        }
        #endregion

        #region 更新开奖方式:自动或人工
        //更新抓取与不抓取
        if (dr == "0")
        {
            //游戏日志记录
            string[] p_pageArr = { "dr", "gid" };
            BCW.User.GameLog.GameLogGetPage(1, Utils.getPageUrl(), p_pageArr, "后台管理员" + ManageId + "号将赛事" + model.p_one + "VS" + model.p_two + "(" + gid + ")设置为自动开奖", gid);
            model.p_dr = 0;
            new TPR2.BLL.guess.BaList().Updatep_dr(model);
        }
        else if (dr == "1")
        {
            //游戏日志记录
            string[] p_pageArr = { "dr", "gid" };
            BCW.User.GameLog.GameLogGetPage(1, Utils.getPageUrl(), p_pageArr, "后台管理员" + ManageId + "号将赛事" + model.p_one + "VS" + model.p_two + "(" + gid + ")设置为人工开奖", gid);
            model.p_dr = 1;
            new TPR2.BLL.guess.BaList().Updatep_dr(model);
        }
        #endregion

        #region  除赛事
        //删除赛事
        if (act == "del" || act == "delok1" || act == "delok2")
        {
            if (act == "del")
            {
                builder.Append(Out.Tab("<div class=\"title\">", ""));
                builder.Append("确定删除此赛事吗");
                builder.Append(Out.Tab("</div>", "<br />"));
                builder.Append(Out.Tab("<div>", ""));
                builder.Append(Out.waplink(Utils.getUrl("showGuess.aspx?gid=" + gid + "&amp;act=delok1"), "删除,不包含下注记录") + "<br />");
                builder.Append(Out.waplink(Utils.getUrl("showGuess.aspx?gid=" + gid + "&amp;act=delok2"), "删除,包含下注记录") + "<br />");
                builder.Append(Out.waplink(Utils.getUrl("showGuess.aspx?gid=" + gid + ""), "先留着吧.."));
                builder.Append(Out.Tab("</div>", "<br />"));
            }
            else
            {
                //游戏日志记录
                string[] p_pageArr = { "act", "gid" };
                BCW.User.GameLog.GameLogGetPage(1, Utils.getPageUrl(), p_pageArr, "后台管理员" + ManageId + "号删除赛事" + model.p_one + "VS" + model.p_two + "(" + gid + ")", gid);

                new TPR2.BLL.guess.BaList().Delete(gid);
                if (act == "delok2")
                {
                    TPR2.BLL.guess.BaPay bll2 = new TPR2.BLL.guess.BaPay();
                    new TPR2.BLL.guess.BaPay().Deletebcid(gid);
                }
                Utils.Success("删除赛事", "删除赛事成功..", Utils.getUrl("default.aspx"), "1");
            }
        }
        #endregion

        #region 转换成滚球模式
        //转换成" + ub.Get("SiteGqText") + "模式
        else if (act == "once" || act == "onceok")
        {
            if (act == "once")
            {
                string p_oncetime = string.Empty;
                if (string.IsNullOrEmpty(model.p_oncetime.ToString()))
                {
                    p_oncetime = DT.FormatDate(Convert.ToDateTime(model.p_TPRtime).AddMinutes(130), 0);
                }
                else
                {
                    p_oncetime = DT.FormatDate(Convert.ToDateTime(model.p_oncetime), 0);
                }

                builder.Append(Out.Tab("<div class=\"title\">", ""));
                builder.Append("确定要转换成" + ub.Get("SiteGqText") + "下注模式吗");
                builder.Append(Out.Tab("</div>", ""));
                string strText = "封盘时间,,";
                string strName = "oncetime,gid,act";
                string strType = "date,hidden,hidden";
                string strValu = "" + p_oncetime + "'" + gid + "'onceok";
                string strEmpt = "false,false,false";
                string strIdea = "/";
                string strOthe = "转换,showGuess.aspx,post,1,red";
                builder.Append(Out.wapform(strText, strName, strType, strValu, strEmpt, strIdea, strOthe));

                builder.Append(Out.Tab("<div>", " "));
                builder.Append(Out.waplink(Utils.getUrl("showGuess.aspx?gid=" + gid + ""), "取消"));
                builder.Append(Out.Tab("</div>", "<br />"));
            }
            else
            {
                DateTime oncetime = Utils.ParseTime(Utils.GetRequest("oncetime", "all", 2, DT.RegexTime, "请正确填写封盘时间"));

                if (Convert.ToDateTime(model.p_TPRtime) > oncetime)
                {
                    Utils.Error("封盘时间应大于开赛时间", "");
                }
                //游戏日志记录
                string[] p_pageArr = { "oncetime", "act", "gid" };
                BCW.User.GameLog.GameLogGetPage(1, Utils.getPageUrl(), p_pageArr, "后台管理员" + ManageId + "号编辑赛事" + model.p_one + "VS" + model.p_two + "(" + gid + ")成为" + ub.Get("SiteGqText") + "", gid);

                new TPR2.BLL.guess.BaList().FootOnceType(gid, oncetime);
                Utils.Success("转换" + ub.Get("SiteGqText") + "", "转换成功..", Utils.getUrl("showguess.aspx?gid=" + gid + ""), "1");
            }
        }
        #endregion

        #region 赛事分析
        else if (act == "analysis")
        {
            Master.Title = "赛事分析";
            builder.Append(Out.Tab("<div class=\"title\">即时赛事分析</div>", ""));
            builder.Append(Out.Tab("<div>", ""));
            string strAnal = string.Empty;
            if (model.p_type == 1)
            {
                strAnal = new TPR2.Collec.Analysis().GetAnalysisFoot(0, Convert.ToInt32(model.p_id), gid);

                if (strAnal == "暂无数据。")
                {
                    strAnal = new TPR2.Collec.Analysis().GetAnalysisFoot(1, Convert.ToInt32(model.p_id), gid);
                }
            }
            else
            {
                strAnal = new TPR2.Collec.Analysis().GetAnalysisBasket(0, Convert.ToInt32(model.p_id), gid);

                if (strAnal == "暂无数据。")
                {
                    strAnal = new TPR2.Collec.Analysis().GetAnalysisBasket(1, Convert.ToInt32(model.p_id), gid);
                }
            }
            if (strAnal != "")
            {
                builder.Append("" + strAnal + "");
            }
            else
            {
                builder.Append("暂无记录..");
            }
            builder.Append(Out.Tab("</div>", Out.Hr()));
            builder.Append(Out.Tab("<div>", ""));
            builder.Append(Out.waplink(Utils.getPage("showGuess.aspx?gid=" + gid + ""), "返回上级") + "");
            builder.Append(Out.Tab("</div>", "<br />"));
        }
        #endregion

        #region 波胆设置
        else if (act == "score")
        {
            Master.Title = "波胆盘设置";

            builder.Append(Out.Tab("<div class=\"title\">", ""));
            builder.Append(model.p_title + ":" + model.p_one + "VS" + model.p_two);
            builder.Append(Out.Tab("</div>", "<br />"));
            builder.Append(Out.Tab("<div>", ""));
            builder.Append("〓波胆盘〓<br />");
            builder.Append("主胜↔客胜↔打和");
            builder.Append(Out.Tab("</div>", "<br />"));


            string strText = "1:0,0:1,0:0,/,2:0,0:2,1:1,/,3:0,0:3,2:2,/,4:0,0:4,3:3,/,2:1,1:2,4:4,/,3:1,1:3,/,4:1,1:4,/,3:2,2:3,/,4:2,2:4,/,4:3,3:4,/,主净胜5球或以上,/,客净胜5球或以上,/,其他胆,,,,,,";
            string strName = "score10,score01,score00,,score20,score02,score11,,score30,score03,score22,,score40,score04,score33,,score21,score12,score44,,score31,score13,,score41,score14,,score32,score23,,score42,score24,,score43,score34,,score5z,,score5k,,scoreot,gid,act";
            string strType = "small,small,small,hr,small,small,small,hr,small,small,small,hr,small,small,small,hr,small,small,small,hr,small,small,hr,small,small,hr,small,small,hr,small,small,hr,small,small,hr,small,hr,small,hr,small,hidden,hidden";

            string strValu = "";
            if (!string.IsNullOrEmpty(model.p_score))
            {
                string[] score = model.p_score.Split(',');
                string   other = "15";
                if (score.Length > 27)
                {
                    other = score[27].Split('|')[1];
                }
                strValu = "" + score[0].Split('|')[1] + "'" + score[1].Split('|')[1] + "'" + score[2].Split('|')[1] + "''" + score[3].Split('|')[1] + "'" + score[4].Split('|')[1] + "'" + score[5].Split('|')[1] + "''" + score[6].Split('|')[1] + "'" + score[7].Split('|')[1] + "'" + score[8].Split('|')[1] + "''" + score[9].Split('|')[1] + "'" + score[10].Split('|')[1] + "'" + score[11].Split('|')[1] + "''" + score[12].Split('|')[1] + "'" + score[13].Split('|')[1] + "'" + score[14].Split('|')[1] + "''" + score[15].Split('|')[1] + "'" + score[16].Split('|')[1] + "''" + score[17].Split('|')[1] + "'" + score[18].Split('|')[1] + "''" + score[19].Split('|')[1] + "'" + score[20].Split('|')[1] + "''" + score[21].Split('|')[1] + "'" + score[22].Split('|')[1] + "''" + score[23].Split('|')[1] + "'" + score[24].Split('|')[1] + "''" + score[25].Split('|')[1] + "''" + score[26].Split('|')[1] + "''" + other + "'" + gid + "'scoreok";
            }
            else
            {
                strValu = "''''''''''''''''''''''''''''''''''''''''" + gid + "'scoreok";
            }
            string strEmpt = "true,true,true,,true,true,true,,true,true,true,,true,true,true,,true,true,true,,true,true,,true,true,,true,true,,true,true,,true,true,,true,,true,true,true,true,true,true,false,false";
            string strIdea = "倍 '倍 '倍 ''倍 '倍 '倍 ''倍 '倍 '倍 ''倍 '倍 '倍 ''倍 '倍 '倍 ''倍 '倍 ''倍 '倍 ''倍 '倍 ''倍 '倍 ''倍 '倍 ''倍 ''倍 '''倍 ''倍 '倍 ''倍 ''倍 '''倍 ''倍 '倍 ''倍 ''倍 '''倍 ''倍 '倍 ''倍 ''倍 ''|/";
            string strOthe = "确定编辑,showGuess.aspx,post,3,red";
            builder.Append(Out.wapform(strText, strName, strType, strValu, strEmpt, strIdea, strOthe));
            builder.Append(Out.Tab("<div class=\"hr\"></div>", Out.Hr()));
            builder.Append(Out.Tab("<div>", ""));
            builder.Append("温馨提示:当某项不开放投注或无赔率时,请填写-1<br />");
            builder.Append(Out.waplink(Utils.getUrl("showGuess.aspx?act=scoreok2&amp;gid=" + gid + ""), "[取消本场波胆]") + "<br />");
            builder.Append(Out.waplink(Utils.getUrl("showGuess.aspx?gid=" + gid + ""), "返回上级") + "");
            builder.Append(Out.Tab("</div>", "<br />"));
            builder.Append(Out.Tab("<div class=\"title\">", ""));
            builder.Append("<a href=\"" + Utils.getUrl("../default.aspx") + "\">返回管理中心</a>");
            builder.Append(Out.Tab("</div>", "<br />"));
        }
        #endregion

        #region 游戏日志记录
        else if (act == "scoreok")
        {
            //游戏日志记录
            string[] p_pageArr = { "act", "gid", "score10", "score01", "score00", "score20", "score02", "score11", "score30", "score03", "score22", "score40", "score04", "score33", "score21", "score12", "score44", "score31", "score13", "score41", "score14", "score32", "score23", "score42", "score24", "score43", "score34", "score5z", "score5k", "scoreot" };
            BCW.User.GameLog.GameLogPage(1, Utils.getPageUrl(), p_pageArr, "后台管理员" + ManageId + "号将赛事编辑波胆" + model.p_one + "VS" + model.p_two + "(" + gid + ")", gid);

            decimal score10 = Convert.ToDecimal(Utils.GetRequest("score10", "post", 2, @"^-1$|^(\d)*(\.(\d){1,2})?$", "请正确填写1赔率,小数点后保留1-2位"));
            decimal score01 = Convert.ToDecimal(Utils.GetRequest("score01", "post", 2, @"^-1$|^(\d)*(\.(\d){1,2})?$", "请正确填写2赔率,小数点后保留1-2位"));
            decimal score00 = Convert.ToDecimal(Utils.GetRequest("score00", "post", 2, @"^-1$|^(\d)*(\.(\d){1,2})?$", "请正确填写3赔率,小数点后保留1-2位"));
            decimal score20 = Convert.ToDecimal(Utils.GetRequest("score20", "post", 2, @"^-1$|^(\d)*(\.(\d){1,2})?$", "请正确填写4赔率,小数点后保留1-2位"));
            decimal score02 = Convert.ToDecimal(Utils.GetRequest("score02", "post", 2, @"^-1$|^(\d)*(\.(\d){1,2})?$", "请正确填写5赔率,小数点后保留1-2位"));
            decimal score11 = Convert.ToDecimal(Utils.GetRequest("score11", "post", 2, @"^-1$|^(\d)*(\.(\d){1,2})?$", "请正确填写6赔率,小数点后保留1-2位"));
            decimal score30 = Convert.ToDecimal(Utils.GetRequest("score30", "post", 2, @"^-1$|^(\d)*(\.(\d){1,2})?$", "请正确填写7赔率,小数点后保留1-2位"));
            decimal score03 = Convert.ToDecimal(Utils.GetRequest("score03", "post", 2, @"^-1$|^(\d)*(\.(\d){1,2})?$", "请正确填写8赔率,小数点后保留1-2位"));
            decimal score22 = Convert.ToDecimal(Utils.GetRequest("score22", "post", 2, @"^-1$|^(\d)*(\.(\d){1,2})?$", "请正确填写9赔率,小数点后保留1-2位"));
            decimal score40 = Convert.ToDecimal(Utils.GetRequest("score40", "post", 2, @"^-1$|^(\d)*(\.(\d){1,2})?$", "请正确填写10赔率,小数点后保留1-2位"));
            decimal score04 = Convert.ToDecimal(Utils.GetRequest("score04", "post", 2, @"^-1$|^(\d)*(\.(\d){1,2})?$", "请正确填写11赔率,小数点后保留1-2位"));
            decimal score33 = Convert.ToDecimal(Utils.GetRequest("score33", "post", 2, @"^-1$|^(\d)*(\.(\d){1,2})?$", "请正确填写12赔率,小数点后保留1-2位"));
            decimal score21 = Convert.ToDecimal(Utils.GetRequest("score21", "post", 2, @"^-1$|^(\d)*(\.(\d){1,2})?$", "请正确填写13赔率,小数点后保留1-2位"));
            decimal score12 = Convert.ToDecimal(Utils.GetRequest("score12", "post", 2, @"^-1$|^(\d)*(\.(\d){1,2})?$", "请正确填写14赔率,小数点后保留1-2位"));
            decimal score44 = Convert.ToDecimal(Utils.GetRequest("score44", "post", 2, @"^-1$|^(\d)*(\.(\d){1,2})?$", "请正确填写15赔率,小数点后保留1-2位"));
            decimal score31 = Convert.ToDecimal(Utils.GetRequest("score31", "post", 2, @"^-1$|^(\d)*(\.(\d){1,2})?$", "请正确填写16赔率,小数点后保留1-2位"));
            decimal score13 = Convert.ToDecimal(Utils.GetRequest("score13", "post", 2, @"^-1$|^(\d)*(\.(\d){1,2})?$", "请正确填写17赔率,小数点后保留1-2位"));
            decimal score41 = Convert.ToDecimal(Utils.GetRequest("score41", "post", 2, @"^-1$|^(\d)*(\.(\d){1,2})?$", "请正确填写18赔率,小数点后保留1-2位"));
            decimal score14 = Convert.ToDecimal(Utils.GetRequest("score14", "post", 2, @"^-1$|^(\d)*(\.(\d){1,2})?$", "请正确填写19赔率,小数点后保留1-2位"));
            decimal score32 = Convert.ToDecimal(Utils.GetRequest("score32", "post", 2, @"^-1$|^(\d)*(\.(\d){1,2})?$", "请正确填写20赔率,小数点后保留1-2位"));
            decimal score23 = Convert.ToDecimal(Utils.GetRequest("score23", "post", 2, @"^-1$|^(\d)*(\.(\d){1,2})?$", "请正确填写21赔率,小数点后保留1-2位"));
            decimal score42 = Convert.ToDecimal(Utils.GetRequest("score42", "post", 2, @"^-1$|^(\d)*(\.(\d){1,2})?$", "请正确填写22赔率,小数点后保留1-2位"));
            decimal score24 = Convert.ToDecimal(Utils.GetRequest("score24", "post", 2, @"^-1$|^(\d)*(\.(\d){1,2})?$", "请正确填写23赔率,小数点后保留1-2位"));
            decimal score43 = Convert.ToDecimal(Utils.GetRequest("score43", "post", 2, @"^-1$|^(\d)*(\.(\d){1,2})?$", "请正确填写24赔率,小数点后保留1-2位"));
            decimal score34 = Convert.ToDecimal(Utils.GetRequest("score34", "post", 2, @"^-1$|^(\d)*(\.(\d){1,2})?$", "请正确填写25赔率,小数点后保留1-2位"));
            decimal score5z = Convert.ToDecimal(Utils.GetRequest("score5z", "post", 2, @"^-1$|^(\d)*(\.(\d){1,2})?$", "请正确填写26赔率,小数点后保留1-2位"));
            decimal score5k = Convert.ToDecimal(Utils.GetRequest("score5k", "post", 2, @"^-1$|^(\d)*(\.(\d){1,2})?$", "请正确填写27赔率,小数点后保留1-2位"));
            decimal scoreot = Convert.ToDecimal(Utils.GetRequest("scoreot", "post", 2, @"^-1$|^(\d)*(\.(\d){1,2})?$", "请正确填写27赔率,小数点后保留1-2位"));

            string score = "";
            score += "1:0|" + score10 + ",0:1|" + score01 + ",0:0|" + score00 + ",2:0|" + score20 + ",0:2|" + score02 + ",1:1|" + score11 + ",3:0|" + score30 + ",0:3|" + score03 + ",2:2|" + score22 + "";
            score += ",4:0|" + score40 + ",0:4|" + score04 + ",3:3|" + score33 + ",2:1|" + score21 + ",1:2|" + score12 + ",4:4|" + score44 + "";
            score += ",3:1|" + score31 + ",1:3|" + score13 + ",4:1|" + score41 + ",1:4|" + score14 + ",3:2|" + score32 + ",2:3|" + score23 + ",4:2|" + score42 + ",2:4|" + score24 + ",4:3|" + score43 + ",3:4|" + score34 + ",5z|" + score5z + ",5k|" + score5k + ",ot|" + scoreot;

            new TPR2.BLL.guess.BaList().Updatep_score(gid, score);
            Utils.Success("波胆设置", "波胆设置成功..", Utils.getUrl("showguess.aspx?act=score&amp;gid=" + gid + ""), "1");
        }
        #endregion

        #region 清空波胆
        else if (act == "scoreok2")
        {
            //游戏日志记录
            string[] p_pageArr = { "act", "gid" };
            BCW.User.GameLog.GameLogGetPage(1, Utils.getPageUrl(), p_pageArr, "后台管理员" + ManageId + "号将赛事清空波胆" + model.p_one + "VS" + model.p_two + "(" + gid + ")", gid);

            new TPR2.BLL.guess.BaList().Updatep_score(gid, "");
            Utils.Success("清空波胆", "清空波胆成功..", Utils.getUrl("showguess.aspx?act=score&amp;gid=" + gid + ""), "1");
        }
        #endregion

        #region  注受限设置
        else if (act == "xz")
        {
            Master.Title = "下注受限设置";

            builder.Append(Out.Tab("<div class=\"title\">", ""));
            builder.Append("下注受限设置");
            builder.Append(Out.Tab("</div>", ""));
            string strText = "全场受限ID(全局设置|用#分隔):/,上盘受限ID(用#分隔):/,下盘受限ID(用#分隔):/,大盘受限(用#分隔):/,小盘受限(用#分隔):/,,";
            string strName = "ID0,ID1,ID2,ID3,ID4,gid,act";
            string strType = "text,text,text,text,text,hidden,hidden";
            string strValu = "" + model.xID0 + "'" + model.xID1 + "'" + model.xID2 + "'" + model.xID3 + "'" + model.xID4 + "'" + gid + "'xzok";
            string strEmpt = "true,true,true,true,true,false,false";
            string strIdea = "/";
            string strOthe = "确定编辑,showGuess.aspx,post,1,red";
            builder.Append(Out.wapform(strText, strName, strType, strValu, strEmpt, strIdea, strOthe));
            builder.Append(Out.Tab("<div class=\"hr\"></div>", Out.Hr()));
            builder.Append(Out.Tab("<div>", ""));
            builder.Append(Out.waplink(Utils.getUrl("showGuess.aspx?gid=" + gid + ""), "返回上级") + "");
            builder.Append(Out.Tab("</div>", "<br />"));
            builder.Append(Out.Tab("<div class=\"title\">", ""));
            builder.Append("<a href=\"" + Utils.getUrl("../default.aspx") + "\">返回管理中心</a>");
            builder.Append(Out.Tab("</div>", "<br />"));
        }
        #endregion

        #region 设置受限ID
        else if (act == "xzok")
        {
            //游戏日志记录
            string[] p_pageArr = { "act", "gid", "ID0", "ID1", "ID2", "ID3", "ID4" };
            BCW.User.GameLog.GameLogPage(1, Utils.getPageUrl(), p_pageArr, "后台管理员" + ManageId + "号将赛事设置受限ID" + model.p_one + "VS" + model.p_two + "(" + gid + ")", gid);

            string ID0 = Utils.GetRequest("ID0", "post", 3, @"^[^\#]{1,50}(?:\#[^\#]{1,50}){0,500}$", "填写错误");
            string ID1 = Utils.GetRequest("ID1", "post", 3, @"^[^\#]{1,50}(?:\#[^\#]{1,50}){0,500}$", "填写错误");
            string ID2 = Utils.GetRequest("ID2", "post", 3, @"^[^\#]{1,50}(?:\#[^\#]{1,50}){0,500}$", "填写错误");
            string ID3 = Utils.GetRequest("ID3", "post", 3, @"^[^\#]{1,50}(?:\#[^\#]{1,50}){0,500}$", "填写错误");
            string ID4 = Utils.GetRequest("ID4", "post", 3, @"^[^\#]{1,50}(?:\#[^\#]{1,50}){0,500}$", "填写错误");

            new TPR2.BLL.guess.BaList().UpdatexID(gid, ID0, 0);
            new TPR2.BLL.guess.BaList().UpdatexID(gid, ID1, 1);
            new TPR2.BLL.guess.BaList().UpdatexID(gid, ID2, 2);
            new TPR2.BLL.guess.BaList().UpdatexID(gid, ID3, 3);
            new TPR2.BLL.guess.BaList().UpdatexID(gid, ID4, 4);

            Utils.Success("下注受限", "下注受限设置成功..", Utils.getUrl("showguess.aspx?act=xz&amp;gid=" + gid + ""), "1");
        }
        #endregion

        #region 全局封盘
        if (act == "luck")
        {
            //游戏日志记录
            string[] p_pageArr = { "act", "gid" };
            BCW.User.GameLog.GameLogGetPage(1, Utils.getPageUrl(), p_pageArr, "后台管理员" + ManageId + "号将赛事" + model.p_one + "VS" + model.p_two + "(" + gid + ")全局封盘", gid);

            new TPR2.BLL.guess.BaList().Updatep_isluck(gid, 1);
            Utils.Success("全局封盘", "全局封盘成功,所有会员将不能下注本场,需要手工解除封盘才可以..", Utils.getUrl("showguess.aspx?gid=" + gid + ""), "2");
        }
        #endregion

        #region 全局解封
        if (act == "noluck")
        {
            //游戏日志记录
            string[] p_pageArr = { "act", "gid" };
            BCW.User.GameLog.GameLogGetPage(1, Utils.getPageUrl(), p_pageArr, "后台管理员" + ManageId + "号将赛事" + model.p_one + "VS" + model.p_two + "(" + gid + ")全局解封", gid);

            new TPR2.BLL.guess.BaList().Updatep_isluck(gid, 0);
            Utils.Success("全局解封", "全局解封成功,所有会员可以下注了..", Utils.getUrl("showguess.aspx?gid=" + gid + ""), "2");
        }
        #endregion

        else
        {
            builder.Append(Out.Tab("<div class=\"title\">", ""));
            builder.Append(model.p_one + "VS" + model.p_two);
            builder.Append(Out.Tab("</div>", "<br />"));
            builder.Append(Out.Tab("<div>", ""));

            builder.Append(Out.waplink(Utils.getUrl("default.aspx?ptype=4&amp;fly=" + model.p_title + ""), model.p_title) + ":" + model.p_one + "VS" + model.p_two);

            #region 受限提示
            if (model.xID0 != "" || model.xID1 != "" || model.xID2 != "" || model.xID3 != "" || model.xID4 != "")
            {
                builder.Append("(有受限)");
            }
            #endregion

            #region 波胆
            builder.Append("<br />开赛:" + DT.FormatDate(Convert.ToDateTime(model.p_TPRtime), 0));
            if (model.p_type == 1)
            {
                builder.Append("" + Out.waplink(Utils.getUrl("showGuess.aspx?act=score&amp;gid=" + gid + ""), "[波胆]"));
                builder.AppendFormat("|" + Out.waplink(Utils.getUrl("plGuess.aspx?gid=" + model.ID + "&amp;p=100"), "{0}注") + "", new TPR2.BLL.guess.BaPay().GetCount(model.ID, Convert.ToInt32(model.p_type), 100));
            }

            #endregion

            #region 完场比分
            if (model.p_result_one != null && model.p_result_two != null)
            {
                builder.Append("<br />完场比分:" + model.p_result_one + ":" + model.p_result_two + "");
            }
            else
            {
                if (model.p_TPRtime > DateTime.Now)
                {
                    builder.Append("<br />比赛状态:未");
                }
                else
                {
                    builder.Append("<br />比赛状态:" + Convertp_once(model.p_once) + "");
                }

                builder.Append("<br />即时比分:" + model.p_result_temp1 + ":" + model.p_result_temp2 + "");
            }
            builder.Append("" + Out.waplink(Utils.getUrl("showGuess.aspx?act=analysis&amp;gid=" + gid + ""), "[析]"));

            builder.Append(Out.Tab("</div>", "<br />"));

            string hp_one = "";
            string hp_two = "";
            if (model.p_type == 1)
            {
                if (model.p_hp_one > 0)
                {
                    hp_one = "<img src=\"/Files/sys/guess/redcard" + model.p_hp_one + ".gif\" alt=\"红" + model.p_hp_one + "\"/>";
                }

                if (model.p_hp_two > 0)
                {
                    hp_two = "<img src=\"/Files/sys/guess/redcard" + model.p_hp_two + ".gif\" alt=\"红" + model.p_hp_two + "\"/>";
                }
            }
            #endregion

            #region 处理封盘状态
            int Min = 0;
            try
            {
                Min = Convert.ToInt32(model.p_once.ToString().Replace("'", "").Replace("+", ""));
            }
            catch
            {
            }
            if (model.p_type == 1)
            {
                if (Min > 41 && Min < 46 || Min > 87 || (model.p_once == "中" && model.p_basketve == 9))
                {
                    model.p_isluck = 1;
                }
            }
            #endregion

            #region 让球盘
            builder.Append(Out.Tab("<div class=\"text\">", ""));
            builder.Append("〓让球盘〓");

            if (model.p_ison == 1)
            {
                if (model.p_isluckone == 0)
                {
                    builder.Append("" + Out.waplink(Utils.getUrl("showGuess.aspx?gid=" + gid + "&amp;act=luck1"), "封"));
                }
                else
                {
                    builder.Append("" + Out.waplink(Utils.getUrl("showGuess.aspx?gid=" + gid + "&amp;act=noluck1"), "解封"));
                }
            }
            if (((model.p_ison == 1 && model.p_isluckone == 1) || model.p_isluck == 1) && model.p_active == 0)
            {
                builder.Append("<b>(封)</b>");
            }
            else if (bo == "")
            {
                builder.Append("<b>(停)</b>");
            }

            builder.AppendFormat("<br />{0}" + Out.waplink(Utils.getUrl("plGuess.aspx?gid=" + model.ID + "&amp;p=1"), "{1}注"), model.p_one + "" + hp_one + "(" + Convert.ToDouble(model.p_one_lu) + ")", new TPR2.BLL.guess.BaPay().GetCount(model.ID, Convert.ToInt32(model.p_type), 1));

            if (model.p_type == 1)
            {
                builder.Append("<br />" + GCK.getZqPn(Convert.ToInt32(model.p_pn)) + "" + GCK.getPkName(Convert.ToInt32(model.p_pk)) + "");
            }
            else
            {
                builder.Append("<br />" + Convert.ToDouble(model.p_pk) + "");
            }

            builder.AppendFormat("<br />{0}" + Out.waplink(Utils.getUrl("plGuess.aspx?gid=" + model.ID + "&amp;p=2"), "{1}注"), model.p_two + "" + hp_two + "(" + Convert.ToDouble(model.p_two_lu) + ")", new TPR2.BLL.guess.BaPay().GetCount(model.ID, Convert.ToInt32(model.p_type), 2));
            #endregion

            #region 大小盘
            if (model.p_big_lu != 0)
            {
                builder.Append("<br />〓大小盘〓");
                if (model.p_ison == 1)
                {
                    if (model.p_islucktwo == 0)
                    {
                        builder.Append("" + Out.waplink(Utils.getUrl("showGuess.aspx?gid=" + gid + "&amp;act=luck2"), "封"));
                    }
                    else
                    {
                        builder.Append("" + Out.waplink(Utils.getUrl("showGuess.aspx?gid=" + gid + "&amp;act=noluck2"), "解封"));
                    }
                }

                if (((model.p_ison == 1 && model.p_islucktwo == 1) || model.p_isluck == 1) && model.p_active == 0)
                {
                    builder.Append("<b>(封)</b>");
                }
                else if (bo == "")
                {
                    builder.Append("<b>(停)</b>");
                }

                builder.AppendFormat("<br />" + Out.waplink(Utils.getUrl("plGuess.aspx?gid=" + model.ID + "&amp;p=3"), "{0}注") + "{1}", new TPR2.BLL.guess.BaPay().GetCount(model.ID, Convert.ToInt32(model.p_type), 3), "大(" + Convert.ToDouble(model.p_big_lu) + ")");

                if (model.p_type == 1)
                {
                    builder.Append(GCK.getDxPkName(Convert.ToInt32(model.p_dx_pk)));
                }
                else
                {
                    builder.Append(Convert.ToDouble(model.p_dx_pk));
                }

                builder.AppendFormat("{0}" + Out.waplink(Utils.getUrl("plGuess.aspx?gid=" + model.ID + "&amp;p=4"), "{1}注"), "小(" + Convert.ToDouble(model.p_small_lu) + ")", new TPR2.BLL.guess.BaPay().GetCount(model.ID, Convert.ToInt32(model.p_type), 4));
            }
            #endregion

            #region 标准盘
            if (model.p_bzs_lu != 0)
            {
                builder.Append("<br />〓标准盘〓");
                if (model.p_ison == 1)
                {
                    if (model.p_isluckthr == 0)
                    {
                        builder.Append("" + Out.waplink(Utils.getUrl("showGuess.aspx?gid=" + gid + "&amp;act=luck3"), "封"));
                    }
                    else
                    {
                        builder.Append("" + Out.waplink(Utils.getUrl("showGuess.aspx?gid=" + gid + "&amp;act=noluck3"), "解封"));
                    }
                }
                if (((model.p_ison == 1 && model.p_isluckthr == 1) || model.p_isluck == 1) && model.p_active == 0)
                {
                    builder.Append("<b>(封)</b>");
                }
                else if (bo == "")
                {
                    builder.Append("<b>(停)</b>");
                }

                builder.AppendFormat("<br />{0}" + Out.waplink(Utils.getUrl("plGuess.aspx?gid=" + model.ID + "&amp;p=5"), "{1}注"), "主胜(" + Convert.ToDouble(model.p_bzs_lu) + ")", new TPR2.BLL.guess.BaPay().GetCount(model.ID, Convert.ToInt32(model.p_type), 5));
                builder.AppendFormat("<br />{0}" + Out.waplink(Utils.getUrl("plGuess.aspx?gid=" + model.ID + "&amp;p=6"), "{1}注"), "平手(" + Convert.ToDouble(model.p_bzp_lu) + ")", new TPR2.BLL.guess.BaPay().GetCount(model.ID, Convert.ToInt32(model.p_type), 6));
                builder.AppendFormat("<br />{0}" + Out.waplink(Utils.getUrl("plGuess.aspx?gid=" + model.ID + "&amp;p=7"), "{1}注"), "客胜(" + Convert.ToDouble(model.p_bzx_lu) + ")", new TPR2.BLL.guess.BaPay().GetCount(model.ID, Convert.ToInt32(model.p_type), 7));
            }
            builder.Append(Out.Tab("</div>", "<br />"));
            builder.Append(Out.Tab("<div>", ""));
            #endregion

            #region 统计 邵广林 20160817 增加机器人盈利分析
            long PayCents       = new TPR2.BLL.guess.BaPay().GetBaPayCent(model.ID, Convert.ToInt32(model.p_type));
            long PayCents_robot = new TPR2.BLL.guess.BaPay().GetBaPayCent_robot(model.ID, Convert.ToInt32(model.p_type));
            builder.Append("" + ub.Get("SiteBz") + "统计:<br />会员总注数:" + new TPR2.BLL.guess.BaPay().GetBaPayNum(model.ID, Convert.ToInt32(model.p_type)) + "/会员下注额:" + PayCents + "");
            builder.Append("<br />机器总注数:" + new TPR2.BLL.guess.BaPay().GetBaPayNum_robot(model.ID, Convert.ToInt32(model.p_type)) + "/机器下注额:" + PayCents_robot + "");
            if (model.p_result_one != null && model.p_result_two != null)
            {
                long WinMoney       = new TPR2.BLL.guess.BaPay().GetBaPaygetMoney("bcid=" + gid + " and Types=0 and isrobot=0");
                long WinMoney_robot = new TPR2.BLL.guess.BaPay().GetBaPaygetMoney("bcid=" + gid + " and Types=0 and isrobot=1");
                builder.Append("<br />会员总返彩:" + WinMoney + "/会员盈利额:" + (PayCents - WinMoney) + "");
                builder.Append("<br />机器总返彩:" + WinMoney_robot + "/机器盈利额:" + (PayCents_robot - WinMoney_robot) + "");
            }

            #endregion

            #region 〓管理〓
            builder.Append("<br />〓管理〓");
            if (model.p_active > 0 && model.p_result_one != null && model.p_result_two != null)
            {
                builder.Append("<br />" + Out.waplink(Utils.getUrl("openGuess.aspx?gid=" + gid + ""), "重开奖"));
            }
            else
            {
                builder.Append("<br />" + Out.waplink(Utils.getUrl("openGuess.aspx?gid=" + gid + ""), "开奖"));
            }

            builder.Append(" " + Out.waplink(Utils.getUrl("editGuess.aspx?gid=" + gid + ""), "修改"));
            builder.Append(" " + Out.waplink(Utils.getUrl("showGuess.aspx?gid=" + gid + "&amp;act=del"), "删除"));

            builder.Append(" " + Out.waplink(Utils.getUrl("payView.aspx?gid=" + gid + ""), "记录"));

            if (model.p_del == 0)
            {
                builder.Append(" " + Out.waplink(Utils.getUrl("showGuess.aspx?gid=" + gid + "&amp;act=no"), "隐藏"));
            }
            else
            {
                builder.Append(" " + Out.waplink(Utils.getUrl("showGuess.aspx?gid=" + gid + "&amp;act=yes"), "显示"));
            }

            if (model.p_jc == 0)
            {
                builder.Append("<br />抓取状态:正常抓取<br />" + Out.waplink(Utils.getUrl("showGuess.aspx?gid=" + gid + "&amp;jc=no"), "关闭抓取"));
            }
            else
            {
                builder.Append("<br />抓取状态:停止抓取<br />" + Out.waplink(Utils.getUrl("showGuess.aspx?gid=" + gid + "&amp;jc=yes"), "开启抓取"));
            }

            if (model.p_dr == 0)
            {
                builder.Append("<br />开奖方式:自动开奖<br />" + Out.waplink(Utils.getUrl("showGuess.aspx?gid=" + gid + "&amp;dr=1"), "人工开奖"));
            }
            else
            {
                builder.Append("<br />开奖方式:人工开奖<br />" + Out.waplink(Utils.getUrl("showGuess.aspx?gid=" + gid + "&amp;dr=0"), "自动开奖"));
            }

            if (model.p_ison == 1)
            {
                builder.Append("<br />" + ub.Get("SiteGqText") + "状态:" + ub.Get("SiteGqText") + "");
            }
            else
            {
                builder.Append("<br />" + ub.Get("SiteGqText") + "状态:非" + ub.Get("SiteGqText") + "");
            }

            builder.Append("" + Out.waplink(Utils.getUrl("showGuess.aspx?gid=" + gid + "&amp;act=once"), "编辑"));

            builder.Append("<br />8bo:" + model.p_id + "<br />");
            if (model.p_isluck == 0)
            {
                builder.Append("" + Out.waplink(Utils.getUrl("showGuess.aspx?gid=" + gid + "&amp;act=luck"), "全局封盘"));
            }
            else
            {
                builder.Append("" + Out.waplink(Utils.getUrl("showGuess.aspx?gid=" + gid + "&amp;act=noluck"), "全局解封"));
            }

            builder.Append("<br />" + Out.waplink(Utils.getUrl("showGuess.aspx?gid=" + gid + "&amp;act=xz"), "本场受限ID"));
            builder.Append("<br />" + Out.waplink(Utils.getUrl("../forumlog.aspx?act=gamelog&amp;ptype=2&amp;gid=" + gid + "&amp;backurl=" + Utils.PostPage(1) + ""), "" + ub.Get("SiteGqText") + "失败日志"));
            builder.Append("<br />" + Out.waplink(Utils.getUrl("../forumlog.aspx?act=gamelog&amp;ptype=1&amp;gid=" + gid + "&amp;backurl=" + Utils.PostPage(1) + ""), "操作日志"));
            builder.Append("<br />" + Out.waplink(Utils.getUrl("../forumlog.aspx?act=gameowe&amp;ptype=1&amp;gid=" + gid + "&amp;backurl=" + Utils.PostPage(1) + ""), "欠币日志"));
            #endregion

            builder.Append(Out.Tab("</div>", ""));
            builder.Append(Out.Tab("<div class=\"hr\"></div>", Out.Hr()));
            builder.Append(Out.Tab("<div>", ""));
            builder.Append(Out.waplink(Utils.getPage("default.aspx"), "返回上一级"));
            builder.Append(Out.Tab("</div>", ""));
            builder.Append(Out.Tab("<div class=\"title\">", "<br />"));
            builder.Append("<a href=\"" + Utils.getUrl("../default.aspx") + "\">返回管理中心</a>");
            builder.Append(Out.Tab("</div>", "<br />"));
        }
    }
Example #30
0
    protected void Page_Load(object sender, EventArgs e)
    {
        Master.Title = "增加赛事";
        int    ptype = Utils.ParseInt(Utils.GetRequest("ptype", "all", 1, @"^[1-2]$", "1"));
        string ac    = Utils.GetRequest("ac", "all", 1, "", "");

        if (ac == "确定添加" || ac == Utils.ToTChinese("确定添加"))
        {
            string   p_title   = Out.UBB(Utils.GetRequest("p_title", "post", 2, @"^[\u4e00-\u9fa5A-Za-z0-9_\-\s]+$", "请正确填写联赛名称"));
            DateTime p_TPRtime = Utils.ParseTime(Utils.GetRequest("p_TPRtime", "post", 2, DT.RegexTime, "请正确填写联赛时间"));
            string   p_one     = Out.UBB(Utils.GetRequest("p_one", "post", 2, @"^[\u4e00-\u9fa5A-Za-z0-9_\-\s]+$", "请正确填写上盘名称"));
            string   p_two     = Out.UBB(Utils.GetRequest("p_two", "post", 2, @"^[\u4e00-\u9fa5A-Za-z0-9_\-\s]+$", "请正确填写下盘名称"));
            decimal  p_one_lu  = Convert.ToDecimal(Utils.GetRequest("p_one_lu", "post", 2, @"^(\d)*(\.(\d){1,2})?$", "请正确填写上盘赔率,小数点后保留1-2位"));
            decimal  p_two_lu  = Convert.ToDecimal(Utils.GetRequest("p_two_lu", "post", 2, @"^(\d)*(\.(\d){1,2})?$", "请正确填写下盘赔率,小数点后保留1-2位"));

            decimal p_big_lu   = Convert.ToDecimal(Utils.GetRequest("p_big_lu", "post", 2, @"^-1$|^(\d)*(\.(\d){1,2})?$", "请正确填写大盘赔率,小数点后保留1-2位"));
            decimal p_small_lu = Convert.ToDecimal(Utils.GetRequest("p_small_lu", "post", 2, @"^-1$|^(\d)*(\.(\d){1,2})?$", "请正确填写小盘赔率,小数点后保留1-2位"));


            int     p_pn     = 0;
            decimal p_pk     = 0;
            decimal p_dx_pk  = 0;
            decimal p_bzs_lu = 0;
            decimal p_bzp_lu = 0;
            decimal p_bzx_lu = 0;
            if (ptype == 1)
            {//足球特征
                p_pn    = Utils.ParseInt(Utils.GetRequest("p_pn", "post", 2, @"^[1-2]$", "请正确选择让球类型"));
                p_pk    = Convert.ToDecimal(Utils.GetRequest("p_pk", "post", 2, @"^[0-9]{1,21}$", "请正确选择上下盘口"));
                p_dx_pk = Convert.ToDecimal(Utils.GetRequest("p_dx_pk", "post", 2, @"^[0-9]{1,19}$", "请正确选择大小盘口"));
                if (Request["p_bzs_lu"] != "")
                {
                    p_bzs_lu = Convert.ToDecimal(Utils.GetRequest("p_bzs_lu", "post", 2, @"^-1$|^(\d)*(\.(\d){1,2})?$", "请正确填写主胜赔率,小数点后保留1-2位"));
                    p_bzp_lu = Convert.ToDecimal(Utils.GetRequest("p_bzp_lu", "post", 2, @"^-1$|^(\d)*(\.(\d){1,2})?$", "请正确填写平手赔率,小数点后保留1-2位"));
                    p_bzx_lu = Convert.ToDecimal(Utils.GetRequest("p_bzx_lu", "post", 2, @"^-1$|^(\d)*(\.(\d){1,2})?$", "请正确填写客胜赔率,小数点后保留1-2位"));
                }
                else
                {
                    p_bzs_lu = 0;
                    p_bzp_lu = 0;
                    p_bzx_lu = 0;
                }
            }
            else
            {//篮球特征
                p_pk    = Convert.ToDecimal(Utils.GetRequest("p_pk", "post", 2, @"^(-)?(\d)*(\.(\d){1})?$", "请正确填写上下盘口"));
                p_dx_pk = Convert.ToDecimal(Utils.GetRequest("p_dx_pk", "post", 2, @"^(-)?(\d)*(\.(\d){1})?$", "请正确填写大小盘口"));
            }
            int p_ison = Convert.ToInt32(Utils.GetRequest("p_ison", "post", 1, @"^[0-1]$", "0"));


            //联赛限制显示
            string xmlPath = "/Controls/guess.xml";
            string Levens  = "";
            if (ptype == 1)
            {
                Levens = "#" + ub.GetSub("SiteLeven1", xmlPath) + "#" + ub.GetSub("SiteLeven2", xmlPath) + "#" + ub.GetSub("SiteLeven3", xmlPath) + "#" + ub.GetSub("SiteLeven4", xmlPath) + "#";
            }
            else
            {
                Levens = "#" + ub.GetSub("SiteLevenb1", xmlPath) + "#" + ub.GetSub("SiteLevenb2", xmlPath) + "#" + ub.GetSub("SiteLevenb3", xmlPath) + "#" + ub.GetSub("SiteLevenb4", xmlPath) + "#";
            }

            if (!Levens.Contains("#" + p_title + "#"))
            {
                Utils.Error("在四个联赛分级中不存在“" + p_title + "”联赛,请设置才能继续...", "");
            }


            //游戏日志记录
            int      ManageId  = new BCW.User.Manage().IsManageLogin();
            int      gid       = new TPR.BLL.guess.BaList().GetMaxId();
            string[] p_pageArr = { "ac", "p_title", "ptype", "p_one", "p_two", "p_pk", "p_dx_pk", "p_pn", "p_one_lu", "p_two_lu", "p_big_lu", "p_small_lu", "p_bzs_lu", "p_bzp_lu", "p_bzx_lu", "p_TPRtime", "p_ison" };
            BCW.User.GameLog.GameLogPage(Utils.getPageUrl(), p_pageArr, "后台管理员" + ManageId + "号增加赛事" + p_one + "VS" + p_two + "(" + gid + ")", gid);

            //写入数据
            TPR.Model.guess.BaList model = new TPR.Model.guess.BaList();
            model.p_id       = 0;
            model.p_title    = p_title;
            model.p_type     = ptype;
            model.p_one      = p_one;
            model.p_two      = p_two;
            model.p_pk       = p_pk;
            model.p_dx_pk    = p_dx_pk;
            model.p_pn       = p_pn;
            model.p_one_lu   = p_one_lu;
            model.p_two_lu   = p_two_lu;
            model.p_big_lu   = p_big_lu;
            model.p_small_lu = p_small_lu;
            model.p_bzs_lu   = p_bzs_lu;
            model.p_bzp_lu   = p_bzp_lu;
            model.p_bzx_lu   = p_bzx_lu;
            model.p_addtime  = DateTime.Now;
            model.p_TPRtime  = p_TPRtime;
            model.p_ison     = p_ison;
            model.p_del      = 0;
            new TPR.BLL.guess.BaList().Add(model);
            Utils.Success("添加赛事", "添加赛事成功..<br />" + Out.waplink(Utils.getUrl("addGuess.aspx"), "继续添加") + "", Utils.getUrl("default.aspx"), "1");
        }
        else
        {
            builder.Append(Out.Tab("<div class=\"title\">", ""));
            builder.Append("增加赛事");
            builder.Append(Out.Tab("</div>", "<br />"));
            if (ptype == 1)
            {
                builder.Append(Out.Tab("<div class=\"text\">", ""));
                builder.Append("增加:足球赛事 " + Out.waplink(Utils.getUrl("addGuess.aspx?ptype=2"), "切换篮球"));
                builder.Append(Out.Tab("</div>", ""));
                string strText = "联赛名称,联赛时间,上盘名称,上盘赔率,下盘名称,下盘赔率,让球类型,上下盘口,大盘赔率,小盘赔率,大小盘口,主胜赔率,平手赔率,客胜赔率,是否开走地,";
                string strName = "p_title,p_TPRtime,p_one,p_one_lu,p_two,p_two_lu,p_pn,p_pk,p_big_lu,p_small_lu,p_dx_pk,p_bzs_lu,p_bzp_lu,p_bzx_lu,p_ison,ptype";
                string strType = "text,date,text,text,text,text,select,select,text,text,select,text,text,text,select,hidden";
                string strValu = "'" + DT.FormatDate(DateTime.Now.AddHours(5), 0) + "'''''1'1'''1''''0'" + ptype + "";
                string strEmpt = "flase,false,false,false,false,false,1|让球|2|受让,1|平手|2|平手/半球|3|半球|4|半球/一球|5|一球|6|一球/球半|7|球半|8|球半/二球|9|二球|10|二球/二球半|11|二球半|12|二球半/三球|13|三球|14|三球/三球半|15|三球半|16|三球半/四球|17|四球|18|四球/四球半|19|四球半|20|四球半/五球|21|五球,true,true,20|0.5|21|0.5/1.0|22|1.0|23|1.0/1.5|1|1.5|2|1.5/2.0|3|2.0|4|2/2.5|5|2.5|6|2.5/3.0|7|3.0|8|3/3.5|9|3.5|10|3.5/4.0|11|4.0|12|4/4.5|13|4.5|14|4.5/5.0|15|5.0|16|5/5.5|17|5.5|18|5.5/6.0|19|6.0|24|6.0/6.5|25|6.5|26|6.5/7.0|27|7.0|28|7.0/7.5|29|7.5|30|7.5/8.0|31|8.0|32|8.0/8.5|33|8.5|34|8.5/9.0|35|9.0|36|9.0/9.5|37|9.5|38|9.5/10.0|39|10.0,true,true,true,0|否|1|是,true";
                string strIdea = "/联赛时间格式:" + DT.FormatDate(DateTime.Now.AddHours(5), 0) + "/";
                string strOthe = "确定添加,addGuess.aspx,post,1,red";

                builder.Append(Out.wapform(strText, strName, strType, strValu, strEmpt, strIdea, strOthe));
                builder.Append(Out.Tab("<div>", "<br />"));
                builder.Append("大小盘赔率与标准盘填写-1可隐藏,即不可下注大小盘与标准盘!");
                builder.Append(Out.Tab("</div>", ""));
            }
            else
            {
                builder.Append(Out.Tab("<div class=\"text\">", ""));
                builder.Append("增加:足球赛事 " + Out.waplink(Utils.getUrl("addGuess.aspx?ptype=1"), "切换足球"));
                builder.Append(Out.Tab("</div>", ""));
                string strText = "联赛名称,联赛时间,上盘名称,上盘赔率,下盘名称,下盘赔率,上下盘口,大盘赔率,小盘赔率,大小盘口,";
                string strName = "p_title,p_TPRtime,p_one,p_one_lu,p_two,p_two_lu,p_pk,p_big_lu,p_small_lu,p_dx_pk,ptype";
                string strType = "text,date,text,text,text,text,text,text,text,text,hidden";
                string strValu = "'" + DateTime.Now.AddHours(5) + "'''''''''" + ptype + "";
                string strEmpt = "flase,false,false,false,false,false,false,true,true,true,true";
                string strIdea = "/联赛时间格式:" + DT.FormatDate(DateTime.Now.AddHours(5), 0) + "/";
                string strOthe = "确定添加,addGuess.aspx,post,1,red";

                builder.Append(Out.wapform(strText, strName, strType, strValu, strEmpt, strIdea, strOthe));
                builder.Append(Out.Tab("<div>", "<br />"));
                builder.Append("大小盘赔率填写-1可隐藏大小盘,即不可下注大小盘!");
                builder.Append(Out.Tab("</div>", ""));
            }
        }
        builder.Append(Out.Tab("<div class=\"hr\"></div>", Out.Hr()));
        builder.Append(Out.Tab("<div>", ""));
        builder.Append(Out.waplink(Utils.getUrl("default.aspx"), "返回上一级"));
        builder.Append(Out.Tab("</div>", ""));
        builder.Append(Out.Tab("<div class=\"title\">", "<br />"));
        builder.Append("<a href=\"" + Utils.getUrl("../default.aspx") + "\">返回管理中心</a>");
        builder.Append(Out.Tab("</div>", "<br />"));
    }