管道基础大数据平台系统开发-【CS】-ExportMap
1
13693261870
2023-05-06 07a8639a614379f78d2d98b87e9104d75df2010e
1
已修改2个文件
9 ■■■■■ 文件已修改
ExportMap/cs/TerraUtils.cs 5 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ExportMap/db/PubDBHelper.cs 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ExportMap/cs/TerraUtils.cs
@@ -1,4 +1,5 @@
using ExportMap.Models;
using ExportMap.db;
using ExportMap.Models;
using System;
using System.Collections.Generic;
using System.IO;
@@ -200,7 +201,7 @@
        /// </summary>
        private static int InsertToDB(List<SysMeta> metas, XYZArgs args)
        {
            if (PubDBHelper.IsPublish(args.dircode, "DEM")) return 0;
            return 0;
        }
ExportMap/db/PubDBHelper.cs
@@ -43,9 +43,9 @@
        /// <summary>
        /// 是/否发布过
        /// </summary>
        public static bool IsPublish(string dirid)
        public static bool IsPublish(string dirid, string type = "DOM")
        {
            string sql = "select count(*) from lf.sys_meta_pub a inner join lf.sys_publish b on a.pubid = b.id where b.type = 'DOM' and b.dirid = @dirid";
            string sql = string.Format("select count(*) from lf.sys_meta_pub a inner join lf.sys_publish b on a.pubid = b.id where b.type = '{0}' and b.dirid = @dirid", type);
            DbParameter dp = new NpgsqlParameter("@dirid", dirid);
            object obj = Tools.DBHelper.GetScalar(sql, dp);