change - 修改电实时、整点数据获取
parent
ee0c2c36f9
commit
f1795b5f63
@ -1,99 +0,0 @@
|
||||
package com.hw.ems.base.controller;
|
||||
|
||||
|
||||
import com.hw.common.core.utils.poi.ExcelUtil;
|
||||
import com.hw.common.core.web.controller.BaseController;
|
||||
import com.hw.common.core.web.domain.AjaxResult;
|
||||
import com.hw.common.core.web.page.TableDataInfo;
|
||||
import com.hw.common.log.annotation.Log;
|
||||
import com.hw.common.log.enums.BusinessType;
|
||||
import com.hw.common.security.annotation.RequiresPermissions;
|
||||
import com.hw.ems.base.domain.CbsMonitorReport;
|
||||
import com.hw.ems.base.service.ICbsMonitorReportService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* CBS抄报Controller
|
||||
*
|
||||
* @author YinQ
|
||||
* @date 2023-10-20
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/base/cbsMonitorReport")
|
||||
public class CbsMonitorReportController extends BaseController
|
||||
{
|
||||
@Autowired
|
||||
private ICbsMonitorReportService cbsMonitorReportService;
|
||||
|
||||
/**
|
||||
* 查询CBS抄报列表
|
||||
*/
|
||||
@RequiresPermissions("base:cbsMonitorReport:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(CbsMonitorReport cbsMonitorReport)
|
||||
{
|
||||
startPage();
|
||||
List<CbsMonitorReport> list = cbsMonitorReportService.selectCbsMonitorReportList(cbsMonitorReport);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出CBS抄报列表
|
||||
*/
|
||||
@RequiresPermissions("base:cbsMonitorReport:export")
|
||||
@Log(title = "CBS抄报", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(HttpServletResponse response, CbsMonitorReport cbsMonitorReport)
|
||||
{
|
||||
List<CbsMonitorReport> list = cbsMonitorReportService.selectCbsMonitorReportList(cbsMonitorReport);
|
||||
ExcelUtil<CbsMonitorReport> util = new ExcelUtil<CbsMonitorReport>(CbsMonitorReport.class);
|
||||
util.exportExcel(response, list, "CBS抄报数据");
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取CBS抄报详细信息
|
||||
*/
|
||||
@RequiresPermissions("base:cbsMonitorReport:query")
|
||||
@GetMapping(value = "/{objId}")
|
||||
public AjaxResult getInfo(@PathVariable("objId") Long objId)
|
||||
{
|
||||
return success(cbsMonitorReportService.selectCbsMonitorReportByObjId(objId));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增CBS抄报
|
||||
*/
|
||||
@RequiresPermissions("base:cbsMonitorReport:add")
|
||||
@Log(title = "CBS抄报", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
public AjaxResult add(@RequestBody CbsMonitorReport cbsMonitorReport)
|
||||
{
|
||||
return toAjax(cbsMonitorReportService.insertCbsMonitorReport(cbsMonitorReport));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改CBS抄报
|
||||
*/
|
||||
@RequiresPermissions("base:cbsMonitorReport:edit")
|
||||
@Log(title = "CBS抄报", businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
public AjaxResult edit(@RequestBody CbsMonitorReport cbsMonitorReport)
|
||||
{
|
||||
return toAjax(cbsMonitorReportService.updateCbsMonitorReport(cbsMonitorReport));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除CBS抄报
|
||||
*/
|
||||
@RequiresPermissions("base:cbsMonitorReport:remove")
|
||||
@Log(title = "CBS抄报", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{objIds}")
|
||||
public AjaxResult remove(@PathVariable Long[] objIds)
|
||||
{
|
||||
return toAjax(cbsMonitorReportService.deleteCbsMonitorReportByObjIds(objIds));
|
||||
}
|
||||
}
|
@ -1,82 +0,0 @@
|
||||
package com.hw.ems.base.mapper;
|
||||
|
||||
|
||||
|
||||
import com.hw.ems.base.domain.CbsMonitorReport;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* CBS抄报Mapper接口
|
||||
*
|
||||
* @author YinQ
|
||||
* @date 2023-10-20
|
||||
*/
|
||||
public interface CbsMonitorReportMapper
|
||||
{
|
||||
/**
|
||||
* 查询CBS抄报
|
||||
*
|
||||
* @param objId CBS抄报主键
|
||||
* @return CBS抄报
|
||||
*/
|
||||
public CbsMonitorReport selectCbsMonitorReportByObjId(Long objId);
|
||||
|
||||
/**
|
||||
* 查询CBS抄报列表
|
||||
*
|
||||
* @param cbsMonitorReport CBS抄报
|
||||
* @return CBS抄报集合
|
||||
*/
|
||||
public List<CbsMonitorReport> selectCbsMonitorReportList(CbsMonitorReport cbsMonitorReport);
|
||||
|
||||
/**
|
||||
* 新增CBS抄报
|
||||
*
|
||||
* @param cbsMonitorReport CBS抄报
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertCbsMonitorReport(CbsMonitorReport cbsMonitorReport);
|
||||
|
||||
/**
|
||||
* 修改CBS抄报
|
||||
*
|
||||
* @param cbsMonitorReport CBS抄报
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateCbsMonitorReport(CbsMonitorReport cbsMonitorReport);
|
||||
|
||||
/**
|
||||
* 删除CBS抄报
|
||||
*
|
||||
* @param objId CBS抄报主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteCbsMonitorReportByObjId(Long objId);
|
||||
|
||||
/**
|
||||
* 批量删除CBS抄报
|
||||
*
|
||||
* @param objIds 需要删除的数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteCbsMonitorReportByObjIds(Long[] objIds);
|
||||
|
||||
|
||||
// /**
|
||||
// * 查询电实时数据
|
||||
// *
|
||||
// * @param emsApiVo CBS抄报
|
||||
// * @return CBS抄报集合
|
||||
// */
|
||||
// public List<CbsMonitorReport> selectRealTimeMonitorList(EmsApiVo emsApiVo);
|
||||
|
||||
/**
|
||||
* 查询上次CBS抄表数据
|
||||
*
|
||||
* @param cbsMonitorReport CBS抄报主键
|
||||
* @return CBS抄报
|
||||
*/
|
||||
public CbsMonitorReport selectLastTimeCbsMonitorReport(CbsMonitorReport cbsMonitorReport);
|
||||
|
||||
}
|
@ -1,80 +0,0 @@
|
||||
package com.hw.ems.base.service;
|
||||
|
||||
|
||||
import com.hw.ems.base.domain.CbsMonitorReport;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* CBS抄报Service接口
|
||||
*
|
||||
* @author YinQ
|
||||
* @date 2023-10-20
|
||||
*/
|
||||
public interface ICbsMonitorReportService
|
||||
{
|
||||
/**
|
||||
* 查询CBS抄报
|
||||
*
|
||||
* @param objId CBS抄报主键
|
||||
* @return CBS抄报
|
||||
*/
|
||||
public CbsMonitorReport selectCbsMonitorReportByObjId(Long objId);
|
||||
|
||||
/**
|
||||
* 查询CBS抄报列表
|
||||
*
|
||||
* @param cbsMonitorReport CBS抄报
|
||||
* @return CBS抄报集合
|
||||
*/
|
||||
public List<CbsMonitorReport> selectCbsMonitorReportList(CbsMonitorReport cbsMonitorReport);
|
||||
|
||||
/**
|
||||
* 新增CBS抄报
|
||||
*
|
||||
* @param cbsMonitorReport CBS抄报
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertCbsMonitorReport(CbsMonitorReport cbsMonitorReport);
|
||||
|
||||
/**
|
||||
* 修改CBS抄报
|
||||
*
|
||||
* @param cbsMonitorReport CBS抄报
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateCbsMonitorReport(CbsMonitorReport cbsMonitorReport);
|
||||
|
||||
/**
|
||||
* 批量删除CBS抄报
|
||||
*
|
||||
* @param objIds 需要删除的CBS抄报主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteCbsMonitorReportByObjIds(Long[] objIds);
|
||||
|
||||
/**
|
||||
* 删除CBS抄报信息
|
||||
*
|
||||
* @param objId CBS抄报主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteCbsMonitorReportByObjId(Long objId);
|
||||
|
||||
// /**
|
||||
// * 查询实时数据
|
||||
// *
|
||||
// * @param emsApiVo CBS抄报
|
||||
// * @return CBS抄报集合
|
||||
// */
|
||||
// public List<CbsMonitorReport> selectRealTimeMonitorList(EmsApiVo emsApiVo);
|
||||
|
||||
/**
|
||||
* 查询上次CBS抄表数据
|
||||
*
|
||||
* @param cbsMonitorReport CBS抄报主键
|
||||
* @return CBS抄报
|
||||
*/
|
||||
public CbsMonitorReport selectLastTimeCbsMonitorReport(CbsMonitorReport cbsMonitorReport);
|
||||
|
||||
}
|
@ -1,132 +0,0 @@
|
||||
package com.hw.ems.base.service.impl;
|
||||
|
||||
import com.hw.common.core.utils.DateUtils;
|
||||
import com.hw.ems.base.domain.CbsMonitorReport;
|
||||
import com.hw.ems.base.mapper.CbsMonitorReportMapper;
|
||||
import com.hw.ems.base.service.ICbsMonitorReportService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* CBS抄报Service业务层处理
|
||||
*
|
||||
* @author YinQ
|
||||
* @date 2023-10-20
|
||||
*/
|
||||
@Service
|
||||
public class CbsMonitorReportServiceImpl implements ICbsMonitorReportService
|
||||
{
|
||||
@Autowired
|
||||
private CbsMonitorReportMapper cbsMonitorReportMapper;
|
||||
|
||||
/**
|
||||
* 查询CBS抄报
|
||||
*
|
||||
* @param objId CBS抄报主键
|
||||
* @return CBS抄报
|
||||
*/
|
||||
@Override
|
||||
// @DS("#header.poolName")
|
||||
public CbsMonitorReport selectCbsMonitorReportByObjId(Long objId)
|
||||
{
|
||||
return cbsMonitorReportMapper.selectCbsMonitorReportByObjId(objId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询CBS抄报列表
|
||||
*
|
||||
* @param cbsMonitorReport CBS抄报
|
||||
* @return CBS抄报
|
||||
*/
|
||||
@Override
|
||||
// @DS("#header.poolName")
|
||||
public List<CbsMonitorReport> selectCbsMonitorReportList(CbsMonitorReport cbsMonitorReport)
|
||||
{
|
||||
return cbsMonitorReportMapper.selectCbsMonitorReportList(cbsMonitorReport);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增CBS抄报
|
||||
*
|
||||
* @param cbsMonitorReport CBS抄报
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
// @DS("#header.poolName")
|
||||
public int insertCbsMonitorReport(CbsMonitorReport cbsMonitorReport)
|
||||
{
|
||||
cbsMonitorReport.setCreateTime(DateUtils.getNowDate());
|
||||
return cbsMonitorReportMapper.insertCbsMonitorReport(cbsMonitorReport);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改CBS抄报
|
||||
*
|
||||
* @param cbsMonitorReport CBS抄报
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
// @DS("#header.poolName")
|
||||
public int updateCbsMonitorReport(CbsMonitorReport cbsMonitorReport)
|
||||
{
|
||||
cbsMonitorReport.setUpdateTime(DateUtils.getNowDate());
|
||||
return cbsMonitorReportMapper.updateCbsMonitorReport(cbsMonitorReport);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除CBS抄报
|
||||
*
|
||||
* @param objIds 需要删除的CBS抄报主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
// @DS("#header.poolName")
|
||||
public int deleteCbsMonitorReportByObjIds(Long[] objIds)
|
||||
{
|
||||
return cbsMonitorReportMapper.deleteCbsMonitorReportByObjIds(objIds);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除CBS抄报信息
|
||||
*
|
||||
* @param objId CBS抄报主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
// @DS("#header.poolName")
|
||||
public int deleteCbsMonitorReportByObjId(Long objId)
|
||||
{
|
||||
return cbsMonitorReportMapper.deleteCbsMonitorReportByObjId(objId);
|
||||
}
|
||||
|
||||
//
|
||||
|
||||
|
||||
// /**
|
||||
// * 查询实时数据
|
||||
// * @param emsApiVo CBS抄报
|
||||
// * @return
|
||||
// */
|
||||
// @Override
|
||||
// @DS("#header.poolName")
|
||||
// public List<CbsMonitorReport> selectRealTimeMonitorList(EmsApiVo emsApiVo)
|
||||
// {
|
||||
// return cbsMonitorReportMapper.selectRealTimeMonitorList(emsApiVo);
|
||||
// }
|
||||
|
||||
/**
|
||||
* 查询上次CBS抄表数据
|
||||
*
|
||||
* @param cbsMonitorReport CBS抄报主键
|
||||
* @return CBS抄报
|
||||
*/
|
||||
@Override
|
||||
// @DS("#header.poolName")
|
||||
public CbsMonitorReport selectLastTimeCbsMonitorReport(CbsMonitorReport cbsMonitorReport)
|
||||
{
|
||||
return cbsMonitorReportMapper.selectLastTimeCbsMonitorReport(cbsMonitorReport);
|
||||
}
|
||||
|
||||
}
|
@ -1,212 +0,0 @@
|
||||
<?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.hw.ems.base.mapper.CbsMonitorReportMapper">
|
||||
|
||||
<resultMap type="CbsMonitorReport" id="CbsMonitorReportResult">
|
||||
<result property="objId" column="obj_id" />
|
||||
<result property="monitorId" column="monitor_id" />
|
||||
<result property="monitorName" column="monitor_name" />
|
||||
<result property="monitorType" column="monitor_type" />
|
||||
<result property="publicShareType" column="public_share_type" />
|
||||
<result property="roomCode" column="room_code" />
|
||||
<result property="roomName" column="room_name" />
|
||||
<result property="roomName" column="room_name" />
|
||||
<result property="buildCode" column="build_code" />
|
||||
<result property="buildName" column="build_name" />
|
||||
<result property="isBind" column="is_bind" />
|
||||
<result property="lastMonitorTime" column="last_monitor_time" />
|
||||
<result property="lastMonitorExpend" column="last_monitor_expend" />
|
||||
<result property="thisMonitorTime" column="this_monitor_time" />
|
||||
<result property="thisMonitorExpend" column="this_monitor_expend" />
|
||||
<result property="lastFlag" column="last_flag" />
|
||||
<result property="thisFlag" column="this_flag" />
|
||||
<result property="remark" column="remark" />
|
||||
<result property="createBy" column="create_by" />
|
||||
<result property="createTime" column="create_time" />
|
||||
<result property="updateBy" column="update_by" />
|
||||
<result property="updateTime" column="update_time" />
|
||||
<result property="physicalCode" column="physical_code" />
|
||||
<result property="loadingPosition" column="loadingPosition" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectCbsMonitorReportVo">
|
||||
select obj_id, monitor_id, monitor_name, monitor_type, public_share_type,
|
||||
room_code, room_name,physical_code, build_code, build_name, is_bind, last_monitor_time, last_monitor_expend, this_monitor_time, this_monitor_expend, last_flag, this_flag, remark, create_by, create_time, update_by, update_time from cbs_monitor_report
|
||||
</sql>
|
||||
|
||||
<select id="selectCbsMonitorReportList" parameterType="CbsMonitorReport" resultMap="CbsMonitorReportResult">
|
||||
<include refid="selectCbsMonitorReportVo"/>
|
||||
<where>
|
||||
<if test="monitorId != null and monitorId != ''"> and monitor_id = #{monitorId}</if>
|
||||
<if test="monitorName != null and monitorName != ''"> and monitor_name like concat('%', #{monitorName}, '%')</if>
|
||||
<if test="monitorType != null and monitorType != ''"> and monitor_type = #{monitorType}</if>
|
||||
<if test="publicShareType != null and publicShareType != ''"> and public_share_type = #{publicShareType}</if>
|
||||
<if test="roomName != null and roomName != ''"> and room_name like concat('%', #{roomName}, '%')</if>
|
||||
<if test="buildCode != null and buildCode != ''"> and build_code = #{buildCode}</if>
|
||||
<if test="buildName != null and buildName != ''"> and build_name like concat('%', #{buildName}, '%')</if>
|
||||
<if test="isBind != null and isBind != ''"> and is_bind = #{isBind}</if>
|
||||
<if test="lastMonitorTime != null "> and last_monitor_time = #{lastMonitorTime}</if>
|
||||
<if test="lastMonitorExpend != null "> and last_monitor_expend = #{lastMonitorExpend}</if>
|
||||
<if test="thisMonitorTime != null "> and this_monitor_time = #{thisMonitorTime}</if>
|
||||
<if test="thisMonitorExpend != null "> and this_monitor_expend = #{thisMonitorExpend}</if>
|
||||
<if test="lastFlag != null and lastFlag != ''"> and last_flag = #{lastFlag}</if>
|
||||
<if test="thisFlag != null and thisFlag != ''"> and this_flag = #{thisFlag}</if>
|
||||
<if test="roomCode != null and roomCode != '' ">
|
||||
and room_code IN
|
||||
<foreach collection="roomCode.split(',')" index="index" item="item" open="(" separator=","
|
||||
close=")">
|
||||
#{item}
|
||||
</foreach>
|
||||
</if>
|
||||
</where>
|
||||
order by create_time desc
|
||||
</select>
|
||||
|
||||
<select id="selectCbsMonitorReportByObjId" parameterType="Long" resultMap="CbsMonitorReportResult">
|
||||
<include refid="selectCbsMonitorReportVo"/>
|
||||
where obj_id = #{objId}
|
||||
</select>
|
||||
|
||||
<!-- <select id="selectRealTimeMonitorList" parameterType="EmsApiVo" resultMap="CbsMonitorReportResult">-->
|
||||
<!-- SELECT bmi.monitor_id,-->
|
||||
<!-- bmi.monitor_name,-->
|
||||
<!-- bmi.monitor_type,-->
|
||||
<!-- bmi.public_share_type,-->
|
||||
<!-- bmi.room_code,-->
|
||||
<!-- bmi.room_name,-->
|
||||
<!-- bmi.physical_code,-->
|
||||
<!-- bmi.monitor_addr loadingPosition,-->
|
||||
<!-- '0' AS is_bind,-->
|
||||
<!-- sysdate() AS this_monitor_time,-->
|
||||
<!-- rdi.this_monitor_expend * IF(ISNULL(bmi.ct), 1, bmi.ct) * IF(ISNULL(bmi.pt), 1, bmi.pt) AS this_monitor_expend,-->
|
||||
<!-- IF(rdi.this_monitor_expend IS NOT NULL, '0', '1') AS this_flag-->
|
||||
<!-- FROM base_monitor_info bmi-->
|
||||
<!-- LEFT JOIN (-->
|
||||
<!-- SELECT t1.monitor_id, t1.water_flow AS this_monitor_expend-->
|
||||
<!-- FROM record_water_instant t1-->
|
||||
<!-- JOIN (-->
|
||||
<!-- SELECT monitor_id, MAX(collect_time) AS max_time-->
|
||||
<!-- FROM record_water_instant-->
|
||||
<!-- <if test="meterReadingTime != null and meterReadingTime != ''">-->
|
||||
<!-- where collect_time < #{meterReadingTime}-->
|
||||
<!-- </if>-->
|
||||
<!-- GROUP BY monitor_id-->
|
||||
<!-- ) t2 ON t1.monitor_id = t2.monitor_id AND t1.collect_time = t2.max_time-->
|
||||
<!-- UNION ALL-->
|
||||
<!-- SELECT t1.monitor_id, t1.zxyg AS this_monitor_expend-->
|
||||
<!-- FROM record_dnb_instant t1-->
|
||||
<!-- JOIN (-->
|
||||
<!-- SELECT monitor_id, MAX(collect_time) AS max_time-->
|
||||
<!-- FROM record_dnb_instant-->
|
||||
<!-- <if test="meterReadingTime != null and meterReadingTime != ''">-->
|
||||
<!-- where collect_time < #{meterReadingTime}-->
|
||||
<!-- </if>-->
|
||||
<!-- GROUP BY monitor_id-->
|
||||
<!-- ) t2 ON t1.monitor_id = t2.monitor_id AND t1.collect_time = t2.max_time-->
|
||||
<!-- ) AS rdi ON rdi.monitor_id = bmi.monitor_id-->
|
||||
<!-- WHERE bmi.room_code IS NOT NULL-->
|
||||
<!-- <if test="monitorIdList != null and monitorIdList.size > 0">-->
|
||||
<!-- and bmi.monitor_id IN-->
|
||||
<!-- <foreach item="monitorId" collection="monitorIdList" open="(" separator="," close=")">-->
|
||||
<!-- #{monitorId}-->
|
||||
<!-- </foreach>-->
|
||||
<!-- </if>-->
|
||||
<!-- </select>-->
|
||||
<!-- <select id="selectLastTimeCbsMonitorReport" parameterType="CbsMonitorReport" resultMap="CbsMonitorReportResult">-->
|
||||
<!-- <include refid="selectCbsMonitorReportVo"/>-->
|
||||
<!-- <if test="monitorId != null and monitorId != ''"> where monitor_id = #{monitorId}</if>-->
|
||||
<!-- order by this_monitor_time desc-->
|
||||
<!-- limit 1-->
|
||||
<!-- </select>-->
|
||||
|
||||
<insert id="insertCbsMonitorReport" parameterType="CbsMonitorReport" useGeneratedKeys="true" keyProperty="objId">
|
||||
insert into cbs_monitor_report
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="monitorId != null">monitor_id,</if>
|
||||
<if test="monitorName != null">monitor_name,</if>
|
||||
<if test="monitorType != null">monitor_type,</if>
|
||||
<if test="publicShareType != null">public_share_type,</if>
|
||||
<if test="roomCode != null">room_code,</if>
|
||||
<if test="roomName != null">room_name,</if>
|
||||
<if test="buildCode != null">build_code,</if>
|
||||
<if test="buildName != null">build_name,</if>
|
||||
<if test="isBind != null">is_bind,</if>
|
||||
<if test="lastMonitorTime != null">last_monitor_time,</if>
|
||||
<if test="lastMonitorExpend != null">last_monitor_expend,</if>
|
||||
<if test="thisMonitorTime != null">this_monitor_time,</if>
|
||||
<if test="thisMonitorExpend != null">this_monitor_expend,</if>
|
||||
<if test="lastFlag != null">last_flag,</if>
|
||||
<if test="thisFlag != null">this_flag,</if>
|
||||
<if test="remark != null">remark,</if>
|
||||
<if test="createBy != null">create_by,</if>
|
||||
<if test="createTime != null">create_time,</if>
|
||||
<if test="updateBy != null">update_by,</if>
|
||||
<if test="updateTime != null">update_time,</if>
|
||||
<if test="physicalCode != null">physical_code,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="monitorId != null">#{monitorId},</if>
|
||||
<if test="monitorName != null">#{monitorName},</if>
|
||||
<if test="monitorType != null">#{monitorType},</if>
|
||||
<if test="publicShareType != null">#{publicShareType},</if>
|
||||
<if test="roomCode != null">#{roomCode},</if>
|
||||
<if test="roomName != null">#{roomName},</if>
|
||||
<if test="buildCode != null">#{buildCode},</if>
|
||||
<if test="buildName != null">#{buildName},</if>
|
||||
<if test="isBind != null">#{isBind},</if>
|
||||
<if test="lastMonitorTime != null">#{lastMonitorTime},</if>
|
||||
<if test="lastMonitorExpend != null">#{lastMonitorExpend},</if>
|
||||
<if test="thisMonitorTime != null">#{thisMonitorTime},</if>
|
||||
<if test="thisMonitorExpend != null">#{thisMonitorExpend},</if>
|
||||
<if test="lastFlag != null">#{lastFlag},</if>
|
||||
<if test="thisFlag != null">#{thisFlag},</if>
|
||||
<if test="remark != null">#{remark},</if>
|
||||
<if test="createBy != null">#{createBy},</if>
|
||||
<if test="createTime != null">#{createTime},</if>
|
||||
<if test="updateBy != null">#{updateBy},</if>
|
||||
<if test="updateTime != null">#{updateTime},</if>
|
||||
<if test="physicalCode != null">#{physicalCode},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateCbsMonitorReport" parameterType="CbsMonitorReport">
|
||||
update cbs_monitor_report
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="monitorId != null">monitor_id = #{monitorId},</if>
|
||||
<if test="monitorName != null">monitor_name = #{monitorName},</if>
|
||||
<if test="monitorType != null">monitor_type = #{monitorType},</if>
|
||||
<if test="publicShareType != null">public_share_type = #{publicShareType},</if>
|
||||
<if test="roomCode != null">room_code = #{roomCode},</if>
|
||||
<if test="roomName != null">room_name = #{roomName},</if>
|
||||
<if test="buildCode != null">build_code = #{buildCode},</if>
|
||||
<if test="buildName != null">build_name = #{buildName},</if>
|
||||
<if test="isBind != null">is_bind = #{isBind},</if>
|
||||
<if test="lastMonitorTime != null">last_monitor_time = #{lastMonitorTime},</if>
|
||||
<if test="lastMonitorExpend != null">last_monitor_expend = #{lastMonitorExpend},</if>
|
||||
<if test="thisMonitorTime != null">this_monitor_time = #{thisMonitorTime},</if>
|
||||
<if test="thisMonitorExpend != null">this_monitor_expend = #{thisMonitorExpend},</if>
|
||||
<if test="lastFlag != null">last_flag = #{lastFlag},</if>
|
||||
<if test="thisFlag != null">this_flag = #{thisFlag},</if>
|
||||
<if test="remark != null">remark = #{remark},</if>
|
||||
<if test="createBy != null">create_by = #{createBy},</if>
|
||||
<if test="createTime != null">create_time = #{createTime},</if>
|
||||
<if test="updateBy != null">update_by = #{updateBy},</if>
|
||||
<if test="updateTime != null">update_time = #{updateTime},</if>
|
||||
<if test="physicalCode != null">physical_code = #{physicalCode},</if>
|
||||
</trim>
|
||||
where obj_id = #{objId}
|
||||
</update>
|
||||
|
||||
<delete id="deleteCbsMonitorReportByObjId" parameterType="Long">
|
||||
delete from cbs_monitor_report where obj_id = #{objId}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteCbsMonitorReportByObjIds" parameterType="String">
|
||||
delete from cbs_monitor_report where obj_id in
|
||||
<foreach item="objId" collection="array" open="(" separator="," close=")">
|
||||
#{objId}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
@ -0,0 +1,50 @@
|
||||
import request from '@/utils/request'
|
||||
import { parseStrEmpty } from "@/utils/ruoyi";
|
||||
import qs from 'qs';
|
||||
// 查询用户列表1
|
||||
export function listUser(data) {
|
||||
return request({
|
||||
url: '/ems/report/preview/consumptionReport/2',
|
||||
method: 'post',
|
||||
data: qs.stringify(data),
|
||||
contentType:'application/x-www-form-urlencoded',
|
||||
})
|
||||
}
|
||||
|
||||
export function consumptionAll(data) {
|
||||
return request({
|
||||
url: '/ems/report/preview/consumptionAll/2',
|
||||
method: 'post',
|
||||
data: qs.stringify(data),
|
||||
contentType:'application/x-www-form-urlencoded',
|
||||
})
|
||||
}
|
||||
|
||||
// 查询部门下拉树结构
|
||||
export function deptTreeSelect() {
|
||||
return request({
|
||||
url: '/ems/base/monitorInfo/treeData/2',
|
||||
method: 'get'
|
||||
})
|
||||
}
|
||||
// 真查询部门下拉树结构 建筑
|
||||
export function treeDat() {
|
||||
return request({
|
||||
url: '/ems/buildInfo/treeData',
|
||||
method: 'get'
|
||||
})
|
||||
}
|
||||
//业态
|
||||
export function treeDattwo() {
|
||||
return request({
|
||||
url: '/ems/businessType/treeData',
|
||||
method: 'get'
|
||||
})
|
||||
}
|
||||
//分页
|
||||
export function treeDatthree() {
|
||||
return request({
|
||||
url: '/ems/subentryType/treeData',
|
||||
method: 'get'
|
||||
})
|
||||
}
|
@ -0,0 +1,55 @@
|
||||
import request from '@/utils/request'
|
||||
import { parseStrEmpty } from "@/utils/ruoyi";
|
||||
import qs from 'qs';
|
||||
|
||||
// 查询用户列表
|
||||
export function listUser(data) {
|
||||
return request({
|
||||
url: '/ems/report/analysis/emsStatisticsData',
|
||||
method: 'post',
|
||||
data: qs.stringify(data),
|
||||
contentType:'application/x-www-form-urlencoded',
|
||||
//formdata:true,
|
||||
})
|
||||
}
|
||||
// 查询底部列表
|
||||
export function instantLis(data) {
|
||||
return request({
|
||||
url: '/ems/record/dnbInstant/instantList',
|
||||
method: 'get',
|
||||
params: data
|
||||
})
|
||||
}
|
||||
|
||||
// 真查询部门下拉树结构
|
||||
export function treeDat() {
|
||||
return request({
|
||||
url: '/ems/base/monitorInfo/treeData/2',
|
||||
method: 'get'
|
||||
})
|
||||
}
|
||||
//
|
||||
// // 一键秒表
|
||||
// export function editMeterReading(data) {
|
||||
// return request({
|
||||
// url: '/ems/config/editMeterReading',
|
||||
// method: 'post',
|
||||
// data: data,
|
||||
// //contentType:'application/x-www-form-urlencoded',
|
||||
// })
|
||||
// }
|
||||
export function previewPolyline(params) {
|
||||
return request({
|
||||
url: '/ems/report/board/previewPolyline',
|
||||
method: 'get',
|
||||
params: params
|
||||
})
|
||||
}
|
||||
|
||||
export function dailyLossReport(params) {
|
||||
return request({
|
||||
url: '/ems/report/board/dailyLossReport',
|
||||
method: 'get',
|
||||
params: params
|
||||
})
|
||||
}
|
@ -0,0 +1,26 @@
|
||||
import request from '@/utils/request'
|
||||
import { parseStrEmpty } from "@/utils/ruoyi";
|
||||
import qs from 'qs';
|
||||
// 查询用户列表1
|
||||
export function listUser(data) {
|
||||
return request({
|
||||
url: '/ems/record/dnbInstant/list',
|
||||
method: 'post',
|
||||
data: data,
|
||||
})
|
||||
}
|
||||
// 查询部门下拉树结构
|
||||
export function treeDat() {
|
||||
return request({
|
||||
url: '/ems/base/monitorInfo/treeData/2',
|
||||
method: 'get'
|
||||
})
|
||||
}
|
||||
|
||||
// 删除电实时数据
|
||||
export function delDnbRemoveInstant(objid) {
|
||||
return request({
|
||||
url: '/ems/record/dnbInstant/dnbRemove/' + objid,
|
||||
method: 'get'
|
||||
})
|
||||
}
|
@ -0,0 +1,51 @@
|
||||
import request from '@/utils/request'
|
||||
import { parseStrEmpty } from "@/utils/ruoyi";
|
||||
import qs from 'qs';
|
||||
|
||||
// 查询用户列表
|
||||
export function listUser(data) {
|
||||
return request({
|
||||
url: '/ems/record/dnbInstant/selectRealTimeList',
|
||||
method: 'post',
|
||||
data: qs.stringify(data),
|
||||
contentType:'application/x-www-form-urlencoded',
|
||||
timeout: 1000 * 60,
|
||||
//formdata:true,
|
||||
})
|
||||
}
|
||||
// 查询底部列表
|
||||
export function instantLis(data) {
|
||||
return request({
|
||||
url: '/ems/record/dnbInstant/instantList',
|
||||
method: 'get',
|
||||
params: data,
|
||||
timeout: 1000 * 60,
|
||||
})
|
||||
}
|
||||
|
||||
// 真查询部门下拉树结构
|
||||
export function treeDat() {
|
||||
return request({
|
||||
url: '/ems/base/monitorInfo/treeData/2',
|
||||
method: 'get'
|
||||
})
|
||||
}
|
||||
//
|
||||
// 一键秒表
|
||||
export function editMeterReading(data) {
|
||||
return request({
|
||||
url: '/ems/config/editMeterReading',
|
||||
method: 'post',
|
||||
data: qs.stringify(data),
|
||||
contentType:'application/x-www-form-urlencoded',
|
||||
})
|
||||
}
|
||||
// 一键秒表
|
||||
export function voltageCurrentCurve(data) {
|
||||
return request({
|
||||
url: '/ems/record/dnbInstant/voltageCurrentCurve',
|
||||
method: 'post',
|
||||
data: qs.stringify(data),
|
||||
contentType:'application/x-www-form-urlencoded',
|
||||
})
|
||||
}
|
@ -0,0 +1,19 @@
|
||||
import request from '@/utils/request'
|
||||
import { parseStrEmpty } from "@/utils/ruoyi";
|
||||
|
||||
// 柱状图1
|
||||
export function dnbCountingData(query) {
|
||||
return request({
|
||||
url: '/ems/report/analysis/emsMomAnalysisData',
|
||||
method: 'get',
|
||||
params: query
|
||||
})
|
||||
}
|
||||
|
||||
// 查询部门下拉树结构
|
||||
export function deptTreeSelect() {
|
||||
return request({
|
||||
url: '/ems/base/monitorInfo/treeData/2',
|
||||
method: 'get'
|
||||
})
|
||||
}
|
@ -0,0 +1,45 @@
|
||||
import request from '@/utils/request'
|
||||
import { parseStrEmpty } from "@/utils/ruoyi";
|
||||
import qs from 'qs';
|
||||
|
||||
// 查询列表1
|
||||
export function listUser(data) {
|
||||
return request({
|
||||
url: '/ems/report/pointDnb/list',
|
||||
method: 'post',
|
||||
data: qs.stringify(data),
|
||||
contentType:'application/x-www-form-urlencoded',
|
||||
})
|
||||
}
|
||||
//日月年列表查询接口
|
||||
export function listUser2(data) {
|
||||
return request({
|
||||
url: '/ems/report/pointDnb/datePointDnbList',
|
||||
method: 'post',
|
||||
data: qs.stringify(data),
|
||||
contentType:'application/x-www-form-urlencoded',
|
||||
})
|
||||
}
|
||||
// 柱状图1
|
||||
export function dnbCountingData(query) {
|
||||
return request({
|
||||
url: '/ems/report/board/dnbCountingData',
|
||||
method: 'get',
|
||||
params: query
|
||||
})
|
||||
}
|
||||
// 真查询部门下拉树结构
|
||||
export function treeDat() {
|
||||
return request({
|
||||
url: '/ems/base/monitorInfo/treeData/2',
|
||||
method: 'get'
|
||||
})
|
||||
}
|
||||
|
||||
// 查询部门下拉树结构
|
||||
export function deptTreeSelect() {
|
||||
return request({
|
||||
url: '/system/user/deptTree',
|
||||
method: 'get'
|
||||
})
|
||||
}
|
@ -0,0 +1,61 @@
|
||||
import request from '@/utils/request'
|
||||
import { parseStrEmpty } from "@/utils/ruoyi";
|
||||
import qs from 'qs';
|
||||
|
||||
// 查询用户列表
|
||||
export function listUser(data) {
|
||||
return request({
|
||||
url: '/ems/record/dnbInstant/list',
|
||||
method: 'post',
|
||||
data: qs.stringify(data),
|
||||
contentType:'application/x-www-form-urlencoded',
|
||||
})
|
||||
}
|
||||
|
||||
// 新增
|
||||
export function addUser(data) {
|
||||
return request({
|
||||
url: '/ems/record/dnbInstant/add',
|
||||
method: 'post',
|
||||
data: qs.stringify(data),
|
||||
contentType:'application/x-www-form-urlencoded',
|
||||
})
|
||||
}
|
||||
|
||||
// 修改
|
||||
export function updateUser(data) {
|
||||
return request({
|
||||
url: '/ems/record/dnbInstant/edit',
|
||||
method: 'post',
|
||||
data: qs.stringify(data),
|
||||
contentType:'application/x-www-form-urlencoded',
|
||||
})
|
||||
}
|
||||
|
||||
// 删除用户
|
||||
export function delUser(data) {
|
||||
return request({
|
||||
url: '/ems/record/dnbInstant/remove',
|
||||
method: 'post',
|
||||
data: qs.stringify(data),
|
||||
contentType:'application/x-www-form-urlencoded',
|
||||
})
|
||||
}
|
||||
|
||||
// 查询部门下拉树结构
|
||||
export function deptTreeSelect() {
|
||||
return request({
|
||||
url: '/ems/base/monitorInfo/treeData/2',
|
||||
method: 'get'
|
||||
})
|
||||
}
|
||||
|
||||
// 新增光伏发电整点数据
|
||||
export function addReportPointDnb(data) {
|
||||
return request({
|
||||
url: '/ems/report/pointDnb/addPhotovoltaicPower',
|
||||
method: 'post',
|
||||
data: qs.stringify(data),
|
||||
contentType:'application/x-www-form-urlencoded',
|
||||
})
|
||||
}
|
@ -0,0 +1,27 @@
|
||||
import request from '@/utils/request'
|
||||
import { parseStrEmpty } from "@/utils/ruoyi";
|
||||
import qs from 'qs';
|
||||
// 查询用户列表1
|
||||
export function listUser(data) {
|
||||
return request({
|
||||
url: '/ems/record/dnbInstant/list',
|
||||
method: 'post',
|
||||
data: qs.stringify(data),
|
||||
contentType:'application/x-www-form-urlencoded',
|
||||
})
|
||||
}
|
||||
// 柱状图1
|
||||
export function dnbCountingData(query) {
|
||||
return request({
|
||||
url: '/report/board/dnbCountingData',
|
||||
method: 'get',
|
||||
params: query
|
||||
})
|
||||
}
|
||||
// 查询部门下拉树结构
|
||||
export function deptTreeSelect() {
|
||||
return request({
|
||||
url: '/ems/base/monitorInfo/treeData/2',
|
||||
method: 'get'
|
||||
})
|
||||
}
|
@ -0,0 +1,19 @@
|
||||
import request from '@/utils/request'
|
||||
import { parseStrEmpty } from "@/utils/ruoyi";
|
||||
|
||||
// 柱状图1
|
||||
export function dnbCountingData(query) {
|
||||
return request({
|
||||
url: '/ems/report/analysis/emsYoyAnalysisData',
|
||||
method: 'get',
|
||||
params: query
|
||||
})
|
||||
}
|
||||
|
||||
// 查询部门下拉树结构
|
||||
export function deptTreeSelect() {
|
||||
return request({
|
||||
url: '/ems/base/monitorInfo/treeData/2',
|
||||
method: 'get'
|
||||
})
|
||||
}
|
@ -0,0 +1,28 @@
|
||||
import request from '@/utils/request'
|
||||
import { parseStrEmpty } from "@/utils/ruoyi";
|
||||
import qs from 'qs';
|
||||
// 查询用户列表1
|
||||
export function listUser(data) {
|
||||
return request({
|
||||
url: '/ems/report/analysis/lineLossAnalysisData',
|
||||
method: 'post',
|
||||
data: qs.stringify(data),
|
||||
contentType:'application/x-www-form-urlencoded',
|
||||
})
|
||||
}
|
||||
// 查询部门下拉树结构
|
||||
export function treeDat() {
|
||||
return request({
|
||||
url: '/ems/base/monitorInfo/treeData/2',
|
||||
method: 'get'
|
||||
})
|
||||
}
|
||||
//report/analysis/lineLossAnalysisDetailsData
|
||||
export function listUser2(data) {
|
||||
return request({
|
||||
url: '/ems/report/analysis/lineLossAnalysisDetailsData',
|
||||
method: 'post',
|
||||
data: qs.stringify(data),
|
||||
contentType:'application/x-www-form-urlencoded',
|
||||
})
|
||||
}
|
Loading…
Reference in New Issue