change - add蒸汽实时数据
parent
6f25e0086f
commit
0cccc11761
@ -0,0 +1,100 @@
|
||||
package com.os.ems.record.controller;
|
||||
|
||||
import java.util.List;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.PutMapping;
|
||||
import org.springframework.web.bind.annotation.DeleteMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
import com.os.common.annotation.Log;
|
||||
import com.os.common.core.controller.BaseController;
|
||||
import com.os.common.core.domain.AjaxResult;
|
||||
import com.os.common.enums.BusinessType;
|
||||
import com.os.ems.record.domain.EmsRecordSteamInstant;
|
||||
import com.os.ems.record.service.IEmsRecordSteamInstantService;
|
||||
import com.os.common.utils.poi.ExcelUtil;
|
||||
import com.os.common.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 蒸汽实时数据Controller
|
||||
*
|
||||
* @author Yinq
|
||||
* @date 2024-05-22
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/ems/record/recordSteamInstant")
|
||||
public class EmsRecordSteamInstantController extends BaseController {
|
||||
@Autowired
|
||||
private IEmsRecordSteamInstantService emsRecordSteamInstantService;
|
||||
|
||||
/**
|
||||
* 查询蒸汽实时数据列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('ems/record:recordSteamInstant:list')")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(EmsRecordSteamInstant emsRecordSteamInstant) {
|
||||
startPage();
|
||||
List<EmsRecordSteamInstant> list = emsRecordSteamInstantService.selectEmsRecordSteamInstantList(emsRecordSteamInstant);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出蒸汽实时数据列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('ems/record:recordSteamInstant:export')")
|
||||
@Log(title = "蒸汽实时数据", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(HttpServletResponse response, EmsRecordSteamInstant emsRecordSteamInstant) {
|
||||
List<EmsRecordSteamInstant> list = emsRecordSteamInstantService.selectEmsRecordSteamInstantList(emsRecordSteamInstant);
|
||||
ExcelUtil<EmsRecordSteamInstant> util = new ExcelUtil<EmsRecordSteamInstant>(EmsRecordSteamInstant.class);
|
||||
util.exportExcel(response, list, "蒸汽实时数据数据");
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取蒸汽实时数据详细信息
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('ems/record:recordSteamInstant:query')")
|
||||
@GetMapping(value = "/{objId}")
|
||||
public AjaxResult getInfo(@PathVariable("objId") Long objId) {
|
||||
return success(emsRecordSteamInstantService.selectEmsRecordSteamInstantByObjId(objId));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增蒸汽实时数据
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('ems/record:recordSteamInstant:add')")
|
||||
@Log(title = "蒸汽实时数据", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
public AjaxResult add(@RequestBody EmsRecordSteamInstant emsRecordSteamInstant) {
|
||||
emsRecordSteamInstant.setCreateBy(getUsername());
|
||||
return toAjax(emsRecordSteamInstantService.insertEmsRecordSteamInstant(emsRecordSteamInstant));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改蒸汽实时数据
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('ems/record:recordSteamInstant:edit')")
|
||||
@Log(title = "蒸汽实时数据", businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
public AjaxResult edit(@RequestBody EmsRecordSteamInstant emsRecordSteamInstant) {
|
||||
emsRecordSteamInstant.setUpdateBy(getUsername());
|
||||
return toAjax(emsRecordSteamInstantService.updateEmsRecordSteamInstant(emsRecordSteamInstant));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除蒸汽实时数据
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('ems/record:recordSteamInstant:remove')")
|
||||
@Log(title = "蒸汽实时数据", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{objIds}")
|
||||
public AjaxResult remove(@PathVariable Long[] objIds) {
|
||||
return toAjax(emsRecordSteamInstantService.deleteEmsRecordSteamInstantByObjIds(objIds));
|
||||
}
|
||||
}
|
@ -0,0 +1,219 @@
|
||||
package com.os.ems.record.domain;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
import com.os.common.annotation.Excel;
|
||||
import com.os.common.core.domain.BaseEntity;
|
||||
|
||||
/**
|
||||
* 蒸汽实时数据对象 ems_record_steam_instant
|
||||
*
|
||||
* @author Yinq
|
||||
* @date 2024-05-22
|
||||
*/
|
||||
public class EmsRecordSteamInstant extends BaseEntity {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 自增标识
|
||||
*/
|
||||
private Long objId;
|
||||
|
||||
/**
|
||||
* 计量设备编号
|
||||
*/
|
||||
@Excel(name = "计量设备编号")
|
||||
private String monitorCode;
|
||||
|
||||
/** 计量设备编号 */
|
||||
@Excel(name = "计量设备名称")
|
||||
private String monitorName;
|
||||
|
||||
/**
|
||||
* 采集时间
|
||||
*/
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "采集时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date collectTime;
|
||||
|
||||
/**
|
||||
* 瞬时流量
|
||||
*/
|
||||
@Excel(name = "瞬时流量")
|
||||
private BigDecimal fluxFlow;
|
||||
|
||||
/**
|
||||
* 累计流量
|
||||
*/
|
||||
@Excel(name = "累计流量")
|
||||
private BigDecimal steamFlow;
|
||||
|
||||
/**
|
||||
* 瞬时热量
|
||||
*/
|
||||
@Excel(name = "瞬时热量")
|
||||
private BigDecimal heatInstantValue;
|
||||
|
||||
/**
|
||||
* 累计热量
|
||||
*/
|
||||
@Excel(name = "累计热量")
|
||||
private BigDecimal heatTotalValue;
|
||||
|
||||
/**
|
||||
* 温度
|
||||
*/
|
||||
@Excel(name = "温度")
|
||||
private BigDecimal temperature;
|
||||
|
||||
/**
|
||||
* 压力
|
||||
*/
|
||||
@Excel(name = "压力")
|
||||
private BigDecimal press;
|
||||
|
||||
/**
|
||||
* 密度
|
||||
*/
|
||||
@Excel(name = "密度")
|
||||
private BigDecimal density;
|
||||
|
||||
/**
|
||||
* 压力差值
|
||||
*/
|
||||
@Excel(name = "压力差值")
|
||||
private BigDecimal differencePress;
|
||||
|
||||
/**
|
||||
* 记录时间
|
||||
*/
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "记录时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date recordTime;
|
||||
|
||||
public String getMonitorName() {
|
||||
return monitorName;
|
||||
}
|
||||
|
||||
public void setMonitorName(String monitorName) {
|
||||
this.monitorName = monitorName;
|
||||
}
|
||||
|
||||
public void setObjId(Long objId) {
|
||||
this.objId = objId;
|
||||
}
|
||||
|
||||
public Long getObjId() {
|
||||
return objId;
|
||||
}
|
||||
|
||||
public void setMonitorCode(String monitorCode) {
|
||||
this.monitorCode = monitorCode;
|
||||
}
|
||||
|
||||
public String getMonitorCode() {
|
||||
return monitorCode;
|
||||
}
|
||||
|
||||
public void setCollectTime(Date collectTime) {
|
||||
this.collectTime = collectTime;
|
||||
}
|
||||
|
||||
public Date getCollectTime() {
|
||||
return collectTime;
|
||||
}
|
||||
|
||||
public void setFluxFlow(BigDecimal fluxFlow) {
|
||||
this.fluxFlow = fluxFlow;
|
||||
}
|
||||
|
||||
public BigDecimal getFluxFlow() {
|
||||
return fluxFlow;
|
||||
}
|
||||
|
||||
public void setSteamFlow(BigDecimal steamFlow) {
|
||||
this.steamFlow = steamFlow;
|
||||
}
|
||||
|
||||
public BigDecimal getSteamFlow() {
|
||||
return steamFlow;
|
||||
}
|
||||
|
||||
public void setHeatInstantValue(BigDecimal heatInstantValue) {
|
||||
this.heatInstantValue = heatInstantValue;
|
||||
}
|
||||
|
||||
public BigDecimal getHeatInstantValue() {
|
||||
return heatInstantValue;
|
||||
}
|
||||
|
||||
public void setHeatTotalValue(BigDecimal heatTotalValue) {
|
||||
this.heatTotalValue = heatTotalValue;
|
||||
}
|
||||
|
||||
public BigDecimal getHeatTotalValue() {
|
||||
return heatTotalValue;
|
||||
}
|
||||
|
||||
public void setTemperature(BigDecimal temperature) {
|
||||
this.temperature = temperature;
|
||||
}
|
||||
|
||||
public BigDecimal getTemperature() {
|
||||
return temperature;
|
||||
}
|
||||
|
||||
public void setPress(BigDecimal press) {
|
||||
this.press = press;
|
||||
}
|
||||
|
||||
public BigDecimal getPress() {
|
||||
return press;
|
||||
}
|
||||
|
||||
public void setDensity(BigDecimal density) {
|
||||
this.density = density;
|
||||
}
|
||||
|
||||
public BigDecimal getDensity() {
|
||||
return density;
|
||||
}
|
||||
|
||||
public void setDifferencePress(BigDecimal differencePress) {
|
||||
this.differencePress = differencePress;
|
||||
}
|
||||
|
||||
public BigDecimal getDifferencePress() {
|
||||
return differencePress;
|
||||
}
|
||||
|
||||
public void setRecordTime(Date recordTime) {
|
||||
this.recordTime = recordTime;
|
||||
}
|
||||
|
||||
public Date getRecordTime() {
|
||||
return recordTime;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("objId", getObjId())
|
||||
.append("monitorCode", getMonitorCode())
|
||||
.append("collectTime", getCollectTime())
|
||||
.append("fluxFlow", getFluxFlow())
|
||||
.append("steamFlow", getSteamFlow())
|
||||
.append("heatInstantValue", getHeatInstantValue())
|
||||
.append("heatTotalValue", getHeatTotalValue())
|
||||
.append("temperature", getTemperature())
|
||||
.append("press", getPress())
|
||||
.append("density", getDensity())
|
||||
.append("differencePress", getDifferencePress())
|
||||
.append("recordTime", getRecordTime())
|
||||
.toString();
|
||||
}
|
||||
}
|
@ -0,0 +1,61 @@
|
||||
package com.os.ems.record.mapper;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.os.ems.record.domain.EmsRecordSteamInstant;
|
||||
|
||||
/**
|
||||
* 蒸汽实时数据Mapper接口
|
||||
*
|
||||
* @author Yinq
|
||||
* @date 2024-05-22
|
||||
*/
|
||||
public interface EmsRecordSteamInstantMapper {
|
||||
/**
|
||||
* 查询蒸汽实时数据
|
||||
*
|
||||
* @param objId 蒸汽实时数据主键
|
||||
* @return 蒸汽实时数据
|
||||
*/
|
||||
public EmsRecordSteamInstant selectEmsRecordSteamInstantByObjId(Long objId);
|
||||
|
||||
/**
|
||||
* 查询蒸汽实时数据列表
|
||||
*
|
||||
* @param emsRecordSteamInstant 蒸汽实时数据
|
||||
* @return 蒸汽实时数据集合
|
||||
*/
|
||||
public List<EmsRecordSteamInstant> selectEmsRecordSteamInstantList(EmsRecordSteamInstant emsRecordSteamInstant);
|
||||
|
||||
/**
|
||||
* 新增蒸汽实时数据
|
||||
*
|
||||
* @param emsRecordSteamInstant 蒸汽实时数据
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertEmsRecordSteamInstant(EmsRecordSteamInstant emsRecordSteamInstant);
|
||||
|
||||
/**
|
||||
* 修改蒸汽实时数据
|
||||
*
|
||||
* @param emsRecordSteamInstant 蒸汽实时数据
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateEmsRecordSteamInstant(EmsRecordSteamInstant emsRecordSteamInstant);
|
||||
|
||||
/**
|
||||
* 删除蒸汽实时数据
|
||||
*
|
||||
* @param objId 蒸汽实时数据主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteEmsRecordSteamInstantByObjId(Long objId);
|
||||
|
||||
/**
|
||||
* 批量删除蒸汽实时数据
|
||||
*
|
||||
* @param objIds 需要删除的数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteEmsRecordSteamInstantByObjIds(Long[] objIds);
|
||||
}
|
@ -0,0 +1,61 @@
|
||||
package com.os.ems.record.service;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.os.ems.record.domain.EmsRecordSteamInstant;
|
||||
|
||||
/**
|
||||
* 蒸汽实时数据Service接口
|
||||
*
|
||||
* @author Yinq
|
||||
* @date 2024-05-22
|
||||
*/
|
||||
public interface IEmsRecordSteamInstantService {
|
||||
/**
|
||||
* 查询蒸汽实时数据
|
||||
*
|
||||
* @param objId 蒸汽实时数据主键
|
||||
* @return 蒸汽实时数据
|
||||
*/
|
||||
public EmsRecordSteamInstant selectEmsRecordSteamInstantByObjId(Long objId);
|
||||
|
||||
/**
|
||||
* 查询蒸汽实时数据列表
|
||||
*
|
||||
* @param emsRecordSteamInstant 蒸汽实时数据
|
||||
* @return 蒸汽实时数据集合
|
||||
*/
|
||||
public List<EmsRecordSteamInstant> selectEmsRecordSteamInstantList(EmsRecordSteamInstant emsRecordSteamInstant);
|
||||
|
||||
/**
|
||||
* 新增蒸汽实时数据
|
||||
*
|
||||
* @param emsRecordSteamInstant 蒸汽实时数据
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertEmsRecordSteamInstant(EmsRecordSteamInstant emsRecordSteamInstant);
|
||||
|
||||
/**
|
||||
* 修改蒸汽实时数据
|
||||
*
|
||||
* @param emsRecordSteamInstant 蒸汽实时数据
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateEmsRecordSteamInstant(EmsRecordSteamInstant emsRecordSteamInstant);
|
||||
|
||||
/**
|
||||
* 批量删除蒸汽实时数据
|
||||
*
|
||||
* @param objIds 需要删除的蒸汽实时数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteEmsRecordSteamInstantByObjIds(Long[] objIds);
|
||||
|
||||
/**
|
||||
* 删除蒸汽实时数据信息
|
||||
*
|
||||
* @param objId 蒸汽实时数据主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteEmsRecordSteamInstantByObjId(Long objId);
|
||||
}
|
@ -0,0 +1,87 @@
|
||||
package com.os.ems.record.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.os.ems.record.mapper.EmsRecordSteamInstantMapper;
|
||||
import com.os.ems.record.domain.EmsRecordSteamInstant;
|
||||
import com.os.ems.record.service.IEmsRecordSteamInstantService;
|
||||
|
||||
/**
|
||||
* 蒸汽实时数据Service业务层处理
|
||||
*
|
||||
* @author Yinq
|
||||
* @date 2024-05-22
|
||||
*/
|
||||
@Service
|
||||
public class EmsRecordSteamInstantServiceImpl implements IEmsRecordSteamInstantService {
|
||||
@Autowired
|
||||
private EmsRecordSteamInstantMapper emsRecordSteamInstantMapper;
|
||||
|
||||
/**
|
||||
* 查询蒸汽实时数据
|
||||
*
|
||||
* @param objId 蒸汽实时数据主键
|
||||
* @return 蒸汽实时数据
|
||||
*/
|
||||
@Override
|
||||
public EmsRecordSteamInstant selectEmsRecordSteamInstantByObjId(Long objId) {
|
||||
return emsRecordSteamInstantMapper.selectEmsRecordSteamInstantByObjId(objId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询蒸汽实时数据列表
|
||||
*
|
||||
* @param emsRecordSteamInstant 蒸汽实时数据
|
||||
* @return 蒸汽实时数据
|
||||
*/
|
||||
@Override
|
||||
public List<EmsRecordSteamInstant> selectEmsRecordSteamInstantList(EmsRecordSteamInstant emsRecordSteamInstant) {
|
||||
return emsRecordSteamInstantMapper.selectEmsRecordSteamInstantList(emsRecordSteamInstant);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增蒸汽实时数据
|
||||
*
|
||||
* @param emsRecordSteamInstant 蒸汽实时数据
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertEmsRecordSteamInstant(EmsRecordSteamInstant emsRecordSteamInstant) {
|
||||
return emsRecordSteamInstantMapper.insertEmsRecordSteamInstant(emsRecordSteamInstant);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改蒸汽实时数据
|
||||
*
|
||||
* @param emsRecordSteamInstant 蒸汽实时数据
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateEmsRecordSteamInstant(EmsRecordSteamInstant emsRecordSteamInstant) {
|
||||
return emsRecordSteamInstantMapper.updateEmsRecordSteamInstant(emsRecordSteamInstant);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除蒸汽实时数据
|
||||
*
|
||||
* @param objIds 需要删除的蒸汽实时数据主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteEmsRecordSteamInstantByObjIds(Long[] objIds) {
|
||||
return emsRecordSteamInstantMapper.deleteEmsRecordSteamInstantByObjIds(objIds);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除蒸汽实时数据信息
|
||||
*
|
||||
* @param objId 蒸汽实时数据主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteEmsRecordSteamInstantByObjId(Long objId) {
|
||||
return emsRecordSteamInstantMapper.deleteEmsRecordSteamInstantByObjId(objId);
|
||||
}
|
||||
}
|
@ -0,0 +1,129 @@
|
||||
<?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="com.os.ems.record.mapper.EmsRecordSteamInstantMapper">
|
||||
|
||||
<resultMap type="EmsRecordSteamInstant" id="EmsRecordSteamInstantResult">
|
||||
<result property="objId" column="obj_id"/>
|
||||
<result property="monitorCode" column="monitor_code"/>
|
||||
<result property="monitorName" column="monitor_name"/>
|
||||
<result property="collectTime" column="collect_time"/>
|
||||
<result property="fluxFlow" column="flux_flow"/>
|
||||
<result property="steamFlow" column="steam_flow"/>
|
||||
<result property="heatInstantValue" column="heat_instant_value"/>
|
||||
<result property="heatTotalValue" column="heat_total_value"/>
|
||||
<result property="temperature" column="temperature"/>
|
||||
<result property="press" column="press"/>
|
||||
<result property="density" column="density"/>
|
||||
<result property="differencePress" column="difference_press"/>
|
||||
<result property="recordTime" column="record_time"/>
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectEmsRecordSteamInstantVo">
|
||||
select ersi.obj_id,
|
||||
ersi.monitor_code,
|
||||
ebmi.monitor_name,
|
||||
ersi.collect_time,
|
||||
ersi.flux_flow,
|
||||
ersi.steam_flow,
|
||||
ersi.heat_instant_value,
|
||||
ersi.heat_total_value,
|
||||
ersi.temperature,
|
||||
ersi.press,
|
||||
ersi.density,
|
||||
ersi.difference_press,
|
||||
ersi.record_time
|
||||
from ems_record_steam_instant ersi
|
||||
left join ems_base_monitor_info ebmi on ersi.monitor_code = ebmi.monitor_code
|
||||
</sql>
|
||||
|
||||
<select id="selectEmsRecordSteamInstantList" parameterType="EmsRecordSteamInstant"
|
||||
resultMap="EmsRecordSteamInstantResult">
|
||||
<include refid="selectEmsRecordSteamInstantVo"/>
|
||||
<where>
|
||||
<if test="monitorCode != null and monitorCode != ''">and ersi.monitor_code = #{monitorCode}</if>
|
||||
<if test="params.beginCollectTime != null and params.beginCollectTime != '' and params.endCollectTime != null and params.endCollectTime != ''">
|
||||
and ersi.collect_time between #{params.beginCollectTime} and #{params.endCollectTime}
|
||||
</if>
|
||||
<if test="fluxFlow != null ">and ersi.flux_flow = #{fluxFlow}</if>
|
||||
<if test="steamFlow != null ">and ersi.steam_flow = #{steamFlow}</if>
|
||||
<if test="heatInstantValue != null ">and ersi.heat_instant_value = #{heatInstantValue}</if>
|
||||
<if test="heatTotalValue != null ">and ersi.heat_total_value = #{heatTotalValue}</if>
|
||||
<if test="temperature != null ">and ersi.temperature = #{temperature}</if>
|
||||
<if test="press != null ">and ersi.press = #{press}</if>
|
||||
<if test="density != null ">and ersi.density = #{density}</if>
|
||||
<if test="differencePress != null ">and ersi.difference_press = #{differencePress}</if>
|
||||
<if test="params.beginRecordTime != null and params.beginRecordTime != '' and params.endRecordTime != null and params.endRecordTime != ''">
|
||||
and ersi.record_time between #{params.beginRecordTime} and #{params.endRecordTime}
|
||||
</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectEmsRecordSteamInstantByObjId" parameterType="Long" resultMap="EmsRecordSteamInstantResult">
|
||||
<include refid="selectEmsRecordSteamInstantVo"/>
|
||||
where ersi.obj_id = #{objId}
|
||||
</select>
|
||||
|
||||
<insert id="insertEmsRecordSteamInstant" parameterType="EmsRecordSteamInstant" useGeneratedKeys="true"
|
||||
keyProperty="objId">
|
||||
insert into ems_record_steam_instant
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="monitorCode != null">monitor_code,</if>
|
||||
<if test="collectTime != null">collect_time,</if>
|
||||
<if test="fluxFlow != null">flux_flow,</if>
|
||||
<if test="steamFlow != null">steam_flow,</if>
|
||||
<if test="heatInstantValue != null">heat_instant_value,</if>
|
||||
<if test="heatTotalValue != null">heat_total_value,</if>
|
||||
<if test="temperature != null">temperature,</if>
|
||||
<if test="press != null">press,</if>
|
||||
<if test="density != null">density,</if>
|
||||
<if test="differencePress != null">difference_press,</if>
|
||||
<if test="recordTime != null">record_time,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="monitorCode != null">#{monitorCode},</if>
|
||||
<if test="collectTime != null">#{collectTime},</if>
|
||||
<if test="fluxFlow != null">#{fluxFlow},</if>
|
||||
<if test="steamFlow != null">#{steamFlow},</if>
|
||||
<if test="heatInstantValue != null">#{heatInstantValue},</if>
|
||||
<if test="heatTotalValue != null">#{heatTotalValue},</if>
|
||||
<if test="temperature != null">#{temperature},</if>
|
||||
<if test="press != null">#{press},</if>
|
||||
<if test="density != null">#{density},</if>
|
||||
<if test="differencePress != null">#{differencePress},</if>
|
||||
<if test="recordTime != null">#{recordTime},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateEmsRecordSteamInstant" parameterType="EmsRecordSteamInstant">
|
||||
update ems_record_steam_instant
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="monitorCode != null">monitor_code = #{monitorCode},</if>
|
||||
<if test="collectTime != null">collect_time = #{collectTime},</if>
|
||||
<if test="fluxFlow != null">flux_flow = #{fluxFlow},</if>
|
||||
<if test="steamFlow != null">steam_flow = #{steamFlow},</if>
|
||||
<if test="heatInstantValue != null">heat_instant_value = #{heatInstantValue},</if>
|
||||
<if test="heatTotalValue != null">heat_total_value = #{heatTotalValue},</if>
|
||||
<if test="temperature != null">temperature = #{temperature},</if>
|
||||
<if test="press != null">press = #{press},</if>
|
||||
<if test="density != null">density = #{density},</if>
|
||||
<if test="differencePress != null">difference_press = #{differencePress},</if>
|
||||
<if test="recordTime != null">record_time = #{recordTime},</if>
|
||||
</trim>
|
||||
where obj_id = #{objId}
|
||||
</update>
|
||||
|
||||
<delete id="deleteEmsRecordSteamInstantByObjId" parameterType="Long">
|
||||
delete
|
||||
from ems_record_steam_instant
|
||||
where obj_id = #{objId}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteEmsRecordSteamInstantByObjIds" parameterType="String">
|
||||
delete from ems_record_steam_instant where obj_id in
|
||||
<foreach item="objId" collection="array" open="(" separator="," close=")">
|
||||
#{objId}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
Loading…
Reference in New Issue