feat: 根据站码查询单条水温基础数据
This commit is contained in:
parent
fa0519fab6
commit
d4eb75bea8
@ -191,6 +191,12 @@ public class SdWTMonitorController {
|
|||||||
return ResponseResult.successData(sdWtMonitorService.getVmsstbprptList(dataSourceRequest));
|
return ResponseResult.successData(sdWtMonitorService.getVmsstbprptList(dataSourceRequest));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@GetMapping("/msstbprpt/getStcdInfo")
|
||||||
|
@Operation(summary = "根据站码查询单条水温基础数据")
|
||||||
|
public ResponseResult getStcdInfo(@RequestParam String stcd) {
|
||||||
|
return ResponseResult.successData(sdWtMonitorService.getStcdInfo(stcd));
|
||||||
|
}
|
||||||
|
|
||||||
@PostMapping("/wbsb/GetKendoList")
|
@PostMapping("/wbsb/GetKendoList")
|
||||||
@Operation(summary = "查询水电基地流域字典列表")
|
@Operation(summary = "查询水电基地流域字典列表")
|
||||||
public ResponseResult getWbsbList(@RequestBody DataSourceRequest dataSourceRequest) {
|
public ResponseResult getWbsbList(@RequestBody DataSourceRequest dataSourceRequest) {
|
||||||
|
|||||||
187
backend/src/main/java/com/yfd/platform/env/wt/entity/vo/WtBaseInfoVo.java
vendored
Normal file
187
backend/src/main/java/com/yfd/platform/env/wt/entity/vo/WtBaseInfoVo.java
vendored
Normal file
@ -0,0 +1,187 @@
|
|||||||
|
package com.yfd.platform.env.wt.entity.vo;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.math.BigDecimal;
|
||||||
|
import java.util.Date;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
@Schema(description = "水温基础站点信息")
|
||||||
|
public class WtBaseInfoVo {
|
||||||
|
|
||||||
|
@Schema(description = "站码")
|
||||||
|
private String stcd;
|
||||||
|
|
||||||
|
@Schema(description = "站名")
|
||||||
|
private String stnm;
|
||||||
|
|
||||||
|
@Schema(description = "数据时间")
|
||||||
|
private Date tm;
|
||||||
|
|
||||||
|
@Schema(description = "站类")
|
||||||
|
private String sttp;
|
||||||
|
|
||||||
|
@Schema(description = "经度")
|
||||||
|
private Double lgtd;
|
||||||
|
|
||||||
|
@Schema(description = "纬度")
|
||||||
|
private Double lttd;
|
||||||
|
|
||||||
|
@Schema(description = "海拔")
|
||||||
|
private Double elev;
|
||||||
|
|
||||||
|
@Schema(description = "站址")
|
||||||
|
private String stlc;
|
||||||
|
|
||||||
|
@Schema(description = "测站来源")
|
||||||
|
private String stsr;
|
||||||
|
|
||||||
|
@Schema(description = "水温断面设备类型")
|
||||||
|
private Integer wtDeviceType;
|
||||||
|
|
||||||
|
@Schema(description = "水温监测断面类型")
|
||||||
|
private String wtType;
|
||||||
|
|
||||||
|
@Schema(description = "电站水温结构类型")
|
||||||
|
private String wts;
|
||||||
|
|
||||||
|
@Schema(description = "固定垂向水温类型")
|
||||||
|
private Integer wtHgtType;
|
||||||
|
|
||||||
|
@Schema(description = "第一个探头高程")
|
||||||
|
private Double wtFirstHgt;
|
||||||
|
|
||||||
|
@Schema(description = "垂向水温探头分布")
|
||||||
|
private String wtDist;
|
||||||
|
|
||||||
|
@Schema(description = "建成日期")
|
||||||
|
private Date jcdt;
|
||||||
|
|
||||||
|
@Schema(description = "撤站日期")
|
||||||
|
private Date wddt;
|
||||||
|
|
||||||
|
@Schema(description = "建设状态分类")
|
||||||
|
private Integer bldsttCode;
|
||||||
|
|
||||||
|
@Schema(description = "建设状态名称")
|
||||||
|
private String bldsttCcodeName;
|
||||||
|
|
||||||
|
|
||||||
|
@Schema(description = "总投资")
|
||||||
|
private BigDecimal inv;
|
||||||
|
|
||||||
|
@Schema(description = "投资是否计入主体工程")
|
||||||
|
private Integer invinmn;
|
||||||
|
|
||||||
|
@Schema(description = "简介")
|
||||||
|
private String introduce;
|
||||||
|
|
||||||
|
@Schema(description = "LOGO")
|
||||||
|
private String logo;
|
||||||
|
|
||||||
|
@Schema(description = "介绍图片")
|
||||||
|
private String inffile;
|
||||||
|
|
||||||
|
@Schema(description = "是否启用")
|
||||||
|
private Integer usfl;
|
||||||
|
|
||||||
|
@Schema(description = "数据是否接入")
|
||||||
|
private Integer dtin;
|
||||||
|
|
||||||
|
@Schema(description = "数据接入来源")
|
||||||
|
private String dtinSrc;
|
||||||
|
|
||||||
|
@Schema(description = "数据接入类型")
|
||||||
|
private Integer dtinType;
|
||||||
|
|
||||||
|
@Schema(description = "数据接入开始时间")
|
||||||
|
private Date dtinTm;
|
||||||
|
|
||||||
|
@Schema(description = "监测方式")
|
||||||
|
private Integer mway;
|
||||||
|
|
||||||
|
@Schema(description = "监测方式名称")
|
||||||
|
private String mwayName;
|
||||||
|
|
||||||
|
@Schema(description = "监测指标")
|
||||||
|
private String stindx;
|
||||||
|
|
||||||
|
@Schema(description = "排序")
|
||||||
|
private Integer orderIndex;
|
||||||
|
|
||||||
|
@Schema(description = "所属断面编码")
|
||||||
|
private String dmstcd;
|
||||||
|
|
||||||
|
@Schema(description = "所属电站编码")
|
||||||
|
private String rstcd;
|
||||||
|
|
||||||
|
@Schema(description = "所属电站名称")
|
||||||
|
private String ennm;
|
||||||
|
|
||||||
|
@Schema(description = "所属基地编码")
|
||||||
|
private String baseId;
|
||||||
|
|
||||||
|
@Schema(description = "所属基地名称")
|
||||||
|
private String baseName;
|
||||||
|
|
||||||
|
@Schema(description = "基地流域编码")
|
||||||
|
private String hbrvcd;
|
||||||
|
|
||||||
|
@Schema(description = "基地流域名称")
|
||||||
|
private String hbrvcdName;
|
||||||
|
|
||||||
|
@Schema(description = "流域编码")
|
||||||
|
private String rvcd;
|
||||||
|
|
||||||
|
@Schema(description = "流域名称")
|
||||||
|
private String rvcdName;
|
||||||
|
|
||||||
|
@Schema(description = "行政区编码")
|
||||||
|
private String addvcd;
|
||||||
|
|
||||||
|
@Schema(description = "行政区名称")
|
||||||
|
private String addvcdName;
|
||||||
|
|
||||||
|
@Schema(description = "所属栖息地编码")
|
||||||
|
private String fhstcd;
|
||||||
|
|
||||||
|
@Schema(description = "是否属于测站")
|
||||||
|
private Integer ispro;
|
||||||
|
|
||||||
|
@Schema(description = "依托项目")
|
||||||
|
private String project;
|
||||||
|
|
||||||
|
@Schema(description = "数据监测频次")
|
||||||
|
private Integer dtfrqcy;
|
||||||
|
|
||||||
|
@Schema(description = "备注")
|
||||||
|
private String remark;
|
||||||
|
|
||||||
|
@Schema(description = "数据来源")
|
||||||
|
private String vlsr;
|
||||||
|
|
||||||
|
@Schema(description = "数据来源时间")
|
||||||
|
private Date vlsrTm;
|
||||||
|
|
||||||
|
@Schema(description = "创建人")
|
||||||
|
private String recordUser;
|
||||||
|
|
||||||
|
@Schema(description = "创建时间")
|
||||||
|
private Date recordTime;
|
||||||
|
|
||||||
|
@Schema(description = "更新人")
|
||||||
|
private String modifyUser;
|
||||||
|
|
||||||
|
@Schema(description = "更新时间")
|
||||||
|
private Date modifyTime;
|
||||||
|
|
||||||
|
@Schema(description = "是否删除")
|
||||||
|
private Integer isDeleted;
|
||||||
|
|
||||||
|
@Schema(description = "删除人")
|
||||||
|
private String deleteUser;
|
||||||
|
|
||||||
|
@Schema(description = "删除时间")
|
||||||
|
private Date deleteTime;
|
||||||
|
}
|
||||||
@ -9,6 +9,7 @@ import com.yfd.platform.env.wt.entity.vo.SdMonthDetailVO;
|
|||||||
import com.yfd.platform.env.wt.entity.vo.SdYearDetailVO;
|
import com.yfd.platform.env.wt.entity.vo.SdYearDetailVO;
|
||||||
import com.yfd.platform.env.wt.entity.vo.SttpInfoVo;
|
import com.yfd.platform.env.wt.entity.vo.SttpInfoVo;
|
||||||
import com.yfd.platform.env.wt.entity.vo.WbsbVo;
|
import com.yfd.platform.env.wt.entity.vo.WbsbVo;
|
||||||
|
import com.yfd.platform.env.wt.entity.vo.WtBaseInfoVo;
|
||||||
import com.yfd.platform.env.wt.entity.vo.WtrvVo;
|
import com.yfd.platform.env.wt.entity.vo.WtrvVo;
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
@ -19,6 +20,8 @@ public interface SdWtMonitorService {
|
|||||||
|
|
||||||
DataSourceResult getVmsstbprptList(DataSourceRequest dataSourceRequest);
|
DataSourceResult getVmsstbprptList(DataSourceRequest dataSourceRequest);
|
||||||
|
|
||||||
|
WtBaseInfoVo getStcdInfo(String stcd);
|
||||||
|
|
||||||
DataSourceResult getCxDetailList(DataSourceRequest dataSourceRequest);
|
DataSourceResult getCxDetailList(DataSourceRequest dataSourceRequest);
|
||||||
|
|
||||||
DataSourceResult getWtFishAnalysis(DataSourceRequest dataSourceRequest);
|
DataSourceResult getWtFishAnalysis(DataSourceRequest dataSourceRequest);
|
||||||
|
|||||||
@ -3,6 +3,7 @@ package com.yfd.platform.env.wt.service.impl;
|
|||||||
import cn.hutool.core.util.StrUtil;
|
import cn.hutool.core.util.StrUtil;
|
||||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||||
import com.yfd.platform.common.*;
|
import com.yfd.platform.common.*;
|
||||||
|
import com.yfd.platform.common.exception.BizException;
|
||||||
import com.yfd.platform.env.wt.entity.vo.DfltkwFacilityCountVo;
|
import com.yfd.platform.env.wt.entity.vo.DfltkwFacilityCountVo;
|
||||||
import com.yfd.platform.env.wt.entity.vo.FishSpawnVo;
|
import com.yfd.platform.env.wt.entity.vo.FishSpawnVo;
|
||||||
import com.yfd.platform.env.wt.entity.vo.RstcdTreeInfoVo;
|
import com.yfd.platform.env.wt.entity.vo.RstcdTreeInfoVo;
|
||||||
@ -12,6 +13,7 @@ import com.yfd.platform.env.wt.entity.vo.SdWtBaseInfoVO;
|
|||||||
import com.yfd.platform.env.wt.entity.vo.SdWtMonitorCountVO;
|
import com.yfd.platform.env.wt.entity.vo.SdWtMonitorCountVO;
|
||||||
import com.yfd.platform.env.wt.entity.vo.SttpInfoVo;
|
import com.yfd.platform.env.wt.entity.vo.SttpInfoVo;
|
||||||
import com.yfd.platform.env.wt.entity.vo.WbsbVo;
|
import com.yfd.platform.env.wt.entity.vo.WbsbVo;
|
||||||
|
import com.yfd.platform.env.wt.entity.vo.WtBaseInfoVo;
|
||||||
import com.yfd.platform.env.wt.entity.vo.WtFishVo;
|
import com.yfd.platform.env.wt.entity.vo.WtFishVo;
|
||||||
import com.yfd.platform.env.wt.entity.vo.WtTreeStcdVo;
|
import com.yfd.platform.env.wt.entity.vo.WtTreeStcdVo;
|
||||||
import com.yfd.platform.env.wt.entity.vo.WtrvVo;
|
import com.yfd.platform.env.wt.entity.vo.WtrvVo;
|
||||||
@ -78,6 +80,90 @@ public class SdWtMonitorServiceImpl implements SdWtMonitorService {
|
|||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public WtBaseInfoVo getStcdInfo(String stcd) {
|
||||||
|
if (StrUtil.isBlank(stcd)) {
|
||||||
|
throw new BizException("站点编码不能为空!");
|
||||||
|
}
|
||||||
|
String sql = "SELECT " +
|
||||||
|
"t.STCD AS stcd, " +
|
||||||
|
"t.STNM AS stnm, " +
|
||||||
|
"t.TM AS tm, " +
|
||||||
|
"t.STTP AS sttp, " +
|
||||||
|
"t.LGTD AS lgtd, " +
|
||||||
|
"t.LTTD AS lttd, " +
|
||||||
|
"t.ELEV AS elev, " +
|
||||||
|
"t.STLC AS stlc, " +
|
||||||
|
"t.STSR AS stsr, " +
|
||||||
|
"t.WT_DEVICE_TYPE AS wtDeviceType, " +
|
||||||
|
"t.WT_TYPE AS wtType, " +
|
||||||
|
"t.WTS AS wts, " +
|
||||||
|
"t.WT_HGT_TYPE AS wtHgtType, " +
|
||||||
|
"t.WT_FIRST_HGT AS wtFirstHgt, " +
|
||||||
|
"t.WT_DIST AS wtDist, " +
|
||||||
|
"t.JCDT AS jcdt, " +
|
||||||
|
"t.WDDT AS wddt, " +
|
||||||
|
"t.BLDSTT_CODE AS bldsttCode, " +
|
||||||
|
"CASE WHEN t.BLDSTT_CODE IN ('1', '10', '11') THEN '已建' WHEN t.BLDSTT_CODE IN ('2', '7', '8') THEN '在建' ELSE '未建/规划' END AS bldsttCcodeName, "+
|
||||||
|
"t.INV AS inv, " +
|
||||||
|
"t.INVINMN AS invinmn, " +
|
||||||
|
"t.INTRODUCE AS introduce, " +
|
||||||
|
"t.LOGO AS logo, " +
|
||||||
|
"t.INFFILE AS inffile, " +
|
||||||
|
"t.USFL AS usfl, " +
|
||||||
|
"t.DTIN AS dtin, " +
|
||||||
|
"t.DTIN_SRC AS dtinSrc, " +
|
||||||
|
"t.DTIN_TYPE AS dtinType, " +
|
||||||
|
"t.DTIN_TM AS dtinTm, " +
|
||||||
|
"t.MWAY AS mway, " +
|
||||||
|
"CASE NVL(t.MWAY, 0) WHEN 1 THEN '人工' WHEN 2 THEN '自动' ELSE '未知' END AS mwayName , "+
|
||||||
|
"t.STINDX AS stindx, " +
|
||||||
|
"t.ORDER_INDEX AS orderIndex, " +
|
||||||
|
"t.DMSTCD AS dmstcd, " +
|
||||||
|
"t.RSTCD AS rstcd, " +
|
||||||
|
"eng.ENNM AS ennm, " +
|
||||||
|
"eng.BASE_ID AS baseId, " +
|
||||||
|
"base.BASENAME AS baseName, " +
|
||||||
|
"eng.HBRVCD AS hbrvcd, " +
|
||||||
|
"hbrv.HBRVNM AS hbrvcdName, " +
|
||||||
|
"eng.RVCD AS rvcd, " +
|
||||||
|
"rv.RVNM AS rvcdName, " +
|
||||||
|
"eng.ADDVCD AS addvcd, " +
|
||||||
|
"addv.ADDVNM AS addvcdName, " +
|
||||||
|
"t.FHSTCD AS fhstcd, " +
|
||||||
|
"t.ISPRO AS ispro, " +
|
||||||
|
"t.PROJECT AS project, " +
|
||||||
|
"t.DTFRQCY AS dtfrqcy, " +
|
||||||
|
"t.REMARK AS remark, " +
|
||||||
|
"t.VLSR AS vlsr, " +
|
||||||
|
"t.VLSR_TM AS vlsrTm, " +
|
||||||
|
"t.RECORD_USER AS recordUser, " +
|
||||||
|
"t.RECORD_TIME AS recordTime, " +
|
||||||
|
"t.MODIFY_USER AS modifyUser, " +
|
||||||
|
"t.MODIFY_TIME AS modifyTime, " +
|
||||||
|
"t.IS_DELETED AS isDeleted, " +
|
||||||
|
"t.DELETE_USER AS deleteUser, " +
|
||||||
|
"t.DELETE_TIME AS deleteTime " +
|
||||||
|
"FROM SD_WT_B_H t " +
|
||||||
|
"LEFT JOIN SD_ENGINFO_B_H eng ON eng.STCD = t.RSTCD " +
|
||||||
|
"LEFT JOIN SD_HYDROBASE base ON base.BASEID = eng.BASE_ID AND NVL(base.IS_DELETED, 0) = 0 " +
|
||||||
|
"LEFT JOIN SD_HBRV_DIC hbrv ON hbrv.HBRVCD = eng.HBRVCD " +
|
||||||
|
" AND hbrv.BASEID = eng.BASE_ID " +
|
||||||
|
" AND NVL(hbrv.IS_DELETED, 0) = 0 " +
|
||||||
|
" AND NVL(hbrv.ENABLED, 1) = 1 " +
|
||||||
|
"LEFT JOIN SD_RVCD_DIC rv ON rv.RVCD = eng.RVCD " +
|
||||||
|
"LEFT JOIN SD_ADDVCD_DIC addv ON addv.ADDVCD = eng.ADDVCD " +
|
||||||
|
"WHERE t.STCD = #{map.stcd} " +
|
||||||
|
" AND NVL(t.IS_DELETED, 0) = 0 ";
|
||||||
|
Map<String, Object> paramMap = new HashMap<>();
|
||||||
|
paramMap.put("stcd", stcd);
|
||||||
|
List<WtBaseInfoVo> list = microservicDynamicSQLMapper.getAllListWithResultType(sql, paramMap, WtBaseInfoVo.class);
|
||||||
|
if (list == null || list.isEmpty()) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
return list.get(0);
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public DataSourceResult<WbsbVo> getWbsbList(DataSourceRequest dataSourceRequest) {
|
public DataSourceResult<WbsbVo> getWbsbList(DataSourceRequest dataSourceRequest) {
|
||||||
DataSourceLoadOptionsBase loadOptions = dataSourceRequest == null ? null : dataSourceRequest.toDevRequest();
|
DataSourceLoadOptionsBase loadOptions = dataSourceRequest == null ? null : dataSourceRequest.toDevRequest();
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user