pom.xml
@@ -468,6 +468,7 @@ <artifactId>mapper</artifactId> <version>3.3.9</version> </dependency> <!-- 2025.10.17 å¼å ¥èªå®ä¹æä»¶ï¼ ç¨äºå¨çææ°æ®åºè¡¨æ¨¡åæ¶ï¼èªå¨æ·»å swaggerç@ApiModel注解 --> <dependency> <groupId>cn.flight.feather.devtool</groupId> <artifactId>mybatis-plugin</artifactId> src/main/kotlin/cn/flightfeather/supervision/domain/ds1/entity/DataProductBase.java
@@ -73,6 +73,13 @@ private Byte dpbSceneTypeId; /** * æ°æ®äº§åçæ¬å·ï¼ä»1å¼å§çèªç¶æ°ï¼æ°åè¶å¤§ï¼çæ¬è¶æ° */ @Column(name = "DPB_Version") @ApiModelProperty(value = "æ°æ®äº§åçæ¬å·ï¼ä»1å¼å§çèªç¶æ°ï¼æ°åè¶å¤§ï¼çæ¬è¶æ°") private Integer dpbVersion; /** * æ°æ®äº§åå 容 */ @Column(name = "DPB_Content") @@ -242,6 +249,24 @@ } /** * è·åæ°æ®äº§åçæ¬å·ï¼ä»1å¼å§çèªç¶æ°ï¼æ°åè¶å¤§ï¼çæ¬è¶æ° * * @return DPB_Version - æ°æ®äº§åçæ¬å·ï¼ä»1å¼å§çèªç¶æ°ï¼æ°åè¶å¤§ï¼çæ¬è¶æ° */ public Integer getDpbVersion() { return dpbVersion; } /** * è®¾ç½®æ°æ®äº§åçæ¬å·ï¼ä»1å¼å§çèªç¶æ°ï¼æ°åè¶å¤§ï¼çæ¬è¶æ° * * @param dpbVersion æ°æ®äº§åçæ¬å·ï¼ä»1å¼å§çèªç¶æ°ï¼æ°åè¶å¤§ï¼çæ¬è¶æ° */ public void setDpbVersion(Integer dpbVersion) { this.dpbVersion = dpbVersion; } /** * è·åæ°æ®äº§åå 容 * * @return DPB_Content - æ°æ®äº§åå 容 src/main/kotlin/cn/flightfeather/supervision/domain/ds1/entity/DataProductFinal.java
@@ -73,6 +73,13 @@ private Byte dpfSceneTypeId; /** * æ°æ®äº§åçæ¬å·ï¼ä»1å¼å§çèªç¶æ°ï¼æ°åè¶å¤§ï¼çæ¬è¶æ° */ @Column(name = "DPF_Version") @ApiModelProperty(value = "æ°æ®äº§åçæ¬å·ï¼ä»1å¼å§çèªç¶æ°ï¼æ°åè¶å¤§ï¼çæ¬è¶æ°") private Integer dpfVersion; /** * æ°æ®äº§åå 容 */ @Column(name = "DPF_Content") @@ -242,6 +249,24 @@ } /** * è·åæ°æ®äº§åçæ¬å·ï¼ä»1å¼å§çèªç¶æ°ï¼æ°åè¶å¤§ï¼çæ¬è¶æ° * * @return DPF_Version - æ°æ®äº§åçæ¬å·ï¼ä»1å¼å§çèªç¶æ°ï¼æ°åè¶å¤§ï¼çæ¬è¶æ° */ public Integer getDpfVersion() { return dpfVersion; } /** * è®¾ç½®æ°æ®äº§åçæ¬å·ï¼ä»1å¼å§çèªç¶æ°ï¼æ°åè¶å¤§ï¼çæ¬è¶æ° * * @param dpfVersion æ°æ®äº§åçæ¬å·ï¼ä»1å¼å§çèªç¶æ°ï¼æ°åè¶å¤§ï¼çæ¬è¶æ° */ public void setDpfVersion(Integer dpfVersion) { this.dpfVersion = dpfVersion; } /** * è·åæ°æ®äº§åå 容 * * @return DPF_Content - æ°æ®äº§åå 容 src/main/kotlin/cn/flightfeather/supervision/domain/ds1/entity/DataProductMiddle.java
@@ -73,6 +73,13 @@ private Byte dpmSceneTypeId; /** * æ°æ®äº§åçæ¬å·ï¼ä»1å¼å§çèªç¶æ°ï¼æ°åè¶å¤§ï¼çæ¬è¶æ° */ @Column(name = "DPM_Version") @ApiModelProperty(value = "æ°æ®äº§åçæ¬å·ï¼ä»1å¼å§çèªç¶æ°ï¼æ°åè¶å¤§ï¼çæ¬è¶æ°") private Integer dpmVersion; /** * æ°æ®äº§åå 容 */ @Column(name = "DPM_Content") @@ -242,6 +249,24 @@ } /** * è·åæ°æ®äº§åçæ¬å·ï¼ä»1å¼å§çèªç¶æ°ï¼æ°åè¶å¤§ï¼çæ¬è¶æ° * * @return DPM_Version - æ°æ®äº§åçæ¬å·ï¼ä»1å¼å§çèªç¶æ°ï¼æ°åè¶å¤§ï¼çæ¬è¶æ° */ public Integer getDpmVersion() { return dpmVersion; } /** * è®¾ç½®æ°æ®äº§åçæ¬å·ï¼ä»1å¼å§çèªç¶æ°ï¼æ°åè¶å¤§ï¼çæ¬è¶æ° * * @param dpmVersion æ°æ®äº§åçæ¬å·ï¼ä»1å¼å§çèªç¶æ°ï¼æ°åè¶å¤§ï¼çæ¬è¶æ° */ public void setDpmVersion(Integer dpmVersion) { this.dpmVersion = dpmVersion; } /** * è·åæ°æ®äº§åå 容 * * @return DPM_Content - æ°æ®äº§åå 容 src/main/kotlin/cn/flightfeather/supervision/domain/ds1/repository/DataProductRep.kt
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,31 @@ package cn.flightfeather.supervision.domain.ds1.repository import cn.flightfeather.supervision.domain.ds1.mapper.DataProductBaseMapper import cn.flightfeather.supervision.domain.ds1.mapper.DataProductFinalMapper import cn.flightfeather.supervision.domain.ds1.mapper.DataProductMiddleMapper import org.springframework.stereotype.Repository /** * æ°æ®äº§åæ°æ®åºæ¥è¯¢ * @date 2025/10/17 * @author feiyu02 */ @Repository class DataProductRep( private val dataProductBaseMapper: DataProductBaseMapper, private val dataProductMiddleMapper: DataProductMiddleMapper, private val dataProductFinalMapper: DataProductFinalMapper ) { /** * æå ¥æ°æ®äº§å */ fun insertDataProduct() { } fun selectDataProduct() { } } src/main/kotlin/cn/flightfeather/supervision/lightshare/service/DataProdBaseService.kt
@@ -1,6 +1,10 @@ package cn.flightfeather.supervision.lightshare.service import cn.flightfeather.supervision.lightshare.vo.dataprod.* import cn.flightfeather.supervision.lightshare.vo.dataprod.base.DPEvaluateInfo import cn.flightfeather.supervision.lightshare.vo.dataprod.base.DPInspectionInfo import cn.flightfeather.supervision.lightshare.vo.dataprod.base.DPMonitorDataInfo import cn.flightfeather.supervision.lightshare.vo.dataprod.base.DPSceneInfo /** * åºç¡æ°æ®äº§åæå¡æ¥å£ src/main/kotlin/cn/flightfeather/supervision/lightshare/service/DataProdSingleSceneService.kt
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,28 @@ package cn.flightfeather.supervision.lightshare.service import cn.flightfeather.supervision.lightshare.vo.dataprod.DPChangeInfo import cn.flightfeather.supervision.lightshare.vo.dataprod.DPProblemRecurrence import cn.flightfeather.supervision.lightshare.vo.dataprod.QueryOptSingle /** * ååºæ¯çºµåæ°æ®ç»è®¡äº§åæå¡æ¥å£ * @date 2025/10/30 * @author feiyu02 */ interface DataProdSingleSceneService { /** * æ´æ¹æ åµ */ fun getChangeInfo(option: QueryOptSingle): DPChangeInfo /** * æ¹éæ¥è¯¢æ´æ¹æ åµ */ fun getChangeInfoList(options: List<QueryOptSingle>): List<DPChangeInfo> /** * é®é¢é夿 åµ */ fun getProblemRecurrence(option: QueryOptSingle): List<DPProblemRecurrence> } src/main/kotlin/cn/flightfeather/supervision/lightshare/service/ScenseService.kt
@@ -38,9 +38,9 @@ fun getSceneByToken(token: String, page: Int? = 1, perPage: Int? = 30): BaseResponse<BaseSearchResultVo> fun getSceneDetail(sceneId: String):BaseResponse<SceneDetail> fun getSceneDetail(sceneId: String):SceneDetail fun updateSceneDetail(typeId: Int, sceneDetailStr: SceneDetailStr): BaseResponse<String> fun updateSceneDetail(typeId: Int, sceneDetailStr: SceneDetailStr): String fun searchScene(areaVo: AreaVo, page: Int?, perPage: Int?): BaseResponse<List<Scense>> src/main/kotlin/cn/flightfeather/supervision/lightshare/service/impl/DataProdBaseServiceImpl.kt
@@ -7,6 +7,10 @@ import cn.flightfeather.supervision.lightshare.service.DataProdBaseService import cn.flightfeather.supervision.lightshare.vo.ProblemListVo import cn.flightfeather.supervision.lightshare.vo.dataprod.* import cn.flightfeather.supervision.lightshare.vo.dataprod.base.DPEvaluateInfo import cn.flightfeather.supervision.lightshare.vo.dataprod.base.DPInspectionInfo import cn.flightfeather.supervision.lightshare.vo.dataprod.base.DPMonitorDataInfo import cn.flightfeather.supervision.lightshare.vo.dataprod.base.DPSceneInfo import org.springframework.beans.BeanUtils import org.springframework.stereotype.Service import tk.mybatis.mapper.entity.Example src/main/kotlin/cn/flightfeather/supervision/lightshare/service/impl/DataProdSingleSceneServiceImpl.kt
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,110 @@ package cn.flightfeather.supervision.lightshare.service.impl import cn.flightfeather.supervision.business.autooutput.datasource.AopDbMapper import cn.flightfeather.supervision.common.utils.QueryByCache import cn.flightfeather.supervision.domain.ds1.entity.Problemlist import cn.flightfeather.supervision.domain.ds1.entity.Problemtype import cn.flightfeather.supervision.domain.ds1.entity.Subtask import cn.flightfeather.supervision.lightshare.service.DataProdSingleSceneService import cn.flightfeather.supervision.lightshare.vo.ProblemListVo import cn.flightfeather.supervision.lightshare.vo.dataprod.DPChangeInfo import cn.flightfeather.supervision.lightshare.vo.dataprod.DPProblemRecurrence import cn.flightfeather.supervision.lightshare.vo.dataprod.QueryOptSingle import cn.flightfeather.supervision.lightshare.vo.dataprod.base.DPInspectionInfo import org.springframework.beans.BeanUtils import org.springframework.stereotype.Service import tk.mybatis.mapper.entity.Example /** * ååºæ¯çºµåæ°æ®ç»è®¡äº§åæå¡å®ç°ç±» * @date 2025/10/30 * @author feiyu02 */ @Service class DataProdSingleSceneServiceImpl(private val aopDbMapper: AopDbMapper) : DataProdSingleSceneService { // æ´æ¹è¦æ±æå¤§èæ¶ï¼å¤©ï¼ private val maxChangeTime = 3 override fun getChangeInfo(option: QueryOptSingle): DPChangeInfo { return QueryByCache.queryCache( cache = { return@queryCache null }, calculate = { val subtaskList = aopDbMapper.subtaskMapper.selectByExample(Example(Subtask::class.java).apply { createCriteria().andEqualTo("scenseid", option.sceneId) .andBetween("planstarttime", option.startTime, option.endTime) orderBy("planstarttime").desc() }) if (subtaskList.isEmpty()) return@queryCache DPChangeInfo() val problemList = aopDbMapper.problemlistMapper.selectByExample(Example(Problemlist::class.java).apply { createCriteria().andIn("stguid", subtaskList.map { it.stguid }) }) return@queryCache DPChangeInfo().apply { subTasks = subtaskList problems = problemList.map {problem -> val problemListVo = ProblemListVo() BeanUtils.copyProperties(problem, problemListVo) problemListVo } proCount = problemList.size changeCount = problemList.count { it.ischanged == true } changePer = if (proCount == 0) 0.0 else changeCount.toDouble() / proCount changeTime = problemList .filter { it.ischanged == true } .maxOf { (it.changedtime?.time?:0L) - (it?.time?.time?:0L) }.toInt() .div(1000 * 60 * 60 * 24) val eff = if (changeTime == 0) 1.0 else maxChangeTime.toDouble() / changeTime changeEfficiency = if (eff > 1.0) 1.0 else eff } } ) } override fun getChangeInfoList(options: List<QueryOptSingle>): List<DPChangeInfo> { return options.map { getChangeInfo(it) } } override fun getProblemRecurrence(option: QueryOptSingle): List<DPProblemRecurrence> { return QueryByCache.queryCache( cache = { return@queryCache null }, calculate = { val problemList = aopDbMapper.problemlistMapper.selectByExample(Example(Problemlist::class.java).apply { createCriteria().andEqualTo("scenseid", option.sceneId) .andBetween("planstarttime", option.startTime, option.endTime) orderBy("planstarttime").desc() }) if (problemList.isEmpty()) return@queryCache emptyList() val problemTypeList = aopDbMapper.problemtypeMapper.selectByExample(Example(Problemtype::class.java) .apply { createCriteria().andIn("guid", problemList.map { it.ptguid }) }) val problemMap = problemList .filter { val type = problemTypeList.find { type-> type.guid == it.ptguid } type?.typename != "éè·¯æ¬å°" || type.description == "å·¥å°å 夿¡éè·¯ææ¾æ³¥ç/æ³¥æ³/积å°/éæ" }.groupBy { problem -> val type = problemTypeList.find { type-> type.guid == problem.ptguid } ?: return@groupBy null /** * 2025.10.30 ç®åæ ¹æ®ä¸å¡è¦æ±ï¼å¨å·¥å°ç±»åä¸ï¼âéè·¯æ¬å°âé®é¢åºç°æ¦çé常é«ï¼ * å æ¤è¯¥é®é¢å¨åé夿§ç»è®¡æ¶ï¼ åªç»è®¡ç¨å ¶åç±»å"å·¥å°å 夿¡éè·¯ææ¾æ³¥ç/æ³¥æ³/积å°/éæ"为å类类å */ if (type.typename == "éè·¯æ¬å°") { type.description } else { type.typename } } return@queryCache problemMap.map { (key, value) -> val type = problemTypeList.find { type-> type.guid == value.first().ptguid } DPProblemRecurrence().apply { problemTag = key problemType = type count = value.size changeCount = value.count { it.ischanged == true } changePer = if (count == 0) 0.0 else changeCount.toDouble() / count } } } ) } } src/main/kotlin/cn/flightfeather/supervision/lightshare/service/impl/ScenseServiceImpl.kt
@@ -280,7 +280,7 @@ return BaseResponse(true, "è¯·æ±æå", data = result) } override fun getSceneDetail(sceneId: String): BaseResponse<SceneDetail> { override fun getSceneDetail(sceneId: String): SceneDetail { val sceneDetail = SceneDetail() val scene = sceneRep.findScene(sceneId = sceneId) @@ -302,10 +302,10 @@ val sceneDevice = sceneDeviceMapper.selectByPrimaryKey(sceneId) sceneDetail.sceneDevice = sceneDevice return BaseResponse(true, data = sceneDetail) return sceneDetail } override fun updateSceneDetail(typeId: Int, sceneDetailStr: SceneDetailStr): BaseResponse<String> { override fun updateSceneDetail(typeId: Int, sceneDetailStr: SceneDetailStr): String { val result = StringBuilder() if (sceneDetailStr.scense?.guid != null) { @@ -380,7 +380,7 @@ result.append("åºæ¯ç¹æä¿¡æ¯${if (isUpdate) "æ´æ°" else "æ°å¢"}: $r; ") } return BaseResponse(true, data = result.toString()) return result.toString() } override fun searchScene(areaVo: AreaVo, page: Int?, perPage: Int?): BaseResponse<List<Scense>> { src/main/kotlin/cn/flightfeather/supervision/lightshare/vo/dataprod/DPChangeInfo.kt
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,53 @@ package cn.flightfeather.supervision.lightshare.vo.dataprod import cn.flightfeather.supervision.domain.ds1.entity.Subtask import cn.flightfeather.supervision.lightshare.vo.ProblemListVo import io.swagger.annotations.ApiModel import io.swagger.annotations.ApiModelProperty import java.time.LocalDateTime import java.util.* /** * åºæ¯æ´æ¹æ åµ * @date 2025/10/30 * @author feiyu02 */ @ApiModel("åºæ¯æ´æ¹æ åµ") class DPChangeInfo { // /** // * æ¶é´æ ç¾ï¼å¯å¯¹åºä¸åçç»è®¡æ¶é´é¢ç²åº¦ï¼ç®å常è§çæ¯æåº¦ãå£åº¦ãä»»æå¤ä¸ªæç // * ä¾å¦ï¼2025å¹´10æã2025年第ä¸å£åº¦ã2025å¹´ä¸åå¹´ç // */ // @ApiModelProperty(value = "æ¶é´æ ç¾ï¼å¯å¯¹åºä¸åçç»è®¡æ¶é´é¢ç²åº¦ï¼ç®å常è§çæ¯æåº¦ãå£åº¦ãä»»æå¤ä¸ªæç") // var timeTag: String? = null // // @ApiModelProperty("èµ·å§æ¶é´") // var startTime: Date? = null // // @ApiModelProperty("ç»ææ¶é´") // var endTime: Date? = null @ApiModelProperty(value = "åä»»å¡ä¿¡æ¯") var subTasks: List<Subtask>? = null @ApiModelProperty(value = "é®é¢å表") var problems: List<ProblemListVo>? = null @ApiModelProperty(value = "é®é¢æ°") var proCount = 0 @ApiModelProperty(value = "æ´æ¹æ°") var changeCount = 0 @ApiModelProperty(value = "æ´æ¹ç") var changePer: Double = 0.0 @ApiModelProperty(value = "æ´æ¹èæ¶ï¼å¤©ï¼(åèæ¶æé¿çé®é¢ä½ä¸ºæç»æ´æ¹èæ¶)") var changeTime: Int = 0 // æ´æ¹æç = æ´æ¹è¦æ±æå¤§èæ¶ / æ´æ¹å®é èæ¶ @ApiModelProperty(value = "æ´æ¹æç") var changeEfficiency: Double = 0.0 } src/main/kotlin/cn/flightfeather/supervision/lightshare/vo/dataprod/DPProblemRecurrence.kt
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,27 @@ package cn.flightfeather.supervision.lightshare.vo.dataprod import cn.flightfeather.supervision.domain.ds1.entity.Problemtype import io.swagger.annotations.ApiModelProperty /** * é®é¢é夿 åµ * @date 2025/10/30 * @author feiyu02 */ class DPProblemRecurrence { @ApiModelProperty(value = "é®é¢æ ç¾") var problemTag:String? = null @ApiModelProperty(value = "é®é¢ç±»å") var problemType: Problemtype? = null @ApiModelProperty(value = "åºç°æ¬¡æ°") var count = 0 @ApiModelProperty(value = "æ´æ¹æ°") var changeCount = 0 @ApiModelProperty(value = "æ´æ¹ç") var changePer: Double = 0.0 } src/main/kotlin/cn/flightfeather/supervision/lightshare/vo/dataprod/QueryOpt.kt
@@ -1,6 +1,7 @@ package cn.flightfeather.supervision.lightshare.vo.dataprod import com.fasterxml.jackson.annotation.JsonFormat import io.swagger.annotations.ApiModel import io.swagger.annotations.ApiModelProperty import java.time.LocalDateTime @@ -9,6 +10,7 @@ * @date 2025/9/15 * @author feiyu02 */ @ApiModel("æ¥è¯¢åæ°") class QueryOpt { @ApiModelProperty("æ»ä»»å¡id") var topTaskId: String? = null src/main/kotlin/cn/flightfeather/supervision/lightshare/vo/dataprod/QueryOptSingle.kt
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,26 @@ package cn.flightfeather.supervision.lightshare.vo.dataprod import com.fasterxml.jackson.annotation.JsonFormat import io.swagger.annotations.ApiModel import io.swagger.annotations.ApiModelProperty import java.time.LocalDateTime /** * åä¸ªåºæ¯çºµåæ°æ®ç»è®¡äº§åæ¥è¯¢æ¡ä»¶ * @date 2025/10/30 * @author feiyu02 */ @ApiModel("åä¸ªåºæ¯çºµåæ°æ®ç»è®¡äº§åæ¥è¯¢æ¡ä»¶") class QueryOptSingle { @ApiModelProperty("åºæ¯id") var sceneId: String? = null @ApiModelProperty("èµ·å§æ¶é´ï¼æ ¼å¼ yyyy-MM-dd HH:mm:ss") @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") var startTime: LocalDateTime? = null @ApiModelProperty("ç»ææ¶é´ï¼æ ¼å¼ yyyy-MM-dd HH:mm:ss") @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") var endTime: LocalDateTime? = null } src/main/kotlin/cn/flightfeather/supervision/lightshare/vo/dataprod/base/DPEvaluateInfo.kt
ÎļþÃû´Ó src/main/kotlin/cn/flightfeather/supervision/lightshare/vo/dataprod/DPEvaluateInfo.kt ÐÞ¸Ä @@ -1,4 +1,4 @@ package cn.flightfeather.supervision.lightshare.vo.dataprod package cn.flightfeather.supervision.lightshare.vo.dataprod.base import cn.flightfeather.supervision.domain.ds1.entity.Evaluation import cn.flightfeather.supervision.domain.ds1.entity.Subtask src/main/kotlin/cn/flightfeather/supervision/lightshare/vo/dataprod/base/DPInspectionInfo.kt
ÎļþÃû´Ó src/main/kotlin/cn/flightfeather/supervision/lightshare/vo/dataprod/DPInspectionInfo.kt ÐÞ¸Ä @@ -1,4 +1,4 @@ package cn.flightfeather.supervision.lightshare.vo.dataprod package cn.flightfeather.supervision.lightshare.vo.dataprod.base import cn.flightfeather.supervision.domain.ds1.entity.Subtask import cn.flightfeather.supervision.lightshare.vo.ProblemListVo src/main/kotlin/cn/flightfeather/supervision/lightshare/vo/dataprod/base/DPMonitorDataInfo.kt
ÎļþÃû´Ó src/main/kotlin/cn/flightfeather/supervision/lightshare/vo/dataprod/DPMonitorDataInfo.kt ÐÞ¸Ä @@ -1,4 +1,4 @@ package cn.flightfeather.supervision.lightshare.vo.dataprod package cn.flightfeather.supervision.lightshare.vo.dataprod.base import cn.flightfeather.supervision.domain.ds1.entity.DustDataResult import cn.flightfeather.supervision.domain.ds1.entity.Scense src/main/kotlin/cn/flightfeather/supervision/lightshare/vo/dataprod/base/DPSceneInfo.kt
ÎļþÃû´Ó src/main/kotlin/cn/flightfeather/supervision/lightshare/vo/dataprod/DPSceneInfo.kt ÐÞ¸Ä @@ -1,4 +1,4 @@ package cn.flightfeather.supervision.lightshare.vo.dataprod package cn.flightfeather.supervision.lightshare.vo.dataprod.base import cn.flightfeather.supervision.domain.ds1.entity.BaseScene import cn.flightfeather.supervision.domain.ds1.entity.Scense src/main/kotlin/cn/flightfeather/supervision/lightshare/web/DataProdSingleSceneController.kt
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,37 @@ package cn.flightfeather.supervision.lightshare.web import cn.flightfeather.supervision.lightshare.service.DataProdSingleSceneService import cn.flightfeather.supervision.lightshare.vo.dataprod.QueryOptSingle import io.swagger.annotations.Api import io.swagger.annotations.ApiOperation import io.swagger.annotations.ApiParam import org.springframework.web.bind.annotation.PostMapping import org.springframework.web.bind.annotation.RequestBody import org.springframework.web.bind.annotation.RequestMapping import org.springframework.web.bind.annotation.RestController /** * ååºæ¯çºµåæ°æ®ç»è®¡äº§åæ§å¶å¨ * @date 2025/10/30 * @author feiyu02 */ @Api(tags = ["ååºæ¯çºµåæ°æ®ç»è®¡äº§åç¸å ³APIæ¥å£"], description = "ååºæ¯çºµåæ°æ®ç»è®¡äº§åç¸å ³APIæ¥å£") @RestController @RequestMapping("/dataProd/singleScene") class DataProdSingleSceneController(private val dataProdSingleSceneService: DataProdSingleSceneService) { @ApiOperation(value = "æ´æ¹æ åµ") @PostMapping("/changeInfo/get") fun getChangeInfo(@ApiParam("æ¥è¯¢æ¡ä»¶") @RequestBody queryOpt: QueryOptSingle) = dataProdSingleSceneService.getChangeInfo(queryOpt) @ApiOperation(value = "æ¹éæ¥è¯¢æ´æ¹æ åµ") @PostMapping("/changeInfo/get/list") fun getChangeInfoList(@ApiParam("æ¥è¯¢æ¡ä»¶") @RequestBody queryOpts: List<QueryOptSingle>) = dataProdSingleSceneService.getChangeInfoList(queryOpts) @ApiOperation(value = "é®é¢é夿 åµ") @PostMapping("/problemRecurrence/get") fun getProblemRecurrence(@ApiParam("æ¥è¯¢æ¡ä»¶") @RequestBody queryOpt: QueryOptSingle) = dataProdSingleSceneService.getProblemRecurrence(queryOpt) } src/main/kotlin/cn/flightfeather/supervision/lightshare/web/DomainitemController.kt
@@ -10,46 +10,61 @@ @Api(tags = ["DomainitemController"], description = "å¼åä¿¡æ¯APIæ¥å£") @RestController @IgnoreResponseAdvice @RequestMapping("/domainitem") class DomainitemController (val domainitemService: DomainitemService) { @IgnoreResponseAdvice @GetMapping fun getAll() = domainitemService.findAll() @IgnoreResponseAdvice @PutMapping fun add(@RequestBody domainitem: Domainitem) = domainitemService.save(domainitem) @IgnoreResponseAdvice @PostMapping fun update(@RequestBody domainitem: Domainitem) = domainitemService.update(domainitem) @IgnoreResponseAdvice @GetMapping("/{id}") fun getById(@PathVariable id:String) = domainitemService.findOne(id) @IgnoreResponseAdvice @DeleteMapping("/{id}") fun delete (@PathVariable id: String) = domainitemService.delete(id) @IgnoreResponseAdvice @ApiOperation("è·åæç±»åºæ¯çé®é¢ä½ç½®é项") @GetMapping("/location") fun getLocation( @ApiParam("åºæ¯ç±»åid") @RequestParam("sceneType") sceneType:Int ) = domainitemService.getLocation(sceneType) @IgnoreResponseAdvice @ApiOperation("è·åå·¡æ¥ä»»å¡çç±»åé项") @GetMapping("/taskType") fun getTaskType() = domainitemService.getTaskType() @IgnoreResponseAdvice @ApiOperation("è·åå·¡æ¥ä»»å¡çæéç±»åé项") @GetMapping("/deadlineType") fun getDeadlineType() = domainitemService.getDeadlineType() @IgnoreResponseAdvice @ApiOperation("è·åå·¡æ¥ä»»å¡å±æ¬¡ç±»åé项") @GetMapping("/level") fun getLevelType() = domainitemService.getLevelType() @IgnoreResponseAdvice @ApiOperation("æ ¹æ®åºæ¯ç±»åè·åä»»ææçç±»å") @GetMapping("/mediaFileType") fun getMediaFileType( @ApiParam("åºæ¯ç±»åid") @RequestParam("sceneType") sceneType:Int ) = domainitemService.getMediaFileType(sceneType) @ApiOperation("æ ¹æ®å¼åç±»å«åç§°ï¼è·åå ·ä½çé项") @GetMapping("/name") fun getItemByName( @ApiParam("å¼ååç§°") @RequestParam("name") name:String ) = domainitemService.findOneByName(name) } src/main/resources/generator/generatorConfig4ds1.xml
@@ -11,7 +11,7 @@ <property name="javaFileEncoding" value="UTF-8"/> <property name="beginningDelimiter" value="`"/> <property name="endingDelimiter" value="`"/> <!-- é ç½®èªå®ä¹æ³¨è§£æä»¶ --> <!-- é ç½®èªå®ä¹æ³¨è§£æä»¶ï¼ç¨äºå¨çææ°æ®åºè¡¨æ¨¡åæ¶ï¼èªå¨æ·»å swaggerç@ApiModel注解 --> <plugin type="cn.flight.feather.devtool.mybatis.plugin.CustomAnnotationPlugin"> <!-- å¯ä»¥å¨è¿éæ·»å æä»¶å±æ§ --> </plugin> src/main/resources/mapper/ds1/DataProductBaseMapper.xml
ÎļþÒÑɾ³ý src/main/resources/mapper/ds1/DataProductFinalMapper.xml
ÎļþÒÑɾ³ý src/main/resources/mapper/ds1/DataProductMiddleMapper.xml
ÎļþÒÑɾ³ý