Exemple #1
0
        public override void Ashx_Load()
        {
            string actionType = "";
            string type       = "";
            string text       = "";

            CheckRequery.checkNotNull("actionType", "类型不能为空!", out actionType);
            string strSql = "";

            switch (actionType)
            {
            case "POI":
                CheckRequery.check("text", out text);
                strSql = string.Format("SELECT 经度,纬度,geom,st_asgeojson(geom) geometry from leakage.poi where 名称='{0}'", text);
                DataSet ContentList = APP.PGSQL_Helper.Query(strSql);
                Context.Response.Write(EasyUI_Pagination.ExportSuccess(ContentList.Tables[0], ContentList.Tables[0].Rows.Count));
                break;

            case "Road":
                CheckRequery.check("text", out text);
                strSql      = string.Format("SELECT 道路名称,geom,st_asgeojson(geom) geometry from leakage.dlzxx where 道路名称='{0}'", text);
                ContentList = APP.PGSQL_Helper.Query(strSql);
                Context.Response.Write(EasyUI_Pagination.ExportSuccess(ContentList.Tables[0], ContentList.Tables[0].Rows.Count));
                break;
            }
        }
Exemple #2
0
        protected void getHiddenById(string hdId)
        {
            string  strSql      = string.Format(@"  select p.cAdminName,d.lhd_xy,d.lhd_uptime,d.lhd_faxiantime,d.lhd_address,d.lhd_miaoshu,d.lhd_hiddenimage from Line_HiddenDanger d 
                                           left join P_Admin p on d.lhd_upname=p.iAdminID where d.lhd_id={0}", hdId);
            DataSet ContentList = APP.SQLServer_Helper.Query(strSql);

            Context.Response.Write(EasyUI_Pagination.ExportSuccess(ContentList.Tables[0], ContentList.Tables[0].Rows.Count));
        }
        protected void getTaskStatus(string lpId)
        {
            string  strSql      = string.Format(@"select lpa.lpa_typeid,lpa.lpa_xy,lpa.lpa_id,lpa.lpa_jihuaname,lhd.lp_id as lhd_id from Line_Patrol lp
                                                    left join Line_PatrolArea lpa on lp.lp_fanwei = lpa.lpa_typeid
                                                    left join (select  distinct  lp_id,lpa_id,lpa_ids from Line_HiddenDanger group by lp_id,lpa_id,lpa_ids) lhd on lhd.lp_id = lp.lp_id and lhd.lpa_id = lpa.lpa_typeid and lhd.lpa_ids = lpa.lpa_id
                                                    where 1=1 and lp.lp_shenhe = '已审核' and lp.lp_id={0}", lpId);
            DataSet ContentList = APP.SQLServer_Helper.Query(strSql);

            Context.Response.Write(EasyUI_Pagination.ExportSuccess(ContentList.Tables[0], ContentList.Tables[0].Rows.Count));
        }
Exemple #4
0
        public override void Ashx_Load()
        {
            var sql = "";

            //变量赋值
            CheckRequery.checkNotNull("strSql", "", out sql);

            string  strSql      = sql;
            string  ErrInfo     = string.Empty;
            DataSet ContentList = APP.PGSQL_Helper.Query(strSql);

            Context.Response.Write(EasyUI_Pagination.ExportSuccess(ContentList.Tables[0], ContentList.Tables[0].Rows.Count));
        }
        public override void Ashx_Load()
        {
            string biaoming = "";

            CheckRequery.checkNotNull("biaoming", "", out biaoming);

            //string sql = "select count(0) from leakage.ptjsgx;";
            string sql = "select count(0) from " + biaoming;

            string    ErrInfo = string.Empty;
            DataTable dt      = new DataTable();


            dt = APP.PGSQL_Helper.SelectDataTable(sql.ToString(), out ErrInfo);

            if (string.IsNullOrEmpty(ErrInfo))
            {
                Context.Response.Write(EasyUI_Pagination.ExportSuccess(dt));
            }
            else
            {
                Context.Response.Write(EasyUI_Pagination.ExportErrMsg(ErrInfo));
            }
        }