| | |
| | | /// <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); |