|
|
|
|
using ESRI.ArcGIS.Carto;
|
|
|
|
|
using KGIS.Framework.AE;
|
|
|
|
|
using KGIS.Framework.Maps;
|
|
|
|
|
using KGIS.Framework.Platform;
|
|
|
|
|
using KGIS.Framework.Utils.ExtensionMethod;
|
|
|
|
|
using Kingo.PluginServiceInterface;
|
|
|
|
|
using System;
|
|
|
|
|
using System.Collections.Generic;
|
|
|
|
|
using System.Data;
|
|
|
|
|
using System.Linq;
|
|
|
|
|
|
|
|
|
|
namespace Kingo.Plugin.DataCheck.Helper
|
|
|
|
|
{
|
|
|
|
|
public class BGTBCheck : DataCheckRule
|
|
|
|
|
{
|
|
|
|
|
private string _RuleName;
|
|
|
|
|
public override string RuleName { get => _RuleName; set => _RuleName = value; }
|
|
|
|
|
private string _RuleDesc;
|
|
|
|
|
public override string RuleDesc { get => _RuleDesc; set => _RuleDesc = value; }
|
|
|
|
|
|
|
|
|
|
private List<DataDicTionary> DLBMdataDic = null;
|
|
|
|
|
private List<DataDicTionary> QSDMdataDic = null;
|
|
|
|
|
public BGTBCheck() : base()
|
|
|
|
|
{
|
|
|
|
|
DLBMdataDic = Platform.Instance.DicHelper.GetNoGroupDic(DicTypeEnum.DLBM);
|
|
|
|
|
QSDMdataDic = Platform.Instance.DicHelper.GetNoGroupDic(DicTypeEnum.QSDM);
|
|
|
|
|
_RuleName = "变更图斑属性检查";
|
|
|
|
|
_RuleDesc = "变更图斑数据中图层内属性逻辑一致性检查、属性完整性";
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public override void StartCheck(object pParm)
|
|
|
|
|
{
|
|
|
|
|
IFeatureLayer m_Layer = MapsManager.Instance.MapService.GetFeatureLayerByName("DLTBBG");
|
|
|
|
|
|
|
|
|
|
IFeatureClassAPI fcAPI = new FeatureClassAPI(m_Layer.FeatureClass);
|
|
|
|
|
DataTable data = new DataTable();
|
|
|
|
|
fcAPI.QueryFeaturesToDataTable(null, -1, out data);
|
|
|
|
|
string m_Msg = "地类图斑变更层OBJECTID等于【{0}】的要素,";
|
|
|
|
|
foreach (DataRow row in data.Rows)
|
|
|
|
|
{
|
|
|
|
|
|
|
|
|
|
int _oid = Convert.ToInt32(row["OBJECTID"].ToString());
|
|
|
|
|
//if (!CheckResult.Keys.Contains(_oid))
|
|
|
|
|
// CheckResult.Add(_oid, new List<CheckResultModel>());
|
|
|
|
|
//errosData.Oid = _oid;
|
|
|
|
|
string DLBM = row["DLBM"].ToString();//地类编码
|
|
|
|
|
string QSDWDM = row["QSDWDM"].ToString();//权属单位名称
|
|
|
|
|
string GDLX = row["GDLX"].ToString();//耕地类型
|
|
|
|
|
string GDPDJB = row["GDPDJB"].ToString();//耕地坡度级别
|
|
|
|
|
string TBXHDM = row["TBXHDM"].ToString();//图斑细化代码
|
|
|
|
|
string ZZSXDM = row["ZZSXDM"].ToString();//种植属性代码
|
|
|
|
|
if (string.IsNullOrWhiteSpace(DLBM))
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, _oid) + "地类编码不能为空",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
if (DLBMdataDic != null)//地类编码字典
|
|
|
|
|
{
|
|
|
|
|
if (string.IsNullOrEmpty(DLBM) || DLBMdataDic.FirstOrDefault(x => x.CODE == DLBM).NAME != row["DLMC"].ToString())//不在字典中,或者为空
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + string.Format(m_Msg, row["OBJECTID"]) + "地类编码与名称不匹配!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
else if (string.IsNullOrEmpty(row["DLMC"].ToString()) || DLBMdataDic.FirstOrDefault(x => x.NAME == row["DLMC"].ToString()).CODE != DLBM)
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "地类编码与名称不匹配!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
if (string.IsNullOrEmpty(QSDWDM))
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "权属单位编码为空!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
if (string.IsNullOrEmpty(row["ZLDWDM"].ToString()))
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "坐落单位编码为空!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
#region 1) 除标识码、要素代码、图斑预编号、图斑面积、扣除地类面积、图斑地类面积外,其他属性取值名称、类型、长度、小数位数《国土调查数据库标准》要求
|
|
|
|
|
{
|
|
|
|
|
string TBBH = row["TBBH"].ToString();//图斑编号
|
|
|
|
|
if (TBBH.Length > 8)
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "TBBH长度不符合《国土调查数据库标准》!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
string DLBM1 = row["DLBM"].ToString();//地类编码
|
|
|
|
|
if (DLBM1.Length > 5)
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "DLBM长度不符合《国土调查数据库标准》!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
string DLMC = row["DLMC"].ToString();//地类名称
|
|
|
|
|
if (DLMC.Length > 60)
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "DLMC长度不符合《国土调查数据库标准》!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
string QSXZ = row["QSXZ"].ToString();//权属性质
|
|
|
|
|
if (QSXZ.Length > 2)
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "QSXZ长度不符合《国土调查数据库标准》!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
if (QSDWDM.Length > 19)
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "QSDWDM长度不符合《国土调查数据库标准》!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
string QSDWMC = row["QSDWMC"].ToString();//权属单位名称
|
|
|
|
|
if (QSDWMC.Length > 255)
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "QSDWMC长度不符合《国土调查数据库标准》!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
string ZLDWDM = row["ZLDWDM"].ToString();//坐落单位代码
|
|
|
|
|
if (ZLDWDM.Length > 19)
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "ZLDWDM长度不符合《国土调查数据库标准》!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
string ZLDWMC = row["ZLDWMC"].ToString();//坐落单位名称
|
|
|
|
|
if (ZLDWMC.Length > 255)
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "ZLDWMC长度不符合《国土调查数据库标准》!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
string KCDLBM = row["KCDLBM"].ToString();//扣除地类编码
|
|
|
|
|
if (KCDLBM.Length > 5)
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "KCDLBM长度不符合《国土调查数据库标准》!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
string KCXS = row["KCXS"].ToString();//扣除地类系数
|
|
|
|
|
if (KCXS.Length > 6)
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "KCXS长度不符合《国土调查数据库标准》!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
string GDLX1 = row["GDLX"].ToString();//耕地类型
|
|
|
|
|
if (GDLX1.Length > 2)
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "GDLX长度不符合《国土调查数据库标准》!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
string GDPDJB1 = row["GDPDJB"].ToString();//耕地坡度级别
|
|
|
|
|
if (GDPDJB1.Length > 2)
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "GDPDJB长度不符合《国土调查数据库标准》!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
string XZDWKD = row["XZDWKD"].ToString();//线状地物宽度
|
|
|
|
|
if (XZDWKD.Length > 5)
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "XZDWKD长度不符合《国土调查数据库标准》!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
string TBXHDM1 = row["TBXHDM"].ToString();//图斑细化代码
|
|
|
|
|
if (TBXHDM1.Length > 6)
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "TBXHDM长度不符合《国土调查数据库标准》!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
string TBXHMC = row["TBXHMC"].ToString();//图斑细化名称
|
|
|
|
|
if (TBXHMC.Length > 20)
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "TBXHMC长度不符合《国土调查数据库标准》!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
string ZZSXDM1 = row["ZZSXDM"].ToString();//种植属性代码
|
|
|
|
|
if (ZZSXDM1.Length > 6)
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "ZZSXDM长度不符合《国土调查数据库标准》!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
string ZZSXMC = row["ZZSXMC"].ToString();//种植属性名称
|
|
|
|
|
if (ZZSXMC.Length > 20)
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "ZZSXMC长度不符合《国土调查数据库标准》!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
string GDDB = row["GDDB"].ToString();//耕地等别
|
|
|
|
|
if (GDDB.Length > 2)
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "GDDB长度不符合《国土调查数据库标准》!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
string FRDBS = row["FRDBS"].ToString();//飞入地标识
|
|
|
|
|
if (FRDBS.Length > 1)
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "FRDBS长度不符合《国土调查数据库标准》!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
string CZCSXM = row["CZCSXM"].ToString();//城镇村属性码
|
|
|
|
|
if (CZCSXM.Length > 4)
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "CZCSXM长度不符合《国土调查数据库标准》!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
string HDMC = row["HDMC"].ToString();//海岛名称
|
|
|
|
|
if (HDMC.Length > 100)
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "HDMC长度不符合《国土调查数据库标准》!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
string MSSM = row["MSSM"].ToString();//描述说明
|
|
|
|
|
//if (string.IsNullOrWhiteSpace(MSSM))
|
|
|
|
|
//{
|
|
|
|
|
// base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
// {
|
|
|
|
|
// ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) +"MSSM为空!",
|
|
|
|
|
// ErrorCode = "100",ErrorLayer = "DLTBBG",PrimaryKey = "OBJECTID",PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
// ErrorType = EnumErrorType.错误
|
|
|
|
|
// });
|
|
|
|
|
//}
|
|
|
|
|
//else
|
|
|
|
|
//{
|
|
|
|
|
// if (MSSM.Length > 2)
|
|
|
|
|
// {
|
|
|
|
|
// base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
// {
|
|
|
|
|
// ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) +"MSSM长度不符合《国土调查数据库标准》!",
|
|
|
|
|
// ErrorCode = "100",ErrorLayer = "DLTBBG",PrimaryKey = "OBJECTID",PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
// ErrorType = EnumErrorType.错误
|
|
|
|
|
// });
|
|
|
|
|
// }
|
|
|
|
|
//}
|
|
|
|
|
if (MSSM != "00" && MSSM != "01")
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + $"字段MSSM的值【{MSSM}】不符合《国土调查数据库标准》!(海岛区域应填写01,非海岛区域应填写00)",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
if (MSSM == "01")
|
|
|
|
|
{
|
|
|
|
|
if (string.IsNullOrWhiteSpace(HDMC))
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "MSSM为01时HDMC不可为空!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
#region 2) 扣除地类系数(KCXS)大于0时, 扣除地类编码(KCDLBM)不为空, 扣除地类系数(KCXS)等于0时, 扣除地类编码(KCDLBM)为空
|
|
|
|
|
{
|
|
|
|
|
var KCXS = row["KCXS"].ToDouble();
|
|
|
|
|
var KCDLBM = row["KCDLBM"].ToString();
|
|
|
|
|
if (KCXS > 0)
|
|
|
|
|
{
|
|
|
|
|
if (string.IsNullOrWhiteSpace(KCDLBM))
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "扣除地类系数(KCXS)大于0时, 扣除地类编码(KCDLBM)不应为空!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
if (KCXS == 0)
|
|
|
|
|
{
|
|
|
|
|
if (!string.IsNullOrWhiteSpace(KCDLBM))
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "扣除地类系数(KCXS)等于0时, 扣除地类编码(KCDLBM)应为空!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
#region 3) 地类编码(DLBM)前2位非01时,耕地类型(GDLX)为空
|
|
|
|
|
{
|
|
|
|
|
if (!string.IsNullOrWhiteSpace(DLBM))
|
|
|
|
|
{
|
|
|
|
|
if (DLBM.Substring(0, 2) != "01")
|
|
|
|
|
{
|
|
|
|
|
if (!string.IsNullOrWhiteSpace(GDLX))
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "地类编码(DLBM)前2位非01时,耕地类型(GDLX)应为空!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
#region 4) 地类编码(DLBM)前2位为01且GDPDJB为1时, 耕地类型(GDLX)为空
|
|
|
|
|
{
|
|
|
|
|
if (!string.IsNullOrWhiteSpace(DLBM) && DLBM.Substring(0, 2) == "01" && GDPDJB == "1")
|
|
|
|
|
{
|
|
|
|
|
if (!string.IsNullOrWhiteSpace(GDLX))
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "地类编码(DLBM)前2位为01且GDPDJB为1时, 耕地类型(GDLX)应为空!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
#region 5) 耕地类型(GDLX)与地类编码(DLBM)、耕地坡度级别(GDPDJB)逻辑一致, 地类编码(DLBM)前两位为01且耕地坡度级别(GDPDJB)为2、3、4、5时, 耕地类型(GDLX)为PD或TT
|
|
|
|
|
{
|
|
|
|
|
string[] sGDPDJB = { "2", "3", "4", "5" };
|
|
|
|
|
var index = sGDPDJB.ToList().IndexOf(GDPDJB);
|
|
|
|
|
if (!string.IsNullOrWhiteSpace(DLBM) && DLBM.Substring(0, 2) == "01" && index >= 0)
|
|
|
|
|
{
|
|
|
|
|
if (GDLX != "PD" && GDLX != "TT")
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "地类编码(DLBM)前两位为01且耕地坡度级别(GDPDJB)为2、3、4、5时, 耕地类型(GDLX)为PD或TT!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
#region 6) 地类编码(DLBM)前2位非01时, 耕地坡度级别(GDPDJB)为空或填与0
|
|
|
|
|
{
|
|
|
|
|
if (!string.IsNullOrWhiteSpace(DLBM) && DLBM.Substring(0, 2) != "01")
|
|
|
|
|
{
|
|
|
|
|
if (!string.IsNullOrWhiteSpace(GDPDJB) && GDPDJB != "0")
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "地类编码(DLBM)前2位非01时, 耕地坡度级别(GDPDJB)应为空或为0!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
#region 7) 耕地坡度级别(GDPDJB)与地类编码(DLBM)逻辑一致,DLBM前两位为01时, 耕地坡度级别(GDPDJB)为1、2、3、4、5
|
|
|
|
|
{
|
|
|
|
|
string[] sGDPDJB = { "1", "2", "3", "4", "5" };
|
|
|
|
|
var index = sGDPDJB.ToList().IndexOf(GDPDJB);
|
|
|
|
|
if (!string.IsNullOrWhiteSpace(DLBM) && DLBM.Substring(0, 2) == "01")
|
|
|
|
|
{
|
|
|
|
|
if (index < 0)
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "耕地坡度级别(GDPDJB)与地类编码(DLBM)逻辑一致,DLBM前两位为01时, 耕地坡度级别(GDPDJB)应为1、2、3、4、5!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
#region 2020.07.09添加规则
|
|
|
|
|
//地类为铁路、公路、管道用地、农村道路和沟渠等线形地物时,线状地物宽度(XZDWKD)大于0;地类非河流、铁路、公路、管道用地、农村道路和沟渠,字段XZDWKD等于0,或为空值;
|
|
|
|
|
{
|
|
|
|
|
string[] sDLBM = { "1001", "1003", "1004", "1006", "1107", "1002", "1009", "1107A" };
|
|
|
|
|
var index = sDLBM.ToList().IndexOf(DLBM);
|
|
|
|
|
var XZDWKD = row["XZDWKD"].ToDouble();
|
|
|
|
|
if (index >= 0)
|
|
|
|
|
{
|
|
|
|
|
if (XZDWKD <= 0)
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "地类为铁路、公路、管道用地、农村道路和沟渠等线形地物时,线状地物宽度(XZDWKD)大于0!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
string[] sDLBM1 = { "1001", "1003", "1004", "1006", "1107", "1101", "1009", "1107A" };
|
|
|
|
|
var strindex = sDLBM1.ToList().IndexOf(DLBM);
|
|
|
|
|
if (strindex < 0)
|
|
|
|
|
{
|
|
|
|
|
if (XZDWKD != 0 && !string.IsNullOrWhiteSpace(XZDWKD.ToString()))
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "地类非河流、铁路、公路、管道用地、农村道路和沟渠,字段XZDWKD应等于0,或为空值!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
#region 9) 地类编码(DLBM)前2位为02时, 图斑细化代码(TBXHDM)字段取值为LQYD或空
|
|
|
|
|
{
|
|
|
|
|
if (!string.IsNullOrWhiteSpace(DLBM) && DLBM.Substring(0, 2) == "02")
|
|
|
|
|
{
|
|
|
|
|
if (TBXHDM != "LQYD" && !string.IsNullOrWhiteSpace(TBXHDM))
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "地类编码(DLBM)前2位为02时, 图斑细化代码(TBXHDM)字段取值应为LQYD或空!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
#region 10) 地类编码(DLBM)前2位为04(不含0404、0402),图斑细化代码(TBXHDM)等于GCCD或为空
|
|
|
|
|
{
|
|
|
|
|
if (!string.IsNullOrWhiteSpace(DLBM) && DLBM.Substring(0, 2) == "04" && DLBM != "0404" && DLBM != "0402")
|
|
|
|
|
{
|
|
|
|
|
if (TBXHDM != "GCCD" && !string.IsNullOrWhiteSpace(TBXHDM))
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "地类编码(DLBM)前2位为04(不含0404、0402),图斑细化代码(TBXHDM)应等于GCCD或空!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
#region 11) 图斑细化代码(TBXHDM)字取值在HDGY、GTGY、MTGY、SNGY、BLGY、DLGY范围内时, 地类编码(DLBM)等于0601
|
|
|
|
|
{
|
|
|
|
|
string[] sTBXHDM = { "HDGY", "GTGY", "MTGY", "SNGY", "BLGY", "DLGY" };
|
|
|
|
|
var index = sTBXHDM.ToList().IndexOf(TBXHDM);
|
|
|
|
|
if (index >= 0)
|
|
|
|
|
{
|
|
|
|
|
if (DLBM != "0601")
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "图斑细化代码(TBXHDM)字取值在HDGY、GTGY、MTGY、SNGY、BLGY、DLGY范围内时, 地类编码(DLBM)应等于0601!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
#region 12) 地类编码(DLBM)为0601时, 图斑细化代码(TBXHDM)字段为HDGY、GTGY、MTGY、SNGY、BLGY、DLGY或为空
|
|
|
|
|
{
|
|
|
|
|
if (DLBM == "0601")
|
|
|
|
|
{
|
|
|
|
|
string[] sTBXHDM = { "HDGY", "GTGY", "MTGY", "SNGY", "BLGY", "DLGY" };
|
|
|
|
|
var index = sTBXHDM.ToList().IndexOf(TBXHDM);
|
|
|
|
|
if (index < 0 && !string.IsNullOrWhiteSpace(TBXHDM))
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "地类编码(DLBM)为0601时, 图斑细化代码(TBXHDM)字段应为HDGY、GTGY、MTGY、SNGY、BLGY、DLGY或空!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#region 14) 图斑细化代码(TBXHDM)字段取值在HDGD、HQGD、LQGD、MQGD、SHGD、SMGD、YJGD范围内时, 地类编码(DLBM)前2位为01
|
|
|
|
|
{
|
|
|
|
|
string[] sTBXHDM = { "HDGD", "HQGD", "LQGD", "MQGD", "SHGD", "SMGD", "YJGD" };
|
|
|
|
|
var index = sTBXHDM.ToList().IndexOf(TBXHDM);
|
|
|
|
|
if (index >= 0)
|
|
|
|
|
{
|
|
|
|
|
if (!string.IsNullOrWhiteSpace(DLBM) && DLBM.Substring(0, 2) != "01")
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "图斑细化代码(TBXHDM)字段取值在HDGD、HQGD、LQGD、MQGD、SHGD、SMGD、YJGD范围内时, 地类编码(DLBM)前2位应为01!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
#region 15) DLBM除0101、0102、0103、0201、0201K、0202、0202K、0203、0203K、0204、0204K、0301、0301K、0302、0302K、0305、0307、0307K、0401、0403、0403K、0404、0601、0602、1001、1003外其他地类, TBXHDM字段为空
|
|
|
|
|
{
|
|
|
|
|
string[] sDLBM = { "0101", "0102", "0103", "0201", "0201K", "0202", "0202K", "0203", "0203K", "0204", "0204K", "0301", "0301K", "0302", "0302K", "0305", "0307", "0307K", "0401", "0403", "0403K", "0404", "0601", "0602", "1001", "1003" };
|
|
|
|
|
var index = sDLBM.ToList().IndexOf(DLBM);
|
|
|
|
|
if (index < 0)
|
|
|
|
|
{
|
|
|
|
|
if (!string.IsNullOrWhiteSpace(TBXHDM))
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "DLBM除0101、0102、0103、0201、0201K、0202、0202K、0203、0203K、0204、0204K、0301、0301K、0302、0302K、0305、0307、0307K、0401、0403、0403K、0404、0601、0602、1001、1003外其他地类, TBXHDM字段应为空!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
#region 16) DLBM前2位为03时(不含0303、0304、0306),图斑细化代码(TBXHDM)取值在LJTM、空范围内
|
|
|
|
|
{
|
|
|
|
|
if (!string.IsNullOrWhiteSpace(DLBM) && DLBM.Substring(0, 2) == "03" && DLBM != "0303" && DLBM != "0304" && DLBM != "0306")
|
|
|
|
|
{
|
|
|
|
|
if (TBXHDM != "LJTM" && !string.IsNullOrWhiteSpace(TBXHDM))
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "DLBM前2位为03时(不含0303、0304、0306),图斑细化代码(TBXHDM)取值应为 LJTM 或 空!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
#region 17) DLBM前2位为02时,图斑细化代码(TBXHDM)取值在LQYD、空范围内
|
|
|
|
|
{
|
|
|
|
|
if (!string.IsNullOrWhiteSpace(DLBM) && DLBM.Substring(0, 2) == "02")
|
|
|
|
|
{
|
|
|
|
|
if (TBXHDM != "LQYD" && !string.IsNullOrWhiteSpace(TBXHDM))
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "DLBM前2位为02时,图斑细化代码(TBXHDM)取值应为 LQYD 或 空!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
#region 18) DLBM为0404时,图斑细化代码(TBXHDM)取值在LJTM、GCCD、空范围内
|
|
|
|
|
{
|
|
|
|
|
if (DLBM == "0404")
|
|
|
|
|
{
|
|
|
|
|
if (TBXHDM != "LJTM" && TBXHDM != "GCCD" && !string.IsNullOrWhiteSpace(TBXHDM))
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "DLBM为0404时,图斑细化代码(TBXHDM)取值应为 LJTM、GCCD 或 空!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
#region 19) DLBM为0602、1001、 1003时 , TBXHDM字段为FQ或空值
|
|
|
|
|
{
|
|
|
|
|
if (DLBM == "0602" || DLBM == "1001" || DLBM == "1003")
|
|
|
|
|
{
|
|
|
|
|
if (TBXHDM != "FQ" && !string.IsNullOrWhiteSpace(TBXHDM))
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "DLBM为0602、1001、 1003时 , TBXHDM字段应为 FQ 或 空 !",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
#region 20) 地类编码(DLBM)字段值前 2 位为 01 时,且图斑细化代码(TBXHDM)为空时,种植属性代码(ZZSXDM)为LS、FLS、LYFL、XG、LLJZ、WG范围内
|
|
|
|
|
{
|
|
|
|
|
if (!string.IsNullOrWhiteSpace(DLBM) && DLBM.Substring(0, 2) == "01")
|
|
|
|
|
{
|
|
|
|
|
if (string.IsNullOrWhiteSpace(TBXHDM))
|
|
|
|
|
{
|
|
|
|
|
string[] sZZSXDM = { "LS", "FLS", "LYFL", "XG", "LLJZ", "WG" };
|
|
|
|
|
var index = sZZSXDM.ToList().IndexOf(ZZSXDM);
|
|
|
|
|
if (index < 0)
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "地类编码(DLBM)字段值前 2 位为 01 时,且图斑细化代码(TBXHDM)为空时,种植属性代码(ZZSXDM)应在LS、FLS、LYFL、XG、LLJZ、WG范围内!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
string[] sTBXHDM = { "HDGD", "HQGD", "LQGD", "MQGD", "SHGD", "SMGD", "YJGD" };
|
|
|
|
|
var index = sTBXHDM.ToList().IndexOf(TBXHDM);
|
|
|
|
|
if (index < 0)
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "地类编码(DLBM)前2位为01时, 图斑细化代码(TBXHDM)字段取值应在HDGD、HQGD、LQGD、MQGD、SHGD、SMGD、YJGD或空范围内!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
#region 21) 地类编码(DLBM)字段值 前2位为01时,且TBXHDM不为空时, ZZSXDM取值为LS、 FLS、 LYFL
|
|
|
|
|
{
|
|
|
|
|
if (!string.IsNullOrWhiteSpace(DLBM) && DLBM.Substring(0, 2) == "01" && !string.IsNullOrWhiteSpace(TBXHDM))
|
|
|
|
|
{
|
|
|
|
|
if (ZZSXDM != "LS" && ZZSXDM != "FLS" && ZZSXDM != "LYFL")
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "地类编码(DLBM)字段值 前2位为01时,且TBXHDM不为空时, ZZSXDM取值应为 LS、 FLS、 LYFL!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
#region 22) 地类编码(DLBM)为0201、0202、0203、0204时,且TBXHDM为LQYD时,ZZSXDM取值为空
|
|
|
|
|
{
|
|
|
|
|
string[] sDLBM = { "0201", "0202", "0203", "0204" };
|
|
|
|
|
var index = sDLBM.ToList().IndexOf(DLBM);
|
|
|
|
|
if (index >= 0 && TBXHDM == "LQYD")
|
|
|
|
|
{
|
|
|
|
|
if (!string.IsNullOrWhiteSpace(ZZSXDM))
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "地类编码(DLBM)为0201、0202、0203、0204时,且TBXHDM为LQYD时,ZZSXDM取值应为空!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
#region 23) DLBM前2位为04 (不包括0404、0403K)、05、06、07、08、09、10、11 (不包括1104、1104A、1104K)、12,或属于湿地(00大类)的,ZZSXDM字段为空
|
|
|
|
|
{
|
|
|
|
|
//湿地 00 大类 0303 0304 0306 0402 0603 1105 1106 1108
|
|
|
|
|
string[] sDLBM = { "04", "05", "06", "07", "08", "09", "10", "11", "12" };
|
|
|
|
|
var DLBMsub = string.Empty;
|
|
|
|
|
if (!string.IsNullOrWhiteSpace(DLBM))
|
|
|
|
|
DLBMsub = DLBM.Substring(0, 2);
|
|
|
|
|
var index = sDLBM.ToList().IndexOf(DLBMsub);
|
|
|
|
|
string[] shidi = { "0303", "0304", "0306", "0402", "0603", "1105", "1106", "1108" };
|
|
|
|
|
var sindex = shidi.ToList().IndexOf(DLBM);
|
|
|
|
|
if (index >= 0 || sindex >= 0)
|
|
|
|
|
{
|
|
|
|
|
if (DLBM != "0404" && DLBM != "0403L" && DLBM != "1104" && DLBM != "1104A" && DLBM != "1104K")
|
|
|
|
|
{
|
|
|
|
|
if (!string.IsNullOrWhiteSpace(ZZSXDM))
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "DLBM前2位为04 (不包括0404、0403K)、05、06、07、08、09、10、11 (不包括1104、1104A、1104K)、12,或属于湿地(00大类)的,ZZSXDM应为空!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
#region 24) 地类编码(DLBM)为0201、0202、0203、0204时,且TBXHDM为空时, ZZSXDM取值在JKHF、GCHF或空范围内
|
|
|
|
|
{
|
|
|
|
|
string[] sDLBM = { "0201", "0202", "0203", "0204" };
|
|
|
|
|
var index = sDLBM.ToList().IndexOf(DLBM);
|
|
|
|
|
if (index >= 0)
|
|
|
|
|
{
|
|
|
|
|
if (string.IsNullOrWhiteSpace(TBXHDM))
|
|
|
|
|
{
|
|
|
|
|
if (ZZSXDM != "JKHF" && ZZSXDM != "GCHF" && !string.IsNullOrWhiteSpace(ZZSXDM))
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "地类编码(DLBM)为0201、0202、0203、0204时,且TBXHDM为空时, ZZSXDM取值应为 JKHF、GCHF 或 空!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
#region 25) DLBM为0201K、0202K、0203K、0204K、0301K、0302K、0307K、0403K、1104K时,种植属性代码(ZZSXDM)值在JKHF、 GCHF范围内
|
|
|
|
|
{
|
|
|
|
|
string[] sDLBM = { "0201K", "0202K", "0203K", "0204K", "0301K", "0302K", "0307K", "0403K", "1104K" };
|
|
|
|
|
var index = sDLBM.ToList().IndexOf(DLBM);
|
|
|
|
|
if (index >= 0)
|
|
|
|
|
{
|
|
|
|
|
if (ZZSXDM != "JKHF" && ZZSXDM != "GCHF")
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "DLBM为0201K、0202K、0203K、0204K、0301K、0302K、0307K、0403K、1104K时,种植属性代码(ZZSXDM)值应为 JKHF、 GCHF!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
#region 26) DLBM为0301、0302、0305、0307、0404、1104、1104A时,种植属性代码(ZZSXDM)值在JKHF、 GCHF、空范围内
|
|
|
|
|
{
|
|
|
|
|
string[] sDLBM = { "0301", "0302", "0305", "0307", "0404", "1104", "1104A" };
|
|
|
|
|
var index = sDLBM.ToList().IndexOf(DLBM);
|
|
|
|
|
if (index >= 0)
|
|
|
|
|
{
|
|
|
|
|
if (ZZSXDM != "JKHF" && ZZSXDM != "GCHF" && !string.IsNullOrWhiteSpace(ZZSXDM))
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "DLBM为0301、0302、0305、0307、0404、1104、1104A时,种植属性代码(ZZSXDM)值应为 JKHF、 GCHF 或 空!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
#region 27) 地类编码(DLBM)前2位非01时,耕地等别(GDDB)字段取值为0
|
|
|
|
|
{
|
|
|
|
|
if (!string.IsNullOrWhiteSpace(DLBM) && DLBM.Substring(0, 2) != "01")
|
|
|
|
|
{
|
|
|
|
|
var GDDB = row["GDDB"].ToString();
|
|
|
|
|
if (GDDB != "0")
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "地类编码(DLBM)前2位非01时,耕地等别(GDDB)字段取值应为0!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
#region 28) 地类编码(DLBM)前2位为01时,耕地等别(GDDB)字段取值在[1-15]、空范围内
|
|
|
|
|
{
|
|
|
|
|
if (!string.IsNullOrWhiteSpace(DLBM) && DLBM.Substring(0, 2) == "01")
|
|
|
|
|
{
|
|
|
|
|
var GDDB = row["GDDB"].ToString();
|
|
|
|
|
if (!string.IsNullOrEmpty(GDDB))
|
|
|
|
|
{
|
|
|
|
|
if (GDDB.ToDouble() < 1 || GDDB.ToDouble() > 15)
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "地类编码(DLBM)前2位为01时,耕地等别(GDDB)字段取值应在[1-15]或空范围内!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
#region 29) 飞入地标识(FRDBS)字段取值为 1 时,坐落单位代码(ZLDWDM)前 12 位与权属单位代码(QSDWDM)前12 位不相等
|
|
|
|
|
{
|
|
|
|
|
var FRDBS = row["FRDBS"].ToString();
|
|
|
|
|
if (FRDBS == "1" && !string.IsNullOrWhiteSpace(QSDWDM))
|
|
|
|
|
{
|
|
|
|
|
var QSXZ = row["QSXZ"].ToString();
|
|
|
|
|
string ZLDWDM = row["ZLDWDM"].ToString();
|
|
|
|
|
if (QSXZ == "10" || QSXZ == "20")
|
|
|
|
|
{
|
|
|
|
|
if (ZLDWDM.Substring(0, 6) == QSDWDM.Substring(0, 6))
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "权属性质(QSXZ)为国有用地(10、20),且坐落单位代码与权属单位代码前6位相同,飞入地标识(FRDBS)不应为1!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
if (ZLDWDM.Substring(0, 12) == QSDWDM.Substring(0, 12))
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "飞入地标识(FRDBS)字段取值为 1 时,坐落单位代码(ZLDWDM)前12位与权属单位代码(QSDWDM)前12 位应不相等!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#region 31) 地类为工业用地 0601,城镇村属性码(CZCSXM)标注 201、 202、 203、 201A、 202A、 203A、204、205
|
|
|
|
|
{
|
|
|
|
|
if (DLBM == "0601")
|
|
|
|
|
{
|
|
|
|
|
string[] sCZCSXM = { "201", "202", "203", "201A", "202A", "203A", "204", "205" };
|
|
|
|
|
string CZCSXM = row["CZCSXM"].ToString();
|
|
|
|
|
var index = sCZCSXM.ToList().IndexOf(CZCSXM);
|
|
|
|
|
if (index < 0)
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "地类为工业用地 0601,城镇村属性码(CZCSXM)应在 201、 202、 203、 201A、 202A、 203A、204、205 范围内!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
#region 32) 城镇村属性码(CZCSXM)为 201A、 202A、 203A,地类编码(DLBM)为工业用地 0601
|
|
|
|
|
{
|
|
|
|
|
string[] sCZCSXM = { "201A", "202A", "203A" };
|
|
|
|
|
string CZCSXM = row["CZCSXM"].ToString();
|
|
|
|
|
var index = sCZCSXM.ToList().IndexOf(CZCSXM);
|
|
|
|
|
if (index >= 0 && DLBM != "0601")
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "城镇村属性码(CZCSXM)为 201A、 202A、 203A,地类编码(DLBM)应为 0601!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
#region 33) 地类编码(DLBM)为1001/1002/1003/1006/1007/1008/1009/1109,城镇村属性码(CZCSXM)为 201、 202、203、204、205,或为空
|
|
|
|
|
{
|
|
|
|
|
string[] sDLBM = { "1001", "1002", "1003", "1006", "1007", "1008", "1009", "1109" };
|
|
|
|
|
var index = sDLBM.ToList().IndexOf(DLBM);
|
|
|
|
|
if (index >= 0)
|
|
|
|
|
{
|
|
|
|
|
string[] sCZCSXM = { "201", "202", "203", "204", "205" };
|
|
|
|
|
string CZCSXM = row["CZCSXM"].ToString();
|
|
|
|
|
var czcindex = sCZCSXM.ToList().IndexOf(CZCSXM);
|
|
|
|
|
if (czcindex < 0 && !string.IsNullOrWhiteSpace(CZCSXM))
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "地类编码(DLBM)为1001/1002/1003/1006/1007/1008/1009/1109时,城镇村属性码(CZCSXM)应在 201、 202、203、204、205,或空 范围内!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
#region 34) 地类为城镇住宅用地(0701)的城镇村属性码不能为203、201A、 202A、203A、204、205
|
|
|
|
|
{
|
|
|
|
|
if (DLBM == "0701")
|
|
|
|
|
{
|
|
|
|
|
string[] sCZCSXM = { "203", "201A", "202A", "203A", "204", "205" };
|
|
|
|
|
string CZCSXM = row["CZCSXM"].ToString();
|
|
|
|
|
var czcindex = sCZCSXM.ToList().IndexOf(CZCSXM);
|
|
|
|
|
if (czcindex > 0)
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "地类为城镇住宅用地(0701)的城镇村属性码不应该为203、201A、 202A、203A、204、205!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
#region 35) 建设用地(05H1、 0508、 0602、0603、 0701、 0702、 08H1、 08H2、 08H2A、0809、 0810、 0810A、 1004、 1005、 1201),CZCSXM 取值在 201、 202、 203、 204、 205 范围内, 不允许为空
|
|
|
|
|
{
|
|
|
|
|
string[] sDLBM = { "05H1", "0508", "0602", "0603", "0701", "0702", "08H1", "08H2", "08H2A", "0809", "0810", "0810A", "1004", "1005", "1201" };
|
|
|
|
|
var index = sDLBM.ToList().IndexOf(DLBM);
|
|
|
|
|
if (index >= 0)
|
|
|
|
|
{
|
|
|
|
|
string[] sCZCSXM = { "201", "202", "203", "204", "205" };
|
|
|
|
|
string CZCSXM = row["CZCSXM"].ToString();
|
|
|
|
|
var czcindex = sCZCSXM.ToList().IndexOf(CZCSXM);
|
|
|
|
|
if (czcindex < 0 && string.IsNullOrWhiteSpace(CZCSXM))
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "建设用地(05H1、 0508、 0602、0603、 0701、 0702、 08H1、 08H2、 08H2A、0809、 0810、 0810A、 1004、 1005、 1201),CZCSXM 取值应在 201、 202、 203、 204、 205 范围内, 不应为空!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
#region 36) 非建设用地、及交通运输用地(1001、1002、1003、1004、1005、1006、1007、1008、1009)、水工建筑用地(1109),CZCSXM 字段取值在 201、 202、 203、 204、 205、空范围内
|
|
|
|
|
{
|
|
|
|
|
string[] sDLBM = { "1001", "1002", "1003", "1004", "1005", "1006", "1007", "1008", "1009", "1109" };
|
|
|
|
|
var index = sDLBM.ToList().IndexOf(DLBM);
|
|
|
|
|
if (index >= 0)
|
|
|
|
|
{
|
|
|
|
|
string[] sCZCSXM = { "201", "202", "203", "204", "205" };
|
|
|
|
|
string CZCSXM = row["CZCSXM"].ToString();
|
|
|
|
|
var czcindex = sCZCSXM.ToList().IndexOf(CZCSXM);
|
|
|
|
|
if (czcindex < 0 && !string.IsNullOrWhiteSpace(CZCSXM))
|
|
|
|
|
{
|
|
|
|
|
base.CheckResults.Add(new DataCheckResult()
|
|
|
|
|
{
|
|
|
|
|
ErrorDesc = string.Format(m_Msg, row["OBJECTID"]) + "非建设用地、及交通运输用地(1001、1002、1003、1004、1005、1006、1007、1008、1009)、水工建筑用地(1109),CZCSXM 字段取值应在 201、 202、 203、 204、 205、空范围内!",
|
|
|
|
|
ErrorCode = "100",
|
|
|
|
|
ErrorLayer = "DLTBBG",
|
|
|
|
|
PrimaryKey = "OBJECTID",
|
|
|
|
|
PrimaryKeyValue = _oid.ToTrim(),
|
|
|
|
|
ErrorType = EnumErrorType.错误
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public override void StartCheckForThread(object pParam)
|
|
|
|
|
{
|
|
|
|
|
throw new NotImplementedException();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public override void StartLoadData(object pParm)
|
|
|
|
|
{
|
|
|
|
|
throw new NotImplementedException();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public override void StartRepair(object pParm)
|
|
|
|
|
{
|
|
|
|
|
throw new NotImplementedException();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public override void StartSingleRepair(object pParm)
|
|
|
|
|
{
|
|
|
|
|
throw new NotImplementedException();
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|