Ejemplo n.º 1
0
        /// <summary>
        /// 初始化绑定数据
        /// </summary>
        private void StoreDataBind()
        {
            try
            {
                this.StorePlateType.DataSource = Bll.Common.ChangColName(GetRedisData.GetData("t_sys_code:140001")); // tgsPproperty.GetPalteType();
                this.StorePlateType.DataBind();
                this.StoreStartStation.DataSource = tgsPproperty.GetStartStationInfo();
                this.StoreStartStation.DataBind();

                this.StorePecType.DataSource = GetRedisData.ChangColName(GetRedisData.GetData("Peccancy:WFXW"), true); //tgsPproperty.GetPeccancyType("isuse='1'");
                this.StorePecType.DataBind();
                DataTable deal = Bll.Common.ChangColName(GetRedisData.GetData("t_sys_code:240019"));                   // tgsPproperty.GetProcessType();
                this.StoreDealType.DataSource = deal;
                this.StoreDealType.DataBind();

                DataTable dt = Bll.Common.ChangColName(GetRedisData.GetData("t_sys_code:140006"));// tgsPproperty.GetQueryNum();
                //  this.StoreQueryNum.DataSource = dt;
                // this.StoreQueryNum.DataBind();
                // if (dt.Rows.Count > 0)
                //    CmbQueryNum.SelectedIndex = 0;
            }
            catch (Exception ex)
            {
                ILog.WriteErrorLog(ex);
                logManager.InsertLogError("PeccancyAreaQuery.aspx-StoreDataBind", ex.Message + ";" + ex.StackTrace, "StoreDataBind has an exception");
            }
        }
        /// <summary>
        /// 重置事件
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        protected void ButResetClick(object sender, DirectEventArgs e)
        {
            try
            {
                starttime = DateTime.Now.ToString("yyyy-MM-dd 00:00:00");
                endtime   = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss");
                string timeJs = "clearTime('" + starttime + "','" + endtime + "');";//js方法后面的分号一定要加上
                this.ResourceManager1.RegisterAfterClientInitScript(timeJs);
                this.uiDepartment.Reset();
                this.CmbPecType.Reset();
                this.CmbPlateType.Reset();
                this.CmbLocation.Reset();
                this.CmbDataSource.Reset();
                // CmbDealType.SelectedIndex = 0;
                this.TxtplateId.Reset();
                this.ChkLike.Reset();
                this.CmbDirection.Reset();
                this.CmbDealType.Reset();
                this.WindowEditor1.SetVehicleText("");
                if (Session["location"] != null)
                {
                    Session["location"] = null;
                }
                //违法地点
                DataTable dt2 = GetRedisData.GetData("Station:t_cfg_set_station_type_istmsshow");
                if (dt2 != null)
                {
                    this.StoreLocation.DataSource = ChangColName(dt2);
                    this.StoreLocation.DataBind();
                }
                else
                {
                    this.StoreLocation.DataSource = tgsPproperty.GetStationInfo("b.istmsshow ='1'");
                    this.StoreLocation.DataBind();
                }

                //行驶方向
                DataTable dt6 = GetRedisData.GetData("t_sys_code:240025");
                if (dt6 != null)
                {
                    this.StoreDirection.DataSource = GetRedisData.ChangColName(dt6, true);
                    this.StoreDirection.DataBind();
                }
                else
                {
                }
            }
            catch (Exception ex)
            {
                ILog.WriteErrorLog(ex);
                logManager.InsertLogError("PeccancyCheck.aspx-ButResetClick", ex.Message + ";" + ex.StackTrace, "ButResetClick has an exception");
            }
        }
Ejemplo n.º 3
0
        /// <summary>
        ///开始绑定数据
        /// </summary>
        private void StartDataBind()
        {
            //UserInfo userInfo = System.Web.HttpContext.Current.Session["userinfo"] as UserInfo;
            //DataTable ddbh = new DataTable();
            //ddbh = tgsPproperty.GetUserStationInfo(userInfo.UserCode, "2");

            //if (ddbh == null || ddbh.Rows.Count <= 0)
            //{
            //    ddbh = tgsPproperty.GetStationInfo("b.istmsshow ='1'");
            //}
            //this.StoreLocation.DataSource = ddbh;
            //this.StoreLocation.DataBind();
            DataTable dt1 = GetRedisData.GetData("Station:t_cfg_set_station_type_istmsshow");

            if (dt1 != null)
            {
                this.StoreLocation.DataSource = GetRedisData.ChangColName(dt1, true);
                this.StoreLocation.DataBind();
            }
            else
            {
                this.StoreLocation.DataSource = tgsPproperty.GetStationInfo("b.istmsshow ='1'");
                this.StoreLocation.DataBind();
            }

            //车俩类型
            DataTable dt2 = GetRedisData.GetData("t_sys_code:140001");

            if (dt2 != null)
            {
                this.StorePlateType.DataSource = GetRedisData.ChangColName(dt2, true);
                this.StorePlateType.DataBind();
            }
            else
            {
                this.StorePlateType.DataSource = tgsPproperty.GetPalteType();
                this.StorePlateType.DataBind();
            }
            //违法行为
            DataTable dt3 = GetRedisData.GetData("Peccancy:WFXW");

            if (dt3 != null)
            {
                this.StorePeccancyType.DataSource = GetRedisData.ChangColName(dt3, true);
                this.StorePeccancyType.DataBind();
            }
            DataTable dt4 = settingManager.GetConfigInfo("00", "06");

            if (dt4 != null)
            {
                Session["plateHead"] = dt4.Rows[0]["col3"].ToString();
            }
        }
        private void StartDataBind()
        {
            this.StorePlateType.DataSource = Bll.Common.ChangColName(GetRedisData.GetData("t_sys_code:140001")); // tgsPproperty.GetPalteType();
            this.StorePlateType.DataBind();

            this.StoreLocation.DataSource = tgsPproperty.GetStationInfo("a.station_type_id in (01,02,03,06,07,08)");
            this.StoreLocation.DataBind();

            this.StorePeccancyType.DataSource = GetRedisData.ChangColName(GetRedisData.GetData("Peccancy:WFXW"), true);//tgsPproperty.GetPeccancyType("isuse='1'");
            this.StorePeccancyType.DataBind();

            Session["plateHead"] = settingManager.GetConfigInfo("00", "06").Rows[0]["col3"].ToString();
        }
        /// <summary>
        /// 初始化页面
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        protected void Page_Load(object sender, EventArgs e)
        {
            string username = Request.QueryString["username"]; if (!userLogin.CheckLogin(username))

            {
                string js = "alert('您没有登录或操作超时,请重新登录!');window.top.location.href='" + StaticInfo.LoginPage + "'"; System.Web.HttpContext.Current.Response.Write("<script type='text/javascript'>" + js + "</script>"); return;
            }

            if (!X.IsAjaxRequest)
            {
                this.StorePlateType.DataSource = GetRedisData.GetData("t_sys_code:140001"); //tgsPproperty.GetPalteType();
                this.StorePlateType.DataBind();

                this.StoreLocation.DataSource = GetRedisData.GetData("Station:t_cfg_set_station_type_istmsshow");
                this.StoreLocation.DataBind();


                this.StorePecType.DataSource = GetRedisData.ChangColName(GetRedisData.GetData("Peccancy:WFXW"), true);
                this.StorePecType.DataBind();

                DataTable dtCaptureUser = GetRedisData.ChangColName(GetRedisData.GetData("Peccancy:CaptureUser"), true);
                this.StoreCaptureUser.DataSource = dtCaptureUser;//userManager.GetSerUserInfo(SystemID, " 1=1 ", "");
                this.StoreCaptureUser.DataBind();


                DataTable deal = GetRedisData.GetData("t_sys_code:240019");
                this.StoreDealType.DataSource = deal;
                this.StoreDealType.DataBind();

                DataTable dt = tgsPproperty.GetQueryNum();
                this.StoreQueryNum.DataSource = dt;
                this.StoreQueryNum.DataBind();
                this.DateStartTime.SelectedDate = DateTime.Now;
                this.DateEndTime.SelectedDate   = DateTime.Now;
                this.TimeStart.Text             = DateTime.Now.ToString("00:00:01");
                this.TimeEnd.Text = DateTime.Now.ToString("23:59:59");

                //ButCsv.Disabled = true;
                ButExcel.Disabled = true;
                // ButXml.Disabled = true;
                // ButPrint.Disabled = true;

                if (dt.Rows.Count > 0)
                {
                    CmbQueryNum.SelectedIndex = 0;
                }
            }
        }
Ejemplo n.º 6
0
        /// <summary>
        /// 页面加载时候执行
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        protected void Page_Load(object sender, EventArgs e)
        {
            //判断用户是否登录
            string username = Request.QueryString["username"];

            if (!userLogin.CheckLogin(username))
            {
                string js = "alert('您没有登录或操作超时,请重新登录!');window.top.location.href='" + StaticInfo.LoginPage + "'";
                System.Web.HttpContext.Current.Response.Write("<script type='text/javascript'>" + js + "</script>");
                return;
            }
            // 判断用户是否登录结束
            if (!X.IsAjaxRequest)
            {
                this.StorePlateType.DataSource = Bll.Common.ChangColName(GetRedisData.GetData("t_sys_code:140001")); // tgsPproperty.GetPalteType();
                this.StorePlateType.DataBind();
                this.StoreStartStation.DataSource = tgsPproperty.GetStartStationInfo();
                this.StoreStartStation.DataBind();
                DataTable deal = Bll.Common.ChangColName(GetRedisData.GetData("t_sys_code:240019")); // tgsPproperty.GetProcessType();

                this.StoreDealType.DataSource = deal;
                this.StoreDealType.DataBind();
                this.StorePecType.DataSource = GetRedisData.ChangColName(GetRedisData.GetData("Peccancy:WFXW"), true); //tgsPproperty.GetPeccancyType("isuse='1'");
                this.StorePecType.DataBind();
                DataTable dt = Bll.Common.ChangColName(GetRedisData.GetData("t_sys_code:140006"));                     // tgsPproperty.GetQueryNum();
                //    this.StoreQueryNum.DataSource = dt;
                //   this.StoreQueryNum.DataBind();
                starttime = start.InnerText = DateTime.Now.ToString("yyyy-MM-dd 00:00:00");
                endtime   = end.InnerText = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss");
                TbutQueryClick(null, null);

                UserInfo userinfo = Session["Userinfo"] as UserInfo;
                //// if (dt.Rows.Count > 0)
                ////      CmbQueryNum.SelectedIndex = 0;
                ////   this.Panel2.Title = "查询结果:共计查询出符合条件的记录0条,现在显示0条";
                logManager.InsertLogRunning(userinfo.UserName, "访问:" + Request.QueryString["funcname"], userinfo.NowIp, "0");
            }
        }
        /// <summary>
        ///
        /// </summary>
        private void GetDeviceData()
        {
            try
            {
                DataTable dt = tgsDataInfo.GetDeviceInfo("1=1 and substr(isshow,2,1)='1'");
                if (dt != null)
                {
                    StoreDevice.DataSource = dt;
                    StoreDevice.DataBind();
                }
                DataTable dt1 = GetRedisData.ChangColName(GetRedisData.GetData("t_sys_code:240014"), true);
                StoreCompany.DataSource = dt1; //tgsPproperty.GetCompanyDict();
                StoreCompany.DataBind();

                DataTable tgs = GetRedisData.ChangColName(ToDataTable(GetRedisData.GetData("Station:t_cfg_set_station").Select("", "station_name asc")), true);//tgsPproperty.GetTmsStationInfo();
                // tgs.Columns.RemoveAt(0);
                StoreStaion.DataSource = Bll.Common.ChangColName(GetRedisData.GetData("Station:t_cfg_set_station"));
                StoreStaion.DataBind();
            }
            catch (Exception ex)
            {
                ILog.WriteErrorLog(ex);
            }
        }
Ejemplo n.º 8
0
        /// <summary>
        /// 初始化绑定数据
        /// </summary>
        private void StoreDataBind()
        {
            try
            {
                UserInfo userInfo = new UserInfo();
                //车俩类型
                DataTable dt1 = GetRedisData.GetData("t_sys_code:140001");
                if (dt1 != null)
                {
                    this.StorePlateType.DataSource = GetRedisData.ChangColName(dt1, true);
                    this.StorePlateType.DataBind();
                }
                else
                {
                    this.StorePlateType.DataSource = tgsPproperty.GetPalteType();
                    this.StorePlateType.DataBind();
                }

                //违法行为
                DataTable dt3 = GetRedisData.GetData("Peccancy:WFXW");
                if (dt3 != null)
                {
                    this.StorePecType.DataSource = GetRedisData.ChangColName(dt3, true);
                    this.StorePecType.DataBind();
                }
                else
                {
                    this.StorePecType.DataSource = tgsPproperty.GetPeccancyType("isuse='1'");
                    this.StorePecType.DataBind();
                }

                //数据来源
                DataTable dt4 = GetRedisData.GetData("t_sys_code:240022");
                if (dt4 != null)
                {
                    this.StoreDataSource.DataSource = GetRedisData.ChangColName(dt4, true);
                    this.StoreDataSource.DataBind();
                }
                else
                {
                    this.StoreDataSource.DataSource = tgsPproperty.GetDeviceTypeDict("240022");
                    this.StoreDataSource.DataBind();
                }

                //违法地点
                DataTable dt2 = GetRedisData.GetData("Station:t_cfg_set_station_type_istmsshow");
                if (dt2 != null)
                {
                    this.StoreLocation.DataSource = ChangColName(dt2);
                    this.StoreLocation.DataBind();
                }
                else
                {
                    this.StoreLocation.DataSource = tgsPproperty.GetStationInfo("b.istmsshow ='1'");
                    this.StoreLocation.DataBind();
                }

                //处理状态
                DataTable dt5 = GetRedisData.GetData("t_sys_code:240019");
                if (dt5 != null)
                {
                    dt5.Rows.RemoveAt(1);
                    dt5.Rows.RemoveAt(1);
                    dt5.Rows.RemoveAt(1);
                    dt5.Rows.RemoveAt(1);
                    this.StoreDealType.DataSource = GetRedisData.ChangColName(dt5, true);
                    this.StoreDealType.DataBind();
                }
                else
                {
                    DataTable dt8 = tgsPproperty.GetProcessType();
                    dt8.Rows.RemoveAt(1);
                    dt8.Rows.RemoveAt(1);
                    dt8.Rows.RemoveAt(1);
                    dt8.Rows.RemoveAt(1);
                    this.StoreDealType.DataSource = dt8;
                    this.StoreDealType.DataBind();
                }
                //DataTable deal = GetRedisData.GetData("t_sys_code:240019");
                //deal.Rows.RemoveAt(1);
                //deal.Rows.RemoveAt(1);
                //deal.Rows.RemoveAt(1);
                //deal.Rows.RemoveAt(1);
                //this.StoreDealType.DataSource = deal;
                //this.StoreDealType.DataBind();

                //DataTable dt = tgsPproperty.GetQueryNum();
                //this.StoreQueryNum.DataSource = dt;
                //this.StoreQueryNum.DataBind();

                ButDelete.Disabled = true;

                //if (dt.Rows.Count > 0)
                //    CmbQueryNum.SelectedIndex = 0;
            }
            catch (Exception ex)
            {
                ILog.WriteErrorLog(ex);
                logManager.InsertLogError("PeccancyDelete.aspx-StoreDataBind", ex.Message + ";" + ex.StackTrace, "StoreDataBind has an exception");
            }
        }
        /// <summary>
        /// 初始化绑定数据
        /// </summary>
        private void StoreDataBind()
        {
            try
            {
                //UserInfo userInfo = System.Web.HttpContext.Current.Session["userinfo"] as UserInfo;

                //DataTable ddbh = new DataTable();
                //ddbh = tgsPproperty.GetUserStationInfo(userInfo.UserCode, "2");

                //if (ddbh != null || ddbh.Rows.Count > 0)
                //{
                //    Session["location"] = ddbh;
                //}
                //else
                //{
                //    ddbh = tgsPproperty.GetStationInfo("b.istmsshow ='1'");
                //}
                //this.StoreLocation.DataSource = ddbh;
                //this.StoreLocation.DataBind();

                //车俩类型
                DataTable dt1 = GetRedisData.GetData("t_sys_code:140001");
                if (dt1 != null)
                {
                    this.StorePlateType.DataSource = GetRedisData.ChangColName(dt1, true);
                    this.StorePlateType.DataBind();
                }
                else
                {
                    this.StorePlateType.DataSource = tgsPproperty.GetPalteType();
                    this.StorePlateType.DataBind();
                }

                //违法地点
                DataTable dt2 = GetRedisData.GetData("Station:t_cfg_set_station_type_istmsshow");
                if (dt2 != null)
                {
                    this.StoreLocation.DataSource = ChangColName(dt2);
                    this.StoreLocation.DataBind();
                }
                else
                {
                    this.StoreLocation.DataSource = tgsPproperty.GetStationInfo("b.istmsshow ='1'");
                    this.StoreLocation.DataBind();
                }

                //违法行为
                DataTable dt3 = GetRedisData.GetData("Peccancy:WFXW");
                if (dt3 != null)
                {
                    this.StorePecType.DataSource = GetRedisData.ChangColName(dt3, true);
                    this.StorePecType.DataBind();
                }
                else
                {
                    this.StorePecType.DataSource = tgsPproperty.GetPeccancyType("isuse='1'");
                    this.StorePecType.DataBind();
                }

                //数据来源
                DataTable dt4 = GetRedisData.GetData("t_sys_code:240022");
                if (dt4 != null)
                {
                    this.StoreDataSource.DataSource = GetRedisData.ChangColName(dt4, true);
                    this.StoreDataSource.DataBind();
                }
                else
                {
                    this.StoreDataSource.DataSource = tgsPproperty.GetDeviceTypeDict("240022");
                    this.StoreDataSource.DataBind();
                }

                //处理状态
                DataTable dt5 = GetRedisData.GetData("t_sys_code:240019");
                if (dt5 != null)
                {
                    dt5.Rows.RemoveAt(0);
                    dt5.Rows.RemoveAt(1);
                    this.StoreDealType.DataSource = GetRedisData.ChangColName(dt5, true);
                    this.StoreDealType.DataBind();
                }
                else
                {
                    DataTable dt8 = tgsPproperty.GetProcessType();
                    dt8.Rows.RemoveAt(0);
                    dt8.Rows.RemoveAt(1);
                    this.StoreDealType.DataSource = dt8;
                    this.StoreDealType.DataBind();
                }
                //DataTable deal = GetRedisData.GetData("t_sys_code:240019");
                //deal.Rows.RemoveAt(0);
                //deal.Rows.RemoveAt(1);
                //this.StoreDealType.DataSource = deal;
                //this.StoreDealType.DataBind();

                //行驶方向
                DataTable dt6 = dtFangxiang = GetRedisData.GetData("t_sys_code:240025");
                if (dt6 != null)
                {
                    this.StoreDirection.DataSource = GetRedisData.ChangColName(dt6, true);
                    this.StoreDirection.DataBind();
                }
                else
                {
                }
                DataTable dt7 = GetRedisData.GetData("t_sys_code:140006");

                if (dt7 != null)
                {
                    this.StoreQueryNum.DataSource = Bll.Common.ChangColName(dt7);
                    this.StoreQueryNum.DataBind();
                }
                else
                {
                    this.StoreQueryNum.DataSource = tgsPproperty.GetQueryNum();
                    this.StoreQueryNum.DataBind();
                }
                //DataTable dt = tgsPproperty.GetQueryNum();
                //this.StoreQueryNum.DataSource = dt;
                //this.StoreQueryNum.DataBind();
                CmbDealType.SelectedIndex = 0;

                if (dt7.Rows.Count > 0)
                {
                    CmbQueryNum.SelectedIndex = 0;
                }
            }
            catch (Exception ex)
            {
                ILog.WriteErrorLog(ex);
                logManager.InsertLogError("PeccancyRepeatCheck.aspx-StoreDataBind", ex.Message + ";" + ex.StackTrace, "StoreDataBind has an exception");
            }
        }