From 9c315b4dbbb9f25d5373d1f228ed441a4e8ccbf7 Mon Sep 17 00:00:00 2001 From: hcong <1050828145@qq.com> Date: 星期四, 12 十二月 2024 15:31:00 +0800 Subject: [PATCH] 1. 数据产品中间结果基本信息和具体信息入库 --- src/main/kotlin/cn/flightfeather/supervision/business/report/bean/ProAnalysisSummaryResult.kt | 22 src/main/kotlin/cn/flightfeather/supervision/domain/ds1/entity/DataProductTownProAnalysis.java | 465 +++++++++++++ src/main/resources/mapper/ds1/DataProductProDetailMapper.xml | 100 ++ src/main/kotlin/cn/flightfeather/supervision/domain/ds1/repository/DataProductRep.kt | 74 ++ src/main/resources/mapper/ds1/DataProductTownProAnalysisMapper.xml | 72 ++ src/main/resources/mapper/ds1/DataProductMapper.xml | 37 + src/main/kotlin/cn/flightfeather/supervision/domain/ds1/mapper/DataProductTownProAnalysisMapper.kt | 8 src/main/kotlin/cn/flightfeather/supervision/domain/ds1/entity/DataProduct.java | 411 +++++++++++ src/main/kotlin/cn/flightfeather/supervision/business/report/bean/BaseTemplateResult.kt | 5 src/main/kotlin/cn/flightfeather/supervision/domain/ds1/mapper/DataProductMapper.java | 7 src/main/kotlin/cn/flightfeather/supervision/domain/ds1/entity/DataProductProDetail.java | 753 +++++++++++++++++++++ src/main/kotlin/cn/flightfeather/supervision/common/utils/Constant.kt | 6 src/main/kotlin/cn/flightfeather/supervision/domain/ds1/mapper/DataProductProDetailMapper.kt | 8 src/main/kotlin/cn/flightfeather/supervision/business/report/BaseTemplate.kt | 42 + src/main/kotlin/cn/flightfeather/supervision/business/report/bean/ProDetailSummaryResult.kt | 38 + 15 files changed, 2,048 insertions(+), 0 deletions(-) diff --git a/src/main/kotlin/cn/flightfeather/supervision/business/report/BaseTemplate.kt b/src/main/kotlin/cn/flightfeather/supervision/business/report/BaseTemplate.kt index a053d99..0c8047d 100644 --- a/src/main/kotlin/cn/flightfeather/supervision/business/report/BaseTemplate.kt +++ b/src/main/kotlin/cn/flightfeather/supervision/business/report/BaseTemplate.kt @@ -2,10 +2,13 @@ import cn.flightfeather.supervision.common.utils.ExcelUtil import cn.flightfeather.supervision.business.report.bean.BaseTemplateResult +import cn.flightfeather.supervision.common.utils.UUIDGenerator +import cn.flightfeather.supervision.domain.ds1.entity.DataProduct import org.apache.poi.hssf.usermodel.HSSFWorkbook import java.io.FileOutputStream import java.io.OutputStream import java.util.* +import kotlin.collections.ArrayList import kotlin.reflect.full.createInstance /** @@ -23,6 +26,12 @@ // 涓棿缁撴灉瀵硅薄 by hc 2024.12.5 abstract var resultObjects: MutableList<BaseTemplateResult> + + // 涓棿缁撴灉鍩烘湰淇℃伅瀵瑰簲鏁版嵁搴撲腑鐨別ntity + var dataProduct = DataProduct() + + // 涓棿缁撴灉鍏蜂綋淇℃伅瀵瑰簲鏁版嵁搴撲腑鐨別ntity + val entities = ArrayList<Any>() // 鎵ц鐘舵�� by hc 2024.12.5 var isExecuted: Boolean = false @@ -101,6 +110,39 @@ } /** + * 鐢熸垚涓棿缁撴灉鍏蜂綋淇℃伅entity + * by hc 2024.12.12 + */ + fun toDBEntity() { + entities.clear() + if (!isExecuted) { + execute() + } + // 鍏堟墽琛宼oObject鍚庡皢toObject鐨勭粨鏋滆浆鍖栦负DBEntity + toObject() + resultObjects.forEach { + entities.add(it.convertToDBEntity()) + } + } + + /** + * 鐢熸垚涓棿缁撴灉鍩烘湰淇℃伅entity + * by hc 2024.12.12 + */ + fun toDBBaseInfoEntity() { + dataProduct = DataProduct() + dataProduct.guid = UUIDGenerator.generate16ShortUUID() + dataProduct.townCode = dataSource.config.townCode + dataProduct.cityCode = dataSource.config.cityCode + dataProduct.districtCode = dataSource.config.districtCode + dataProduct.endTime = dataSource.config.endTime + dataProduct.startTime = dataSource.config.startTime + dataProduct.provinceCode = dataSource.config.provinceCode + dataProduct.sceneTypeId = dataSource.config.sceneType?.toByte() ?: -1 + dataProduct.taskGuid = dataSource.config.topTaskGuid + } + + /** * 杈撳嚭涓烘枃妗� */ override fun toFile(path: String) { diff --git a/src/main/kotlin/cn/flightfeather/supervision/business/report/bean/BaseTemplateResult.kt b/src/main/kotlin/cn/flightfeather/supervision/business/report/bean/BaseTemplateResult.kt index 04826b8..dc3757a 100644 --- a/src/main/kotlin/cn/flightfeather/supervision/business/report/bean/BaseTemplateResult.kt +++ b/src/main/kotlin/cn/flightfeather/supervision/business/report/bean/BaseTemplateResult.kt @@ -13,6 +13,11 @@ // 瀹氫箟娉ㄨВ annotation class ExcelHead(val index: Int, val des: String) + /** + * 杞崲涓烘暟鎹簱琛ㄥ搴旂殑瀹炰綋绫诲璞� + */ + abstract fun convertToDBEntity(): Any + fun setProperties(values: MutableList<Any>) { // 閬嶅巻鎵�鏈夊睘鎬у苟璧嬪�� var index = 0 diff --git a/src/main/kotlin/cn/flightfeather/supervision/business/report/bean/ProAnalysisSummaryResult.kt b/src/main/kotlin/cn/flightfeather/supervision/business/report/bean/ProAnalysisSummaryResult.kt index 0711386..6c8cb06 100644 --- a/src/main/kotlin/cn/flightfeather/supervision/business/report/bean/ProAnalysisSummaryResult.kt +++ b/src/main/kotlin/cn/flightfeather/supervision/business/report/bean/ProAnalysisSummaryResult.kt @@ -1,5 +1,6 @@ package cn.flightfeather.supervision.business.report.bean +import cn.flightfeather.supervision.domain.ds1.entity.DataProductTownProAnalysis import java.math.BigDecimal /** @@ -54,4 +55,25 @@ @ExcelHead(16, "鎷熷垪鍏ラ噸鐐圭洃绠″崰姣�") var focusScenePer: BigDecimal? = null + + override fun convertToDBEntity(): DataProductTownProAnalysis { + val entity = DataProductTownProAnalysis() + entity.formIndex = this.formIndex + entity.townName = this.sceneTownname + entity.sceneType = this.sceneType + entity.sceneCount = this.sceneCount + entity.inactiveSceneCount = this.inactiveScenes + entity.activeSceneCount = this.activeScenes + entity.changeSceneCount = this.changeScenes + entity.changeScenePer = this.changeScenePer + entity.proCount = this.proNum + entity.proPer = this.proPer + entity.changeCount = this.changeNum + entity.changePer = this.changePer + entity.changeSceneRank = this.changeSceneRank + entity.proChangeRank = this.proChangeRank + entity.focusSceneCount = this.focusSceneNum + entity.focusScenePer = this.focusScenePer + return entity + } } \ No newline at end of file diff --git a/src/main/kotlin/cn/flightfeather/supervision/business/report/bean/ProDetailSummaryResult.kt b/src/main/kotlin/cn/flightfeather/supervision/business/report/bean/ProDetailSummaryResult.kt index 209e29b..0877fe1 100644 --- a/src/main/kotlin/cn/flightfeather/supervision/business/report/bean/ProDetailSummaryResult.kt +++ b/src/main/kotlin/cn/flightfeather/supervision/business/report/bean/ProDetailSummaryResult.kt @@ -1,5 +1,7 @@ package cn.flightfeather.supervision.business.report.bean +import cn.flightfeather.supervision.common.utils.DateUtil +import cn.flightfeather.supervision.domain.ds1.entity.DataProductProDetail import java.math.BigDecimal /** @@ -91,4 +93,40 @@ @ExcelHead(28, "鏁存敼璺熻釜鎻愰啋") var changeTrackingReminder: String? = null + + override fun convertToDBEntity(): DataProductProDetail { + val entity = DataProductProDetail() + entity.formIndex = this.formIndex + entity.sceneIndex = this.sceneIndex + entity.sceneType = this.sceneType + entity.sceneName = this.sceneName + // 灏哠tring绫诲瀷鐨勭洃绠℃椂闂磋浆鎹负Date绫诲瀷 + entity.inspectionTime = DateUtil.StringToDate(this.subTaskPlanstarttime, "mm-dd") + entity.executors = this.subTaskExecutorrealtimes + entity.problemType = this.problemTypename + entity.problemDescription = this.problemDescription + entity.problemLocation = this.problemLocation + entity.problemNum = this.problemNum + entity.changeTime = this.changeTime + entity.problemChanged = this.problemChanged + entity.changedProblem = this.changedProblem + entity.changedNum = this.changedNum + entity.unchangedProblems = this.unchangedProblems + entity.unchangedNum = this.unChangedProblem + entity.changePercent = this.changePercent + entity.checkStatus = this.checkStatus + entity.proCheckTime = this.pCheckTime + entity.changeCheckTime = this.cCheckTime + entity.proCheckNum = this.pCheckNum + entity.proCheckPer = this.pCheckPer + entity.changeCheckNum = this.cCheckNum + entity.changeCheckPer = this.cCheckPer + entity.ledgerPercent = this.ledgerPercent + // 灏哠tring绫诲瀷鐨勫彴璐︽彁浜ゆ椂闂磋浆鎹负Date绫诲瀷 + entity.ledgerSubmitDate = DateUtil.StringToDate(this.ledgerSubmitdate, "yyyy-mm-dd hh:mm:ss") + // 灏哠tring绫诲瀷鐨勫彴璐﹀鏍告椂闂磋浆鎹负Date绫诲瀷锛岃繖閲屽亣璁緇edgerCheckTime鏄鍚圖ate鏍煎紡鐨勫瓧绗︿覆 + entity.ledgerCheckTime = DateUtil.StringToDate(this.ledgerCheckTime, "yyyy-mm-dd hh:mm:ss") + entity.changeTrackingReminder = this.changeTrackingReminder + return entity + } } diff --git a/src/main/kotlin/cn/flightfeather/supervision/common/utils/Constant.kt b/src/main/kotlin/cn/flightfeather/supervision/common/utils/Constant.kt index deb1ae8..0f7a9f8 100644 --- a/src/main/kotlin/cn/flightfeather/supervision/common/utils/Constant.kt +++ b/src/main/kotlin/cn/flightfeather/supervision/common/utils/Constant.kt @@ -222,6 +222,12 @@ HEART_MESSAGE_TYPE(0, "蹇冭烦鏈哄埗") } + // 鏁版嵁浜у搧绫诲瀷 + enum class DataProductType(val value: Byte, val des: String){ + PRO_DETAIL_SUMMARY(1, "闂涓庢暣鏀硅窡韪眹鎬昏〃"), + PRO_ANALYSIS_SUMMARY(2, "鍒嗚闀囬棶棰樻暣鏀瑰垎鏋愭眹鎬昏〃") + } + companion object { //闂瀹℃牳 diff --git a/src/main/kotlin/cn/flightfeather/supervision/domain/ds1/entity/DataProduct.java b/src/main/kotlin/cn/flightfeather/supervision/domain/ds1/entity/DataProduct.java new file mode 100644 index 0000000..cbadfab --- /dev/null +++ b/src/main/kotlin/cn/flightfeather/supervision/domain/ds1/entity/DataProduct.java @@ -0,0 +1,411 @@ +package cn.flightfeather.supervision.domain.ds1.entity; + +import java.util.Date; +import javax.persistence.*; + +@Table(name = "sm_t_data_product") +public class DataProduct { + @Id + @Column(name = "GUID") + private String guid; + + /** + * 鎶ヨ〃绫诲瀷(1锛氶棶棰樹笌鏁存敼璺熻釜姹囨�昏〃 2锛氬垎琛楅晣闂鏁存敼鍒嗘瀽姹囨�昏〃) + */ + @Column(name = "Type_ID") + private Byte typeId; + + /** + * 鎬讳换鍔d + */ + @Column(name = "Task_GUID") + private String taskGuid; + + @Column(name = "Scene_Type_ID") + private Byte sceneTypeId; + + @Column(name = "Province_Code") + private String provinceCode; + + @Column(name = "Province_Name") + private String provinceName; + + @Column(name = "City_Code") + private String cityCode; + + @Column(name = "City_Name") + private String cityName; + + @Column(name = "District_Code") + private String districtCode; + + @Column(name = "District_Name") + private String districtName; + + @Column(name = "Town_Code") + private String townCode; + + @Column(name = "Town_Name") + private String townName; + + /** + * 寮�濮嬫椂闂� + */ + @Column(name = "Start_Time") + private Date startTime; + + /** + * 缁撴潫鏃堕棿 + */ + @Column(name = "End_Time") + private Date endTime; + + /** + * 鍒涘缓鏃堕棿 + */ + @Column(name = "Create_Time") + private Date createTime; + + @Column(name = "Update_Time") + private Date updateTime; + + /** + * 鎵╁睍瀛楁1 + */ + @Column(name = "Extension1") + private String extension1; + + /** + * 鎵╁睍瀛楁2 + */ + @Column(name = "Extension2") + private String extension2; + + /** + * 鎵╁睍瀛楁3 + */ + @Column(name = "Extension3") + private String extension3; + + /** + * 澶囨敞 + */ + @Column(name = "Remark") + private String remark; + + /** + * @return GUID + */ + public String getGuid() { + return guid; + } + + /** + * @param guid + */ + public void setGuid(String guid) { + this.guid = guid == null ? null : guid.trim(); + } + + /** + * 鑾峰彇鎶ヨ〃绫诲瀷(1锛氶棶棰樹笌鏁存敼璺熻釜姹囨�昏〃 2锛氬垎琛楅晣闂鏁存敼鍒嗘瀽姹囨�昏〃) + * + * @return Type_ID - 鎶ヨ〃绫诲瀷(1锛氶棶棰樹笌鏁存敼璺熻釜姹囨�昏〃 2锛氬垎琛楅晣闂鏁存敼鍒嗘瀽姹囨�昏〃) + */ + public Byte getTypeId() { + return typeId; + } + + /** + * 璁剧疆鎶ヨ〃绫诲瀷(1锛氶棶棰樹笌鏁存敼璺熻釜姹囨�昏〃 2锛氬垎琛楅晣闂鏁存敼鍒嗘瀽姹囨�昏〃) + * + * @param typeId 鎶ヨ〃绫诲瀷(1锛氶棶棰樹笌鏁存敼璺熻釜姹囨�昏〃 2锛氬垎琛楅晣闂鏁存敼鍒嗘瀽姹囨�昏〃) + */ + public void setTypeId(Byte typeId) { + this.typeId = typeId; + } + + /** + * 鑾峰彇鎬讳换鍔d + * + * @return Task_GUID - 鎬讳换鍔d + */ + public String getTaskGuid() { + return taskGuid; + } + + /** + * 璁剧疆鎬讳换鍔d + * + * @param taskGuid 鎬讳换鍔d + */ + public void setTaskGuid(String taskGuid) { + this.taskGuid = taskGuid == null ? null : taskGuid.trim(); + } + + /** + * @return Scene_Type_ID + */ + public Byte getSceneTypeId() { + return sceneTypeId; + } + + /** + * @param sceneTypeId + */ + public void setSceneTypeId(Byte sceneTypeId) { + this.sceneTypeId = sceneTypeId; + } + + /** + * @return Province_Code + */ + public String getProvinceCode() { + return provinceCode; + } + + /** + * @param provinceCode + */ + public void setProvinceCode(String provinceCode) { + this.provinceCode = provinceCode == null ? null : provinceCode.trim(); + } + + /** + * @return Province_Name + */ + public String getProvinceName() { + return provinceName; + } + + /** + * @param provinceName + */ + public void setProvinceName(String provinceName) { + this.provinceName = provinceName == null ? null : provinceName.trim(); + } + + /** + * @return City_Code + */ + public String getCityCode() { + return cityCode; + } + + /** + * @param cityCode + */ + public void setCityCode(String cityCode) { + this.cityCode = cityCode == null ? null : cityCode.trim(); + } + + /** + * @return City_Name + */ + public String getCityName() { + return cityName; + } + + /** + * @param cityName + */ + public void setCityName(String cityName) { + this.cityName = cityName == null ? null : cityName.trim(); + } + + /** + * @return District_Code + */ + public String getDistrictCode() { + return districtCode; + } + + /** + * @param districtCode + */ + public void setDistrictCode(String districtCode) { + this.districtCode = districtCode == null ? null : districtCode.trim(); + } + + /** + * @return District_Name + */ + public String getDistrictName() { + return districtName; + } + + /** + * @param districtName + */ + public void setDistrictName(String districtName) { + this.districtName = districtName == null ? null : districtName.trim(); + } + + /** + * @return Town_Code + */ + public String getTownCode() { + return townCode; + } + + /** + * @param townCode + */ + public void setTownCode(String townCode) { + this.townCode = townCode == null ? null : townCode.trim(); + } + + /** + * @return Town_Name + */ + public String getTownName() { + return townName; + } + + /** + * @param townName + */ + public void setTownName(String townName) { + this.townName = townName == null ? null : townName.trim(); + } + + /** + * 鑾峰彇寮�濮嬫椂闂� + * + * @return Start_Time - 寮�濮嬫椂闂� + */ + public Date getStartTime() { + return startTime; + } + + /** + * 璁剧疆寮�濮嬫椂闂� + * + * @param startTime 寮�濮嬫椂闂� + */ + public void setStartTime(Date startTime) { + this.startTime = startTime; + } + + /** + * 鑾峰彇缁撴潫鏃堕棿 + * + * @return End_Time - 缁撴潫鏃堕棿 + */ + public Date getEndTime() { + return endTime; + } + + /** + * 璁剧疆缁撴潫鏃堕棿 + * + * @param endTime 缁撴潫鏃堕棿 + */ + public void setEndTime(Date endTime) { + this.endTime = endTime; + } + + /** + * 鑾峰彇鍒涘缓鏃堕棿 + * + * @return Create_Time - 鍒涘缓鏃堕棿 + */ + public Date getCreateTime() { + return createTime; + } + + /** + * 璁剧疆鍒涘缓鏃堕棿 + * + * @param createTime 鍒涘缓鏃堕棿 + */ + public void setCreateTime(Date createTime) { + this.createTime = createTime; + } + + /** + * @return Update_Time + */ + public Date getUpdateTime() { + return updateTime; + } + + /** + * @param updateTime + */ + public void setUpdateTime(Date updateTime) { + this.updateTime = updateTime; + } + + /** + * 鑾峰彇鎵╁睍瀛楁1 + * + * @return Extension1 - 鎵╁睍瀛楁1 + */ + public String getExtension1() { + return extension1; + } + + /** + * 璁剧疆鎵╁睍瀛楁1 + * + * @param extension1 鎵╁睍瀛楁1 + */ + public void setExtension1(String extension1) { + this.extension1 = extension1 == null ? null : extension1.trim(); + } + + /** + * 鑾峰彇鎵╁睍瀛楁2 + * + * @return Extension2 - 鎵╁睍瀛楁2 + */ + public String getExtension2() { + return extension2; + } + + /** + * 璁剧疆鎵╁睍瀛楁2 + * + * @param extension2 鎵╁睍瀛楁2 + */ + public void setExtension2(String extension2) { + this.extension2 = extension2 == null ? null : extension2.trim(); + } + + /** + * 鑾峰彇鎵╁睍瀛楁3 + * + * @return Extension3 - 鎵╁睍瀛楁3 + */ + public String getExtension3() { + return extension3; + } + + /** + * 璁剧疆鎵╁睍瀛楁3 + * + * @param extension3 鎵╁睍瀛楁3 + */ + public void setExtension3(String extension3) { + this.extension3 = extension3 == null ? null : extension3.trim(); + } + + /** + * 鑾峰彇澶囨敞 + * + * @return Remark - 澶囨敞 + */ + public String getRemark() { + return remark; + } + + /** + * 璁剧疆澶囨敞 + * + * @param remark 澶囨敞 + */ + public void setRemark(String remark) { + this.remark = remark == null ? null : remark.trim(); + } +} \ No newline at end of file diff --git a/src/main/kotlin/cn/flightfeather/supervision/domain/ds1/entity/DataProductProDetail.java b/src/main/kotlin/cn/flightfeather/supervision/domain/ds1/entity/DataProductProDetail.java new file mode 100644 index 0000000..84778f1 --- /dev/null +++ b/src/main/kotlin/cn/flightfeather/supervision/domain/ds1/entity/DataProductProDetail.java @@ -0,0 +1,753 @@ +package cn.flightfeather.supervision.domain.ds1.entity; + +import java.math.BigDecimal; +import java.util.Date; +import javax.persistence.*; + +@Table(name = "sm_t_data_product_prodetail") +public class DataProductProDetail { + /** + * 涓婚敭ID + */ + @Id + @Column(name = "ID") + private Integer id; + + /** + * 涓棿缁撴灉鍩烘湰淇℃伅ID锛屽熀鏈俊鎭〃澶栭敭ID + */ + @Column(name = "DP_GUID") + private String dpGuid; + + /** + * 琛ㄥ崟缂栧彿 + */ + @Column(name = "Form_Index") + private Integer formIndex; + + /** + * 鍞竴搴忓彿 + */ + @Column(name = "Scene_Index") + private Integer sceneIndex; + + /** + * 鍦烘櫙绫诲瀷 + */ + @Column(name = "Scene_Type") + private String sceneType; + + /** + * 鍦烘櫙鍚嶇О + */ + @Column(name = "Scene_Name") + private String sceneName; + + /** + * 鐩戠鏃堕棿 + */ + @Column(name = "Inspection_Time") + private Date inspectionTime; + + /** + * 宸℃煡浜哄憳 + */ + @Column(name = "Executors") + private String executors; + + /** + * 闂绫诲瀷 + */ + @Column(name = "Problem_Type") + private String problemType; + + /** + * 闂鎻忚堪 + */ + @Column(name = "Problem_Description") + private String problemDescription; + + /** + * 闂浣嶇疆 + */ + @Column(name = "Problem_Location") + private String problemLocation; + + /** + * 闂鏁� + */ + @Column(name = "Problem_Num") + private Integer problemNum; + + /** + * 鏁存敼鏃堕棿 + */ + @Column(name = "Change_Time") + private String changeTime; + + /** + * 鏁存敼鎯呭喌 + */ + @Column(name = "Problem_Changed") + private String problemChanged; + + /** + * 鏁存敼闂 + */ + @Column(name = "Changed_Problem") + private String changedProblem; + + /** + * 鏁存敼鏁� + */ + @Column(name = "Changed_Num") + private Integer changedNum; + + /** + * 鏈暣鏀归棶棰� + */ + @Column(name = "Unchanged_Problems") + private String unchangedProblems; + + /** + * 鏈暣鏀规暟 + */ + @Column(name = "UnChanged_Num") + private Integer unchangedNum; + + /** + * 闂鏁存敼鐜� + */ + @Column(name = "Change_Percent") + private BigDecimal changePercent; + + /** + * 瀹℃牳鎯呭喌 + */ + @Column(name = "Check_Status") + private String checkStatus; + + /** + * 闂瀹℃牳鏃堕棿 + */ + @Column(name = "Pro_Check_Time") + private String proCheckTime; + + /** + * 鏁存敼瀹℃牳鏃堕棿 + */ + @Column(name = "Change_Check_Time") + private String changeCheckTime; + + /** + * 闂瀹℃牳鏁� + */ + @Column(name = "Pro_Check_Num") + private Integer proCheckNum; + + /** + * 闂瀹℃牳鍗犳瘮 + */ + @Column(name = "Pro_Check_Per") + private BigDecimal proCheckPer; + + /** + * 鏁存敼瀹℃牳鏁� + */ + @Column(name = "Change_Check_Num") + private Integer changeCheckNum; + + /** + * 鏁存敼瀹℃牳鍗犳瘮 + */ + @Column(name = "Change_Check_Per") + private BigDecimal changeCheckPer; + + /** + * 鍙拌处鎻愪氦鐧惧垎姣� + */ + @Column(name = "Ledger_Percent") + private BigDecimal ledgerPercent; + + /** + * 鍙拌处鎻愪氦鏃堕棿 + */ + @Column(name = "Ledger_Submit_Date") + private Date ledgerSubmitDate; + + /** + * 鍙拌处瀹℃牳鏃堕棿 + */ + @Column(name = "Ledger_Check_Time") + private Date ledgerCheckTime; + + /** + * 鏁存敼璺熻釜鎻愰啋 + */ + @Column(name = "Change_Tracking_Reminder") + private String changeTrackingReminder; + + /** + * 鍒涘缓鏃堕棿 + */ + @Column(name = "Create_Time") + private Date createTime; + + /** + * 鑾峰彇涓婚敭ID + * + * @return ID - 涓婚敭ID + */ + public Integer getId() { + return id; + } + + /** + * 璁剧疆涓婚敭ID + * + * @param id 涓婚敭ID + */ + public void setId(Integer id) { + this.id = id; + } + + /** + * 鑾峰彇涓棿缁撴灉鍩烘湰淇℃伅ID锛屽熀鏈俊鎭〃澶栭敭ID + * + * @return DP_GUID - 涓棿缁撴灉鍩烘湰淇℃伅ID锛屽熀鏈俊鎭〃澶栭敭ID + */ + public String getDpGuid() { + return dpGuid; + } + + /** + * 璁剧疆涓棿缁撴灉鍩烘湰淇℃伅ID锛屽熀鏈俊鎭〃澶栭敭ID + * + * @param dpGuid 涓棿缁撴灉鍩烘湰淇℃伅ID锛屽熀鏈俊鎭〃澶栭敭ID + */ + public void setDpGuid(String dpGuid) { + this.dpGuid = dpGuid == null ? null : dpGuid.trim(); + } + + /** + * 鑾峰彇琛ㄥ崟缂栧彿 + * + * @return Form_Index - 琛ㄥ崟缂栧彿 + */ + public Integer getFormIndex() { + return formIndex; + } + + /** + * 璁剧疆琛ㄥ崟缂栧彿 + * + * @param formIndex 琛ㄥ崟缂栧彿 + */ + public void setFormIndex(Integer formIndex) { + this.formIndex = formIndex; + } + + /** + * 鑾峰彇鍞竴搴忓彿 + * + * @return Scene_Index - 鍞竴搴忓彿 + */ + public Integer getSceneIndex() { + return sceneIndex; + } + + /** + * 璁剧疆鍞竴搴忓彿 + * + * @param sceneIndex 鍞竴搴忓彿 + */ + public void setSceneIndex(Integer sceneIndex) { + this.sceneIndex = sceneIndex; + } + + /** + * 鑾峰彇鍦烘櫙绫诲瀷 + * + * @return Scene_Type - 鍦烘櫙绫诲瀷 + */ + public String getSceneType() { + return sceneType; + } + + /** + * 璁剧疆鍦烘櫙绫诲瀷 + * + * @param sceneType 鍦烘櫙绫诲瀷 + */ + public void setSceneType(String sceneType) { + this.sceneType = sceneType == null ? null : sceneType.trim(); + } + + /** + * 鑾峰彇鍦烘櫙鍚嶇О + * + * @return Scene_Name - 鍦烘櫙鍚嶇О + */ + public String getSceneName() { + return sceneName; + } + + /** + * 璁剧疆鍦烘櫙鍚嶇О + * + * @param sceneName 鍦烘櫙鍚嶇О + */ + public void setSceneName(String sceneName) { + this.sceneName = sceneName == null ? null : sceneName.trim(); + } + + /** + * 鑾峰彇鐩戠鏃堕棿 + * + * @return Inspection_Time - 鐩戠鏃堕棿 + */ + public Date getInspectionTime() { + return inspectionTime; + } + + /** + * 璁剧疆鐩戠鏃堕棿 + * + * @param inspectionTime 鐩戠鏃堕棿 + */ + public void setInspectionTime(Date inspectionTime) { + this.inspectionTime = inspectionTime; + } + + /** + * 鑾峰彇宸℃煡浜哄憳 + * + * @return Executors - 宸℃煡浜哄憳 + */ + public String getExecutors() { + return executors; + } + + /** + * 璁剧疆宸℃煡浜哄憳 + * + * @param executors 宸℃煡浜哄憳 + */ + public void setExecutors(String executors) { + this.executors = executors == null ? null : executors.trim(); + } + + /** + * 鑾峰彇闂绫诲瀷 + * + * @return Problem_Type - 闂绫诲瀷 + */ + public String getProblemType() { + return problemType; + } + + /** + * 璁剧疆闂绫诲瀷 + * + * @param problemType 闂绫诲瀷 + */ + public void setProblemType(String problemType) { + this.problemType = problemType == null ? null : problemType.trim(); + } + + /** + * 鑾峰彇闂鎻忚堪 + * + * @return Problem_Description - 闂鎻忚堪 + */ + public String getProblemDescription() { + return problemDescription; + } + + /** + * 璁剧疆闂鎻忚堪 + * + * @param problemDescription 闂鎻忚堪 + */ + public void setProblemDescription(String problemDescription) { + this.problemDescription = problemDescription == null ? null : problemDescription.trim(); + } + + /** + * 鑾峰彇闂浣嶇疆 + * + * @return Problem_Location - 闂浣嶇疆 + */ + public String getProblemLocation() { + return problemLocation; + } + + /** + * 璁剧疆闂浣嶇疆 + * + * @param problemLocation 闂浣嶇疆 + */ + public void setProblemLocation(String problemLocation) { + this.problemLocation = problemLocation == null ? null : problemLocation.trim(); + } + + /** + * 鑾峰彇闂鏁� + * + * @return Problem_Num - 闂鏁� + */ + public Integer getProblemNum() { + return problemNum; + } + + /** + * 璁剧疆闂鏁� + * + * @param problemNum 闂鏁� + */ + public void setProblemNum(Integer problemNum) { + this.problemNum = problemNum; + } + + /** + * 鑾峰彇鏁存敼鏃堕棿 + * + * @return Change_Time - 鏁存敼鏃堕棿 + */ + public String getChangeTime() { + return changeTime; + } + + /** + * 璁剧疆鏁存敼鏃堕棿 + * + * @param changeTime 鏁存敼鏃堕棿 + */ + public void setChangeTime(String changeTime) { + this.changeTime = changeTime == null ? null : changeTime.trim(); + } + + /** + * 鑾峰彇鏁存敼鎯呭喌 + * + * @return Problem_Changed - 鏁存敼鎯呭喌 + */ + public String getProblemChanged() { + return problemChanged; + } + + /** + * 璁剧疆鏁存敼鎯呭喌 + * + * @param problemChanged 鏁存敼鎯呭喌 + */ + public void setProblemChanged(String problemChanged) { + this.problemChanged = problemChanged == null ? null : problemChanged.trim(); + } + + /** + * 鑾峰彇鏁存敼闂 + * + * @return Changed_Problem - 鏁存敼闂 + */ + public String getChangedProblem() { + return changedProblem; + } + + /** + * 璁剧疆鏁存敼闂 + * + * @param changedProblem 鏁存敼闂 + */ + public void setChangedProblem(String changedProblem) { + this.changedProblem = changedProblem == null ? null : changedProblem.trim(); + } + + /** + * 鑾峰彇鏁存敼鏁� + * + * @return Changed_Num - 鏁存敼鏁� + */ + public Integer getChangedNum() { + return changedNum; + } + + /** + * 璁剧疆鏁存敼鏁� + * + * @param changedNum 鏁存敼鏁� + */ + public void setChangedNum(Integer changedNum) { + this.changedNum = changedNum; + } + + /** + * 鑾峰彇鏈暣鏀归棶棰� + * + * @return Unchanged_Problems - 鏈暣鏀归棶棰� + */ + public String getUnchangedProblems() { + return unchangedProblems; + } + + /** + * 璁剧疆鏈暣鏀归棶棰� + * + * @param unchangedProblems 鏈暣鏀归棶棰� + */ + public void setUnchangedProblems(String unchangedProblems) { + this.unchangedProblems = unchangedProblems == null ? null : unchangedProblems.trim(); + } + + /** + * 鑾峰彇鏈暣鏀规暟 + * + * @return UnChanged_Num - 鏈暣鏀规暟 + */ + public Integer getUnchangedNum() { + return unchangedNum; + } + + /** + * 璁剧疆鏈暣鏀规暟 + * + * @param unchangedNum 鏈暣鏀规暟 + */ + public void setUnchangedNum(Integer unchangedNum) { + this.unchangedNum = unchangedNum; + } + + /** + * 鑾峰彇闂鏁存敼鐜� + * + * @return Change_Percent - 闂鏁存敼鐜� + */ + public BigDecimal getChangePercent() { + return changePercent; + } + + /** + * 璁剧疆闂鏁存敼鐜� + * + * @param changePercent 闂鏁存敼鐜� + */ + public void setChangePercent(BigDecimal changePercent) { + this.changePercent = changePercent; + } + + /** + * 鑾峰彇瀹℃牳鎯呭喌 + * + * @return Check_Status - 瀹℃牳鎯呭喌 + */ + public String getCheckStatus() { + return checkStatus; + } + + /** + * 璁剧疆瀹℃牳鎯呭喌 + * + * @param checkStatus 瀹℃牳鎯呭喌 + */ + public void setCheckStatus(String checkStatus) { + this.checkStatus = checkStatus == null ? null : checkStatus.trim(); + } + + /** + * 鑾峰彇闂瀹℃牳鏃堕棿 + * + * @return Pro_Check_Time - 闂瀹℃牳鏃堕棿 + */ + public String getProCheckTime() { + return proCheckTime; + } + + /** + * 璁剧疆闂瀹℃牳鏃堕棿 + * + * @param proCheckTime 闂瀹℃牳鏃堕棿 + */ + public void setProCheckTime(String proCheckTime) { + this.proCheckTime = proCheckTime == null ? null : proCheckTime.trim(); + } + + /** + * 鑾峰彇鏁存敼瀹℃牳鏃堕棿 + * + * @return Change_Check_Time - 鏁存敼瀹℃牳鏃堕棿 + */ + public String getChangeCheckTime() { + return changeCheckTime; + } + + /** + * 璁剧疆鏁存敼瀹℃牳鏃堕棿 + * + * @param changeCheckTime 鏁存敼瀹℃牳鏃堕棿 + */ + public void setChangeCheckTime(String changeCheckTime) { + this.changeCheckTime = changeCheckTime == null ? null : changeCheckTime.trim(); + } + + /** + * 鑾峰彇闂瀹℃牳鏁� + * + * @return Pro_Check_Num - 闂瀹℃牳鏁� + */ + public Integer getProCheckNum() { + return proCheckNum; + } + + /** + * 璁剧疆闂瀹℃牳鏁� + * + * @param proCheckNum 闂瀹℃牳鏁� + */ + public void setProCheckNum(Integer proCheckNum) { + this.proCheckNum = proCheckNum; + } + + /** + * 鑾峰彇闂瀹℃牳鍗犳瘮 + * + * @return Pro_Check_Per - 闂瀹℃牳鍗犳瘮 + */ + public BigDecimal getProCheckPer() { + return proCheckPer; + } + + /** + * 璁剧疆闂瀹℃牳鍗犳瘮 + * + * @param proCheckPer 闂瀹℃牳鍗犳瘮 + */ + public void setProCheckPer(BigDecimal proCheckPer) { + this.proCheckPer = proCheckPer; + } + + /** + * 鑾峰彇鏁存敼瀹℃牳鏁� + * + * @return Change_Check_Num - 鏁存敼瀹℃牳鏁� + */ + public Integer getChangeCheckNum() { + return changeCheckNum; + } + + /** + * 璁剧疆鏁存敼瀹℃牳鏁� + * + * @param changeCheckNum 鏁存敼瀹℃牳鏁� + */ + public void setChangeCheckNum(Integer changeCheckNum) { + this.changeCheckNum = changeCheckNum; + } + + /** + * 鑾峰彇鏁存敼瀹℃牳鍗犳瘮 + * + * @return Change_Check_Per - 鏁存敼瀹℃牳鍗犳瘮 + */ + public BigDecimal getChangeCheckPer() { + return changeCheckPer; + } + + /** + * 璁剧疆鏁存敼瀹℃牳鍗犳瘮 + * + * @param changeCheckPer 鏁存敼瀹℃牳鍗犳瘮 + */ + public void setChangeCheckPer(BigDecimal changeCheckPer) { + this.changeCheckPer = changeCheckPer; + } + + /** + * 鑾峰彇鍙拌处鎻愪氦鐧惧垎姣� + * + * @return Ledger_Percent - 鍙拌处鎻愪氦鐧惧垎姣� + */ + public BigDecimal getLedgerPercent() { + return ledgerPercent; + } + + /** + * 璁剧疆鍙拌处鎻愪氦鐧惧垎姣� + * + * @param ledgerPercent 鍙拌处鎻愪氦鐧惧垎姣� + */ + public void setLedgerPercent(BigDecimal ledgerPercent) { + this.ledgerPercent = ledgerPercent; + } + + /** + * 鑾峰彇鍙拌处鎻愪氦鏃堕棿 + * + * @return Ledger_Submit_Date - 鍙拌处鎻愪氦鏃堕棿 + */ + public Date getLedgerSubmitDate() { + return ledgerSubmitDate; + } + + /** + * 璁剧疆鍙拌处鎻愪氦鏃堕棿 + * + * @param ledgerSubmitDate 鍙拌处鎻愪氦鏃堕棿 + */ + public void setLedgerSubmitDate(Date ledgerSubmitDate) { + this.ledgerSubmitDate = ledgerSubmitDate; + } + + /** + * 鑾峰彇鍙拌处瀹℃牳鏃堕棿 + * + * @return Ledger_Check_Time - 鍙拌处瀹℃牳鏃堕棿 + */ + public Date getLedgerCheckTime() { + return ledgerCheckTime; + } + + /** + * 璁剧疆鍙拌处瀹℃牳鏃堕棿 + * + * @param ledgerCheckTime 鍙拌处瀹℃牳鏃堕棿 + */ + public void setLedgerCheckTime(Date ledgerCheckTime) { + this.ledgerCheckTime = ledgerCheckTime; + } + + /** + * 鑾峰彇鏁存敼璺熻釜鎻愰啋 + * + * @return Change_Tracking_Reminder - 鏁存敼璺熻釜鎻愰啋 + */ + public String getChangeTrackingReminder() { + return changeTrackingReminder; + } + + /** + * 璁剧疆鏁存敼璺熻釜鎻愰啋 + * + * @param changeTrackingReminder 鏁存敼璺熻釜鎻愰啋 + */ + public void setChangeTrackingReminder(String changeTrackingReminder) { + this.changeTrackingReminder = changeTrackingReminder == null ? null : changeTrackingReminder.trim(); + } + + /** + * 鑾峰彇鍒涘缓鏃堕棿 + * + * @return Create_Time - 鍒涘缓鏃堕棿 + */ + public Date getCreateTime() { + return createTime; + } + + /** + * 璁剧疆鍒涘缓鏃堕棿 + * + * @param createTime 鍒涘缓鏃堕棿 + */ + public void setCreateTime(Date createTime) { + this.createTime = createTime; + } +} \ No newline at end of file diff --git a/src/main/kotlin/cn/flightfeather/supervision/domain/ds1/entity/DataProductTownProAnalysis.java b/src/main/kotlin/cn/flightfeather/supervision/domain/ds1/entity/DataProductTownProAnalysis.java new file mode 100644 index 0000000..8248465 --- /dev/null +++ b/src/main/kotlin/cn/flightfeather/supervision/domain/ds1/entity/DataProductTownProAnalysis.java @@ -0,0 +1,465 @@ +package cn.flightfeather.supervision.domain.ds1.entity; + +import java.math.BigDecimal; +import java.util.Date; +import javax.persistence.*; + +@Table(name = "sm_t_data_product_townproanalysis") +public class DataProductTownProAnalysis { + /** + * 涓婚敭ID + */ + @Id + @Column(name = "ID") + private Integer id; + + /** + * 涓棿缁撴灉鍩烘湰淇℃伅ID + */ + @Column(name = "DP_GUID") + private String dpGuid; + + /** + * 琛楅晣搴忓彿 + */ + @Column(name = "Form_Index") + private Integer formIndex; + + /** + * 琛楅晣/宸ヤ笟鍖哄悕绉� + */ + @Column(name = "Town_Name") + private String townName; + + /** + * 鍦烘櫙绫诲埆 + */ + @Column(name = "Scene_Type") + private String sceneType; + + /** + * 鍦烘櫙鏁� + */ + @Column(name = "Scene_Count") + private Integer sceneCount; + + /** + * 瀹屽伐銆佹湭鏂藉伐銆佸仠宸ユ垨鍋滀笟銆佸叧闂瓑鍦烘櫙鏁� + */ + @Column(name = "Inactive_Scene_Count") + private Integer inactiveSceneCount; + + /** + * 鏂藉伐涓�佽繍钀ヤ腑鎬绘暟 + */ + @Column(name = "Active_Scene_Count") + private Integer activeSceneCount; + + /** + * 鏁存敼鍗曚綅鏁� + */ + @Column(name = "Change_Scene_Count") + private Integer changeSceneCount; + + /** + * 鏁存敼鍗曚綅鍗犳瘮 + */ + @Column(name = "Change_Scene_Per") + private BigDecimal changeScenePer; + + /** + * 闂鏁� + */ + @Column(name = "Pro_Count") + private Integer proCount; + + /** + * 闂鍗犳瘮 + */ + @Column(name = "Pro_Per") + private BigDecimal proPer; + + /** + * 鏁存敼鏁� + */ + @Column(name = "Change_Count") + private Integer changeCount; + + /** + * 鏁存敼鐜� + */ + @Column(name = "Change_Per") + private BigDecimal changePer; + + /** + * 鏁存敼鍗曚綅姣旀帓鍚� + */ + @Column(name = "Change_Scene_Rank") + private Integer changeSceneRank; + + /** + * 闂鏁存敼鐜囨帓鍚� + */ + @Column(name = "Pro_Change_Rank") + private Integer proChangeRank; + + /** + * 鎷熷垪鍏ラ噸鐐圭洃绠℃暟 + */ + @Column(name = "Focus_Scene_Count") + private Integer focusSceneCount; + + /** + * 鎷熷垪鍏ラ噸鐐圭洃绠″崰姣� + */ + @Column(name = "Focus_Scene_Per") + private BigDecimal focusScenePer; + + /** + * 鍒涘缓鏃堕棿 + */ + @Column(name = "Create_Time") + private Date createTime; + + /** + * 鑾峰彇涓婚敭ID + * + * @return ID - 涓婚敭ID + */ + public Integer getId() { + return id; + } + + /** + * 璁剧疆涓婚敭ID + * + * @param id 涓婚敭ID + */ + public void setId(Integer id) { + this.id = id; + } + + /** + * 鑾峰彇涓棿缁撴灉鍩烘湰淇℃伅ID + * + * @return DP_GUID - 涓棿缁撴灉鍩烘湰淇℃伅ID + */ + public String getDpGuid() { + return dpGuid; + } + + /** + * 璁剧疆涓棿缁撴灉鍩烘湰淇℃伅ID + * + * @param dpGuid 涓棿缁撴灉鍩烘湰淇℃伅ID + */ + public void setDpGuid(String dpGuid) { + this.dpGuid = dpGuid == null ? null : dpGuid.trim(); + } + + /** + * 鑾峰彇琛楅晣搴忓彿 + * + * @return Form_Index - 琛楅晣搴忓彿 + */ + public Integer getFormIndex() { + return formIndex; + } + + /** + * 璁剧疆琛楅晣搴忓彿 + * + * @param formIndex 琛楅晣搴忓彿 + */ + public void setFormIndex(Integer formIndex) { + this.formIndex = formIndex; + } + + /** + * 鑾峰彇琛楅晣/宸ヤ笟鍖哄悕绉� + * + * @return Town_Name - 琛楅晣/宸ヤ笟鍖哄悕绉� + */ + public String getTownName() { + return townName; + } + + /** + * 璁剧疆琛楅晣/宸ヤ笟鍖哄悕绉� + * + * @param townName 琛楅晣/宸ヤ笟鍖哄悕绉� + */ + public void setTownName(String townName) { + this.townName = townName == null ? null : townName.trim(); + } + + /** + * 鑾峰彇鍦烘櫙绫诲埆 + * + * @return Scene_Type - 鍦烘櫙绫诲埆 + */ + public String getSceneType() { + return sceneType; + } + + /** + * 璁剧疆鍦烘櫙绫诲埆 + * + * @param sceneType 鍦烘櫙绫诲埆 + */ + public void setSceneType(String sceneType) { + this.sceneType = sceneType == null ? null : sceneType.trim(); + } + + /** + * 鑾峰彇鍦烘櫙鏁� + * + * @return Scene_Count - 鍦烘櫙鏁� + */ + public Integer getSceneCount() { + return sceneCount; + } + + /** + * 璁剧疆鍦烘櫙鏁� + * + * @param sceneCount 鍦烘櫙鏁� + */ + public void setSceneCount(Integer sceneCount) { + this.sceneCount = sceneCount; + } + + /** + * 鑾峰彇瀹屽伐銆佹湭鏂藉伐銆佸仠宸ユ垨鍋滀笟銆佸叧闂瓑鍦烘櫙鏁� + * + * @return Inactive_Scene_Count - 瀹屽伐銆佹湭鏂藉伐銆佸仠宸ユ垨鍋滀笟銆佸叧闂瓑鍦烘櫙鏁� + */ + public Integer getInactiveSceneCount() { + return inactiveSceneCount; + } + + /** + * 璁剧疆瀹屽伐銆佹湭鏂藉伐銆佸仠宸ユ垨鍋滀笟銆佸叧闂瓑鍦烘櫙鏁� + * + * @param inactiveSceneCount 瀹屽伐銆佹湭鏂藉伐銆佸仠宸ユ垨鍋滀笟銆佸叧闂瓑鍦烘櫙鏁� + */ + public void setInactiveSceneCount(Integer inactiveSceneCount) { + this.inactiveSceneCount = inactiveSceneCount; + } + + /** + * 鑾峰彇鏂藉伐涓�佽繍钀ヤ腑鎬绘暟 + * + * @return Active_Scene_Count - 鏂藉伐涓�佽繍钀ヤ腑鎬绘暟 + */ + public Integer getActiveSceneCount() { + return activeSceneCount; + } + + /** + * 璁剧疆鏂藉伐涓�佽繍钀ヤ腑鎬绘暟 + * + * @param activeSceneCount 鏂藉伐涓�佽繍钀ヤ腑鎬绘暟 + */ + public void setActiveSceneCount(Integer activeSceneCount) { + this.activeSceneCount = activeSceneCount; + } + + /** + * 鑾峰彇鏁存敼鍗曚綅鏁� + * + * @return Change_Scene_Count - 鏁存敼鍗曚綅鏁� + */ + public Integer getChangeSceneCount() { + return changeSceneCount; + } + + /** + * 璁剧疆鏁存敼鍗曚綅鏁� + * + * @param changeSceneCount 鏁存敼鍗曚綅鏁� + */ + public void setChangeSceneCount(Integer changeSceneCount) { + this.changeSceneCount = changeSceneCount; + } + + /** + * 鑾峰彇鏁存敼鍗曚綅鍗犳瘮 + * + * @return Change_Scene_Per - 鏁存敼鍗曚綅鍗犳瘮 + */ + public BigDecimal getChangeScenePer() { + return changeScenePer; + } + + /** + * 璁剧疆鏁存敼鍗曚綅鍗犳瘮 + * + * @param changeScenePer 鏁存敼鍗曚綅鍗犳瘮 + */ + public void setChangeScenePer(BigDecimal changeScenePer) { + this.changeScenePer = changeScenePer; + } + + /** + * 鑾峰彇闂鏁� + * + * @return Pro_Count - 闂鏁� + */ + public Integer getProCount() { + return proCount; + } + + /** + * 璁剧疆闂鏁� + * + * @param proCount 闂鏁� + */ + public void setProCount(Integer proCount) { + this.proCount = proCount; + } + + /** + * 鑾峰彇闂鍗犳瘮 + * + * @return Pro_Per - 闂鍗犳瘮 + */ + public BigDecimal getProPer() { + return proPer; + } + + /** + * 璁剧疆闂鍗犳瘮 + * + * @param proPer 闂鍗犳瘮 + */ + public void setProPer(BigDecimal proPer) { + this.proPer = proPer; + } + + /** + * 鑾峰彇鏁存敼鏁� + * + * @return Change_Count - 鏁存敼鏁� + */ + public Integer getChangeCount() { + return changeCount; + } + + /** + * 璁剧疆鏁存敼鏁� + * + * @param changeCount 鏁存敼鏁� + */ + public void setChangeCount(Integer changeCount) { + this.changeCount = changeCount; + } + + /** + * 鑾峰彇鏁存敼鐜� + * + * @return Change_Per - 鏁存敼鐜� + */ + public BigDecimal getChangePer() { + return changePer; + } + + /** + * 璁剧疆鏁存敼鐜� + * + * @param changePer 鏁存敼鐜� + */ + public void setChangePer(BigDecimal changePer) { + this.changePer = changePer; + } + + /** + * 鑾峰彇鏁存敼鍗曚綅姣旀帓鍚� + * + * @return Change_Scene_Rank - 鏁存敼鍗曚綅姣旀帓鍚� + */ + public Integer getChangeSceneRank() { + return changeSceneRank; + } + + /** + * 璁剧疆鏁存敼鍗曚綅姣旀帓鍚� + * + * @param changeSceneRank 鏁存敼鍗曚綅姣旀帓鍚� + */ + public void setChangeSceneRank(Integer changeSceneRank) { + this.changeSceneRank = changeSceneRank; + } + + /** + * 鑾峰彇闂鏁存敼鐜囨帓鍚� + * + * @return Pro_Change_Rank - 闂鏁存敼鐜囨帓鍚� + */ + public Integer getProChangeRank() { + return proChangeRank; + } + + /** + * 璁剧疆闂鏁存敼鐜囨帓鍚� + * + * @param proChangeRank 闂鏁存敼鐜囨帓鍚� + */ + public void setProChangeRank(Integer proChangeRank) { + this.proChangeRank = proChangeRank; + } + + /** + * 鑾峰彇鎷熷垪鍏ラ噸鐐圭洃绠℃暟 + * + * @return Focus_Scene_Count - 鎷熷垪鍏ラ噸鐐圭洃绠℃暟 + */ + public Integer getFocusSceneCount() { + return focusSceneCount; + } + + /** + * 璁剧疆鎷熷垪鍏ラ噸鐐圭洃绠℃暟 + * + * @param focusSceneCount 鎷熷垪鍏ラ噸鐐圭洃绠℃暟 + */ + public void setFocusSceneCount(Integer focusSceneCount) { + this.focusSceneCount = focusSceneCount; + } + + /** + * 鑾峰彇鎷熷垪鍏ラ噸鐐圭洃绠″崰姣� + * + * @return Focus_Scene_Per - 鎷熷垪鍏ラ噸鐐圭洃绠″崰姣� + */ + public BigDecimal getFocusScenePer() { + return focusScenePer; + } + + /** + * 璁剧疆鎷熷垪鍏ラ噸鐐圭洃绠″崰姣� + * + * @param focusScenePer 鎷熷垪鍏ラ噸鐐圭洃绠″崰姣� + */ + public void setFocusScenePer(BigDecimal focusScenePer) { + this.focusScenePer = focusScenePer; + } + + /** + * 鑾峰彇鍒涘缓鏃堕棿 + * + * @return Create_Time - 鍒涘缓鏃堕棿 + */ + public Date getCreateTime() { + return createTime; + } + + /** + * 璁剧疆鍒涘缓鏃堕棿 + * + * @param createTime 鍒涘缓鏃堕棿 + */ + public void setCreateTime(Date createTime) { + this.createTime = createTime; + } +} \ No newline at end of file diff --git a/src/main/kotlin/cn/flightfeather/supervision/domain/ds1/mapper/DataProductMapper.java b/src/main/kotlin/cn/flightfeather/supervision/domain/ds1/mapper/DataProductMapper.java new file mode 100644 index 0000000..f120443 --- /dev/null +++ b/src/main/kotlin/cn/flightfeather/supervision/domain/ds1/mapper/DataProductMapper.java @@ -0,0 +1,7 @@ +package cn.flightfeather.supervision.domain.ds1.mapper; + +import cn.flightfeather.supervision.domain.ds1.entity.DataProduct; +import tk.mybatis.mapper.common.Mapper; + +public interface DataProductMapper extends Mapper<DataProduct> { +} \ No newline at end of file diff --git a/src/main/kotlin/cn/flightfeather/supervision/domain/ds1/mapper/DataProductProDetailMapper.kt b/src/main/kotlin/cn/flightfeather/supervision/domain/ds1/mapper/DataProductProDetailMapper.kt new file mode 100644 index 0000000..2e86083 --- /dev/null +++ b/src/main/kotlin/cn/flightfeather/supervision/domain/ds1/mapper/DataProductProDetailMapper.kt @@ -0,0 +1,8 @@ +package cn.flightfeather.supervision.domain.ds1.mapper + +import cn.flightfeather.supervision.domain.ds1.entity.DataProductProDetail +import tk.mybatis.mapper.common.Mapper + +interface DataProductProDetailMapper : Mapper<DataProductProDetail> { + fun insertBatch(list: List<DataProductProDetail>) +} \ No newline at end of file diff --git a/src/main/kotlin/cn/flightfeather/supervision/domain/ds1/mapper/DataProductTownProAnalysisMapper.kt b/src/main/kotlin/cn/flightfeather/supervision/domain/ds1/mapper/DataProductTownProAnalysisMapper.kt new file mode 100644 index 0000000..f1e2f78 --- /dev/null +++ b/src/main/kotlin/cn/flightfeather/supervision/domain/ds1/mapper/DataProductTownProAnalysisMapper.kt @@ -0,0 +1,8 @@ +package cn.flightfeather.supervision.domain.ds1.mapper + +import cn.flightfeather.supervision.domain.ds1.entity.DataProductTownProAnalysis +import tk.mybatis.mapper.common.Mapper + +interface DataProductTownProAnalysisMapper : Mapper<DataProductTownProAnalysis> { + fun insertBatch(list: List<DataProductTownProAnalysis>) +} \ No newline at end of file diff --git a/src/main/kotlin/cn/flightfeather/supervision/domain/ds1/repository/DataProductRep.kt b/src/main/kotlin/cn/flightfeather/supervision/domain/ds1/repository/DataProductRep.kt new file mode 100644 index 0000000..bd282a9 --- /dev/null +++ b/src/main/kotlin/cn/flightfeather/supervision/domain/ds1/repository/DataProductRep.kt @@ -0,0 +1,74 @@ +package cn.flightfeather.supervision.domain.ds1.repository + +import cn.flightfeather.supervision.common.utils.Constant +import cn.flightfeather.supervision.domain.ds1.entity.* +import cn.flightfeather.supervision.domain.ds1.mapper.* +import org.apache.commons.lang3.ObjectUtils +import org.springframework.stereotype.Repository +import tk.mybatis.mapper.entity.Example +import java.util.* + +@Repository +class DataProductRep( + private val dataProductMapper: DataProductMapper, + private val dataProductProDetailMapper: DataProductProDetailMapper, + private val dataProductTownProAnalysisMapper: DataProductTownProAnalysisMapper, + private val provinceMapper: ProvinceMapper, + private val townMapper: TownMapper, + private val cityMapper: CityMapper, + private val districtMapper: DistrictMapper + +) { + + /** + * 鎻掑叆鏁版嵁浜у搧涓棿缁撴灉鍩烘湰淇℃伅鍜屽叿浣撲俊鎭� + */ + fun insertDataProduct(dataProduct: DataProduct, specificEntities: List<Any>) { + // 鏍规嵁绫诲瀷鎻掑叆鎸囧畾鏁版嵁搴撹〃 + if (!ObjectUtils.isEmpty(specificEntities)) { + when (specificEntities.first()::class) { + DataProductProDetail::class -> { + (specificEntities as? List<DataProductProDetail>)?.let { let_it -> + specificEntities.forEach { for_it -> + for_it.dpGuid = dataProduct.guid + } + dataProduct.typeId = Constant.DataProductType.PRO_DETAIL_SUMMARY.value + dataProductProDetailMapper.insertBatch(let_it) + } + } + DataProductTownProAnalysis::class -> { + (specificEntities as? List<DataProductTownProAnalysis>)?.let { let_it -> + specificEntities.forEach { for_it -> + for_it.dpGuid = dataProduct.guid + } + dataProduct.typeId = Constant.DataProductType.PRO_ANALYSIS_SUMMARY.value + dataProductTownProAnalysisMapper.insertBatch(let_it) + } + } + } + } + // 琛屾斂鍖哄煙name濉厖 + if (dataProduct.townCode != null) { + townMapper.selectByExample(Example(Town::class.java).apply { + createCriteria().andEqualTo("towncode", dataProduct.townCode) + })?.takeIf { it.isNotEmpty() }?.get(0)?.let { dataProduct.townName = it.townname ?: "" } + } + if (dataProduct.provinceCode != null) { + provinceMapper.selectByExample(Example(Province::class.java).apply { + createCriteria().andEqualTo("provincecode", dataProduct.provinceCode) + })?.takeIf { it.isNotEmpty() }?.get(0)?.let { dataProduct.provinceName = it.provincename ?: "" } + } + if (dataProduct.cityCode != null) { + cityMapper.selectByExample(Example(City::class.java).apply { + createCriteria().andEqualTo("citycode", dataProduct.cityCode) + })?.takeIf { it.isNotEmpty() }?.get(0)?.let { dataProduct.cityName = it.cityname ?: "" } + } + if (dataProduct.districtCode != null) { + districtMapper.selectByExample(Example(District::class.java).apply { + createCriteria().andEqualTo("districtcode", dataProduct.districtCode) + })?.takeIf { it.isNotEmpty() }?.get(0)?.let { dataProduct.districtName = it.districtname ?: "" } + } + dataProduct.createTime = Date() + dataProductMapper.insert(dataProduct) + } +} \ No newline at end of file diff --git a/src/main/resources/mapper/ds1/DataProductMapper.xml b/src/main/resources/mapper/ds1/DataProductMapper.xml new file mode 100644 index 0000000..dfdec35 --- /dev/null +++ b/src/main/resources/mapper/ds1/DataProductMapper.xml @@ -0,0 +1,37 @@ +<?xml version="1.0" encoding="UTF-8" ?> +<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" > +<mapper namespace="cn.flightfeather.supervision.domain.ds1.mapper.DataProductMapper" > + <resultMap id="BaseResultMap" type="cn.flightfeather.supervision.domain.ds1.entity.DataProduct" > + <!-- + WARNING - @mbg.generated + --> + <id column="GUID" property="guid" jdbcType="VARCHAR" /> + <result column="Type_ID" property="typeId" jdbcType="TINYINT" /> + <result column="Task_GUID" property="taskGuid" jdbcType="VARCHAR" /> + <result column="Scene_Type_ID" property="sceneTypeId" jdbcType="TINYINT" /> + <result column="Province_Code" property="provinceCode" jdbcType="VARCHAR" /> + <result column="Province_Name" property="provinceName" jdbcType="VARCHAR" /> + <result column="City_Code" property="cityCode" jdbcType="VARCHAR" /> + <result column="City_Name" property="cityName" jdbcType="VARCHAR" /> + <result column="District_Code" property="districtCode" jdbcType="VARCHAR" /> + <result column="District_Name" property="districtName" jdbcType="VARCHAR" /> + <result column="Town_Code" property="townCode" jdbcType="VARCHAR" /> + <result column="Town_Name" property="townName" jdbcType="VARCHAR" /> + <result column="Start_Time" property="startTime" jdbcType="TIMESTAMP" /> + <result column="End_Time" property="endTime" jdbcType="TIMESTAMP" /> + <result column="Create_Time" property="createTime" jdbcType="TIMESTAMP" /> + <result column="Update_Time" property="updateTime" jdbcType="TIMESTAMP" /> + <result column="Extension1" property="extension1" jdbcType="VARCHAR" /> + <result column="Extension2" property="extension2" jdbcType="VARCHAR" /> + <result column="Extension3" property="extension3" jdbcType="VARCHAR" /> + <result column="Remark" property="remark" jdbcType="VARCHAR" /> + </resultMap> + <sql id="Base_Column_List" > + <!-- + WARNING - @mbg.generated + --> + GUID, Type_ID, Task_GUID, Scene_Type_ID, Province_Code, Province_Name, City_Code, + City_Name, District_Code, District_Name, Town_Code, Town_Name, Start_Time, End_Time, + Create_Time, Update_Time, Extension1, Extension2, Extension3, Remark + </sql> +</mapper> \ No newline at end of file diff --git a/src/main/resources/mapper/ds1/DataProductProDetailMapper.xml b/src/main/resources/mapper/ds1/DataProductProDetailMapper.xml new file mode 100644 index 0000000..2ac3127 --- /dev/null +++ b/src/main/resources/mapper/ds1/DataProductProDetailMapper.xml @@ -0,0 +1,100 @@ +<?xml version="1.0" encoding="UTF-8" ?> +<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" > +<mapper namespace="cn.flightfeather.supervision.domain.ds1.mapper.DataProductProDetailMapper" > + <resultMap id="BaseResultMap" type="cn.flightfeather.supervision.domain.ds1.entity.DataProductProDetail" > + <!-- + WARNING - @mbg.generated + --> + <id column="ID" property="id" jdbcType="INTEGER" /> + <result column="DP_GUID" property="dpGuid" jdbcType="VARCHAR" /> + <result column="Form_Index" property="formIndex" jdbcType="INTEGER" /> + <result column="Scene_Index" property="sceneIndex" jdbcType="INTEGER" /> + <result column="Scene_Type" property="sceneType" jdbcType="VARCHAR" /> + <result column="Scene_Name" property="sceneName" jdbcType="VARCHAR" /> + <result column="Inspection_Time" property="inspectionTime" jdbcType="TIMESTAMP" /> + <result column="Executors" property="executors" jdbcType="VARCHAR" /> + <result column="Problem_Type" property="problemType" jdbcType="VARCHAR" /> + <result column="Problem_Description" property="problemDescription" jdbcType="VARCHAR" /> + <result column="Problem_Location" property="problemLocation" jdbcType="VARCHAR" /> + <result column="Problem_Num" property="problemNum" jdbcType="INTEGER" /> + <result column="Change_Time" property="changeTime" jdbcType="VARCHAR" /> + <result column="Problem_Changed" property="problemChanged" jdbcType="VARCHAR" /> + <result column="Changed_Problem" property="changedProblem" jdbcType="VARCHAR" /> + <result column="Changed_Num" property="changedNum" jdbcType="INTEGER" /> + <result column="Unchanged_Problems" property="unchangedProblems" jdbcType="VARCHAR" /> + <result column="UnChanged_Num" property="unchangedNum" jdbcType="INTEGER" /> + <result column="Change_Percent" property="changePercent" jdbcType="DECIMAL" /> + <result column="Check_Status" property="checkStatus" jdbcType="VARCHAR" /> + <result column="Pro_Check_Time" property="proCheckTime" jdbcType="VARCHAR" /> + <result column="Change_Check_Time" property="changeCheckTime" jdbcType="VARCHAR" /> + <result column="Pro_Check_Num" property="proCheckNum" jdbcType="INTEGER" /> + <result column="Pro_Check_Per" property="proCheckPer" jdbcType="DECIMAL" /> + <result column="Change_Check_Num" property="changeCheckNum" jdbcType="INTEGER" /> + <result column="Change_Check_Per" property="changeCheckPer" jdbcType="DECIMAL" /> + <result column="Ledger_Percent" property="ledgerPercent" jdbcType="DECIMAL" /> + <result column="Ledger_Submit_Date" property="ledgerSubmitDate" jdbcType="TIMESTAMP" /> + <result column="Ledger_Check_Time" property="ledgerCheckTime" jdbcType="TIMESTAMP" /> + <result column="Change_Tracking_Reminder" property="changeTrackingReminder" jdbcType="VARCHAR" /> + <result column="Create_Time" property="createTime" jdbcType="TIMESTAMP" /> + </resultMap> + <sql id="Base_Column_List" > + <!-- + WARNING - @mbg.generated + --> + ID, DP_GUID, Form_Index, Scene_Index, Scene_Type, Scene_Name, Inspection_Time, Executors, + Problem_Type, Problem_Description, Problem_Location, Problem_Num, Change_Time, Problem_Changed, + Changed_Problem, Changed_Num, Unchanged_Problems, UnChanged_Num, Change_Percent, + Check_Status, Pro_Check_Time, Change_Check_Time, Pro_Check_Num, Pro_Check_Per, Change_Check_Num, + Change_Check_Per, Ledger_Percent, Ledger_Submit_Date, Ledger_Check_Time, Change_Tracking_Reminder, + Create_Time + </sql> + + <sql id="Base_Column_List_Without_ID" > + <!-- + WARNING - @mbg.generated + --> + DP_GUID, Form_Index, Scene_Index, Scene_Type, Scene_Name, Inspection_Time, Executors, + Problem_Type, Problem_Description, Problem_Location, Problem_Num, Change_Time, Problem_Changed, + Changed_Problem, Changed_Num, Unchanged_Problems, UnChanged_Num, Change_Percent, + Check_Status, Pro_Check_Time, Change_Check_Time, Pro_Check_Num, Pro_Check_Per, Change_Check_Num, + Change_Check_Per, Ledger_Percent, Ledger_Submit_Date, Ledger_Check_Time, Change_Tracking_Reminder, + Create_Time + </sql> + <insert id="insertBatch" parameterType="java.util.List"> + INSERT INTO sm_t_data_product_prodetail + ( <include refid="Base_Column_List_Without_ID" /> ) + VALUES + <foreach collection="list" item="item" separator=","> + (#{item.dpGuid,jdbcType=VARCHAR}, + #{item.formIndex,jdbcType=INTEGER}, + #{item.sceneIndex,jdbcType=INTEGER}, + #{item.sceneType,jdbcType=VARCHAR}, + #{item.sceneName,jdbcType=VARCHAR}, + #{item.inspectionTime,jdbcType=TIMESTAMP}, + #{item.executors,jdbcType=VARCHAR}, + #{item.problemType,jdbcType=VARCHAR}, + #{item.problemDescription,jdbcType=VARCHAR}, + #{item.problemLocation,jdbcType=VARCHAR}, + #{item.problemNum,jdbcType=INTEGER}, + #{item.changeTime,jdbcType=VARCHAR}, + #{item.problemChanged,jdbcType=VARCHAR}, + #{item.changedProblem,jdbcType=VARCHAR}, + #{item.changedNum,jdbcType=INTEGER}, + #{item.unchangedProblems,jdbcType=VARCHAR}, + #{item.unchangedNum,jdbcType=INTEGER}, + #{item.changePercent,jdbcType=DECIMAL}, + #{item.checkStatus,jdbcType=VARCHAR}, + #{item.proCheckTime,jdbcType=VARCHAR}, + #{item.changeCheckTime,jdbcType=VARCHAR}, + #{item.proCheckNum,jdbcType=INTEGER}, + #{item.proCheckPer,jdbcType=DECIMAL}, + #{item.changeCheckNum,jdbcType=INTEGER}, + #{item.changeCheckPer,jdbcType=DECIMAL}, + #{item.ledgerPercent,jdbcType=DECIMAL}, + #{item.ledgerSubmitDate,jdbcType=TIMESTAMP}, + #{item.ledgerCheckTime,jdbcType=TIMESTAMP}, + #{item.changeTrackingReminder,jdbcType=VARCHAR}, + #{item.createTime,jdbcType=TIMESTAMP}) + </foreach> + </insert> +</mapper> \ No newline at end of file diff --git a/src/main/resources/mapper/ds1/DataProductTownProAnalysisMapper.xml b/src/main/resources/mapper/ds1/DataProductTownProAnalysisMapper.xml new file mode 100644 index 0000000..0fcbcd7 --- /dev/null +++ b/src/main/resources/mapper/ds1/DataProductTownProAnalysisMapper.xml @@ -0,0 +1,72 @@ +<?xml version="1.0" encoding="UTF-8" ?> +<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" > +<mapper namespace="cn.flightfeather.supervision.domain.ds1.mapper.DataProductTownProAnalysisMapper" > + <resultMap id="BaseResultMap" type="cn.flightfeather.supervision.domain.ds1.entity.DataProductTownProAnalysis" > + <!-- + WARNING - @mbg.generated + --> + <id column="ID" property="id" jdbcType="INTEGER" /> + <result column="DP_GUID" property="dpGuid" jdbcType="VARCHAR" /> + <result column="Form_Index" property="formIndex" jdbcType="INTEGER" /> + <result column="Town_Name" property="townName" jdbcType="VARCHAR" /> + <result column="Scene_Type" property="sceneType" jdbcType="VARCHAR" /> + <result column="Scene_Count" property="sceneCount" jdbcType="INTEGER" /> + <result column="Inactive_Scene_Count" property="inactiveSceneCount" jdbcType="INTEGER" /> + <result column="Active_Scene_Count" property="activeSceneCount" jdbcType="INTEGER" /> + <result column="Change_Scene_Count" property="changeSceneCount" jdbcType="INTEGER" /> + <result column="Change_Scene_Per" property="changeScenePer" jdbcType="DECIMAL" /> + <result column="Pro_Count" property="proCount" jdbcType="INTEGER" /> + <result column="Pro_Per" property="proPer" jdbcType="DECIMAL" /> + <result column="Change_Count" property="changeCount" jdbcType="INTEGER" /> + <result column="Change_Per" property="changePer" jdbcType="DECIMAL" /> + <result column="Change_Scene_Rank" property="changeSceneRank" jdbcType="INTEGER" /> + <result column="Pro_Change_Rank" property="proChangeRank" jdbcType="INTEGER" /> + <result column="Focus_Scene_Count" property="focusSceneCount" jdbcType="INTEGER" /> + <result column="Focus_Scene_Per" property="focusScenePer" jdbcType="DECIMAL" /> + <result column="Create_Time" property="createTime" jdbcType="TIMESTAMP" /> + </resultMap> + <sql id="Base_Column_List" > + <!-- + WARNING - @mbg.generated + --> + ID, DP_GUID, Form_Index, Town_Name, Scene_Type, Scene_Count, Inactive_Scene_Count, + Active_Scene_Count, Change_Scene_Count, Change_Scene_Per, Pro_Count, Pro_Per, Change_Count, + Change_Per, Change_Scene_Rank, Pro_Change_Rank, Focus_Scene_Count, Focus_Scene_Per, + Create_Time + </sql> + + <sql id="Base_Column_List_Without_ID" > + <!-- + WARNING - @mbg.generated + --> + DP_GUID, Form_Index, Town_Name, Scene_Type, Scene_Count, Inactive_Scene_Count, + Active_Scene_Count, Change_Scene_Count, Change_Scene_Per, Pro_Count, Pro_Per, Change_Count, + Change_Per, Change_Scene_Rank, Pro_Change_Rank, Focus_Scene_Count, Focus_Scene_Per, + Create_Time + </sql> + <insert id="insertBatch" parameterType="java.util.List"> + INSERT INTO sm_t_data_product_townproanalysis + ( <include refid="Base_Column_List_Without_ID" /> ) + VALUES + <foreach collection="list" item="item" index="index" separator=","> + ( #{item.dpGuid,jdbcType=VARCHAR}, + #{item.formIndex,jdbcType=INTEGER}, + #{item.townName,jdbcType=VARCHAR}, + #{item.sceneType,jdbcType=VARCHAR}, + #{item.sceneCount,jdbcType=INTEGER}, + #{item.inactiveSceneCount,jdbcType=INTEGER}, + #{item.activeSceneCount,jdbcType=INTEGER}, + #{item.changeSceneCount,jdbcType=INTEGER}, + #{item.changeScenePer,jdbcType=DECIMAL}, + #{item.proCount,jdbcType=INTEGER}, + #{item.proPer,jdbcType=DECIMAL}, + #{item.changeCount,jdbcType=INTEGER}, + #{item.changePer,jdbcType=DECIMAL}, + #{item.changeSceneRank,jdbcType=INTEGER}, + #{item.proChangeRank,jdbcType=INTEGER}, + #{item.focusSceneCount,jdbcType=INTEGER}, + #{item.focusScenePer,jdbcType=DECIMAL}, + #{item.createTime,jdbcType=TIMESTAMP}) + </foreach> + </insert> +</mapper> \ No newline at end of file -- Gitblit v1.9.3