Пример #1
0

        
Пример #2
0
        void Bind()
        {
            hidKeLei.Value = userinfo.KeLei.ToString();

            Entity.GaoKaoCard info = DAL.GaoKaoCard.GaoKaoCardEntityGetByStudentId(userinfo.StudentId);
            if (info != null)
            {
                string strTiXing1 = "";
                Entity.StudentGaoKaoHistory infoChengJi = DAL.StudentGaoKaoHistory.StudentGaoKaoHistoryEntityGet(userinfo.StudentId);
                if (infoChengJi != null)
                {
                    strTiXing1 = "<div class=\"tx\">"
                                 + "提醒:" + Basic.Utils.StrToDateStr(infoChengJi.AddTime.ToString()) + "你设定分数如下"
                                 + " </div>"
                                 + " <div class=\"gkcjul\">"
                                 + " <ul>"
                                 + " <li>考生类别:" + DAL.Common.GetKeLeiMingCheng(userinfo.KeLei) + "</li>"
                                 + " <li>考生分数:" + infoChengJi.FenShu + "</li>";
                    if (userinfo.ProvinceId == 11)//浙江
                    {
                        strTiXing1 += " <li>一批次分数线预估:" + infoChengJi.PcFirst + "</li>"
                                      + " <li>二批次分数线预估:" + infoChengJi.PcSecond + "</li>"
                                      + " <li>三批次分数线预估:" + infoChengJi.PcThird + "</li>";
                    }
                    else
                    {
                        strTiXing1 += " <li>一本分数线预估:" + infoChengJi.PcFirst + "</li>"
                                      + " <li>二本分数线预估:" + infoChengJi.PcSecond + "</li>"
                                      + " <li>三本分数线预估:" + infoChengJi.PcThird + "</li>"
                                      + " <li>专科分数线预估:" + infoChengJi.PcZhuanKeFirst + "</li>";
                    }
                    strTiXing1 += " </ul></div>";
                }
                else
                {
                    strTiXing1 = "<div class=\"tx\">"
                                 + "提醒:你还没有设定分数"
                                 + " </div>";
                }

                ltlTiXing1.Text = strTiXing1;
            }
        }
Пример #3
0

        
Пример #4
0
        void page_Loading(object sender, EventArgs e)
        {
            #region 用户登录信息
            userinfo.StudentId    = Basic.Utils.StrToInt(Basic.CookieHelper.GetCookie("Student", "StudentId"), 0);
            userinfo.StudentLevel = Basic.Utils.StrToInt(Basic.CookieHelper.GetCookie("Student", "StudentLevel"), 0); //用户等级id:1普通注册用户;2高考查看卡; 3普通测试卡; 4普通卡;  5VIP测试卡;  6VIP卡;9会员卡
            userinfo.ProvinceId   = Basic.Utils.StrToInt(Basic.CookieHelper.GetCookie("Student", "ProvinceId"), 0);   //省份id
            userinfo.KeLei        = Basic.Utils.StrToInt(Basic.CookieHelper.GetCookie("Student", "KeLei"), 0);        //科类
            userinfo.GKYear       = Basic.Utils.StrToInt(Basic.CookieHelper.GetCookie("Student", "GKYear"), 0);       //参加高考的年份
            userinfo.Status       = Basic.Utils.StrToInt(Basic.CookieHelper.GetCookie("Student", "Status"), 0);       //登陆之后的状态值
            userinfo.StudentName  = Basic.CookieHelper.GetCookie("Student", "StudentName");                           //学生姓名
            userinfo.Bank         = Basic.CookieHelper.GetCookie("Student", "Bank");                                  //当前登陆的账号
            userinfo.LevelName    = Basic.CookieHelper.GetCookie("Student", "LevelName");                             //用户等级名称: 1普通注册用户;2高考查看卡; 3普通测试卡; 4普通卡;  5VIP测试卡;  6VIP卡;9会员卡
            userinfo.ProvinceName = Basic.CookieHelper.GetCookie("Student", "ProvinceName");                          //省份名称

            //userinfo.StudentId = Basic.Utils.StrToInt(Basic.CookieHelper.GetCookie("Student", "StudentId"), 5);
            //userinfo.StudentLevel = Basic.Utils.StrToInt(Basic.CookieHelper.GetCookie("Student", "StudentLevel"), 4);//用户等级id:1普通注册用户;2高考查看卡; 3普通测试卡; 4普通卡;  5VIP测试卡;  6VIP卡;9会员卡
            //userinfo.ProvinceId = Basic.Utils.StrToInt(Basic.CookieHelper.GetCookie("Student", "ProvinceId"), 3);//省份id
            //userinfo.KeLei = Basic.Utils.StrToInt(Basic.CookieHelper.GetCookie("Student", "KeLei"), 5);//科类
            //userinfo.GKYear = Basic.Utils.StrToInt(Basic.CookieHelper.GetCookie("Student", "GKYear"), 2014);//参加高考的年份
            //userinfo.Status = Basic.Utils.StrToInt(Basic.CookieHelper.GetCookie("Student", "Status"), 1);//登陆之后的状态值

            userinfo.ProvinceName   = DAL.Common.GetProvinceName(userinfo.ProvinceId);
            userinfo.KeLeiMingCheng = DAL.Common.GetKeLeiMingCheng(userinfo.KeLei);
            #endregion


            #region 新疆乌鲁木齐咨询中心的卡不能在喀什地区使用

            if (userinfo.ProvinceId == 72)//新疆乌鲁木齐咨询中心
            {
                Entity.AreaJson infoAreaJson = DAL.AnalysisArea.GetAreaModel();
                if (infoAreaJson != null)
                {
                    if (infoAreaJson.code == "0")
                    {
                        if (infoAreaJson.data.city_id == "653100")
                        {
                            //新疆乌鲁木齐咨询中心的卡不能在喀什地区使用
                            Basic.MsgHelper.AlertUrlMsg("该卡不能在喀什地区使用", "/logout.aspx");
                        }
                    }
                }
            }
            #endregion


            Status(); //根据状态  判定去向

            //根据登陆用户的省份,去取一下省份的志愿配置信息
            int ProvinceId = userinfo.ProvinceId;

            provinceConfig = DAL.ProvinceConfig.ProvinceConfigEntityGet(userinfo.ProvinceId);

            //测试数据
            //history.LeiJiRenShu = 1000;
            //history.RenShu = 99;
            //history.WeiCi = 900;
            //history.FenShu = 600;

            if (userinfo.ProvinceId == 11)//浙江
            {
                history_zhejiang = DAL.StudentGaoKaoHistory_ZheJiang.StudentGaoKaoHistory_ZheJiangEntityGetByStudentId(userinfo.StudentId);
                if (history_zhejiang == null)
                {
                    Basic.MsgHelper.AlertUrlMsg("请首先设置自己的考试成绩!", "/Persional/ChengJiEdit2.aspx"); //跳转到成绩输入页面
                }
                if (history_zhejiang.ZongFen1 == 0 && history_zhejiang.ZongFen2 == 0 && history_zhejiang.ZongFen3 == 0)
                {
                    Basic.MsgHelper.AlertUrlMsg("您的成绩设置有问题,请重新设置后使用", "/Persional/ChengJiEdit2.aspx");
                }

                //判断第几批次,批次线差
                fenshuxian = DAL.FenShuXian.FenShuXianEntityGet(ProvinceId, " AND KeLei = " + userinfo.KeLei);
                // studentChengJi = DAL.CommonTuiJian.GetZheJiangUserPiCi(fenshuxian, history_zhejiang.ZongFen1, provinceConfig.LatestProvinceWeiCiYear, ProvinceId, userinfo.KeLei);

                //if (studentChengJi.PiCi == 0)
                //    Basic.MsgHelper.AlertUrlMsg("您的成绩设置有问题,请重新设置后使用", "/Persional/ChengJiEdit2.aspx");

                //StudentChengJiPiCi = studentChengJi.PiCi;
                ////studentChengJi.PiCiMingCheng = DAL.Common.GetPiCiName(StudentChengJiPiCi, userinfo.ProvinceId);
                //if (StudentChengJiPiCi <= 3)
                //    StudentChengJiPiCiMingCheng = "本科" + StudentChengJiPiCiMingCheng;
            }
            else
            {
                history = DAL.StudentGaoKaoHistory.StudentGaoKaoHistoryEntityGet(userinfo.StudentId);

                //非浙江
                if (history == null)
                {
                    Basic.MsgHelper.AlertUrlMsg("请首先设置自己的考试成绩!", "/Persional/ChengJiEdit2.aspx"); //跳转到成绩输入页面
                }
                if (history.FenShu == 0)
                {
                    Basic.MsgHelper.AlertUrlMsg("您的成绩设置有问题,请重新设置后使用", "/Persional/ChengJiEdit2.aspx");
                }


                if (history.IsSetUpWeiCi == 0)
                {
                    Entity.ProvinceWeiCi infoProvinceWeiCi = null;
                    if (userinfo.ProvinceId == 10)//江苏
                    {
                        //if (history.FenShu < 180)
                        //{
                        //    history.FenShu = 180;
                        //}
                        infoProvinceWeiCi = DAL.ProvinceWeiCi.ProvinceWeiCiEntityGetByFenShu(history.FenShu, provinceConfig.LatestProvinceWeiCiYear, userinfo.ProvinceId, userinfo.KeLei);
                    }
                    else
                    {
                        infoProvinceWeiCi = DAL.ProvinceWeiCi.ProvinceWeiCiEntityGetByFenShu(history.FenShu, provinceConfig.LatestProvinceWeiCiYear, userinfo.ProvinceId, userinfo.KeLei);
                    }
                    if (infoProvinceWeiCi != null)
                    {
                        history.WeiCi = infoProvinceWeiCi.WeiCi;
                    }
                    else
                    {
                        Basic.MsgHelper.AlertUrlMsg("您设置的成绩有问题,请重新设置后使用", "/Persional/ChengJiEdit2.aspx");
                    }
                }

                //判断第几批次,批次线差
                fenshuxian = DAL.FenShuXian.FenShuXianEntityGet(ProvinceId, " AND KeLei = " + userinfo.KeLei);
                if (history.IsSetUpFenShuXian == 1)
                {
                    fenshuxian.PcFirst  = (history.PcFirst > 0 ? history.PcFirst : fenshuxian.PcFirst);
                    fenshuxian.PcSecond = (history.PcSecond > 0 ? history.PcSecond : fenshuxian.PcSecond);
                    fenshuxian.PcThird  = (history.PcThird > 0 ? history.PcThird : fenshuxian.PcThird);
                    fenshuxian.ZkFirst  = (history.PcZhuanKeFirst > 0 ? history.PcZhuanKeFirst : fenshuxian.ZkFirst);
                    fenshuxian.ZkSecond = (history.PcZhuanKeSecond > 0 ? history.PcZhuanKeSecond : fenshuxian.ZkSecond);
                }


                studentChengJi = DAL.CommonTuiJian.GetUserPiCi(fenshuxian, history.FenShu, provinceConfig.LatestProvinceWeiCiYear, ProvinceId, userinfo.KeLei);
                if (studentChengJi.PiCi == 0)
                {
                    Basic.MsgHelper.AlertUrlMsg("您的成绩设置有问题,请重新设置后使用", "/Persional/ChengJiEdit2.aspx");
                }

                StudentChengJiPiCi = studentChengJi.PiCi;
                //<%=DAL.Common.GetPiCiMingCheng(studentChengJi.PiCi) %>
                if (history.IsSetUpFenShuXian == 1)
                {
                    switch (StudentChengJiPiCi)
                    {
                    case 1:
                        if (history.PcFirst > 0)
                        {
                            studentChengJi.PiCiMingCheng = "预估" + DAL.Common.GetPiCiName(StudentChengJiPiCi, userinfo.ProvinceId);
                        }
                        break;

                    case 2:
                        if (history.PcSecond > 0)
                        {
                            studentChengJi.PiCiMingCheng = "预估" + DAL.Common.GetPiCiName(StudentChengJiPiCi, userinfo.ProvinceId);
                        }
                        break;

                    case 3:
                        if (history.PcThird > 0)
                        {
                            studentChengJi.PiCiMingCheng = "预估" + DAL.Common.GetPiCiName(StudentChengJiPiCi, userinfo.ProvinceId);
                        }
                        break;

                    case 4:
                        if (history.PcZhuanKeFirst > 0)
                        {
                            studentChengJi.PiCiMingCheng = "预估" + DAL.Common.GetPiCiName(StudentChengJiPiCi, userinfo.ProvinceId);
                        }
                        break;

                    case 5:
                        if (history.PcZhuanKeSecond > 0)
                        {
                            studentChengJi.PiCiMingCheng = "预估" + DAL.Common.GetPiCiName(StudentChengJiPiCi, userinfo.ProvinceId);
                        }
                        break;

                    default:
                        studentChengJi.PiCiMingCheng = DAL.Common.GetPiCiName(StudentChengJiPiCi, userinfo.ProvinceId);
                        break;
                    }
                }
                else
                {
                    studentChengJi.PiCiMingCheng = DAL.Common.GetPiCiName(StudentChengJiPiCi, userinfo.ProvinceId);
                }
                if (StudentChengJiPiCi <= 3)
                {
                    StudentChengJiPiCiMingCheng = "本科" + StudentChengJiPiCiMingCheng;
                }
            }
        }
Пример #5
0
        protected void Button1_Click(object sender, EventArgs e)
        {
            int intFenShu = Basic.RequestHelper.GetFormInt(txtPingShiFenShu.ClientID, 0);
            int intWeiCi  = Basic.RequestHelper.GetFormInt(txtWeiCi.ClientID, 0);

            if (intFenShu < 0 || intFenShu > 750)
            {
                Basic.MsgHelper.AlertBackMsg("请输入正确的分数。");
            }

            int KeLei = Basic.RequestHelper.GetFormInt("ddlKeLei", -1);

            if (KeLei == -1 && userinfo.KeLei == -1)
            {
                Basic.MsgHelper.AlertBackMsg("设置分数时,必须设置科类。");
            }

            if (userinfo.KeLei == -1)
            {
                DAL.Join_Student.Join_StudentWenLi(userinfo.StudentId, KeLei);

                Basic.CookieHelper.WriteCookie("Student", "KeLei", KeLei.ToString(), 120);
            }


            int FirstLevel  = Basic.RequestHelper.GetFormInt(ddlWuLi.ClientID, 0);
            int SecondLevel = Basic.RequestHelper.GetFormInt(ddlXuanCe.ClientID, 0);

            if (userinfo.ProvinceId == 10)
            {
                if (FirstLevel == 0 || SecondLevel == 0)
                {
                    Basic.MsgHelper.AlertBackMsg("设置分数时,必须选择科目评测等级。");
                }
            }


            Entity.StudentGaoKaoHistory info = new Entity.StudentGaoKaoHistory();
            info.FirstLevel  = FirstLevel;
            info.SecondLevel = SecondLevel;


            info.StudentId = userinfo.StudentId;
            info.FenShu    = intFenShu;
            info.WeiCi     = intWeiCi;
            if (intWeiCi == 0)
            {
                info.IsSetUpWeiCi = 0;
            }
            else
            {
                info.IsSetUpWeiCi = 1;
            }



            if (cb_SetUpFenShuXian.Checked)
            {
                info.IsSetUpFenShuXian = 1;

                int intPcFirst         = Basic.RequestHelper.GetFormInt(txtPcFirst.ClientID, 0);
                int intPcSecond        = Basic.RequestHelper.GetFormInt(txtPcSecond.ClientID, 0);
                int intPcThird         = Basic.RequestHelper.GetFormInt(txtPcThird.ClientID, 0);
                int intPcZhuanKeFirst  = Basic.RequestHelper.GetFormInt(txtPcZhuanKeFirst.ClientID, 0);
                int intPcZhuanKeSecond = Basic.RequestHelper.GetFormInt(txtPcZhuanKeSecond.ClientID, 0);

                info.PcFirst         = intPcFirst;
                info.PcSecond        = intPcSecond;
                info.PcThird         = intPcThird;
                info.PcZhuanKeFirst  = intPcZhuanKeFirst;
                info.PcZhuanKeSecond = intPcZhuanKeSecond;
                info.PcZhuanKeSecond = intPcZhuanKeSecond;
            }
            else
            {
                info.IsSetUpFenShuXian = 0;

                info.PcFirst         = 0;
                info.PcSecond        = 0;
                info.PcThird         = 0;
                info.PcZhuanKeFirst  = 0;
                info.PcZhuanKeSecond = 0;
                info.PcZhuanKeSecond = 0;
            }

            info.IsGaoKao = 0;
            info.IsLatest = 1;

            //开始进行保存了
            DAL.StudentGaoKaoHistory.StudentGaoKaoHistoryAdd(info);
            Basic.MsgHelper.AlertUrlMsg("您已经成功设置平时考试成绩,请使用相关功能。", "/tuijian/default.aspx");
        }
Пример #6
0
        public void ProcessRequest(HttpContext context)
        {
            context.Response.ContentType = "text/plain";

            //基础html
            string strHtml = "";


            StudentProvinceId = Basic.RequestHelper.GetFormInt("StudentProvinceId", 3);
            int StudentId    = Basic.RequestHelper.GetFormInt("StudentId", 0);
            int StudentKeLei = Basic.RequestHelper.GetFormInt("StudentKeLei", 5);

            StudentPiCi = Basic.RequestHelper.GetFormInt("StudentPiCi", 1);
            int StudentPcLeiBie = Basic.RequestHelper.GetFormInt("StudentPcLeiBie", 0);

            //获取传递过来的参数  并 拼接筛选条件
            string strWhere = GetFormStringANDCondition();

            Entity.ProvinceConfig       config  = DAL.ProvinceConfig.ProvinceConfigEntityGet(StudentProvinceId);
            Entity.StudentGaoKaoHistory history = DAL.StudentGaoKaoHistory.StudentGaoKaoHistoryEntityGet(StudentId);
            if (history.IsSetUpWeiCi == 0)
            {
                history.WeiCi = DAL.ProvinceWeiCi.ProvinceWeiCiEntityGetByFenShu(history.FenShu, config.LatestProvinceWeiCiYear, StudentProvinceId, StudentKeLei).WeiCi;
            }
            Entity.FenShuXian fenshuxian = DAL.FenShuXian.FenShuXianEntityGet(StudentProvinceId, " AND KeLei = " + StudentKeLei + "  AND DataYear = " + config.LatestProvinceWeiCiYear);

            if (history.IsSetUpFenShuXian == 1)
            {
                fenshuxian.PcFirst  = (history.PcFirst > 0 ? history.PcFirst : fenshuxian.PcFirst);
                fenshuxian.PcSecond = (history.PcSecond > 0 ? history.PcSecond : fenshuxian.PcSecond);
                fenshuxian.PcThird  = (history.PcThird > 0 ? history.PcThird : fenshuxian.PcThird);
                fenshuxian.ZkFirst  = (history.PcZhuanKeFirst > 0 ? history.PcZhuanKeFirst : fenshuxian.ZkFirst);
                fenshuxian.ZkSecond = (history.PcZhuanKeSecond > 0 ? history.PcZhuanKeSecond : fenshuxian.ZkSecond);
            }

            int FirstPiCiWeiCi = DAL.ProvinceWeiCi.ProvinceWeiCiEntityGetByFenShu(fenshuxian.PcFirst, config.LatestProvinceWeiCiYear, StudentProvinceId, StudentKeLei).WeiCi;

            Entity.StudentChengJi studentChengJi = DAL.CommonTuiJian.GetUserPiCi(fenshuxian, history.FenShu, config.LatestProvinceWeiCiYear, StudentProvinceId, StudentKeLei);

            int XianCha = 0;

            if (StudentProvinceId == 11 && StudentPiCi == 0)//浙江提前批的线差和一批次的线差一样
            {
                XianCha = DAL.CommonTuiJian.GetUserPiCiXianCha(fenshuxian, history.FenShu, 1);
            }
            else
            {
                XianCha = DAL.CommonTuiJian.GetUserPiCiXianCha(fenshuxian, history.FenShu, StudentPiCi);
            }

            int       StudentFirstLevel  = history.FirstLevel;
            int       StudentSecondLevel = history.SecondLevel;
            DataTable dt = DAL.CommonTuiJian.FenShengYuanXiaoLuQuList(strWhere, StudentProvinceId, StudentId, StudentKeLei, StudentPiCi, StudentPcLeiBie, XianCha, StudentFirstLevel, StudentSecondLevel);

            //給DataTable
            if (dt != null)
            {
                dt.Columns.Add("BaoKaoTuiJian", typeof(int));
                foreach (DataRow dr in dt.Rows)
                {
                    dr["BaoKaoTuiJian"] = DAL.CommonTuiJian.ShowSuggest(StudentProvinceId, StudentPiCi, FirstPiCiWeiCi, history.WeiCi, Basic.Utils.StrToInt(dr["glZuiXiaoWeiCi"].ToString(), 0), Basic.Utils.StrToInt(dr["glZuiDaWeiCi"].ToString(), 0), Basic.Utils.StrToInt(dr["glPingJunWeiCi"].ToString(), 0), XianCha, Basic.Utils.StrToInt(dr["PiCiXian"].ToString(), 0), Basic.Utils.StrToInt(dr["glZuiGaoFen"].ToString(), 0), Basic.Utils.StrToInt(dr["glZuiDiFen"].ToString(), 0), Basic.Utils.StrToInt(dr["glPingJunFen"].ToString(), 0));
                }

                DataView dv = dt.DefaultView;
                dv.Sort = "BaoKaoTuiJian ASC";

                DataTable dt2 = dv.ToTable();
                strHtml += GetBaseHtml();
                strHtml += GetSchoolHtml(dt2);//院校相关html
                context.Response.Write(strHtml);

                //ShowSuggestImg(int.Parse(Eval("glZuiXiaoWeiCi").ToString()), int.Parse(Eval("glZuiDaWeiCi").ToString()), int.Parse(Eval("glPingJunWeiCi").ToString()), int.Parse(Eval("PiCiXian").ToString()),  int.Parse(Eval("glZuiGaoFen").ToString()), int.Parse(Eval("glZuiDiFen").ToString()),int.Parse(Eval("glPingJunFen").ToString()))%>
            }
        }