Merge remote-tracking branch 'origin/master'
# Conflicts: # ruoyi-modules/hw-mqtt-broker/src/main/java/com/hw/mqtt/HwMqttBrokerApplication.java # ruoyi-modules/hw-mqtt-broker/src/main/resources/bootstrap.ymlmaster
commit
2431cdee2e
File diff suppressed because it is too large
Load Diff
Binary file not shown.
|
After Width: | Height: | Size: 196 KiB |
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -0,0 +1,63 @@
|
||||
package com.ruoyi.tdengine.api.domain;
|
||||
|
||||
import com.ruoyi.common.core.web.domain.BaseEntity;
|
||||
|
||||
/**
|
||||
* @Description: 设备状态对象
|
||||
* @ClassName: DeviceStatus
|
||||
* @Author : xins
|
||||
* @Date :2023-09-05 11:35
|
||||
* @Version :1.0
|
||||
*/
|
||||
public class DeviceStatus extends BaseEntity {
|
||||
|
||||
private Long ts;
|
||||
|
||||
private String deviceCode;
|
||||
|
||||
private int deviceType;
|
||||
|
||||
private int onlineStatus;
|
||||
|
||||
private Long sceneId;
|
||||
|
||||
public Long getTs() {
|
||||
return ts;
|
||||
}
|
||||
|
||||
public void setTs(Long ts) {
|
||||
this.ts = ts;
|
||||
}
|
||||
|
||||
public String getDeviceCode() {
|
||||
return deviceCode;
|
||||
}
|
||||
|
||||
public void setDeviceCode(String deviceCode) {
|
||||
this.deviceCode = deviceCode;
|
||||
}
|
||||
|
||||
public int getDeviceType() {
|
||||
return deviceType;
|
||||
}
|
||||
|
||||
public void setDeviceType(int deviceType) {
|
||||
this.deviceType = deviceType;
|
||||
}
|
||||
|
||||
public int getOnlineStatus() {
|
||||
return onlineStatus;
|
||||
}
|
||||
|
||||
public void setOnlineStatus(int onlineStatus) {
|
||||
this.onlineStatus = onlineStatus;
|
||||
}
|
||||
|
||||
public Long getSceneId() {
|
||||
return sceneId;
|
||||
}
|
||||
|
||||
public void setSceneId(Long sceneId) {
|
||||
this.sceneId = sceneId;
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,6 @@
|
||||
public class test {
|
||||
|
||||
public static void main(String[] args) {
|
||||
System.out.println(System.currentTimeMillis());
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,2 @@
|
||||
com.ruoyi.tdengine.api.factory.RemoteTdEngineFallbackFactory
|
||||
|
||||
@ -0,0 +1,29 @@
|
||||
package com.ruoyi.common.core.constant;
|
||||
|
||||
/**
|
||||
* @Description: 平台常量字典信息
|
||||
* @ClassName: HwDictConstants
|
||||
* @Author : xins
|
||||
* @Date :2023-09-03 12:27
|
||||
* @Version :1.0
|
||||
*/
|
||||
public class HwDictConstants {
|
||||
|
||||
public static final String EFFECTIVE_TIME_FLAG_LONG = "1";//长期有效
|
||||
public static final String EFFECTIVE_TIME_FLAG_RANGE = "2";//时间范围
|
||||
|
||||
public static final String AREA_SHAPE_FLAG_POLYGN = "1";//多边形
|
||||
public static final String AREA_SHAPE_FLAG_CIRCULA = "2";//圆形
|
||||
|
||||
public static final String DEFAULT_FUNCTION_LONGITUDE_IDENTIFIER = "longitude";//经度标识符
|
||||
public static final String DEFAULT_FUNCTION_LATITUDE_IDENTIFIER = "latitude";//纬度标识符
|
||||
|
||||
public static final String ELECTRONIC_FENCE_TRIGGER_STATUS_EXIT = "1";//电子围栏触发状态:出界
|
||||
public static final String ELECTRONIC_FENCE_TRIGGER_STATUS_ENTRY = "2";//电子围栏触发状态:入界
|
||||
|
||||
public static final String ALARM_INFO_TYPE_DEVICE = "1";//设备报警
|
||||
public static final String ALARM_INFO_TYPE_MONITOR_UNIT = "2";//监控单元
|
||||
public static final String ALARM_INFO_TYPE_OFFLINE = "3";//离线报警
|
||||
public static final String ALARM_INFO_TYPE_ELECTRONIC_FENCE = "4";//电子围栏
|
||||
|
||||
}
|
||||
@ -0,0 +1,35 @@
|
||||
package com.ruoyi.common.core.enums;
|
||||
/**
|
||||
* @Description: 返回结果枚举
|
||||
* @ClassName: ResultEnums
|
||||
* @Author : xins
|
||||
* @Date :2023-09-01 13:40
|
||||
* @Version :1.0
|
||||
*/
|
||||
public enum ResultEnums {
|
||||
|
||||
SUCCESS(200,"成功"),FAIL(500,"失败");
|
||||
public Integer code;
|
||||
public String message;
|
||||
|
||||
ResultEnums(Integer code, String message) {
|
||||
this.code = code;
|
||||
this.message = message;
|
||||
}
|
||||
|
||||
public Integer getCode() {
|
||||
return code;
|
||||
}
|
||||
|
||||
public void setCode(Integer code) {
|
||||
this.code = code;
|
||||
}
|
||||
|
||||
public String getMessage() {
|
||||
return message;
|
||||
}
|
||||
|
||||
public void setMessage(String message) {
|
||||
this.message = message;
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,103 @@
|
||||
package com.ruoyi.basic.controller;
|
||||
|
||||
import java.util.List;
|
||||
import java.io.IOException;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
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.ruoyi.common.log.annotation.Log;
|
||||
import com.ruoyi.common.log.enums.BusinessType;
|
||||
import com.ruoyi.common.security.annotation.RequiresPermissions;
|
||||
import com.ruoyi.basic.domain.HwArea;
|
||||
import com.ruoyi.basic.service.IHwAreaService;
|
||||
import com.ruoyi.common.core.web.controller.BaseController;
|
||||
import com.ruoyi.common.core.web.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.utils.poi.ExcelUtil;
|
||||
|
||||
/**
|
||||
* 区域管理Controller
|
||||
*
|
||||
* @author YINQ
|
||||
* @date 2023-08-30
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/area")
|
||||
public class HwAreaController extends BaseController
|
||||
{
|
||||
@Autowired
|
||||
private IHwAreaService hwAreaService;
|
||||
|
||||
/**
|
||||
* 查询区域管理列表
|
||||
*/
|
||||
@RequiresPermissions("basic:area:list")
|
||||
@GetMapping("/list")
|
||||
public AjaxResult list(HwArea hwArea)
|
||||
{
|
||||
List<HwArea> list = hwAreaService.selectHwAreaList(hwArea);
|
||||
return success(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出区域管理列表
|
||||
*/
|
||||
@RequiresPermissions("basic:area:export")
|
||||
@Log(title = "区域管理", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(HttpServletResponse response, HwArea hwArea)
|
||||
{
|
||||
List<HwArea> list = hwAreaService.selectHwAreaList(hwArea);
|
||||
ExcelUtil<HwArea> util = new ExcelUtil<HwArea>(HwArea.class);
|
||||
util.exportExcel(response, list, "区域管理数据");
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取区域管理详细信息
|
||||
*/
|
||||
@RequiresPermissions("basic:area:query")
|
||||
@GetMapping(value = "/{areaId}")
|
||||
public AjaxResult getInfo(@PathVariable("areaId") Long areaId)
|
||||
{
|
||||
return success(hwAreaService.selectHwAreaByAreaId(areaId));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增区域管理
|
||||
*/
|
||||
@RequiresPermissions("basic:area:add")
|
||||
@Log(title = "区域管理", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
public AjaxResult add(@RequestBody HwArea hwArea)
|
||||
{
|
||||
return toAjax(hwAreaService.insertHwArea(hwArea));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改区域管理
|
||||
*/
|
||||
@RequiresPermissions("basic:area:edit")
|
||||
@Log(title = "区域管理", businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
public AjaxResult edit(@RequestBody HwArea hwArea)
|
||||
{
|
||||
return toAjax(hwAreaService.updateHwArea(hwArea));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除区域管理
|
||||
*/
|
||||
@RequiresPermissions("basic:area:remove")
|
||||
@Log(title = "区域管理", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{areaIds}")
|
||||
public AjaxResult remove(@PathVariable Long[] areaIds)
|
||||
{
|
||||
return toAjax(hwAreaService.deleteHwAreaByAreaIds(areaIds));
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,72 @@
|
||||
package com.ruoyi.basic.domain;
|
||||
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
import com.ruoyi.common.core.annotation.Excel;
|
||||
import com.ruoyi.common.core.web.domain.TreeEntity;
|
||||
|
||||
/**
|
||||
* 区域管理对象 hw_area
|
||||
*
|
||||
* @author YINQ
|
||||
* @date 2023-08-30
|
||||
*/
|
||||
public class HwArea extends TreeEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 区域ID */
|
||||
private Long areaId;
|
||||
|
||||
/** 区域名称 */
|
||||
@Excel(name = "区域名称")
|
||||
private String areaName;
|
||||
|
||||
/** 区域状态 */
|
||||
@Excel(name = "区域状态")
|
||||
private Long areaStatus;
|
||||
|
||||
public void setAreaId(Long areaId)
|
||||
{
|
||||
this.areaId = areaId;
|
||||
}
|
||||
|
||||
public Long getAreaId()
|
||||
{
|
||||
return areaId;
|
||||
}
|
||||
public void setAreaName(String areaName)
|
||||
{
|
||||
this.areaName = areaName;
|
||||
}
|
||||
|
||||
public String getAreaName()
|
||||
{
|
||||
return areaName;
|
||||
}
|
||||
public void setAreaStatus(Long areaStatus)
|
||||
{
|
||||
this.areaStatus = areaStatus;
|
||||
}
|
||||
|
||||
public Long getAreaStatus()
|
||||
{
|
||||
return areaStatus;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("areaId", getAreaId())
|
||||
.append("areaName", getAreaName())
|
||||
.append("ancestors", getAncestors())
|
||||
.append("parentId", getParentId())
|
||||
.append("areaStatus", getAreaStatus())
|
||||
.append("orderNum", getOrderNum())
|
||||
.append("createBy", getCreateBy())
|
||||
.append("createTime", getCreateTime())
|
||||
.append("updateBy", getUpdateBy())
|
||||
.append("updateTime", getUpdateTime())
|
||||
.toString();
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,61 @@
|
||||
package com.ruoyi.basic.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.basic.domain.HwArea;
|
||||
|
||||
/**
|
||||
* 区域管理Mapper接口
|
||||
*
|
||||
* @author YINQ
|
||||
* @date 2023-08-30
|
||||
*/
|
||||
public interface HwAreaMapper
|
||||
{
|
||||
/**
|
||||
* 查询区域管理
|
||||
*
|
||||
* @param areaId 区域管理主键
|
||||
* @return 区域管理
|
||||
*/
|
||||
public HwArea selectHwAreaByAreaId(Long areaId);
|
||||
|
||||
/**
|
||||
* 查询区域管理列表
|
||||
*
|
||||
* @param hwArea 区域管理
|
||||
* @return 区域管理集合
|
||||
*/
|
||||
public List<HwArea> selectHwAreaList(HwArea hwArea);
|
||||
|
||||
/**
|
||||
* 新增区域管理
|
||||
*
|
||||
* @param hwArea 区域管理
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertHwArea(HwArea hwArea);
|
||||
|
||||
/**
|
||||
* 修改区域管理
|
||||
*
|
||||
* @param hwArea 区域管理
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateHwArea(HwArea hwArea);
|
||||
|
||||
/**
|
||||
* 删除区域管理
|
||||
*
|
||||
* @param areaId 区域管理主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteHwAreaByAreaId(Long areaId);
|
||||
|
||||
/**
|
||||
* 批量删除区域管理
|
||||
*
|
||||
* @param areaIds 需要删除的数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteHwAreaByAreaIds(Long[] areaIds);
|
||||
}
|
||||
@ -0,0 +1,61 @@
|
||||
package com.ruoyi.basic.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.basic.domain.HwArea;
|
||||
|
||||
/**
|
||||
* 区域管理Service接口
|
||||
*
|
||||
* @author YINQ
|
||||
* @date 2023-08-30
|
||||
*/
|
||||
public interface IHwAreaService
|
||||
{
|
||||
/**
|
||||
* 查询区域管理
|
||||
*
|
||||
* @param areaId 区域管理主键
|
||||
* @return 区域管理
|
||||
*/
|
||||
public HwArea selectHwAreaByAreaId(Long areaId);
|
||||
|
||||
/**
|
||||
* 查询区域管理列表
|
||||
*
|
||||
* @param hwArea 区域管理
|
||||
* @return 区域管理集合
|
||||
*/
|
||||
public List<HwArea> selectHwAreaList(HwArea hwArea);
|
||||
|
||||
/**
|
||||
* 新增区域管理
|
||||
*
|
||||
* @param hwArea 区域管理
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertHwArea(HwArea hwArea);
|
||||
|
||||
/**
|
||||
* 修改区域管理
|
||||
*
|
||||
* @param hwArea 区域管理
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateHwArea(HwArea hwArea);
|
||||
|
||||
/**
|
||||
* 批量删除区域管理
|
||||
*
|
||||
* @param areaIds 需要删除的区域管理主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteHwAreaByAreaIds(Long[] areaIds);
|
||||
|
||||
/**
|
||||
* 删除区域管理信息
|
||||
*
|
||||
* @param areaId 区域管理主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteHwAreaByAreaId(Long areaId);
|
||||
}
|
||||
@ -0,0 +1,96 @@
|
||||
package com.ruoyi.basic.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.common.core.utils.DateUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.ruoyi.basic.mapper.HwAreaMapper;
|
||||
import com.ruoyi.basic.domain.HwArea;
|
||||
import com.ruoyi.basic.service.IHwAreaService;
|
||||
|
||||
/**
|
||||
* 区域管理Service业务层处理
|
||||
*
|
||||
* @author YINQ
|
||||
* @date 2023-08-30
|
||||
*/
|
||||
@Service
|
||||
public class HwAreaServiceImpl implements IHwAreaService
|
||||
{
|
||||
@Autowired
|
||||
private HwAreaMapper hwAreaMapper;
|
||||
|
||||
/**
|
||||
* 查询区域管理
|
||||
*
|
||||
* @param areaId 区域管理主键
|
||||
* @return 区域管理
|
||||
*/
|
||||
@Override
|
||||
public HwArea selectHwAreaByAreaId(Long areaId)
|
||||
{
|
||||
return hwAreaMapper.selectHwAreaByAreaId(areaId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询区域管理列表
|
||||
*
|
||||
* @param hwArea 区域管理
|
||||
* @return 区域管理
|
||||
*/
|
||||
@Override
|
||||
public List<HwArea> selectHwAreaList(HwArea hwArea)
|
||||
{
|
||||
return hwAreaMapper.selectHwAreaList(hwArea);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增区域管理
|
||||
*
|
||||
* @param hwArea 区域管理
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertHwArea(HwArea hwArea)
|
||||
{
|
||||
hwArea.setCreateTime(DateUtils.getNowDate());
|
||||
return hwAreaMapper.insertHwArea(hwArea);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改区域管理
|
||||
*
|
||||
* @param hwArea 区域管理
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateHwArea(HwArea hwArea)
|
||||
{
|
||||
hwArea.setUpdateTime(DateUtils.getNowDate());
|
||||
return hwAreaMapper.updateHwArea(hwArea);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除区域管理
|
||||
*
|
||||
* @param areaIds 需要删除的区域管理主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteHwAreaByAreaIds(Long[] areaIds)
|
||||
{
|
||||
return hwAreaMapper.deleteHwAreaByAreaIds(areaIds);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除区域管理信息
|
||||
*
|
||||
* @param areaId 区域管理主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteHwAreaByAreaId(Long areaId)
|
||||
{
|
||||
return hwAreaMapper.deleteHwAreaByAreaId(areaId);
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,92 @@
|
||||
<?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.ruoyi.basic.mapper.HwAreaMapper">
|
||||
|
||||
<resultMap type="HwArea" id="HwAreaResult">
|
||||
<result property="areaId" column="area_id" />
|
||||
<result property="areaName" column="area_name" />
|
||||
<result property="ancestors" column="ancestors" />
|
||||
<result property="parentId" column="parent_id" />
|
||||
<result property="areaStatus" column="area_status" />
|
||||
<result property="orderNum" column="order_num" />
|
||||
<result property="createBy" column="create_by" />
|
||||
<result property="createTime" column="create_time" />
|
||||
<result property="updateBy" column="update_by" />
|
||||
<result property="updateTime" column="update_time" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectHwAreaVo">
|
||||
select area_id, area_name, ancestors, parent_id, area_status, order_num, create_by, create_time, update_by, update_time from hw_area
|
||||
</sql>
|
||||
|
||||
<select id="selectHwAreaList" parameterType="HwArea" resultMap="HwAreaResult">
|
||||
<include refid="selectHwAreaVo"/>
|
||||
<where>
|
||||
<if test="areaName != null and areaName != ''"> and area_name like concat('%', #{areaName}, '%')</if>
|
||||
<if test="ancestors != null and ancestors != ''"> and ancestors = #{ancestors}</if>
|
||||
<if test="parentId != null "> and parent_id = #{parentId}</if>
|
||||
<if test="areaStatus != null "> and area_status = #{areaStatus}</if>
|
||||
<if test="orderNum != null "> and order_num = #{orderNum}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectHwAreaByAreaId" parameterType="Long" resultMap="HwAreaResult">
|
||||
<include refid="selectHwAreaVo"/>
|
||||
where area_id = #{areaId}
|
||||
</select>
|
||||
|
||||
<insert id="insertHwArea" parameterType="HwArea" useGeneratedKeys="true" keyProperty="areaId">
|
||||
insert into hw_area
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="areaName != null and areaName != ''">area_name,</if>
|
||||
<if test="ancestors != null">ancestors,</if>
|
||||
<if test="parentId != null">parent_id,</if>
|
||||
<if test="areaStatus != null">area_status,</if>
|
||||
<if test="orderNum != null">order_num,</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>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="areaName != null and areaName != ''">#{areaName},</if>
|
||||
<if test="ancestors != null">#{ancestors},</if>
|
||||
<if test="parentId != null">#{parentId},</if>
|
||||
<if test="areaStatus != null">#{areaStatus},</if>
|
||||
<if test="orderNum != null">#{orderNum},</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>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateHwArea" parameterType="HwArea">
|
||||
update hw_area
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="areaName != null and areaName != ''">area_name = #{areaName},</if>
|
||||
<if test="ancestors != null">ancestors = #{ancestors},</if>
|
||||
<if test="parentId != null">parent_id = #{parentId},</if>
|
||||
<if test="areaStatus != null">area_status = #{areaStatus},</if>
|
||||
<if test="orderNum != null">order_num = #{orderNum},</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>
|
||||
</trim>
|
||||
where area_id = #{areaId}
|
||||
</update>
|
||||
|
||||
<delete id="deleteHwAreaByAreaId" parameterType="Long">
|
||||
delete from hw_area where area_id = #{areaId}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteHwAreaByAreaIds" parameterType="String">
|
||||
delete from hw_area where area_id in
|
||||
<foreach item="areaId" collection="array" open="(" separator="," close=")">
|
||||
#{areaId}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
||||
@ -1,66 +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.ruoyi.basic.mapper.HwDictDataLanguageMapper">
|
||||
|
||||
<resultMap type="HwDictDataLanguage" id="HwDictDataLanguageResult">
|
||||
<result property="dataLanguageId" column="data_language_id" />
|
||||
<result property="dictCode" column="dict_code" />
|
||||
<result property="dictLabel" column="dict_label" />
|
||||
<result property="languageCode" column="language_code" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectHwDictDataLanguageVo">
|
||||
select data_language_id, dict_code, dict_label, language_code from hw_dict_data_language
|
||||
</sql>
|
||||
|
||||
<select id="selectHwDictDataLanguageList" parameterType="HwDictDataLanguage" resultMap="HwDictDataLanguageResult">
|
||||
<include refid="selectHwDictDataLanguageVo"/>
|
||||
<where>
|
||||
<if test="dictCode != null "> and dict_code = #{dictCode}</if>
|
||||
<if test="dictLabel != null and dictLabel != ''"> and dict_label = #{dictLabel}</if>
|
||||
<if test="languageCode != null and languageCode != ''"> and language_code = #{languageCode}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectHwDictDataLanguageByDataLanguageId" parameterType="Long" resultMap="HwDictDataLanguageResult">
|
||||
<include refid="selectHwDictDataLanguageVo"/>
|
||||
where data_language_id = #{dataLanguageId}
|
||||
</select>
|
||||
|
||||
<insert id="insertHwDictDataLanguage" parameterType="HwDictDataLanguage" useGeneratedKeys="true" keyProperty="dataLanguageId">
|
||||
insert into hw_dict_data_language
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="dictCode != null">dict_code,</if>
|
||||
<if test="dictLabel != null">dict_label,</if>
|
||||
<if test="languageCode != null and languageCode != ''">language_code,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="dictCode != null">#{dictCode},</if>
|
||||
<if test="dictLabel != null">#{dictLabel},</if>
|
||||
<if test="languageCode != null and languageCode != ''">#{languageCode},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateHwDictDataLanguage" parameterType="HwDictDataLanguage">
|
||||
update hw_dict_data_language
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="dictCode != null">dict_code = #{dictCode},</if>
|
||||
<if test="dictLabel != null">dict_label = #{dictLabel},</if>
|
||||
<if test="languageCode != null and languageCode != ''">language_code = #{languageCode},</if>
|
||||
</trim>
|
||||
where data_language_id = #{dataLanguageId}
|
||||
</update>
|
||||
|
||||
<delete id="deleteHwDictDataLanguageByDataLanguageId" parameterType="Long">
|
||||
delete from hw_dict_data_language where data_language_id = #{dataLanguageId}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteHwDictDataLanguageByDataLanguageIds" parameterType="String">
|
||||
delete from hw_dict_data_language where data_language_id in
|
||||
<foreach item="dataLanguageId" collection="array" open="(" separator="," close=")">
|
||||
#{dataLanguageId}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
||||
@ -1,118 +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.ruoyi.basic.mapper.HwDictDataMapper">
|
||||
|
||||
<resultMap type="HwDictData" id="HwDictDataResult">
|
||||
<result property="dictCode" column="dict_code" />
|
||||
<result property="dictSort" column="dict_sort" />
|
||||
<result property="dictLabel" column="dict_label" />
|
||||
<result property="dictValue" column="dict_value" />
|
||||
<result property="dictType" column="dict_type" />
|
||||
<result property="cssClass" column="css_class" />
|
||||
<result property="listClass" column="list_class" />
|
||||
<result property="isDefault" column="is_default" />
|
||||
<result property="status" column="status" />
|
||||
<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="remark" column="remark" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectHwDictDataVo">
|
||||
select dict_code, dict_sort, dict_label, dict_value, dict_type, css_class, list_class, is_default, status, create_by, create_time, update_by, update_time, remark from hw_dict_data
|
||||
</sql>
|
||||
|
||||
<select id="selectHwDictDataByType" parameterType="HwDictData" resultMap="HwDictDataResult">
|
||||
<include refid="selectHwDictDataVo"/>
|
||||
where status = '1' and dict_type = #{dictType} order by dict_sort asc
|
||||
</select>
|
||||
|
||||
|
||||
|
||||
<select id="selectHwDictDataList" parameterType="HwDictData" resultMap="HwDictDataResult">
|
||||
<include refid="selectHwDictDataVo"/>
|
||||
<where>
|
||||
<if test="dictSort != null "> and dict_sort = #{dictSort}</if>
|
||||
<if test="dictLabel != null and dictLabel != ''"> and dict_label = #{dictLabel}</if>
|
||||
<if test="dictValue != null and dictValue != ''"> and dict_value = #{dictValue}</if>
|
||||
<if test="dictType != null and dictType != ''"> and dict_type = #{dictType}</if>
|
||||
<if test="cssClass != null and cssClass != ''"> and css_class = #{cssClass}</if>
|
||||
<if test="listClass != null and listClass != ''"> and list_class = #{listClass}</if>
|
||||
<if test="isDefault != null and isDefault != ''"> and is_default = #{isDefault}</if>
|
||||
<if test="status != null and status != ''"> and status = #{status}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectHwDictDataByDictCode" parameterType="Long" resultMap="HwDictDataResult">
|
||||
<include refid="selectHwDictDataVo"/>
|
||||
where dict_code = #{dictCode}
|
||||
</select>
|
||||
|
||||
<insert id="insertHwDictData" parameterType="HwDictData" useGeneratedKeys="true" keyProperty="dictCode">
|
||||
insert into hw_dict_data
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="dictSort != null">dict_sort,</if>
|
||||
<if test="dictLabel != null">dict_label,</if>
|
||||
<if test="dictValue != null">dict_value,</if>
|
||||
<if test="dictType != null">dict_type,</if>
|
||||
<if test="cssClass != null">css_class,</if>
|
||||
<if test="listClass != null">list_class,</if>
|
||||
<if test="isDefault != null">is_default,</if>
|
||||
<if test="status != null">status,</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="remark != null">remark,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="dictSort != null">#{dictSort},</if>
|
||||
<if test="dictLabel != null">#{dictLabel},</if>
|
||||
<if test="dictValue != null">#{dictValue},</if>
|
||||
<if test="dictType != null">#{dictType},</if>
|
||||
<if test="cssClass != null">#{cssClass},</if>
|
||||
<if test="listClass != null">#{listClass},</if>
|
||||
<if test="isDefault != null">#{isDefault},</if>
|
||||
<if test="status != null">#{status},</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="remark != null">#{remark},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateHwDictData" parameterType="HwDictData">
|
||||
update hw_dict_data
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="dictSort != null">dict_sort = #{dictSort},</if>
|
||||
<if test="dictLabel != null">dict_label = #{dictLabel},</if>
|
||||
<if test="dictValue != null">dict_value = #{dictValue},</if>
|
||||
<if test="dictType != null">dict_type = #{dictType},</if>
|
||||
<if test="cssClass != null">css_class = #{cssClass},</if>
|
||||
<if test="listClass != null">list_class = #{listClass},</if>
|
||||
<if test="isDefault != null">is_default = #{isDefault},</if>
|
||||
<if test="status != null">status = #{status},</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="remark != null">remark = #{remark},</if>
|
||||
</trim>
|
||||
where dict_code = #{dictCode}
|
||||
</update>
|
||||
|
||||
<delete id="deleteHwDictDataByDictCode" parameterType="Long">
|
||||
delete from hw_dict_data where dict_code = #{dictCode}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteHwDictDataByDictCodes" parameterType="String">
|
||||
delete from hw_dict_data where dict_code in
|
||||
<foreach item="dictCode" collection="array" open="(" separator="," close=")">
|
||||
#{dictCode}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
||||
@ -1,86 +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.ruoyi.basic.mapper.HwDictTypeMapper">
|
||||
|
||||
<resultMap type="HwDictType" id="HwDictTypeResult">
|
||||
<result property="dictId" column="dict_id" />
|
||||
<result property="dictName" column="dict_name" />
|
||||
<result property="dictType" column="dict_type" />
|
||||
<result property="status" column="status" />
|
||||
<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="remark" column="remark" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectHwDictTypeVo">
|
||||
select dict_id, dict_name, dict_type, status, create_by, create_time, update_by, update_time, remark from hw_dict_type
|
||||
</sql>
|
||||
|
||||
<select id="selectHwDictTypeList" parameterType="HwDictType" resultMap="HwDictTypeResult">
|
||||
<include refid="selectHwDictTypeVo"/>
|
||||
<where>
|
||||
<if test="dictName != null and dictName != ''"> and dict_name like concat('%', #{dictName}, '%')</if>
|
||||
<if test="dictType != null and dictType != ''"> and dict_type = #{dictType}</if>
|
||||
<if test="status != null and status != ''"> and status = #{status}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectHwDictTypeByDictId" parameterType="Long" resultMap="HwDictTypeResult">
|
||||
<include refid="selectHwDictTypeVo"/>
|
||||
where dict_id = #{dictId}
|
||||
</select>
|
||||
|
||||
<insert id="insertHwDictType" parameterType="HwDictType" useGeneratedKeys="true" keyProperty="dictId">
|
||||
insert into hw_dict_type
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="dictName != null">dict_name,</if>
|
||||
<if test="dictType != null">dict_type,</if>
|
||||
<if test="status != null">status,</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="remark != null">remark,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="dictName != null">#{dictName},</if>
|
||||
<if test="dictType != null">#{dictType},</if>
|
||||
<if test="status != null">#{status},</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="remark != null">#{remark},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateHwDictType" parameterType="HwDictType">
|
||||
update hw_dict_type
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="dictName != null">dict_name = #{dictName},</if>
|
||||
<if test="dictType != null">dict_type = #{dictType},</if>
|
||||
<if test="status != null">status = #{status},</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="remark != null">remark = #{remark},</if>
|
||||
</trim>
|
||||
where dict_id = #{dictId}
|
||||
</update>
|
||||
|
||||
<delete id="deleteHwDictTypeByDictId" parameterType="Long">
|
||||
delete from hw_dict_type where dict_id = #{dictId}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteHwDictTypeByDictIds" parameterType="String">
|
||||
delete from hw_dict_type where dict_id in
|
||||
<foreach item="dictId" collection="array" open="(" separator="," close=")">
|
||||
#{dictId}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
||||
@ -1,22 +0,0 @@
|
||||
package com.ruoyi;
|
||||
|
||||
import com.ruoyi.i18n.utils.MessageUtils;
|
||||
|
||||
// Press Shift twice to open the Search Everywhere dialog and type `show whitespaces`,
|
||||
// then press Enter. You can now see whitespace characters in your code.
|
||||
public class Main {
|
||||
public static void main(String[] args) {
|
||||
// Press Alt+Enter with your caret at the highlighted text to see how
|
||||
// IntelliJ IDEA suggests fixing it.
|
||||
System.out.printf("Hello and welcome!");
|
||||
String dd = MessageUtils.getMessages("user.login.username");
|
||||
System.out.println("dddd:"+dd);
|
||||
// Press Shift+F10 or click the green arrow button in the gutter to run the code.
|
||||
for (int i = 1; i <= 5; i++) {
|
||||
|
||||
// Press Shift+F9 to start debugging your code. We have set one breakpoint
|
||||
// for you, but you can always add more by pressing Ctrl+F8.
|
||||
System.out.println("i = " + i);
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,40 @@
|
||||
package com.ruoyi.business.controller;
|
||||
|
||||
import com.ruoyi.business.domain.HwMonitorUnit;
|
||||
import com.ruoyi.business.service.IHwMonitorUnitService;
|
||||
import com.ruoyi.common.core.web.controller.BaseController;
|
||||
import com.ruoyi.common.core.web.page.TableDataInfo;
|
||||
import com.ruoyi.common.security.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Description: 移动端Controller
|
||||
* @ClassName: HwAppController
|
||||
* @Date :2023-08-31 17:46
|
||||
* @Version :1.0
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/app")
|
||||
public class HwAppController extends BaseController {
|
||||
|
||||
@Autowired
|
||||
private IHwMonitorUnitService hwMonitorUnitService;
|
||||
|
||||
/**
|
||||
* 查询监控单元列表
|
||||
*/
|
||||
@RequiresPermissions("business:monitorUnit:list")
|
||||
@GetMapping("/monitorUnit/list")
|
||||
public TableDataInfo monitorUnitList(HwMonitorUnit hwMonitorUnit)
|
||||
{
|
||||
startPage();
|
||||
List<HwMonitorUnit> list = hwMonitorUnitService.selectHwMonitorUnitList(hwMonitorUnit);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
}
|
||||
@ -0,0 +1,105 @@
|
||||
package com.ruoyi.business.controller;
|
||||
|
||||
import java.util.List;
|
||||
import java.io.IOException;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
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.ruoyi.common.log.annotation.Log;
|
||||
import com.ruoyi.common.log.enums.BusinessType;
|
||||
import com.ruoyi.common.security.annotation.RequiresPermissions;
|
||||
import com.ruoyi.business.domain.HwDeviceMode;
|
||||
import com.ruoyi.business.service.IHwDeviceModeService;
|
||||
import com.ruoyi.common.core.web.controller.BaseController;
|
||||
import com.ruoyi.common.core.web.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.common.core.web.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 设备模型Controller
|
||||
*
|
||||
* @author xins
|
||||
* @date 2023-09-04
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/deviceMode")
|
||||
public class HwDeviceModeController extends BaseController
|
||||
{
|
||||
@Autowired
|
||||
private IHwDeviceModeService hwDeviceModeService;
|
||||
|
||||
/**
|
||||
* 查询设备模型列表
|
||||
*/
|
||||
@RequiresPermissions("business:deviceMode:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(HwDeviceMode hwDeviceMode)
|
||||
{
|
||||
startPage();
|
||||
List<HwDeviceMode> list = hwDeviceModeService.selectHwDeviceModeList(hwDeviceMode);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出设备模型列表
|
||||
*/
|
||||
@RequiresPermissions("business:deviceMode:export")
|
||||
@Log(title = "设备模型", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(HttpServletResponse response, HwDeviceMode hwDeviceMode)
|
||||
{
|
||||
List<HwDeviceMode> list = hwDeviceModeService.selectHwDeviceModeList(hwDeviceMode);
|
||||
ExcelUtil<HwDeviceMode> util = new ExcelUtil<HwDeviceMode>(HwDeviceMode.class);
|
||||
util.exportExcel(response, list, "设备模型数据");
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取设备模型详细信息
|
||||
*/
|
||||
@RequiresPermissions("business:deviceMode:query")
|
||||
@GetMapping(value = "/{deviceModeId}")
|
||||
public AjaxResult getInfo(@PathVariable("deviceModeId") Long deviceModeId)
|
||||
{
|
||||
return success(hwDeviceModeService.selectHwDeviceModeByDeviceModeId(deviceModeId));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增设备模型
|
||||
*/
|
||||
@RequiresPermissions("business:deviceMode:add")
|
||||
@Log(title = "设备模型", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
public AjaxResult add(@RequestBody HwDeviceMode hwDeviceMode)
|
||||
{
|
||||
return toAjax(hwDeviceModeService.insertHwDeviceMode(hwDeviceMode));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改设备模型
|
||||
*/
|
||||
@RequiresPermissions("business:deviceMode:edit")
|
||||
@Log(title = "设备模型", businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
public AjaxResult edit(@RequestBody HwDeviceMode hwDeviceMode)
|
||||
{
|
||||
return toAjax(hwDeviceModeService.updateHwDeviceMode(hwDeviceMode));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除设备模型
|
||||
*/
|
||||
@RequiresPermissions("business:deviceMode:remove")
|
||||
@Log(title = "设备模型", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{deviceModeIds}")
|
||||
public AjaxResult remove(@PathVariable Long[] deviceModeIds)
|
||||
{
|
||||
return toAjax(hwDeviceModeService.deleteHwDeviceModeByDeviceModeIds(deviceModeIds));
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,105 @@
|
||||
package com.ruoyi.business.controller;
|
||||
|
||||
import java.util.List;
|
||||
import java.io.IOException;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
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.ruoyi.common.log.annotation.Log;
|
||||
import com.ruoyi.common.log.enums.BusinessType;
|
||||
import com.ruoyi.common.security.annotation.RequiresPermissions;
|
||||
import com.ruoyi.business.domain.HwDeviceModeFunction;
|
||||
import com.ruoyi.business.service.IHwDeviceModeFunctionService;
|
||||
import com.ruoyi.common.core.web.controller.BaseController;
|
||||
import com.ruoyi.common.core.web.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.common.core.web.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 设备模型功能Controller
|
||||
*
|
||||
* @author xins
|
||||
* @date 2023-09-05
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/deviceModeFunction")
|
||||
public class HwDeviceModeFunctionController extends BaseController
|
||||
{
|
||||
@Autowired
|
||||
private IHwDeviceModeFunctionService hwDeviceModeFunctionService;
|
||||
|
||||
/**
|
||||
* 查询设备模型功能列表
|
||||
*/
|
||||
@RequiresPermissions("business:deviceModeFunction:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(HwDeviceModeFunction hwDeviceModeFunction)
|
||||
{
|
||||
startPage();
|
||||
List<HwDeviceModeFunction> list = hwDeviceModeFunctionService.selectHwDeviceModeFunctionList(hwDeviceModeFunction);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出设备模型功能列表
|
||||
*/
|
||||
@RequiresPermissions("business:deviceModeFunction:export")
|
||||
@Log(title = "设备模型功能", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(HttpServletResponse response, HwDeviceModeFunction hwDeviceModeFunction)
|
||||
{
|
||||
List<HwDeviceModeFunction> list = hwDeviceModeFunctionService.selectHwDeviceModeFunctionList(hwDeviceModeFunction);
|
||||
ExcelUtil<HwDeviceModeFunction> util = new ExcelUtil<HwDeviceModeFunction>(HwDeviceModeFunction.class);
|
||||
util.exportExcel(response, list, "设备模型功能数据");
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取设备模型功能详细信息
|
||||
*/
|
||||
@RequiresPermissions("business:deviceModeFunction:query")
|
||||
@GetMapping(value = "/{modeFunctionId}")
|
||||
public AjaxResult getInfo(@PathVariable("modeFunctionId") Long modeFunctionId)
|
||||
{
|
||||
return success(hwDeviceModeFunctionService.selectHwDeviceModeFunctionByModeFunctionId(modeFunctionId));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增设备模型功能
|
||||
*/
|
||||
@RequiresPermissions("business:deviceModeFunction:add")
|
||||
@Log(title = "设备模型功能", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
public AjaxResult add(@RequestBody HwDeviceModeFunction hwDeviceModeFunction)
|
||||
{
|
||||
return toAjax(hwDeviceModeFunctionService.insertHwDeviceModeFunction(hwDeviceModeFunction));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改设备模型功能
|
||||
*/
|
||||
@RequiresPermissions("business:deviceModeFunction:edit")
|
||||
@Log(title = "设备模型功能", businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
public AjaxResult edit(@RequestBody HwDeviceModeFunction hwDeviceModeFunction)
|
||||
{
|
||||
return toAjax(hwDeviceModeFunctionService.updateHwDeviceModeFunction(hwDeviceModeFunction));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除设备模型功能
|
||||
*/
|
||||
@RequiresPermissions("business:deviceModeFunction:remove")
|
||||
@Log(title = "设备模型功能", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{modeFunctionIds}")
|
||||
public AjaxResult remove(@PathVariable Long[] modeFunctionIds)
|
||||
{
|
||||
return toAjax(hwDeviceModeFunctionService.deleteHwDeviceModeFunctionByModeFunctionIds(modeFunctionIds));
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,105 @@
|
||||
package com.ruoyi.business.controller;
|
||||
|
||||
import java.util.List;
|
||||
import java.io.IOException;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
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.ruoyi.common.log.annotation.Log;
|
||||
import com.ruoyi.common.log.enums.BusinessType;
|
||||
import com.ruoyi.common.security.annotation.RequiresPermissions;
|
||||
import com.ruoyi.business.domain.HwElectronicFence;
|
||||
import com.ruoyi.business.service.IHwElectronicFenceService;
|
||||
import com.ruoyi.common.core.web.controller.BaseController;
|
||||
import com.ruoyi.common.core.web.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.common.core.web.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 电子围栏Controller
|
||||
*
|
||||
* @author xins
|
||||
* @date 2023-09-04
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/electronicFence")
|
||||
public class HwElectronicFenceController extends BaseController
|
||||
{
|
||||
@Autowired
|
||||
private IHwElectronicFenceService hwElectronicFenceService;
|
||||
|
||||
/**
|
||||
* 查询电子围栏列表
|
||||
*/
|
||||
@RequiresPermissions("business:electronicFence:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(HwElectronicFence hwElectronicFence)
|
||||
{
|
||||
startPage();
|
||||
List<HwElectronicFence> list = hwElectronicFenceService.selectHwElectronicFenceList(hwElectronicFence);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出电子围栏列表
|
||||
*/
|
||||
@RequiresPermissions("business:electronicFence:export")
|
||||
@Log(title = "电子围栏", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(HttpServletResponse response, HwElectronicFence hwElectronicFence)
|
||||
{
|
||||
List<HwElectronicFence> list = hwElectronicFenceService.selectHwElectronicFenceList(hwElectronicFence);
|
||||
ExcelUtil<HwElectronicFence> util = new ExcelUtil<HwElectronicFence>(HwElectronicFence.class);
|
||||
util.exportExcel(response, list, "电子围栏数据");
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取电子围栏详细信息
|
||||
*/
|
||||
@RequiresPermissions("business:electronicFence:query")
|
||||
@GetMapping(value = "/{electronicFenceId}")
|
||||
public AjaxResult getInfo(@PathVariable("electronicFenceId") Long electronicFenceId)
|
||||
{
|
||||
return success(hwElectronicFenceService.selectHwElectronicFenceByElectronicFenceId(electronicFenceId));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增电子围栏
|
||||
*/
|
||||
@RequiresPermissions("business:electronicFence:add")
|
||||
@Log(title = "电子围栏", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
public AjaxResult add(@RequestBody HwElectronicFence hwElectronicFence)
|
||||
{
|
||||
return toAjax(hwElectronicFenceService.insertHwElectronicFence(hwElectronicFence));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改电子围栏
|
||||
*/
|
||||
@RequiresPermissions("business:electronicFence:edit")
|
||||
@Log(title = "电子围栏", businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
public AjaxResult edit(@RequestBody HwElectronicFence hwElectronicFence)
|
||||
{
|
||||
return toAjax(hwElectronicFenceService.updateHwElectronicFence(hwElectronicFence));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除电子围栏
|
||||
*/
|
||||
@RequiresPermissions("business:electronicFence:remove")
|
||||
@Log(title = "电子围栏", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{electronicFenceIds}")
|
||||
public AjaxResult remove(@PathVariable Long[] electronicFenceIds)
|
||||
{
|
||||
return toAjax(hwElectronicFenceService.deleteHwElectronicFenceByElectronicFenceIds(electronicFenceIds));
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,105 @@
|
||||
package com.ruoyi.business.controller;
|
||||
|
||||
import java.util.List;
|
||||
import java.io.IOException;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
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.ruoyi.common.log.annotation.Log;
|
||||
import com.ruoyi.common.log.enums.BusinessType;
|
||||
import com.ruoyi.common.security.annotation.RequiresPermissions;
|
||||
import com.ruoyi.business.domain.HwFenceTarget;
|
||||
import com.ruoyi.business.service.IHwFenceTargetService;
|
||||
import com.ruoyi.common.core.web.controller.BaseController;
|
||||
import com.ruoyi.common.core.web.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.common.core.web.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 电子围栏目标Controller
|
||||
*
|
||||
* @author xins
|
||||
* @date 2023-09-04
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/fenceTarget")
|
||||
public class HwFenceTargetController extends BaseController
|
||||
{
|
||||
@Autowired
|
||||
private IHwFenceTargetService hwFenceTargetService;
|
||||
|
||||
/**
|
||||
* 查询电子围栏目标列表
|
||||
*/
|
||||
@RequiresPermissions("business:fenceTarget:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(HwFenceTarget hwFenceTarget)
|
||||
{
|
||||
startPage();
|
||||
List<HwFenceTarget> list = hwFenceTargetService.selectHwFenceTargetList(hwFenceTarget);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出电子围栏目标列表
|
||||
*/
|
||||
@RequiresPermissions("business:fenceTarget:export")
|
||||
@Log(title = "电子围栏目标", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(HttpServletResponse response, HwFenceTarget hwFenceTarget)
|
||||
{
|
||||
List<HwFenceTarget> list = hwFenceTargetService.selectHwFenceTargetList(hwFenceTarget);
|
||||
ExcelUtil<HwFenceTarget> util = new ExcelUtil<HwFenceTarget>(HwFenceTarget.class);
|
||||
util.exportExcel(response, list, "电子围栏目标数据");
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取电子围栏目标详细信息
|
||||
*/
|
||||
@RequiresPermissions("business:fenceTarget:query")
|
||||
@GetMapping(value = "/{targetId}")
|
||||
public AjaxResult getInfo(@PathVariable("targetId") Long targetId)
|
||||
{
|
||||
return success(hwFenceTargetService.selectHwFenceTargetByTargetId(targetId));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增电子围栏目标
|
||||
*/
|
||||
@RequiresPermissions("business:fenceTarget:add")
|
||||
@Log(title = "电子围栏目标", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
public AjaxResult add(@RequestBody HwFenceTarget hwFenceTarget)
|
||||
{
|
||||
return toAjax(hwFenceTargetService.insertHwFenceTarget(hwFenceTarget));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改电子围栏目标
|
||||
*/
|
||||
@RequiresPermissions("business:fenceTarget:edit")
|
||||
@Log(title = "电子围栏目标", businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
public AjaxResult edit(@RequestBody HwFenceTarget hwFenceTarget)
|
||||
{
|
||||
return toAjax(hwFenceTargetService.updateHwFenceTarget(hwFenceTarget));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除电子围栏目标
|
||||
*/
|
||||
@RequiresPermissions("business:fenceTarget:remove")
|
||||
@Log(title = "电子围栏目标", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{targetIds}")
|
||||
public AjaxResult remove(@PathVariable Long[] targetIds)
|
||||
{
|
||||
return toAjax(hwFenceTargetService.deleteHwFenceTargetByTargetIds(targetIds));
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,9 @@
|
||||
package com.ruoyi.business.controller;
|
||||
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
@RestController
|
||||
@RequestMapping("/monitorPlatform")
|
||||
public class HwMonitorPlatformController {
|
||||
}
|
||||
@ -0,0 +1,105 @@
|
||||
package com.ruoyi.business.controller;
|
||||
|
||||
import java.util.List;
|
||||
import java.io.IOException;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
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.ruoyi.common.log.annotation.Log;
|
||||
import com.ruoyi.common.log.enums.BusinessType;
|
||||
import com.ruoyi.common.security.annotation.RequiresPermissions;
|
||||
import com.ruoyi.business.domain.HwMonitorUnit;
|
||||
import com.ruoyi.business.service.IHwMonitorUnitService;
|
||||
import com.ruoyi.common.core.web.controller.BaseController;
|
||||
import com.ruoyi.common.core.web.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.common.core.web.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 监控单元Controller
|
||||
*
|
||||
* @author YINQ
|
||||
* @date 2023-08-31
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/monitorUnit")
|
||||
public class HwMonitorUnitController extends BaseController
|
||||
{
|
||||
@Autowired
|
||||
private IHwMonitorUnitService hwMonitorUnitService;
|
||||
|
||||
/**
|
||||
* 查询监控单元列表
|
||||
*/
|
||||
@RequiresPermissions("business:monitorUnit:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(HwMonitorUnit hwMonitorUnit)
|
||||
{
|
||||
startPage();
|
||||
List<HwMonitorUnit> list = hwMonitorUnitService.selectHwMonitorUnitList(hwMonitorUnit);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出监控单元列表
|
||||
*/
|
||||
@RequiresPermissions("business:monitorUnit:export")
|
||||
@Log(title = "监控单元", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(HttpServletResponse response, HwMonitorUnit hwMonitorUnit)
|
||||
{
|
||||
List<HwMonitorUnit> list = hwMonitorUnitService.selectHwMonitorUnitList(hwMonitorUnit);
|
||||
ExcelUtil<HwMonitorUnit> util = new ExcelUtil<HwMonitorUnit>(HwMonitorUnit.class);
|
||||
util.exportExcel(response, list, "监控单元数据");
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取监控单元详细信息
|
||||
*/
|
||||
@RequiresPermissions("business:monitorUnit:query")
|
||||
@GetMapping(value = "/{monitorUnitId}")
|
||||
public AjaxResult getInfo(@PathVariable("monitorUnitId") Long monitorUnitId)
|
||||
{
|
||||
return success(hwMonitorUnitService.selectHwMonitorUnitByMonitorUnitId(monitorUnitId));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增监控单元
|
||||
*/
|
||||
@RequiresPermissions("business:monitorUnit:add")
|
||||
@Log(title = "监控单元", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
public AjaxResult add(@RequestBody HwMonitorUnit hwMonitorUnit)
|
||||
{
|
||||
return toAjax(hwMonitorUnitService.insertHwMonitorUnit(hwMonitorUnit));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改监控单元
|
||||
*/
|
||||
@RequiresPermissions("business:monitorUnit:edit")
|
||||
@Log(title = "监控单元", businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
public AjaxResult edit(@RequestBody HwMonitorUnit hwMonitorUnit)
|
||||
{
|
||||
return toAjax(hwMonitorUnitService.updateHwMonitorUnit(hwMonitorUnit));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除监控单元
|
||||
*/
|
||||
@RequiresPermissions("business:monitorUnit:remove")
|
||||
@Log(title = "监控单元", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{monitorUnitIds}")
|
||||
public AjaxResult remove(@PathVariable Long[] monitorUnitIds)
|
||||
{
|
||||
return toAjax(hwMonitorUnitService.deleteHwMonitorUnitByMonitorUnitIds(monitorUnitIds));
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,105 @@
|
||||
package com.ruoyi.business.controller;
|
||||
|
||||
import java.util.List;
|
||||
import java.io.IOException;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
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.ruoyi.common.log.annotation.Log;
|
||||
import com.ruoyi.common.log.enums.BusinessType;
|
||||
import com.ruoyi.common.security.annotation.RequiresPermissions;
|
||||
import com.ruoyi.business.domain.HwMonitorUnitType;
|
||||
import com.ruoyi.business.service.IHwMonitorUnitTypeService;
|
||||
import com.ruoyi.common.core.web.controller.BaseController;
|
||||
import com.ruoyi.common.core.web.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.common.core.web.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 监控单元类型Controller
|
||||
*
|
||||
* @author YINQ
|
||||
* @date 2023-08-31
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/monitorUnitType")
|
||||
public class HwMonitorUnitTypeController extends BaseController
|
||||
{
|
||||
@Autowired
|
||||
private IHwMonitorUnitTypeService hwMonitorUnitTypeService;
|
||||
|
||||
/**
|
||||
* 查询监控单元类型列表
|
||||
*/
|
||||
@RequiresPermissions("business:monitorUnitType:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(HwMonitorUnitType hwMonitorUnitType)
|
||||
{
|
||||
startPage();
|
||||
List<HwMonitorUnitType> list = hwMonitorUnitTypeService.selectHwMonitorUnitTypeList(hwMonitorUnitType);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出监控单元类型列表
|
||||
*/
|
||||
@RequiresPermissions("business:monitorUnitType:export")
|
||||
@Log(title = "监控单元类型", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(HttpServletResponse response, HwMonitorUnitType hwMonitorUnitType)
|
||||
{
|
||||
List<HwMonitorUnitType> list = hwMonitorUnitTypeService.selectHwMonitorUnitTypeList(hwMonitorUnitType);
|
||||
ExcelUtil<HwMonitorUnitType> util = new ExcelUtil<HwMonitorUnitType>(HwMonitorUnitType.class);
|
||||
util.exportExcel(response, list, "监控单元类型数据");
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取监控单元类型详细信息
|
||||
*/
|
||||
@RequiresPermissions("business:monitorUnitType:query")
|
||||
@GetMapping(value = "/{monitorUnitTypeId}")
|
||||
public AjaxResult getInfo(@PathVariable("monitorUnitTypeId") Long monitorUnitTypeId)
|
||||
{
|
||||
return success(hwMonitorUnitTypeService.selectHwMonitorUnitTypeByMonitorUnitTypeId(monitorUnitTypeId));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增监控单元类型
|
||||
*/
|
||||
@RequiresPermissions("business:monitorUnitType:add")
|
||||
@Log(title = "监控单元类型", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
public AjaxResult add(@RequestBody HwMonitorUnitType hwMonitorUnitType)
|
||||
{
|
||||
return toAjax(hwMonitorUnitTypeService.insertHwMonitorUnitType(hwMonitorUnitType));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改监控单元类型
|
||||
*/
|
||||
@RequiresPermissions("business:monitorUnitType:edit")
|
||||
@Log(title = "监控单元类型", businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
public AjaxResult edit(@RequestBody HwMonitorUnitType hwMonitorUnitType)
|
||||
{
|
||||
return toAjax(hwMonitorUnitTypeService.updateHwMonitorUnitType(hwMonitorUnitType));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除监控单元类型
|
||||
*/
|
||||
@RequiresPermissions("business:monitorUnitType:remove")
|
||||
@Log(title = "监控单元类型", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{monitorUnitTypeIds}")
|
||||
public AjaxResult remove(@PathVariable Long[] monitorUnitTypeIds)
|
||||
{
|
||||
return toAjax(hwMonitorUnitTypeService.deleteHwMonitorUnitTypeByMonitorUnitTypeIds(monitorUnitTypeIds));
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,105 @@
|
||||
package com.ruoyi.business.controller;
|
||||
|
||||
import java.util.List;
|
||||
import java.io.IOException;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
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.ruoyi.common.log.annotation.Log;
|
||||
import com.ruoyi.common.log.enums.BusinessType;
|
||||
import com.ruoyi.common.security.annotation.RequiresPermissions;
|
||||
import com.ruoyi.business.domain.HwSceneMode;
|
||||
import com.ruoyi.business.service.IHwSceneModeService;
|
||||
import com.ruoyi.common.core.web.controller.BaseController;
|
||||
import com.ruoyi.common.core.web.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.common.core.web.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 场景类型Controller
|
||||
*
|
||||
* @author YINQ
|
||||
* @date 2023-08-31
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/sceneMode")
|
||||
public class HwSceneModeController extends BaseController
|
||||
{
|
||||
@Autowired
|
||||
private IHwSceneModeService hwSceneModeService;
|
||||
|
||||
/**
|
||||
* 查询场景类型列表
|
||||
*/
|
||||
@RequiresPermissions("business:sceneMode:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(HwSceneMode hwSceneMode)
|
||||
{
|
||||
startPage();
|
||||
List<HwSceneMode> list = hwSceneModeService.selectHwSceneModeList(hwSceneMode);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出场景类型列表
|
||||
*/
|
||||
@RequiresPermissions("business:sceneMode:export")
|
||||
@Log(title = "场景类型", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(HttpServletResponse response, HwSceneMode hwSceneMode)
|
||||
{
|
||||
List<HwSceneMode> list = hwSceneModeService.selectHwSceneModeList(hwSceneMode);
|
||||
ExcelUtil<HwSceneMode> util = new ExcelUtil<HwSceneMode>(HwSceneMode.class);
|
||||
util.exportExcel(response, list, "场景类型数据");
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取场景类型详细信息
|
||||
*/
|
||||
@RequiresPermissions("business:sceneMode:query")
|
||||
@GetMapping(value = "/{sceneModeId}")
|
||||
public AjaxResult getInfo(@PathVariable("sceneModeId") Long sceneModeId)
|
||||
{
|
||||
return success(hwSceneModeService.selectHwSceneModeBySceneModeId(sceneModeId));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增场景类型
|
||||
*/
|
||||
@RequiresPermissions("business:sceneMode:add")
|
||||
@Log(title = "场景类型", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
public AjaxResult add(@RequestBody HwSceneMode hwSceneMode)
|
||||
{
|
||||
return toAjax(hwSceneModeService.insertHwSceneMode(hwSceneMode));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改场景类型
|
||||
*/
|
||||
@RequiresPermissions("business:sceneMode:edit")
|
||||
@Log(title = "场景类型", businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
public AjaxResult edit(@RequestBody HwSceneMode hwSceneMode)
|
||||
{
|
||||
return toAjax(hwSceneModeService.updateHwSceneMode(hwSceneMode));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除场景类型
|
||||
*/
|
||||
@RequiresPermissions("business:sceneMode:remove")
|
||||
@Log(title = "场景类型", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{sceneModeIds}")
|
||||
public AjaxResult remove(@PathVariable Long[] sceneModeIds)
|
||||
{
|
||||
return toAjax(hwSceneModeService.deleteHwSceneModeBySceneModeIds(sceneModeIds));
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,105 @@
|
||||
package com.ruoyi.business.controller;
|
||||
|
||||
import java.util.List;
|
||||
import java.io.IOException;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
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.ruoyi.common.log.annotation.Log;
|
||||
import com.ruoyi.common.log.enums.BusinessType;
|
||||
import com.ruoyi.common.security.annotation.RequiresPermissions;
|
||||
import com.ruoyi.business.domain.HwTenant;
|
||||
import com.ruoyi.business.service.IHwTenantService;
|
||||
import com.ruoyi.common.core.web.controller.BaseController;
|
||||
import com.ruoyi.common.core.web.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.common.core.web.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 租户信息Controller
|
||||
*
|
||||
* @author xins
|
||||
* @date 2023-09-04
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/tenant")
|
||||
public class HwTenantController extends BaseController
|
||||
{
|
||||
@Autowired
|
||||
private IHwTenantService hwTenantService;
|
||||
|
||||
/**
|
||||
* 查询租户信息列表
|
||||
*/
|
||||
@RequiresPermissions("business:tenant:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(HwTenant hwTenant)
|
||||
{
|
||||
startPage();
|
||||
List<HwTenant> list = hwTenantService.selectHwTenantList(hwTenant);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出租户信息列表
|
||||
*/
|
||||
@RequiresPermissions("business:tenant:export")
|
||||
@Log(title = "租户信息", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(HttpServletResponse response, HwTenant hwTenant)
|
||||
{
|
||||
List<HwTenant> list = hwTenantService.selectHwTenantList(hwTenant);
|
||||
ExcelUtil<HwTenant> util = new ExcelUtil<HwTenant>(HwTenant.class);
|
||||
util.exportExcel(response, list, "租户信息数据");
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取租户信息详细信息
|
||||
*/
|
||||
@RequiresPermissions("business:tenant:query")
|
||||
@GetMapping(value = "/{tenantId}")
|
||||
public AjaxResult getInfo(@PathVariable("tenantId") Long tenantId)
|
||||
{
|
||||
return success(hwTenantService.selectHwTenantByTenantId(tenantId));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增租户信息
|
||||
*/
|
||||
@RequiresPermissions("business:tenant:add")
|
||||
@Log(title = "租户信息", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
public AjaxResult add(@RequestBody HwTenant hwTenant)
|
||||
{
|
||||
return toAjax(hwTenantService.insertHwTenant(hwTenant));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改租户信息
|
||||
*/
|
||||
@RequiresPermissions("business:tenant:edit")
|
||||
@Log(title = "租户信息", businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
public AjaxResult edit(@RequestBody HwTenant hwTenant)
|
||||
{
|
||||
return toAjax(hwTenantService.updateHwTenant(hwTenant));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除租户信息
|
||||
*/
|
||||
@RequiresPermissions("business:tenant:remove")
|
||||
@Log(title = "租户信息", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{tenantIds}")
|
||||
public AjaxResult remove(@PathVariable Long[] tenantIds)
|
||||
{
|
||||
return toAjax(hwTenantService.deleteHwTenantByTenantIds(tenantIds));
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,183 @@
|
||||
package com.ruoyi.business.domain;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
import com.ruoyi.common.core.annotation.Excel;
|
||||
import com.ruoyi.common.core.web.domain.BaseEntity;
|
||||
|
||||
/**
|
||||
* 监控单元对象 hw_monitor_unit
|
||||
*
|
||||
* @author YINQ
|
||||
* @date 2023-08-31
|
||||
*/
|
||||
public class HwMonitorUnit extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 监控单元ID */
|
||||
private Long monitorUnitId;
|
||||
|
||||
/** 监控单元名称 */
|
||||
@Excel(name = "监控单元名称")
|
||||
private String monitorUnitName;
|
||||
|
||||
/** 所属场景 */
|
||||
@Excel(name = "所属场景")
|
||||
private Long sceneId;
|
||||
|
||||
/** 父级监控单元ID */
|
||||
@Excel(name = "父级监控单元ID")
|
||||
private Long parentId;
|
||||
|
||||
/** 监控单元类型ID */
|
||||
@Excel(name = "监控单元类型ID")
|
||||
private Long monitorUnitTypeId;
|
||||
|
||||
/** 区域ID */
|
||||
@Excel(name = "区域ID")
|
||||
private Long areaId;
|
||||
|
||||
/** 详细地址 */
|
||||
@Excel(name = "详细地址")
|
||||
private String monitorAddress;
|
||||
|
||||
/** 监控单元图片地址 */
|
||||
@Excel(name = "监控单元图片地址")
|
||||
private String monitorPic;
|
||||
|
||||
/** 保存周期 */
|
||||
@Excel(name = "保存周期")
|
||||
private BigDecimal preserveTime;
|
||||
|
||||
/** 状态 */
|
||||
@Excel(name = "状态")
|
||||
private Long monitorUnitStatus;
|
||||
|
||||
/** 预留字段 */
|
||||
@Excel(name = "预留字段")
|
||||
private String monitorUnitField;
|
||||
|
||||
public void setMonitorUnitId(Long monitorUnitId)
|
||||
{
|
||||
this.monitorUnitId = monitorUnitId;
|
||||
}
|
||||
|
||||
public Long getMonitorUnitId()
|
||||
{
|
||||
return monitorUnitId;
|
||||
}
|
||||
public void setMonitorUnitName(String monitorUnitName)
|
||||
{
|
||||
this.monitorUnitName = monitorUnitName;
|
||||
}
|
||||
|
||||
public String getMonitorUnitName()
|
||||
{
|
||||
return monitorUnitName;
|
||||
}
|
||||
public void setSceneId(Long sceneId)
|
||||
{
|
||||
this.sceneId = sceneId;
|
||||
}
|
||||
|
||||
public Long getSceneId()
|
||||
{
|
||||
return sceneId;
|
||||
}
|
||||
public void setParentId(Long parentId)
|
||||
{
|
||||
this.parentId = parentId;
|
||||
}
|
||||
|
||||
public Long getParentId()
|
||||
{
|
||||
return parentId;
|
||||
}
|
||||
public void setMonitorUnitTypeId(Long monitorUnitTypeId)
|
||||
{
|
||||
this.monitorUnitTypeId = monitorUnitTypeId;
|
||||
}
|
||||
|
||||
public Long getMonitorUnitTypeId()
|
||||
{
|
||||
return monitorUnitTypeId;
|
||||
}
|
||||
public void setAreaId(Long areaId)
|
||||
{
|
||||
this.areaId = areaId;
|
||||
}
|
||||
|
||||
public Long getAreaId()
|
||||
{
|
||||
return areaId;
|
||||
}
|
||||
public void setMonitorAddress(String monitorAddress)
|
||||
{
|
||||
this.monitorAddress = monitorAddress;
|
||||
}
|
||||
|
||||
public String getMonitorAddress()
|
||||
{
|
||||
return monitorAddress;
|
||||
}
|
||||
public void setMonitorPic(String monitorPic)
|
||||
{
|
||||
this.monitorPic = monitorPic;
|
||||
}
|
||||
|
||||
public String getMonitorPic()
|
||||
{
|
||||
return monitorPic;
|
||||
}
|
||||
public void setPreserveTime(BigDecimal preserveTime)
|
||||
{
|
||||
this.preserveTime = preserveTime;
|
||||
}
|
||||
|
||||
public BigDecimal getPreserveTime()
|
||||
{
|
||||
return preserveTime;
|
||||
}
|
||||
public void setMonitorUnitStatus(Long monitorUnitStatus)
|
||||
{
|
||||
this.monitorUnitStatus = monitorUnitStatus;
|
||||
}
|
||||
|
||||
public Long getMonitorUnitStatus()
|
||||
{
|
||||
return monitorUnitStatus;
|
||||
}
|
||||
public void setMonitorUnitField(String monitorUnitField)
|
||||
{
|
||||
this.monitorUnitField = monitorUnitField;
|
||||
}
|
||||
|
||||
public String getMonitorUnitField()
|
||||
{
|
||||
return monitorUnitField;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("monitorUnitId", getMonitorUnitId())
|
||||
.append("monitorUnitName", getMonitorUnitName())
|
||||
.append("sceneId", getSceneId())
|
||||
.append("parentId", getParentId())
|
||||
.append("monitorUnitTypeId", getMonitorUnitTypeId())
|
||||
.append("areaId", getAreaId())
|
||||
.append("monitorAddress", getMonitorAddress())
|
||||
.append("monitorPic", getMonitorPic())
|
||||
.append("preserveTime", getPreserveTime())
|
||||
.append("remark", getRemark())
|
||||
.append("monitorUnitStatus", getMonitorUnitStatus())
|
||||
.append("createBy", getCreateBy())
|
||||
.append("createTime", getCreateTime())
|
||||
.append("updateBy", getUpdateBy())
|
||||
.append("updateTime", getUpdateTime())
|
||||
.append("monitorUnitField", getMonitorUnitField())
|
||||
.toString();
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,126 @@
|
||||
package com.ruoyi.business.domain;
|
||||
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
import com.ruoyi.common.core.annotation.Excel;
|
||||
import com.ruoyi.common.core.web.domain.BaseEntity;
|
||||
|
||||
/**
|
||||
* 场景类型对象 hw_scene_mode
|
||||
*
|
||||
* @author YINQ
|
||||
* @date 2023-08-31
|
||||
*/
|
||||
public class HwSceneMode extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 类型ID */
|
||||
private Long sceneModeId;
|
||||
|
||||
/** 类型名称 */
|
||||
@Excel(name = "类型名称")
|
||||
private String sceneModeName;
|
||||
|
||||
/** 自定义标识 */
|
||||
@Excel(name = "自定义标识")
|
||||
private Long customFlag;
|
||||
|
||||
/** 租户ID */
|
||||
@Excel(name = "租户ID")
|
||||
private Long tenantId;
|
||||
|
||||
/** 语言code */
|
||||
@Excel(name = "语言code")
|
||||
private String languageCode;
|
||||
|
||||
/** 状态 */
|
||||
@Excel(name = "状态")
|
||||
private Long sceneModeStatus;
|
||||
|
||||
/** 预留字段 */
|
||||
@Excel(name = "预留字段")
|
||||
private String sceneModeField;
|
||||
|
||||
public void setSceneModeId(Long sceneModeId)
|
||||
{
|
||||
this.sceneModeId = sceneModeId;
|
||||
}
|
||||
|
||||
public Long getSceneModeId()
|
||||
{
|
||||
return sceneModeId;
|
||||
}
|
||||
public void setSceneModeName(String sceneModeName)
|
||||
{
|
||||
this.sceneModeName = sceneModeName;
|
||||
}
|
||||
|
||||
public String getSceneModeName()
|
||||
{
|
||||
return sceneModeName;
|
||||
}
|
||||
public void setCustomFlag(Long customFlag)
|
||||
{
|
||||
this.customFlag = customFlag;
|
||||
}
|
||||
|
||||
public Long getCustomFlag()
|
||||
{
|
||||
return customFlag;
|
||||
}
|
||||
public void setTenantId(Long tenantId)
|
||||
{
|
||||
this.tenantId = tenantId;
|
||||
}
|
||||
|
||||
public Long getTenantId()
|
||||
{
|
||||
return tenantId;
|
||||
}
|
||||
public void setLanguageCode(String languageCode)
|
||||
{
|
||||
this.languageCode = languageCode;
|
||||
}
|
||||
|
||||
public String getLanguageCode()
|
||||
{
|
||||
return languageCode;
|
||||
}
|
||||
public void setSceneModeStatus(Long sceneModeStatus)
|
||||
{
|
||||
this.sceneModeStatus = sceneModeStatus;
|
||||
}
|
||||
|
||||
public Long getSceneModeStatus()
|
||||
{
|
||||
return sceneModeStatus;
|
||||
}
|
||||
public void setSceneModeField(String sceneModeField)
|
||||
{
|
||||
this.sceneModeField = sceneModeField;
|
||||
}
|
||||
|
||||
public String getSceneModeField()
|
||||
{
|
||||
return sceneModeField;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("sceneModeId", getSceneModeId())
|
||||
.append("sceneModeName", getSceneModeName())
|
||||
.append("customFlag", getCustomFlag())
|
||||
.append("tenantId", getTenantId())
|
||||
.append("languageCode", getLanguageCode())
|
||||
.append("remark", getRemark())
|
||||
.append("sceneModeStatus", getSceneModeStatus())
|
||||
.append("createBy", getCreateBy())
|
||||
.append("createTime", getCreateTime())
|
||||
.append("updateBy", getUpdateBy())
|
||||
.append("updateTime", getUpdateTime())
|
||||
.append("sceneModeField", getSceneModeField())
|
||||
.toString();
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,61 @@
|
||||
package com.ruoyi.business.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.business.domain.HwDeviceModeFunction;
|
||||
|
||||
/**
|
||||
* 设备模型功能Mapper接口
|
||||
*
|
||||
* @author xins
|
||||
* @date 2023-09-05
|
||||
*/
|
||||
public interface HwDeviceModeFunctionMapper
|
||||
{
|
||||
/**
|
||||
* 查询设备模型功能
|
||||
*
|
||||
* @param modeFunctionId 设备模型功能主键
|
||||
* @return 设备模型功能
|
||||
*/
|
||||
public HwDeviceModeFunction selectHwDeviceModeFunctionByModeFunctionId(Long modeFunctionId);
|
||||
|
||||
/**
|
||||
* 查询设备模型功能列表
|
||||
*
|
||||
* @param hwDeviceModeFunction 设备模型功能
|
||||
* @return 设备模型功能集合
|
||||
*/
|
||||
public List<HwDeviceModeFunction> selectHwDeviceModeFunctionList(HwDeviceModeFunction hwDeviceModeFunction);
|
||||
|
||||
/**
|
||||
* 新增设备模型功能
|
||||
*
|
||||
* @param hwDeviceModeFunction 设备模型功能
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertHwDeviceModeFunction(HwDeviceModeFunction hwDeviceModeFunction);
|
||||
|
||||
/**
|
||||
* 修改设备模型功能
|
||||
*
|
||||
* @param hwDeviceModeFunction 设备模型功能
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateHwDeviceModeFunction(HwDeviceModeFunction hwDeviceModeFunction);
|
||||
|
||||
/**
|
||||
* 删除设备模型功能
|
||||
*
|
||||
* @param modeFunctionId 设备模型功能主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteHwDeviceModeFunctionByModeFunctionId(Long modeFunctionId);
|
||||
|
||||
/**
|
||||
* 批量删除设备模型功能
|
||||
*
|
||||
* @param modeFunctionIds 需要删除的数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteHwDeviceModeFunctionByModeFunctionIds(Long[] modeFunctionIds);
|
||||
}
|
||||
@ -0,0 +1,87 @@
|
||||
package com.ruoyi.business.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.business.domain.HwDeviceMode;
|
||||
import com.ruoyi.business.domain.HwDeviceModeFunction;
|
||||
|
||||
/**
|
||||
* 设备模型Mapper接口
|
||||
*
|
||||
* @author xins
|
||||
* @date 2023-09-04
|
||||
*/
|
||||
public interface HwDeviceModeMapper
|
||||
{
|
||||
/**
|
||||
* 查询设备模型
|
||||
*
|
||||
* @param deviceModeId 设备模型主键
|
||||
* @return 设备模型
|
||||
*/
|
||||
public HwDeviceMode selectHwDeviceModeByDeviceModeId(Long deviceModeId);
|
||||
|
||||
/**
|
||||
* 查询设备模型列表
|
||||
*
|
||||
* @param hwDeviceMode 设备模型
|
||||
* @return 设备模型集合
|
||||
*/
|
||||
public List<HwDeviceMode> selectHwDeviceModeList(HwDeviceMode hwDeviceMode);
|
||||
|
||||
/**
|
||||
* 新增设备模型
|
||||
*
|
||||
* @param hwDeviceMode 设备模型
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertHwDeviceMode(HwDeviceMode hwDeviceMode);
|
||||
|
||||
/**
|
||||
* 修改设备模型
|
||||
*
|
||||
* @param hwDeviceMode 设备模型
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateHwDeviceMode(HwDeviceMode hwDeviceMode);
|
||||
|
||||
/**
|
||||
* 删除设备模型
|
||||
*
|
||||
* @param deviceModeId 设备模型主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteHwDeviceModeByDeviceModeId(Long deviceModeId);
|
||||
|
||||
/**
|
||||
* 批量删除设备模型
|
||||
*
|
||||
* @param deviceModeIds 需要删除的数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteHwDeviceModeByDeviceModeIds(Long[] deviceModeIds);
|
||||
|
||||
/**
|
||||
* 批量删除设备模型功能
|
||||
*
|
||||
* @param deviceModeIds 需要删除的数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteHwDeviceModeFunctionByDeviceModeIds(Long[] deviceModeIds);
|
||||
|
||||
/**
|
||||
* 批量新增设备模型功能
|
||||
*
|
||||
* @param hwDeviceModeFunctionList 设备模型功能列表
|
||||
* @return 结果
|
||||
*/
|
||||
public int batchHwDeviceModeFunction(List<HwDeviceModeFunction> hwDeviceModeFunctionList);
|
||||
|
||||
|
||||
/**
|
||||
* 通过设备模型主键删除设备模型功能信息
|
||||
*
|
||||
* @param deviceModeId 设备模型ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteHwDeviceModeFunctionByDeviceModeId(Long deviceModeId);
|
||||
}
|
||||
@ -0,0 +1,61 @@
|
||||
package com.ruoyi.business.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.business.domain.HwElectronicFence;
|
||||
|
||||
/**
|
||||
* 电子围栏Mapper接口
|
||||
*
|
||||
* @author xins
|
||||
* @date 2023-09-04
|
||||
*/
|
||||
public interface HwElectronicFenceMapper
|
||||
{
|
||||
/**
|
||||
* 查询电子围栏
|
||||
*
|
||||
* @param electronicFenceId 电子围栏主键
|
||||
* @return 电子围栏
|
||||
*/
|
||||
public HwElectronicFence selectHwElectronicFenceByElectronicFenceId(Long electronicFenceId);
|
||||
|
||||
/**
|
||||
* 查询电子围栏列表
|
||||
*
|
||||
* @param hwElectronicFence 电子围栏
|
||||
* @return 电子围栏集合
|
||||
*/
|
||||
public List<HwElectronicFence> selectHwElectronicFenceList(HwElectronicFence hwElectronicFence);
|
||||
|
||||
/**
|
||||
* 新增电子围栏
|
||||
*
|
||||
* @param hwElectronicFence 电子围栏
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertHwElectronicFence(HwElectronicFence hwElectronicFence);
|
||||
|
||||
/**
|
||||
* 修改电子围栏
|
||||
*
|
||||
* @param hwElectronicFence 电子围栏
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateHwElectronicFence(HwElectronicFence hwElectronicFence);
|
||||
|
||||
/**
|
||||
* 删除电子围栏
|
||||
*
|
||||
* @param electronicFenceId 电子围栏主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteHwElectronicFenceByElectronicFenceId(Long electronicFenceId);
|
||||
|
||||
/**
|
||||
* 批量删除电子围栏
|
||||
*
|
||||
* @param electronicFenceIds 需要删除的数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteHwElectronicFenceByElectronicFenceIds(Long[] electronicFenceIds);
|
||||
}
|
||||
@ -0,0 +1,61 @@
|
||||
package com.ruoyi.business.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.business.domain.HwFenceTarget;
|
||||
|
||||
/**
|
||||
* 电子围栏目标Mapper接口
|
||||
*
|
||||
* @author xins
|
||||
* @date 2023-09-04
|
||||
*/
|
||||
public interface HwFenceTargetMapper
|
||||
{
|
||||
/**
|
||||
* 查询电子围栏目标
|
||||
*
|
||||
* @param targetId 电子围栏目标主键
|
||||
* @return 电子围栏目标
|
||||
*/
|
||||
public HwFenceTarget selectHwFenceTargetByTargetId(Long targetId);
|
||||
|
||||
/**
|
||||
* 查询电子围栏目标列表
|
||||
*
|
||||
* @param hwFenceTarget 电子围栏目标
|
||||
* @return 电子围栏目标集合
|
||||
*/
|
||||
public List<HwFenceTarget> selectHwFenceTargetList(HwFenceTarget hwFenceTarget);
|
||||
|
||||
/**
|
||||
* 新增电子围栏目标
|
||||
*
|
||||
* @param hwFenceTarget 电子围栏目标
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertHwFenceTarget(HwFenceTarget hwFenceTarget);
|
||||
|
||||
/**
|
||||
* 修改电子围栏目标
|
||||
*
|
||||
* @param hwFenceTarget 电子围栏目标
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateHwFenceTarget(HwFenceTarget hwFenceTarget);
|
||||
|
||||
/**
|
||||
* 删除电子围栏目标
|
||||
*
|
||||
* @param targetId 电子围栏目标主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteHwFenceTargetByTargetId(Long targetId);
|
||||
|
||||
/**
|
||||
* 批量删除电子围栏目标
|
||||
*
|
||||
* @param targetIds 需要删除的数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteHwFenceTargetByTargetIds(Long[] targetIds);
|
||||
}
|
||||
@ -0,0 +1,61 @@
|
||||
package com.ruoyi.business.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.business.domain.HwMonitorUnit;
|
||||
|
||||
/**
|
||||
* 监控单元Mapper接口
|
||||
*
|
||||
* @author YINQ
|
||||
* @date 2023-08-31
|
||||
*/
|
||||
public interface HwMonitorUnitMapper
|
||||
{
|
||||
/**
|
||||
* 查询监控单元
|
||||
*
|
||||
* @param monitorUnitId 监控单元主键
|
||||
* @return 监控单元
|
||||
*/
|
||||
public HwMonitorUnit selectHwMonitorUnitByMonitorUnitId(Long monitorUnitId);
|
||||
|
||||
/**
|
||||
* 查询监控单元列表
|
||||
*
|
||||
* @param hwMonitorUnit 监控单元
|
||||
* @return 监控单元集合
|
||||
*/
|
||||
public List<HwMonitorUnit> selectHwMonitorUnitList(HwMonitorUnit hwMonitorUnit);
|
||||
|
||||
/**
|
||||
* 新增监控单元
|
||||
*
|
||||
* @param hwMonitorUnit 监控单元
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertHwMonitorUnit(HwMonitorUnit hwMonitorUnit);
|
||||
|
||||
/**
|
||||
* 修改监控单元
|
||||
*
|
||||
* @param hwMonitorUnit 监控单元
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateHwMonitorUnit(HwMonitorUnit hwMonitorUnit);
|
||||
|
||||
/**
|
||||
* 删除监控单元
|
||||
*
|
||||
* @param monitorUnitId 监控单元主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteHwMonitorUnitByMonitorUnitId(Long monitorUnitId);
|
||||
|
||||
/**
|
||||
* 批量删除监控单元
|
||||
*
|
||||
* @param monitorUnitIds 需要删除的数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteHwMonitorUnitByMonitorUnitIds(Long[] monitorUnitIds);
|
||||
}
|
||||
@ -0,0 +1,61 @@
|
||||
package com.ruoyi.business.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.business.domain.HwMonitorUnitType;
|
||||
|
||||
/**
|
||||
* 监控单元类型Mapper接口
|
||||
*
|
||||
* @author YINQ
|
||||
* @date 2023-08-31
|
||||
*/
|
||||
public interface HwMonitorUnitTypeMapper
|
||||
{
|
||||
/**
|
||||
* 查询监控单元类型
|
||||
*
|
||||
* @param monitorUnitTypeId 监控单元类型主键
|
||||
* @return 监控单元类型
|
||||
*/
|
||||
public HwMonitorUnitType selectHwMonitorUnitTypeByMonitorUnitTypeId(Long monitorUnitTypeId);
|
||||
|
||||
/**
|
||||
* 查询监控单元类型列表
|
||||
*
|
||||
* @param hwMonitorUnitType 监控单元类型
|
||||
* @return 监控单元类型集合
|
||||
*/
|
||||
public List<HwMonitorUnitType> selectHwMonitorUnitTypeList(HwMonitorUnitType hwMonitorUnitType);
|
||||
|
||||
/**
|
||||
* 新增监控单元类型
|
||||
*
|
||||
* @param hwMonitorUnitType 监控单元类型
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertHwMonitorUnitType(HwMonitorUnitType hwMonitorUnitType);
|
||||
|
||||
/**
|
||||
* 修改监控单元类型
|
||||
*
|
||||
* @param hwMonitorUnitType 监控单元类型
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateHwMonitorUnitType(HwMonitorUnitType hwMonitorUnitType);
|
||||
|
||||
/**
|
||||
* 删除监控单元类型
|
||||
*
|
||||
* @param monitorUnitTypeId 监控单元类型主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteHwMonitorUnitTypeByMonitorUnitTypeId(Long monitorUnitTypeId);
|
||||
|
||||
/**
|
||||
* 批量删除监控单元类型
|
||||
*
|
||||
* @param monitorUnitTypeIds 需要删除的数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteHwMonitorUnitTypeByMonitorUnitTypeIds(Long[] monitorUnitTypeIds);
|
||||
}
|
||||
@ -0,0 +1,61 @@
|
||||
package com.ruoyi.business.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.business.domain.HwSceneMode;
|
||||
|
||||
/**
|
||||
* 场景类型Mapper接口
|
||||
*
|
||||
* @author YINQ
|
||||
* @date 2023-08-31
|
||||
*/
|
||||
public interface HwSceneModeMapper
|
||||
{
|
||||
/**
|
||||
* 查询场景类型
|
||||
*
|
||||
* @param sceneModeId 场景类型主键
|
||||
* @return 场景类型
|
||||
*/
|
||||
public HwSceneMode selectHwSceneModeBySceneModeId(Long sceneModeId);
|
||||
|
||||
/**
|
||||
* 查询场景类型列表
|
||||
*
|
||||
* @param hwSceneMode 场景类型
|
||||
* @return 场景类型集合
|
||||
*/
|
||||
public List<HwSceneMode> selectHwSceneModeList(HwSceneMode hwSceneMode);
|
||||
|
||||
/**
|
||||
* 新增场景类型
|
||||
*
|
||||
* @param hwSceneMode 场景类型
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertHwSceneMode(HwSceneMode hwSceneMode);
|
||||
|
||||
/**
|
||||
* 修改场景类型
|
||||
*
|
||||
* @param hwSceneMode 场景类型
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateHwSceneMode(HwSceneMode hwSceneMode);
|
||||
|
||||
/**
|
||||
* 删除场景类型
|
||||
*
|
||||
* @param sceneModeId 场景类型主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteHwSceneModeBySceneModeId(Long sceneModeId);
|
||||
|
||||
/**
|
||||
* 批量删除场景类型
|
||||
*
|
||||
* @param sceneModeIds 需要删除的数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteHwSceneModeBySceneModeIds(Long[] sceneModeIds);
|
||||
}
|
||||
@ -0,0 +1,61 @@
|
||||
package com.ruoyi.business.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.business.domain.HwTenant;
|
||||
|
||||
/**
|
||||
* 租户信息Mapper接口
|
||||
*
|
||||
* @author xins
|
||||
* @date 2023-09-04
|
||||
*/
|
||||
public interface HwTenantMapper
|
||||
{
|
||||
/**
|
||||
* 查询租户信息
|
||||
*
|
||||
* @param tenantId 租户信息主键
|
||||
* @return 租户信息
|
||||
*/
|
||||
public HwTenant selectHwTenantByTenantId(Long tenantId);
|
||||
|
||||
/**
|
||||
* 查询租户信息列表
|
||||
*
|
||||
* @param hwTenant 租户信息
|
||||
* @return 租户信息集合
|
||||
*/
|
||||
public List<HwTenant> selectHwTenantList(HwTenant hwTenant);
|
||||
|
||||
/**
|
||||
* 新增租户信息
|
||||
*
|
||||
* @param hwTenant 租户信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertHwTenant(HwTenant hwTenant);
|
||||
|
||||
/**
|
||||
* 修改租户信息
|
||||
*
|
||||
* @param hwTenant 租户信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateHwTenant(HwTenant hwTenant);
|
||||
|
||||
/**
|
||||
* 删除租户信息
|
||||
*
|
||||
* @param tenantId 租户信息主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteHwTenantByTenantId(Long tenantId);
|
||||
|
||||
/**
|
||||
* 批量删除租户信息
|
||||
*
|
||||
* @param tenantIds 需要删除的数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteHwTenantByTenantIds(Long[] tenantIds);
|
||||
}
|
||||
@ -0,0 +1,61 @@
|
||||
package com.ruoyi.business.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.business.domain.HwDeviceModeFunction;
|
||||
|
||||
/**
|
||||
* 设备模型功能Service接口
|
||||
*
|
||||
* @author xins
|
||||
* @date 2023-09-05
|
||||
*/
|
||||
public interface IHwDeviceModeFunctionService
|
||||
{
|
||||
/**
|
||||
* 查询设备模型功能
|
||||
*
|
||||
* @param modeFunctionId 设备模型功能主键
|
||||
* @return 设备模型功能
|
||||
*/
|
||||
public HwDeviceModeFunction selectHwDeviceModeFunctionByModeFunctionId(Long modeFunctionId);
|
||||
|
||||
/**
|
||||
* 查询设备模型功能列表
|
||||
*
|
||||
* @param hwDeviceModeFunction 设备模型功能
|
||||
* @return 设备模型功能集合
|
||||
*/
|
||||
public List<HwDeviceModeFunction> selectHwDeviceModeFunctionList(HwDeviceModeFunction hwDeviceModeFunction);
|
||||
|
||||
/**
|
||||
* 新增设备模型功能
|
||||
*
|
||||
* @param hwDeviceModeFunction 设备模型功能
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertHwDeviceModeFunction(HwDeviceModeFunction hwDeviceModeFunction);
|
||||
|
||||
/**
|
||||
* 修改设备模型功能
|
||||
*
|
||||
* @param hwDeviceModeFunction 设备模型功能
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateHwDeviceModeFunction(HwDeviceModeFunction hwDeviceModeFunction);
|
||||
|
||||
/**
|
||||
* 批量删除设备模型功能
|
||||
*
|
||||
* @param modeFunctionIds 需要删除的设备模型功能主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteHwDeviceModeFunctionByModeFunctionIds(Long[] modeFunctionIds);
|
||||
|
||||
/**
|
||||
* 删除设备模型功能信息
|
||||
*
|
||||
* @param modeFunctionId 设备模型功能主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteHwDeviceModeFunctionByModeFunctionId(Long modeFunctionId);
|
||||
}
|
||||
@ -0,0 +1,61 @@
|
||||
package com.ruoyi.business.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.business.domain.HwDeviceMode;
|
||||
|
||||
/**
|
||||
* 设备模型Service接口
|
||||
*
|
||||
* @author xins
|
||||
* @date 2023-09-04
|
||||
*/
|
||||
public interface IHwDeviceModeService
|
||||
{
|
||||
/**
|
||||
* 查询设备模型
|
||||
*
|
||||
* @param deviceModeId 设备模型主键
|
||||
* @return 设备模型
|
||||
*/
|
||||
public HwDeviceMode selectHwDeviceModeByDeviceModeId(Long deviceModeId);
|
||||
|
||||
/**
|
||||
* 查询设备模型列表
|
||||
*
|
||||
* @param hwDeviceMode 设备模型
|
||||
* @return 设备模型集合
|
||||
*/
|
||||
public List<HwDeviceMode> selectHwDeviceModeList(HwDeviceMode hwDeviceMode);
|
||||
|
||||
/**
|
||||
* 新增设备模型
|
||||
*
|
||||
* @param hwDeviceMode 设备模型
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertHwDeviceMode(HwDeviceMode hwDeviceMode);
|
||||
|
||||
/**
|
||||
* 修改设备模型
|
||||
*
|
||||
* @param hwDeviceMode 设备模型
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateHwDeviceMode(HwDeviceMode hwDeviceMode);
|
||||
|
||||
/**
|
||||
* 批量删除设备模型
|
||||
*
|
||||
* @param deviceModeIds 需要删除的设备模型主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteHwDeviceModeByDeviceModeIds(Long[] deviceModeIds);
|
||||
|
||||
/**
|
||||
* 删除设备模型信息
|
||||
*
|
||||
* @param deviceModeId 设备模型主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteHwDeviceModeByDeviceModeId(Long deviceModeId);
|
||||
}
|
||||
@ -0,0 +1,61 @@
|
||||
package com.ruoyi.business.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.business.domain.HwElectronicFence;
|
||||
|
||||
/**
|
||||
* 电子围栏Service接口
|
||||
*
|
||||
* @author xins
|
||||
* @date 2023-09-04
|
||||
*/
|
||||
public interface IHwElectronicFenceService
|
||||
{
|
||||
/**
|
||||
* 查询电子围栏
|
||||
*
|
||||
* @param electronicFenceId 电子围栏主键
|
||||
* @return 电子围栏
|
||||
*/
|
||||
public HwElectronicFence selectHwElectronicFenceByElectronicFenceId(Long electronicFenceId);
|
||||
|
||||
/**
|
||||
* 查询电子围栏列表
|
||||
*
|
||||
* @param hwElectronicFence 电子围栏
|
||||
* @return 电子围栏集合
|
||||
*/
|
||||
public List<HwElectronicFence> selectHwElectronicFenceList(HwElectronicFence hwElectronicFence);
|
||||
|
||||
/**
|
||||
* 新增电子围栏
|
||||
*
|
||||
* @param hwElectronicFence 电子围栏
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertHwElectronicFence(HwElectronicFence hwElectronicFence);
|
||||
|
||||
/**
|
||||
* 修改电子围栏
|
||||
*
|
||||
* @param hwElectronicFence 电子围栏
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateHwElectronicFence(HwElectronicFence hwElectronicFence);
|
||||
|
||||
/**
|
||||
* 批量删除电子围栏
|
||||
*
|
||||
* @param electronicFenceIds 需要删除的电子围栏主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteHwElectronicFenceByElectronicFenceIds(Long[] electronicFenceIds);
|
||||
|
||||
/**
|
||||
* 删除电子围栏信息
|
||||
*
|
||||
* @param electronicFenceId 电子围栏主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteHwElectronicFenceByElectronicFenceId(Long electronicFenceId);
|
||||
}
|
||||
@ -0,0 +1,61 @@
|
||||
package com.ruoyi.business.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.business.domain.HwFenceTarget;
|
||||
|
||||
/**
|
||||
* 电子围栏目标Service接口
|
||||
*
|
||||
* @author xins
|
||||
* @date 2023-09-04
|
||||
*/
|
||||
public interface IHwFenceTargetService
|
||||
{
|
||||
/**
|
||||
* 查询电子围栏目标
|
||||
*
|
||||
* @param targetId 电子围栏目标主键
|
||||
* @return 电子围栏目标
|
||||
*/
|
||||
public HwFenceTarget selectHwFenceTargetByTargetId(Long targetId);
|
||||
|
||||
/**
|
||||
* 查询电子围栏目标列表
|
||||
*
|
||||
* @param hwFenceTarget 电子围栏目标
|
||||
* @return 电子围栏目标集合
|
||||
*/
|
||||
public List<HwFenceTarget> selectHwFenceTargetList(HwFenceTarget hwFenceTarget);
|
||||
|
||||
/**
|
||||
* 新增电子围栏目标
|
||||
*
|
||||
* @param hwFenceTarget 电子围栏目标
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertHwFenceTarget(HwFenceTarget hwFenceTarget);
|
||||
|
||||
/**
|
||||
* 修改电子围栏目标
|
||||
*
|
||||
* @param hwFenceTarget 电子围栏目标
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateHwFenceTarget(HwFenceTarget hwFenceTarget);
|
||||
|
||||
/**
|
||||
* 批量删除电子围栏目标
|
||||
*
|
||||
* @param targetIds 需要删除的电子围栏目标主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteHwFenceTargetByTargetIds(Long[] targetIds);
|
||||
|
||||
/**
|
||||
* 删除电子围栏目标信息
|
||||
*
|
||||
* @param targetId 电子围栏目标主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteHwFenceTargetByTargetId(Long targetId);
|
||||
}
|
||||
@ -0,0 +1,61 @@
|
||||
package com.ruoyi.business.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.business.domain.HwMonitorUnit;
|
||||
|
||||
/**
|
||||
* 监控单元Service接口
|
||||
*
|
||||
* @author YINQ
|
||||
* @date 2023-08-31
|
||||
*/
|
||||
public interface IHwMonitorUnitService
|
||||
{
|
||||
/**
|
||||
* 查询监控单元
|
||||
*
|
||||
* @param monitorUnitId 监控单元主键
|
||||
* @return 监控单元
|
||||
*/
|
||||
public HwMonitorUnit selectHwMonitorUnitByMonitorUnitId(Long monitorUnitId);
|
||||
|
||||
/**
|
||||
* 查询监控单元列表
|
||||
*
|
||||
* @param hwMonitorUnit 监控单元
|
||||
* @return 监控单元集合
|
||||
*/
|
||||
public List<HwMonitorUnit> selectHwMonitorUnitList(HwMonitorUnit hwMonitorUnit);
|
||||
|
||||
/**
|
||||
* 新增监控单元
|
||||
*
|
||||
* @param hwMonitorUnit 监控单元
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertHwMonitorUnit(HwMonitorUnit hwMonitorUnit);
|
||||
|
||||
/**
|
||||
* 修改监控单元
|
||||
*
|
||||
* @param hwMonitorUnit 监控单元
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateHwMonitorUnit(HwMonitorUnit hwMonitorUnit);
|
||||
|
||||
/**
|
||||
* 批量删除监控单元
|
||||
*
|
||||
* @param monitorUnitIds 需要删除的监控单元主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteHwMonitorUnitByMonitorUnitIds(Long[] monitorUnitIds);
|
||||
|
||||
/**
|
||||
* 删除监控单元信息
|
||||
*
|
||||
* @param monitorUnitId 监控单元主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteHwMonitorUnitByMonitorUnitId(Long monitorUnitId);
|
||||
}
|
||||
@ -0,0 +1,61 @@
|
||||
package com.ruoyi.business.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.business.domain.HwMonitorUnitType;
|
||||
|
||||
/**
|
||||
* 监控单元类型Service接口
|
||||
*
|
||||
* @author YINQ
|
||||
* @date 2023-08-31
|
||||
*/
|
||||
public interface IHwMonitorUnitTypeService
|
||||
{
|
||||
/**
|
||||
* 查询监控单元类型
|
||||
*
|
||||
* @param monitorUnitTypeId 监控单元类型主键
|
||||
* @return 监控单元类型
|
||||
*/
|
||||
public HwMonitorUnitType selectHwMonitorUnitTypeByMonitorUnitTypeId(Long monitorUnitTypeId);
|
||||
|
||||
/**
|
||||
* 查询监控单元类型列表
|
||||
*
|
||||
* @param hwMonitorUnitType 监控单元类型
|
||||
* @return 监控单元类型集合
|
||||
*/
|
||||
public List<HwMonitorUnitType> selectHwMonitorUnitTypeList(HwMonitorUnitType hwMonitorUnitType);
|
||||
|
||||
/**
|
||||
* 新增监控单元类型
|
||||
*
|
||||
* @param hwMonitorUnitType 监控单元类型
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertHwMonitorUnitType(HwMonitorUnitType hwMonitorUnitType);
|
||||
|
||||
/**
|
||||
* 修改监控单元类型
|
||||
*
|
||||
* @param hwMonitorUnitType 监控单元类型
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateHwMonitorUnitType(HwMonitorUnitType hwMonitorUnitType);
|
||||
|
||||
/**
|
||||
* 批量删除监控单元类型
|
||||
*
|
||||
* @param monitorUnitTypeIds 需要删除的监控单元类型主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteHwMonitorUnitTypeByMonitorUnitTypeIds(Long[] monitorUnitTypeIds);
|
||||
|
||||
/**
|
||||
* 删除监控单元类型信息
|
||||
*
|
||||
* @param monitorUnitTypeId 监控单元类型主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteHwMonitorUnitTypeByMonitorUnitTypeId(Long monitorUnitTypeId);
|
||||
}
|
||||
@ -0,0 +1,61 @@
|
||||
package com.ruoyi.business.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.business.domain.HwSceneMode;
|
||||
|
||||
/**
|
||||
* 场景类型Service接口
|
||||
*
|
||||
* @author YINQ
|
||||
* @date 2023-08-31
|
||||
*/
|
||||
public interface IHwSceneModeService
|
||||
{
|
||||
/**
|
||||
* 查询场景类型
|
||||
*
|
||||
* @param sceneModeId 场景类型主键
|
||||
* @return 场景类型
|
||||
*/
|
||||
public HwSceneMode selectHwSceneModeBySceneModeId(Long sceneModeId);
|
||||
|
||||
/**
|
||||
* 查询场景类型列表
|
||||
*
|
||||
* @param hwSceneMode 场景类型
|
||||
* @return 场景类型集合
|
||||
*/
|
||||
public List<HwSceneMode> selectHwSceneModeList(HwSceneMode hwSceneMode);
|
||||
|
||||
/**
|
||||
* 新增场景类型
|
||||
*
|
||||
* @param hwSceneMode 场景类型
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertHwSceneMode(HwSceneMode hwSceneMode);
|
||||
|
||||
/**
|
||||
* 修改场景类型
|
||||
*
|
||||
* @param hwSceneMode 场景类型
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateHwSceneMode(HwSceneMode hwSceneMode);
|
||||
|
||||
/**
|
||||
* 批量删除场景类型
|
||||
*
|
||||
* @param sceneModeIds 需要删除的场景类型主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteHwSceneModeBySceneModeIds(Long[] sceneModeIds);
|
||||
|
||||
/**
|
||||
* 删除场景类型信息
|
||||
*
|
||||
* @param sceneModeId 场景类型主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteHwSceneModeBySceneModeId(Long sceneModeId);
|
||||
}
|
||||
@ -0,0 +1,61 @@
|
||||
package com.ruoyi.business.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.business.domain.HwTenant;
|
||||
|
||||
/**
|
||||
* 租户信息Service接口
|
||||
*
|
||||
* @author xins
|
||||
* @date 2023-09-04
|
||||
*/
|
||||
public interface IHwTenantService
|
||||
{
|
||||
/**
|
||||
* 查询租户信息
|
||||
*
|
||||
* @param tenantId 租户信息主键
|
||||
* @return 租户信息
|
||||
*/
|
||||
public HwTenant selectHwTenantByTenantId(Long tenantId);
|
||||
|
||||
/**
|
||||
* 查询租户信息列表
|
||||
*
|
||||
* @param hwTenant 租户信息
|
||||
* @return 租户信息集合
|
||||
*/
|
||||
public List<HwTenant> selectHwTenantList(HwTenant hwTenant);
|
||||
|
||||
/**
|
||||
* 新增租户信息
|
||||
*
|
||||
* @param hwTenant 租户信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertHwTenant(HwTenant hwTenant);
|
||||
|
||||
/**
|
||||
* 修改租户信息
|
||||
*
|
||||
* @param hwTenant 租户信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateHwTenant(HwTenant hwTenant);
|
||||
|
||||
/**
|
||||
* 批量删除租户信息
|
||||
*
|
||||
* @param tenantIds 需要删除的租户信息主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteHwTenantByTenantIds(Long[] tenantIds);
|
||||
|
||||
/**
|
||||
* 删除租户信息信息
|
||||
*
|
||||
* @param tenantId 租户信息主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteHwTenantByTenantId(Long tenantId);
|
||||
}
|
||||
@ -0,0 +1,93 @@
|
||||
package com.ruoyi.business.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.ruoyi.business.mapper.HwDeviceModeFunctionMapper;
|
||||
import com.ruoyi.business.domain.HwDeviceModeFunction;
|
||||
import com.ruoyi.business.service.IHwDeviceModeFunctionService;
|
||||
|
||||
/**
|
||||
* 设备模型功能Service业务层处理
|
||||
*
|
||||
* @author xins
|
||||
* @date 2023-09-05
|
||||
*/
|
||||
@Service
|
||||
public class HwDeviceModeFunctionServiceImpl implements IHwDeviceModeFunctionService
|
||||
{
|
||||
@Autowired
|
||||
private HwDeviceModeFunctionMapper hwDeviceModeFunctionMapper;
|
||||
|
||||
/**
|
||||
* 查询设备模型功能
|
||||
*
|
||||
* @param modeFunctionId 设备模型功能主键
|
||||
* @return 设备模型功能
|
||||
*/
|
||||
@Override
|
||||
public HwDeviceModeFunction selectHwDeviceModeFunctionByModeFunctionId(Long modeFunctionId)
|
||||
{
|
||||
return hwDeviceModeFunctionMapper.selectHwDeviceModeFunctionByModeFunctionId(modeFunctionId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询设备模型功能列表
|
||||
*
|
||||
* @param hwDeviceModeFunction 设备模型功能
|
||||
* @return 设备模型功能
|
||||
*/
|
||||
@Override
|
||||
public List<HwDeviceModeFunction> selectHwDeviceModeFunctionList(HwDeviceModeFunction hwDeviceModeFunction)
|
||||
{
|
||||
return hwDeviceModeFunctionMapper.selectHwDeviceModeFunctionList(hwDeviceModeFunction);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增设备模型功能
|
||||
*
|
||||
* @param hwDeviceModeFunction 设备模型功能
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertHwDeviceModeFunction(HwDeviceModeFunction hwDeviceModeFunction)
|
||||
{
|
||||
return hwDeviceModeFunctionMapper.insertHwDeviceModeFunction(hwDeviceModeFunction);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改设备模型功能
|
||||
*
|
||||
* @param hwDeviceModeFunction 设备模型功能
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateHwDeviceModeFunction(HwDeviceModeFunction hwDeviceModeFunction)
|
||||
{
|
||||
return hwDeviceModeFunctionMapper.updateHwDeviceModeFunction(hwDeviceModeFunction);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除设备模型功能
|
||||
*
|
||||
* @param modeFunctionIds 需要删除的设备模型功能主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteHwDeviceModeFunctionByModeFunctionIds(Long[] modeFunctionIds)
|
||||
{
|
||||
return hwDeviceModeFunctionMapper.deleteHwDeviceModeFunctionByModeFunctionIds(modeFunctionIds);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除设备模型功能信息
|
||||
*
|
||||
* @param modeFunctionId 设备模型功能主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteHwDeviceModeFunctionByModeFunctionId(Long modeFunctionId)
|
||||
{
|
||||
return hwDeviceModeFunctionMapper.deleteHwDeviceModeFunctionByModeFunctionId(modeFunctionId);
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,134 @@
|
||||
package com.ruoyi.business.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.common.core.utils.DateUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import java.util.ArrayList;
|
||||
import com.ruoyi.common.core.utils.StringUtils;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
import com.ruoyi.business.domain.HwDeviceModeFunction;
|
||||
import com.ruoyi.business.mapper.HwDeviceModeMapper;
|
||||
import com.ruoyi.business.domain.HwDeviceMode;
|
||||
import com.ruoyi.business.service.IHwDeviceModeService;
|
||||
|
||||
/**
|
||||
* 设备模型Service业务层处理
|
||||
*
|
||||
* @author xins
|
||||
* @date 2023-09-04
|
||||
*/
|
||||
@Service
|
||||
public class HwDeviceModeServiceImpl implements IHwDeviceModeService
|
||||
{
|
||||
@Autowired
|
||||
private HwDeviceModeMapper hwDeviceModeMapper;
|
||||
|
||||
/**
|
||||
* 查询设备模型
|
||||
*
|
||||
* @param deviceModeId 设备模型主键
|
||||
* @return 设备模型
|
||||
*/
|
||||
@Override
|
||||
public HwDeviceMode selectHwDeviceModeByDeviceModeId(Long deviceModeId)
|
||||
{
|
||||
return hwDeviceModeMapper.selectHwDeviceModeByDeviceModeId(deviceModeId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询设备模型列表
|
||||
*
|
||||
* @param hwDeviceMode 设备模型
|
||||
* @return 设备模型
|
||||
*/
|
||||
@Override
|
||||
public List<HwDeviceMode> selectHwDeviceModeList(HwDeviceMode hwDeviceMode)
|
||||
{
|
||||
return hwDeviceModeMapper.selectHwDeviceModeList(hwDeviceMode);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增设备模型
|
||||
*
|
||||
* @param hwDeviceMode 设备模型
|
||||
* @return 结果
|
||||
*/
|
||||
@Transactional
|
||||
@Override
|
||||
public int insertHwDeviceMode(HwDeviceMode hwDeviceMode)
|
||||
{
|
||||
hwDeviceMode.setCreateTime(DateUtils.getNowDate());
|
||||
int rows = hwDeviceModeMapper.insertHwDeviceMode(hwDeviceMode);
|
||||
insertHwDeviceModeFunction(hwDeviceMode);
|
||||
return rows;
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改设备模型
|
||||
*
|
||||
* @param hwDeviceMode 设备模型
|
||||
* @return 结果
|
||||
*/
|
||||
@Transactional
|
||||
@Override
|
||||
public int updateHwDeviceMode(HwDeviceMode hwDeviceMode)
|
||||
{
|
||||
hwDeviceMode.setUpdateTime(DateUtils.getNowDate());
|
||||
hwDeviceModeMapper.deleteHwDeviceModeFunctionByDeviceModeId(hwDeviceMode.getDeviceModeId());
|
||||
insertHwDeviceModeFunction(hwDeviceMode);
|
||||
return hwDeviceModeMapper.updateHwDeviceMode(hwDeviceMode);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除设备模型
|
||||
*
|
||||
* @param deviceModeIds 需要删除的设备模型主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Transactional
|
||||
@Override
|
||||
public int deleteHwDeviceModeByDeviceModeIds(Long[] deviceModeIds)
|
||||
{
|
||||
hwDeviceModeMapper.deleteHwDeviceModeFunctionByDeviceModeIds(deviceModeIds);
|
||||
return hwDeviceModeMapper.deleteHwDeviceModeByDeviceModeIds(deviceModeIds);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除设备模型信息
|
||||
*
|
||||
* @param deviceModeId 设备模型主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Transactional
|
||||
@Override
|
||||
public int deleteHwDeviceModeByDeviceModeId(Long deviceModeId)
|
||||
{
|
||||
hwDeviceModeMapper.deleteHwDeviceModeFunctionByDeviceModeId(deviceModeId);
|
||||
return hwDeviceModeMapper.deleteHwDeviceModeByDeviceModeId(deviceModeId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增设备模型功能信息
|
||||
*
|
||||
* @param hwDeviceMode 设备模型对象
|
||||
*/
|
||||
public void insertHwDeviceModeFunction(HwDeviceMode hwDeviceMode)
|
||||
{
|
||||
List<HwDeviceModeFunction> hwDeviceModeFunctionList = hwDeviceMode.getHwDeviceModeFunctionList();
|
||||
Long deviceModeId = hwDeviceMode.getDeviceModeId();
|
||||
if (StringUtils.isNotNull(hwDeviceModeFunctionList))
|
||||
{
|
||||
List<HwDeviceModeFunction> list = new ArrayList<HwDeviceModeFunction>();
|
||||
for (HwDeviceModeFunction hwDeviceModeFunction : hwDeviceModeFunctionList)
|
||||
{
|
||||
hwDeviceModeFunction.setDeviceModeId(deviceModeId);
|
||||
list.add(hwDeviceModeFunction);
|
||||
}
|
||||
if (list.size() > 0)
|
||||
{
|
||||
hwDeviceModeMapper.batchHwDeviceModeFunction(list);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,96 @@
|
||||
package com.ruoyi.business.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.common.core.utils.DateUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.ruoyi.business.mapper.HwElectronicFenceMapper;
|
||||
import com.ruoyi.business.domain.HwElectronicFence;
|
||||
import com.ruoyi.business.service.IHwElectronicFenceService;
|
||||
|
||||
/**
|
||||
* 电子围栏Service业务层处理
|
||||
*
|
||||
* @author xins
|
||||
* @date 2023-09-04
|
||||
*/
|
||||
@Service
|
||||
public class HwElectronicFenceServiceImpl implements IHwElectronicFenceService
|
||||
{
|
||||
@Autowired
|
||||
private HwElectronicFenceMapper hwElectronicFenceMapper;
|
||||
|
||||
/**
|
||||
* 查询电子围栏
|
||||
*
|
||||
* @param electronicFenceId 电子围栏主键
|
||||
* @return 电子围栏
|
||||
*/
|
||||
@Override
|
||||
public HwElectronicFence selectHwElectronicFenceByElectronicFenceId(Long electronicFenceId)
|
||||
{
|
||||
return hwElectronicFenceMapper.selectHwElectronicFenceByElectronicFenceId(electronicFenceId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询电子围栏列表
|
||||
*
|
||||
* @param hwElectronicFence 电子围栏
|
||||
* @return 电子围栏
|
||||
*/
|
||||
@Override
|
||||
public List<HwElectronicFence> selectHwElectronicFenceList(HwElectronicFence hwElectronicFence)
|
||||
{
|
||||
return hwElectronicFenceMapper.selectHwElectronicFenceList(hwElectronicFence);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增电子围栏
|
||||
*
|
||||
* @param hwElectronicFence 电子围栏
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertHwElectronicFence(HwElectronicFence hwElectronicFence)
|
||||
{
|
||||
hwElectronicFence.setCreateTime(DateUtils.getNowDate());
|
||||
return hwElectronicFenceMapper.insertHwElectronicFence(hwElectronicFence);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改电子围栏
|
||||
*
|
||||
* @param hwElectronicFence 电子围栏
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateHwElectronicFence(HwElectronicFence hwElectronicFence)
|
||||
{
|
||||
hwElectronicFence.setUpdateTime(DateUtils.getNowDate());
|
||||
return hwElectronicFenceMapper.updateHwElectronicFence(hwElectronicFence);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除电子围栏
|
||||
*
|
||||
* @param electronicFenceIds 需要删除的电子围栏主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteHwElectronicFenceByElectronicFenceIds(Long[] electronicFenceIds)
|
||||
{
|
||||
return hwElectronicFenceMapper.deleteHwElectronicFenceByElectronicFenceIds(electronicFenceIds);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除电子围栏信息
|
||||
*
|
||||
* @param electronicFenceId 电子围栏主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteHwElectronicFenceByElectronicFenceId(Long electronicFenceId)
|
||||
{
|
||||
return hwElectronicFenceMapper.deleteHwElectronicFenceByElectronicFenceId(electronicFenceId);
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,93 @@
|
||||
package com.ruoyi.business.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.ruoyi.business.mapper.HwFenceTargetMapper;
|
||||
import com.ruoyi.business.domain.HwFenceTarget;
|
||||
import com.ruoyi.business.service.IHwFenceTargetService;
|
||||
|
||||
/**
|
||||
* 电子围栏目标Service业务层处理
|
||||
*
|
||||
* @author xins
|
||||
* @date 2023-09-04
|
||||
*/
|
||||
@Service
|
||||
public class HwFenceTargetServiceImpl implements IHwFenceTargetService
|
||||
{
|
||||
@Autowired
|
||||
private HwFenceTargetMapper hwFenceTargetMapper;
|
||||
|
||||
/**
|
||||
* 查询电子围栏目标
|
||||
*
|
||||
* @param targetId 电子围栏目标主键
|
||||
* @return 电子围栏目标
|
||||
*/
|
||||
@Override
|
||||
public HwFenceTarget selectHwFenceTargetByTargetId(Long targetId)
|
||||
{
|
||||
return hwFenceTargetMapper.selectHwFenceTargetByTargetId(targetId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询电子围栏目标列表
|
||||
*
|
||||
* @param hwFenceTarget 电子围栏目标
|
||||
* @return 电子围栏目标
|
||||
*/
|
||||
@Override
|
||||
public List<HwFenceTarget> selectHwFenceTargetList(HwFenceTarget hwFenceTarget)
|
||||
{
|
||||
return hwFenceTargetMapper.selectHwFenceTargetList(hwFenceTarget);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增电子围栏目标
|
||||
*
|
||||
* @param hwFenceTarget 电子围栏目标
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertHwFenceTarget(HwFenceTarget hwFenceTarget)
|
||||
{
|
||||
return hwFenceTargetMapper.insertHwFenceTarget(hwFenceTarget);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改电子围栏目标
|
||||
*
|
||||
* @param hwFenceTarget 电子围栏目标
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateHwFenceTarget(HwFenceTarget hwFenceTarget)
|
||||
{
|
||||
return hwFenceTargetMapper.updateHwFenceTarget(hwFenceTarget);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除电子围栏目标
|
||||
*
|
||||
* @param targetIds 需要删除的电子围栏目标主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteHwFenceTargetByTargetIds(Long[] targetIds)
|
||||
{
|
||||
return hwFenceTargetMapper.deleteHwFenceTargetByTargetIds(targetIds);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除电子围栏目标信息
|
||||
*
|
||||
* @param targetId 电子围栏目标主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteHwFenceTargetByTargetId(Long targetId)
|
||||
{
|
||||
return hwFenceTargetMapper.deleteHwFenceTargetByTargetId(targetId);
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,96 @@
|
||||
package com.ruoyi.business.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.common.core.utils.DateUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.ruoyi.business.mapper.HwMonitorUnitMapper;
|
||||
import com.ruoyi.business.domain.HwMonitorUnit;
|
||||
import com.ruoyi.business.service.IHwMonitorUnitService;
|
||||
|
||||
/**
|
||||
* 监控单元Service业务层处理
|
||||
*
|
||||
* @author YINQ
|
||||
* @date 2023-08-31
|
||||
*/
|
||||
@Service
|
||||
public class HwMonitorUnitServiceImpl implements IHwMonitorUnitService
|
||||
{
|
||||
@Autowired
|
||||
private HwMonitorUnitMapper hwMonitorUnitMapper;
|
||||
|
||||
/**
|
||||
* 查询监控单元
|
||||
*
|
||||
* @param monitorUnitId 监控单元主键
|
||||
* @return 监控单元
|
||||
*/
|
||||
@Override
|
||||
public HwMonitorUnit selectHwMonitorUnitByMonitorUnitId(Long monitorUnitId)
|
||||
{
|
||||
return hwMonitorUnitMapper.selectHwMonitorUnitByMonitorUnitId(monitorUnitId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询监控单元列表
|
||||
*
|
||||
* @param hwMonitorUnit 监控单元
|
||||
* @return 监控单元
|
||||
*/
|
||||
@Override
|
||||
public List<HwMonitorUnit> selectHwMonitorUnitList(HwMonitorUnit hwMonitorUnit)
|
||||
{
|
||||
return hwMonitorUnitMapper.selectHwMonitorUnitList(hwMonitorUnit);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增监控单元
|
||||
*
|
||||
* @param hwMonitorUnit 监控单元
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertHwMonitorUnit(HwMonitorUnit hwMonitorUnit)
|
||||
{
|
||||
hwMonitorUnit.setCreateTime(DateUtils.getNowDate());
|
||||
return hwMonitorUnitMapper.insertHwMonitorUnit(hwMonitorUnit);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改监控单元
|
||||
*
|
||||
* @param hwMonitorUnit 监控单元
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateHwMonitorUnit(HwMonitorUnit hwMonitorUnit)
|
||||
{
|
||||
hwMonitorUnit.setUpdateTime(DateUtils.getNowDate());
|
||||
return hwMonitorUnitMapper.updateHwMonitorUnit(hwMonitorUnit);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除监控单元
|
||||
*
|
||||
* @param monitorUnitIds 需要删除的监控单元主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteHwMonitorUnitByMonitorUnitIds(Long[] monitorUnitIds)
|
||||
{
|
||||
return hwMonitorUnitMapper.deleteHwMonitorUnitByMonitorUnitIds(monitorUnitIds);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除监控单元信息
|
||||
*
|
||||
* @param monitorUnitId 监控单元主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteHwMonitorUnitByMonitorUnitId(Long monitorUnitId)
|
||||
{
|
||||
return hwMonitorUnitMapper.deleteHwMonitorUnitByMonitorUnitId(monitorUnitId);
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,96 @@
|
||||
package com.ruoyi.business.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.common.core.utils.DateUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.ruoyi.business.mapper.HwMonitorUnitTypeMapper;
|
||||
import com.ruoyi.business.domain.HwMonitorUnitType;
|
||||
import com.ruoyi.business.service.IHwMonitorUnitTypeService;
|
||||
|
||||
/**
|
||||
* 监控单元类型Service业务层处理
|
||||
*
|
||||
* @author YINQ
|
||||
* @date 2023-08-31
|
||||
*/
|
||||
@Service
|
||||
public class HwMonitorUnitTypeServiceImpl implements IHwMonitorUnitTypeService
|
||||
{
|
||||
@Autowired
|
||||
private HwMonitorUnitTypeMapper hwMonitorUnitTypeMapper;
|
||||
|
||||
/**
|
||||
* 查询监控单元类型
|
||||
*
|
||||
* @param monitorUnitTypeId 监控单元类型主键
|
||||
* @return 监控单元类型
|
||||
*/
|
||||
@Override
|
||||
public HwMonitorUnitType selectHwMonitorUnitTypeByMonitorUnitTypeId(Long monitorUnitTypeId)
|
||||
{
|
||||
return hwMonitorUnitTypeMapper.selectHwMonitorUnitTypeByMonitorUnitTypeId(monitorUnitTypeId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询监控单元类型列表
|
||||
*
|
||||
* @param hwMonitorUnitType 监控单元类型
|
||||
* @return 监控单元类型
|
||||
*/
|
||||
@Override
|
||||
public List<HwMonitorUnitType> selectHwMonitorUnitTypeList(HwMonitorUnitType hwMonitorUnitType)
|
||||
{
|
||||
return hwMonitorUnitTypeMapper.selectHwMonitorUnitTypeList(hwMonitorUnitType);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增监控单元类型
|
||||
*
|
||||
* @param hwMonitorUnitType 监控单元类型
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertHwMonitorUnitType(HwMonitorUnitType hwMonitorUnitType)
|
||||
{
|
||||
hwMonitorUnitType.setCreateTime(DateUtils.getNowDate());
|
||||
return hwMonitorUnitTypeMapper.insertHwMonitorUnitType(hwMonitorUnitType);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改监控单元类型
|
||||
*
|
||||
* @param hwMonitorUnitType 监控单元类型
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateHwMonitorUnitType(HwMonitorUnitType hwMonitorUnitType)
|
||||
{
|
||||
hwMonitorUnitType.setUpdateTime(DateUtils.getNowDate());
|
||||
return hwMonitorUnitTypeMapper.updateHwMonitorUnitType(hwMonitorUnitType);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除监控单元类型
|
||||
*
|
||||
* @param monitorUnitTypeIds 需要删除的监控单元类型主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteHwMonitorUnitTypeByMonitorUnitTypeIds(Long[] monitorUnitTypeIds)
|
||||
{
|
||||
return hwMonitorUnitTypeMapper.deleteHwMonitorUnitTypeByMonitorUnitTypeIds(monitorUnitTypeIds);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除监控单元类型信息
|
||||
*
|
||||
* @param monitorUnitTypeId 监控单元类型主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteHwMonitorUnitTypeByMonitorUnitTypeId(Long monitorUnitTypeId)
|
||||
{
|
||||
return hwMonitorUnitTypeMapper.deleteHwMonitorUnitTypeByMonitorUnitTypeId(monitorUnitTypeId);
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,96 @@
|
||||
package com.ruoyi.business.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.common.core.utils.DateUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.ruoyi.business.mapper.HwSceneModeMapper;
|
||||
import com.ruoyi.business.domain.HwSceneMode;
|
||||
import com.ruoyi.business.service.IHwSceneModeService;
|
||||
|
||||
/**
|
||||
* 场景类型Service业务层处理
|
||||
*
|
||||
* @author YINQ
|
||||
* @date 2023-08-31
|
||||
*/
|
||||
@Service
|
||||
public class HwSceneModeServiceImpl implements IHwSceneModeService
|
||||
{
|
||||
@Autowired
|
||||
private HwSceneModeMapper hwSceneModeMapper;
|
||||
|
||||
/**
|
||||
* 查询场景类型
|
||||
*
|
||||
* @param sceneModeId 场景类型主键
|
||||
* @return 场景类型
|
||||
*/
|
||||
@Override
|
||||
public HwSceneMode selectHwSceneModeBySceneModeId(Long sceneModeId)
|
||||
{
|
||||
return hwSceneModeMapper.selectHwSceneModeBySceneModeId(sceneModeId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询场景类型列表
|
||||
*
|
||||
* @param hwSceneMode 场景类型
|
||||
* @return 场景类型
|
||||
*/
|
||||
@Override
|
||||
public List<HwSceneMode> selectHwSceneModeList(HwSceneMode hwSceneMode)
|
||||
{
|
||||
return hwSceneModeMapper.selectHwSceneModeList(hwSceneMode);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增场景类型
|
||||
*
|
||||
* @param hwSceneMode 场景类型
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertHwSceneMode(HwSceneMode hwSceneMode)
|
||||
{
|
||||
hwSceneMode.setCreateTime(DateUtils.getNowDate());
|
||||
return hwSceneModeMapper.insertHwSceneMode(hwSceneMode);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改场景类型
|
||||
*
|
||||
* @param hwSceneMode 场景类型
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateHwSceneMode(HwSceneMode hwSceneMode)
|
||||
{
|
||||
hwSceneMode.setUpdateTime(DateUtils.getNowDate());
|
||||
return hwSceneModeMapper.updateHwSceneMode(hwSceneMode);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除场景类型
|
||||
*
|
||||
* @param sceneModeIds 需要删除的场景类型主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteHwSceneModeBySceneModeIds(Long[] sceneModeIds)
|
||||
{
|
||||
return hwSceneModeMapper.deleteHwSceneModeBySceneModeIds(sceneModeIds);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除场景类型信息
|
||||
*
|
||||
* @param sceneModeId 场景类型主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteHwSceneModeBySceneModeId(Long sceneModeId)
|
||||
{
|
||||
return hwSceneModeMapper.deleteHwSceneModeBySceneModeId(sceneModeId);
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,96 @@
|
||||
package com.ruoyi.business.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.common.core.utils.DateUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.ruoyi.business.mapper.HwTenantMapper;
|
||||
import com.ruoyi.business.domain.HwTenant;
|
||||
import com.ruoyi.business.service.IHwTenantService;
|
||||
|
||||
/**
|
||||
* 租户信息Service业务层处理
|
||||
*
|
||||
* @author xins
|
||||
* @date 2023-09-04
|
||||
*/
|
||||
@Service
|
||||
public class HwTenantServiceImpl implements IHwTenantService
|
||||
{
|
||||
@Autowired
|
||||
private HwTenantMapper hwTenantMapper;
|
||||
|
||||
/**
|
||||
* 查询租户信息
|
||||
*
|
||||
* @param tenantId 租户信息主键
|
||||
* @return 租户信息
|
||||
*/
|
||||
@Override
|
||||
public HwTenant selectHwTenantByTenantId(Long tenantId)
|
||||
{
|
||||
return hwTenantMapper.selectHwTenantByTenantId(tenantId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询租户信息列表
|
||||
*
|
||||
* @param hwTenant 租户信息
|
||||
* @return 租户信息
|
||||
*/
|
||||
@Override
|
||||
public List<HwTenant> selectHwTenantList(HwTenant hwTenant)
|
||||
{
|
||||
return hwTenantMapper.selectHwTenantList(hwTenant);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增租户信息
|
||||
*
|
||||
* @param hwTenant 租户信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertHwTenant(HwTenant hwTenant)
|
||||
{
|
||||
hwTenant.setCreateTime(DateUtils.getNowDate());
|
||||
return hwTenantMapper.insertHwTenant(hwTenant);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改租户信息
|
||||
*
|
||||
* @param hwTenant 租户信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateHwTenant(HwTenant hwTenant)
|
||||
{
|
||||
hwTenant.setUpdateTime(DateUtils.getNowDate());
|
||||
return hwTenantMapper.updateHwTenant(hwTenant);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除租户信息
|
||||
*
|
||||
* @param tenantIds 需要删除的租户信息主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteHwTenantByTenantIds(Long[] tenantIds)
|
||||
{
|
||||
return hwTenantMapper.deleteHwTenantByTenantIds(tenantIds);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除租户信息信息
|
||||
*
|
||||
* @param tenantId 租户信息主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteHwTenantByTenantId(Long tenantId)
|
||||
{
|
||||
return hwTenantMapper.deleteHwTenantByTenantId(tenantId);
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,150 @@
|
||||
<?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.ruoyi.business.mapper.HwDeviceModeFunctionMapper">
|
||||
|
||||
<resultMap type="HwDeviceModeFunction" id="HwDeviceModeFunctionResult">
|
||||
<result property="modeFunctionId" column="mode_function_id" />
|
||||
<result property="deviceModeId" column="device_mode_id" />
|
||||
<result property="functionMode" column="function_mode" />
|
||||
<result property="coordinate" column="coordinate" />
|
||||
<result property="functionName" column="function_name" />
|
||||
<result property="functionIdentifier" column="function_identifier" />
|
||||
<result property="functionType" column="function_type" />
|
||||
<result property="dataType" column="data_type" />
|
||||
<result property="dataDefinition" column="data_definition" />
|
||||
<result property="functionFormula" column="function_formula" />
|
||||
<result property="propertyUnit" column="property_unit" />
|
||||
<result property="displayFlag" column="display_flag" />
|
||||
<result property="rwFlag" column="rw_flag" />
|
||||
<result property="invokeMethod" column="invoke_method" />
|
||||
<result property="eventType" column="event_type" />
|
||||
<result property="remark" column="remark" />
|
||||
<result property="acquisitionFormula" column="acquisition_formula" />
|
||||
<result property="orderFlag" column="order_flag" />
|
||||
<result property="deviceRegister" column="device_register" />
|
||||
<result property="propertyStep" column="property_step" />
|
||||
<result property="propertyField" column="property_field" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectHwDeviceModeFunctionVo">
|
||||
select mode_function_id, device_mode_id, function_mode, coordinate, function_name, function_identifier, function_type, data_type, data_definition, function_formula, property_unit, display_flag, rw_flag, invoke_method, event_type, remark, acquisition_formula, order_flag, device_register, property_step, property_field from hw_device_mode_function
|
||||
</sql>
|
||||
|
||||
<select id="selectHwDeviceModeFunctionList" parameterType="HwDeviceModeFunction" resultMap="HwDeviceModeFunctionResult">
|
||||
<include refid="selectHwDeviceModeFunctionVo"/>
|
||||
<where>
|
||||
<if test="deviceModeId != null "> and device_mode_id = #{deviceModeId}</if>
|
||||
<if test="functionMode != null and functionMode != ''"> and function_mode = #{functionMode}</if>
|
||||
<if test="coordinate != null and coordinate != ''"> and coordinate = #{coordinate}</if>
|
||||
<if test="functionName != null and functionName != ''"> and function_name like concat('%', #{functionName}, '%')</if>
|
||||
<if test="functionIdentifier != null and functionIdentifier != ''"> and function_identifier = #{functionIdentifier}</if>
|
||||
<if test="functionType != null and functionType != ''"> and function_type = #{functionType}</if>
|
||||
<if test="dataType != null "> and data_type = #{dataType}</if>
|
||||
<if test="dataDefinition != null and dataDefinition != ''"> and data_definition = #{dataDefinition}</if>
|
||||
<if test="functionFormula != null and functionFormula != ''"> and function_formula = #{functionFormula}</if>
|
||||
<if test="propertyUnit != null and propertyUnit != ''"> and property_unit = #{propertyUnit}</if>
|
||||
<if test="displayFlag != null and displayFlag != ''"> and display_flag = #{displayFlag}</if>
|
||||
<if test="rwFlag != null and rwFlag != ''"> and rw_flag = #{rwFlag}</if>
|
||||
<if test="invokeMethod != null and invokeMethod != ''"> and invoke_method = #{invokeMethod}</if>
|
||||
<if test="eventType != null and eventType != ''"> and event_type = #{eventType}</if>
|
||||
<if test="acquisitionFormula != null and acquisitionFormula != ''"> and acquisition_formula = #{acquisitionFormula}</if>
|
||||
<if test="orderFlag != null "> and order_flag = #{orderFlag}</if>
|
||||
<if test="deviceRegister != null and deviceRegister != ''"> and device_register = #{deviceRegister}</if>
|
||||
<if test="propertyStep != null "> and property_step = #{propertyStep}</if>
|
||||
<if test="propertyField != null and propertyField != ''"> and property_field = #{propertyField}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectHwDeviceModeFunctionByModeFunctionId" parameterType="Long" resultMap="HwDeviceModeFunctionResult">
|
||||
<include refid="selectHwDeviceModeFunctionVo"/>
|
||||
where mode_function_id = #{modeFunctionId}
|
||||
</select>
|
||||
|
||||
<insert id="insertHwDeviceModeFunction" parameterType="HwDeviceModeFunction" useGeneratedKeys="true" keyProperty="modeFunctionId">
|
||||
insert into hw_device_mode_function
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="deviceModeId != null">device_mode_id,</if>
|
||||
<if test="functionMode != null and functionMode != ''">function_mode,</if>
|
||||
<if test="coordinate != null">coordinate,</if>
|
||||
<if test="functionName != null and functionName != ''">function_name,</if>
|
||||
<if test="functionIdentifier != null and functionIdentifier != ''">function_identifier,</if>
|
||||
<if test="functionType != null">function_type,</if>
|
||||
<if test="dataType != null">data_type,</if>
|
||||
<if test="dataDefinition != null">data_definition,</if>
|
||||
<if test="functionFormula != null">function_formula,</if>
|
||||
<if test="propertyUnit != null">property_unit,</if>
|
||||
<if test="displayFlag != null">display_flag,</if>
|
||||
<if test="rwFlag != null">rw_flag,</if>
|
||||
<if test="invokeMethod != null">invoke_method,</if>
|
||||
<if test="eventType != null">event_type,</if>
|
||||
<if test="remark != null">remark,</if>
|
||||
<if test="acquisitionFormula != null">acquisition_formula,</if>
|
||||
<if test="orderFlag != null">order_flag,</if>
|
||||
<if test="deviceRegister != null">device_register,</if>
|
||||
<if test="propertyStep != null">property_step,</if>
|
||||
<if test="propertyField != null">property_field,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="deviceModeId != null">#{deviceModeId},</if>
|
||||
<if test="functionMode != null and functionMode != ''">#{functionMode},</if>
|
||||
<if test="coordinate != null">#{coordinate},</if>
|
||||
<if test="functionName != null and functionName != ''">#{functionName},</if>
|
||||
<if test="functionIdentifier != null and functionIdentifier != ''">#{functionIdentifier},</if>
|
||||
<if test="functionType != null">#{functionType},</if>
|
||||
<if test="dataType != null">#{dataType},</if>
|
||||
<if test="dataDefinition != null">#{dataDefinition},</if>
|
||||
<if test="functionFormula != null">#{functionFormula},</if>
|
||||
<if test="propertyUnit != null">#{propertyUnit},</if>
|
||||
<if test="displayFlag != null">#{displayFlag},</if>
|
||||
<if test="rwFlag != null">#{rwFlag},</if>
|
||||
<if test="invokeMethod != null">#{invokeMethod},</if>
|
||||
<if test="eventType != null">#{eventType},</if>
|
||||
<if test="remark != null">#{remark},</if>
|
||||
<if test="acquisitionFormula != null">#{acquisitionFormula},</if>
|
||||
<if test="orderFlag != null">#{orderFlag},</if>
|
||||
<if test="deviceRegister != null">#{deviceRegister},</if>
|
||||
<if test="propertyStep != null">#{propertyStep},</if>
|
||||
<if test="propertyField != null">#{propertyField},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateHwDeviceModeFunction" parameterType="HwDeviceModeFunction">
|
||||
update hw_device_mode_function
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="deviceModeId != null">device_mode_id = #{deviceModeId},</if>
|
||||
<if test="functionMode != null and functionMode != ''">function_mode = #{functionMode},</if>
|
||||
<if test="coordinate != null">coordinate = #{coordinate},</if>
|
||||
<if test="functionName != null and functionName != ''">function_name = #{functionName},</if>
|
||||
<if test="functionIdentifier != null and functionIdentifier != ''">function_identifier = #{functionIdentifier},</if>
|
||||
<if test="functionType != null">function_type = #{functionType},</if>
|
||||
<if test="dataType != null">data_type = #{dataType},</if>
|
||||
<if test="dataDefinition != null">data_definition = #{dataDefinition},</if>
|
||||
<if test="functionFormula != null">function_formula = #{functionFormula},</if>
|
||||
<if test="propertyUnit != null">property_unit = #{propertyUnit},</if>
|
||||
<if test="displayFlag != null">display_flag = #{displayFlag},</if>
|
||||
<if test="rwFlag != null">rw_flag = #{rwFlag},</if>
|
||||
<if test="invokeMethod != null">invoke_method = #{invokeMethod},</if>
|
||||
<if test="eventType != null">event_type = #{eventType},</if>
|
||||
<if test="remark != null">remark = #{remark},</if>
|
||||
<if test="acquisitionFormula != null">acquisition_formula = #{acquisitionFormula},</if>
|
||||
<if test="orderFlag != null">order_flag = #{orderFlag},</if>
|
||||
<if test="deviceRegister != null">device_register = #{deviceRegister},</if>
|
||||
<if test="propertyStep != null">property_step = #{propertyStep},</if>
|
||||
<if test="propertyField != null">property_field = #{propertyField},</if>
|
||||
</trim>
|
||||
where mode_function_id = #{modeFunctionId}
|
||||
</update>
|
||||
|
||||
<delete id="deleteHwDeviceModeFunctionByModeFunctionId" parameterType="Long">
|
||||
delete from hw_device_mode_function where mode_function_id = #{modeFunctionId}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteHwDeviceModeFunctionByModeFunctionIds" parameterType="String">
|
||||
delete from hw_device_mode_function where mode_function_id in
|
||||
<foreach item="modeFunctionId" collection="array" open="(" separator="," close=")">
|
||||
#{modeFunctionId}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
||||
@ -0,0 +1,175 @@
|
||||
<?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.ruoyi.business.mapper.HwDeviceModeMapper">
|
||||
|
||||
<resultMap type="HwDeviceMode" id="HwDeviceModeResult">
|
||||
<result property="deviceModeId" column="device_mode_id" />
|
||||
<result property="deviceModeName" column="device_mode_name" />
|
||||
<result property="tenantId" column="tenant_id" />
|
||||
<result property="sceneId" column="scene_id" />
|
||||
<result property="languageCode" column="language_code" />
|
||||
<result property="gpsFlag" column="gps_flag" />
|
||||
<result property="deviceModeStatus" column="device_mode_status" />
|
||||
<result property="commonFlag" column="common_flag" />
|
||||
<result property="modeClassfication" column="mode_classfication" />
|
||||
<result property="deviceModePic" column="device_mode_pic" />
|
||||
<result property="dataVerifyLevel" column="data_verify_level" />
|
||||
<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="deviceModeField" column="device_mode_field" />
|
||||
</resultMap>
|
||||
|
||||
<resultMap id="HwDeviceModeHwDeviceModeFunctionResult" type="HwDeviceMode" extends="HwDeviceModeResult">
|
||||
<collection property="hwDeviceModeFunctionList" notNullColumn="sub_mode_function_id" javaType="java.util.List" resultMap="HwDeviceModeFunctionResult" />
|
||||
</resultMap>
|
||||
|
||||
<resultMap type="HwDeviceModeFunction" id="HwDeviceModeFunctionResult">
|
||||
<result property="modeFunctionId" column="sub_mode_function_id" />
|
||||
<result property="deviceModeId" column="sub_device_mode_id" />
|
||||
<result property="functionMode" column="sub_function_mode" />
|
||||
<result property="coordinate" column="sub_coordinate" />
|
||||
<result property="functionName" column="sub_function_name" />
|
||||
<result property="functionIdentifier" column="sub_function_identifier" />
|
||||
<result property="functionType" column="sub_function_type" />
|
||||
<result property="dataType" column="sub_data_type" />
|
||||
<result property="dataDefinition" column="sub_data_definition" />
|
||||
<result property="functionFormula" column="sub_function_formula" />
|
||||
<result property="propertyUnit" column="sub_property_unit" />
|
||||
<result property="displayFlag" column="sub_display_flag" />
|
||||
<result property="rwFlag" column="sub_rw_flag" />
|
||||
<result property="invokeMethod" column="sub_invoke_method" />
|
||||
<result property="eventType" column="sub_event_type" />
|
||||
<result property="remark" column="sub_remark" />
|
||||
<result property="acquisitionFormula" column="sub_acquisition_formula" />
|
||||
<result property="orderFlag" column="sub_order_flag" />
|
||||
<result property="deviceRegister" column="sub_device_register" />
|
||||
<result property="propertyStep" column="sub_property_step" />
|
||||
<result property="propertyField" column="sub_property_field" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectHwDeviceModeVo">
|
||||
select device_mode_id, device_mode_name, tenant_id, scene_id, language_code, gps_flag, device_mode_status, common_flag, mode_classfication, device_mode_pic, data_verify_level, remark, create_by, create_time, update_by, update_time, device_mode_field from hw_device_mode
|
||||
</sql>
|
||||
|
||||
<select id="selectHwDeviceModeList" parameterType="HwDeviceMode" resultMap="HwDeviceModeResult">
|
||||
<include refid="selectHwDeviceModeVo"/>
|
||||
<where>
|
||||
<if test="deviceModeName != null and deviceModeName != ''"> and device_mode_name like concat('%', #{deviceModeName}, '%')</if>
|
||||
<if test="tenantId != null "> and tenant_id = #{tenantId}</if>
|
||||
<if test="sceneId != null "> and scene_id = #{sceneId}</if>
|
||||
<if test="languageCode != null and languageCode != ''"> and language_code = #{languageCode}</if>
|
||||
<if test="gpsFlag != null and gpsFlag != ''"> and gps_flag = #{gpsFlag}</if>
|
||||
<if test="deviceModeStatus != null and deviceModeStatus != ''"> and device_mode_status = #{deviceModeStatus}</if>
|
||||
<if test="commonFlag != null and commonFlag != ''"> and common_flag = #{commonFlag}</if>
|
||||
<if test="modeClassfication != null "> and mode_classfication = #{modeClassfication}</if>
|
||||
<if test="deviceModePic != null and deviceModePic != ''"> and device_mode_pic = #{deviceModePic}</if>
|
||||
<if test="dataVerifyLevel != null and dataVerifyLevel != ''"> and data_verify_level = #{dataVerifyLevel}</if>
|
||||
<if test="deviceModeField != null and deviceModeField != ''"> and device_mode_field = #{deviceModeField}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectHwDeviceModeByDeviceModeId" parameterType="Long" resultMap="HwDeviceModeHwDeviceModeFunctionResult">
|
||||
select a.device_mode_id, a.device_mode_name, a.tenant_id, a.scene_id, a.language_code, a.gps_flag, a.device_mode_status, a.common_flag, a.mode_classfication, a.device_mode_pic, a.data_verify_level, a.remark, a.create_by, a.create_time, a.update_by, a.update_time, a.device_mode_field,
|
||||
b.mode_function_id as sub_mode_function_id, b.device_mode_id as sub_device_mode_id, b.function_mode as sub_function_mode, b.coordinate as sub_coordinate, b.function_name as sub_function_name, b.function_identifier as sub_function_identifier, b.function_type as sub_function_type, b.data_type as sub_data_type, b.data_definition as sub_data_definition, b.function_formula as sub_function_formula, b.property_unit as sub_property_unit, b.display_flag as sub_display_flag, b.rw_flag as sub_rw_flag, b.invoke_method as sub_invoke_method, b.event_type as sub_event_type, b.remark as sub_remark, b.acquisition_formula as sub_acquisition_formula, b.order_flag as sub_order_flag, b.device_register as sub_device_register, b.property_step as sub_property_step, b.property_field as sub_property_field
|
||||
from hw_device_mode a
|
||||
left join hw_device_mode_function b on b.device_mode_id = a.device_mode_id
|
||||
where a.device_mode_id = #{deviceModeId}
|
||||
</select>
|
||||
|
||||
<insert id="insertHwDeviceMode" parameterType="HwDeviceMode" useGeneratedKeys="true" keyProperty="deviceModeId">
|
||||
insert into hw_device_mode
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="deviceModeName != null and deviceModeName != ''">device_mode_name,</if>
|
||||
<if test="tenantId != null">tenant_id,</if>
|
||||
<if test="sceneId != null">scene_id,</if>
|
||||
<if test="languageCode != null">language_code,</if>
|
||||
<if test="gpsFlag != null and gpsFlag != ''">gps_flag,</if>
|
||||
<if test="deviceModeStatus != null and deviceModeStatus != ''">device_mode_status,</if>
|
||||
<if test="commonFlag != null and commonFlag != ''">common_flag,</if>
|
||||
<if test="modeClassfication != null">mode_classfication,</if>
|
||||
<if test="deviceModePic != null">device_mode_pic,</if>
|
||||
<if test="dataVerifyLevel != null">data_verify_level,</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="deviceModeField != null">device_mode_field,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="deviceModeName != null and deviceModeName != ''">#{deviceModeName},</if>
|
||||
<if test="tenantId != null">#{tenantId},</if>
|
||||
<if test="sceneId != null">#{sceneId},</if>
|
||||
<if test="languageCode != null">#{languageCode},</if>
|
||||
<if test="gpsFlag != null and gpsFlag != ''">#{gpsFlag},</if>
|
||||
<if test="deviceModeStatus != null and deviceModeStatus != ''">#{deviceModeStatus},</if>
|
||||
<if test="commonFlag != null and commonFlag != ''">#{commonFlag},</if>
|
||||
<if test="modeClassfication != null">#{modeClassfication},</if>
|
||||
<if test="deviceModePic != null">#{deviceModePic},</if>
|
||||
<if test="dataVerifyLevel != null">#{dataVerifyLevel},</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="deviceModeField != null">#{deviceModeField},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateHwDeviceMode" parameterType="HwDeviceMode">
|
||||
update hw_device_mode
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="deviceModeName != null and deviceModeName != ''">device_mode_name = #{deviceModeName},</if>
|
||||
<if test="tenantId != null">tenant_id = #{tenantId},</if>
|
||||
<if test="sceneId != null">scene_id = #{sceneId},</if>
|
||||
<if test="languageCode != null">language_code = #{languageCode},</if>
|
||||
<if test="gpsFlag != null and gpsFlag != ''">gps_flag = #{gpsFlag},</if>
|
||||
<if test="deviceModeStatus != null and deviceModeStatus != ''">device_mode_status = #{deviceModeStatus},</if>
|
||||
<if test="commonFlag != null and commonFlag != ''">common_flag = #{commonFlag},</if>
|
||||
<if test="modeClassfication != null">mode_classfication = #{modeClassfication},</if>
|
||||
<if test="deviceModePic != null">device_mode_pic = #{deviceModePic},</if>
|
||||
<if test="dataVerifyLevel != null">data_verify_level = #{dataVerifyLevel},</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="deviceModeField != null">device_mode_field = #{deviceModeField},</if>
|
||||
</trim>
|
||||
where device_mode_id = #{deviceModeId}
|
||||
</update>
|
||||
|
||||
<delete id="deleteHwDeviceModeByDeviceModeId" parameterType="Long">
|
||||
delete from hw_device_mode where device_mode_id = #{deviceModeId}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteHwDeviceModeByDeviceModeIds" parameterType="String">
|
||||
delete from hw_device_mode where device_mode_id in
|
||||
<foreach item="deviceModeId" collection="array" open="(" separator="," close=")">
|
||||
#{deviceModeId}
|
||||
</foreach>
|
||||
</delete>
|
||||
|
||||
<delete id="deleteHwDeviceModeFunctionByDeviceModeIds" parameterType="String">
|
||||
delete from hw_device_mode_function where device_mode_id in
|
||||
<foreach item="deviceModeId" collection="array" open="(" separator="," close=")">
|
||||
#{deviceModeId}
|
||||
</foreach>
|
||||
</delete>
|
||||
|
||||
<delete id="deleteHwDeviceModeFunctionByDeviceModeId" parameterType="Long">
|
||||
delete from hw_device_mode_function where device_mode_id = #{deviceModeId}
|
||||
</delete>
|
||||
|
||||
<insert id="batchHwDeviceModeFunction">
|
||||
insert into hw_device_mode_function( mode_function_id, device_mode_id, function_mode, coordinate, function_name, function_identifier, function_type, data_type, data_definition, function_formula, property_unit, display_flag, rw_flag, invoke_method, event_type, remark, acquisition_formula, order_flag, device_register, property_step, property_field) values
|
||||
<foreach item="item" index="index" collection="list" separator=",">
|
||||
( #{item.modeFunctionId}, #{item.deviceModeId}, #{item.functionMode}, #{item.coordinate}, #{item.functionName}, #{item.functionIdentifier}, #{item.functionType}, #{item.dataType}, #{item.dataDefinition}, #{item.functionFormula}, #{item.propertyUnit}, #{item.displayFlag}, #{item.rwFlag}, #{item.invokeMethod}, #{item.eventType}, #{item.remark}, #{item.acquisitionFormula}, #{item.orderFlag}, #{item.deviceRegister}, #{item.propertyStep}, #{item.propertyField})
|
||||
</foreach>
|
||||
</insert>
|
||||
</mapper>
|
||||
@ -0,0 +1,136 @@
|
||||
<?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.ruoyi.business.mapper.HwElectronicFenceMapper">
|
||||
|
||||
<resultMap type="HwElectronicFence" id="HwElectronicFenceResult">
|
||||
<result property="electronicFenceId" column="electronic_fence_id" />
|
||||
<result property="electronicFenceName" column="electronic_fence_name" />
|
||||
<result property="sceneId" column="scene_id" />
|
||||
<result property="fenceType" column="fence_type" />
|
||||
<result property="effectiveTimeFlag" column="effective_time_flag" />
|
||||
<result property="timeZone" column="time_zone" />
|
||||
<result property="effectiveTime" column="effective_time" />
|
||||
<result property="triggerStatus" column="trigger_status" />
|
||||
<result property="areaShapeFlag" column="area_shape_flag" />
|
||||
<result property="areaRange" column="area_range" />
|
||||
<result property="fencePushFlag" column="fence_push_flag" />
|
||||
<result property="fencePushContent" column="fence_push_content" />
|
||||
<result property="fenceRecoverContent" column="fence_recover_content" />
|
||||
<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="fenceField" column="fence_field" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectHwElectronicFenceVo">
|
||||
select electronic_fence_id, electronic_fence_name, scene_id, fence_type, effective_time_flag, time_zone, effective_time, trigger_status, area_shape_flag, area_range, fence_push_flag, fence_push_content, fence_recover_content, remark, create_by, create_time, update_by, update_time, fence_field from hw_electronic_fence
|
||||
</sql>
|
||||
|
||||
<select id="selectHwElectronicFenceList" parameterType="HwElectronicFence" resultMap="HwElectronicFenceResult">
|
||||
<include refid="selectHwElectronicFenceVo"/>
|
||||
<where>
|
||||
<if test="electronicFenceName != null and electronicFenceName != ''"> and electronic_fence_name like concat('%', #{electronicFenceName}, '%')</if>
|
||||
<if test="sceneId != null "> and scene_id = #{sceneId}</if>
|
||||
<if test="fenceType != null and fenceType != ''"> and fence_type = #{fenceType}</if>
|
||||
<if test="effectiveTimeFlag != null and effectiveTimeFlag != ''"> and effective_time_flag = #{effectiveTimeFlag}</if>
|
||||
<if test="timeZone != null and timeZone != ''"> and time_zone = #{timeZone}</if>
|
||||
<if test="effectiveTime != null and effectiveTime != ''"> and effective_time = #{effectiveTime}</if>
|
||||
<if test="triggerStatus != null and triggerStatus != ''"> and trigger_status = #{triggerStatus}</if>
|
||||
<if test="areaShapeFlag != null and areaShapeFlag != ''"> and area_shape_flag = #{areaShapeFlag}</if>
|
||||
<if test="areaRange != null and areaRange != ''"> and area_range = #{areaRange}</if>
|
||||
<if test="fencePushFlag != null and fencePushFlag != ''"> and fence_push_flag = #{fencePushFlag}</if>
|
||||
<if test="fencePushContent != null and fencePushContent != ''"> and fence_push_content = #{fencePushContent}</if>
|
||||
<if test="fenceRecoverContent != null and fenceRecoverContent != ''"> and fence_recover_content = #{fenceRecoverContent}</if>
|
||||
<if test="fenceField != null and fenceField != ''"> and fence_field = #{fenceField}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectHwElectronicFenceByElectronicFenceId" parameterType="Long" resultMap="HwElectronicFenceResult">
|
||||
<include refid="selectHwElectronicFenceVo"/>
|
||||
where electronic_fence_id = #{electronicFenceId}
|
||||
</select>
|
||||
|
||||
<insert id="insertHwElectronicFence" parameterType="HwElectronicFence" useGeneratedKeys="true" keyProperty="electronicFenceId">
|
||||
insert into hw_electronic_fence
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="electronicFenceName != null and electronicFenceName != ''">electronic_fence_name,</if>
|
||||
<if test="sceneId != null">scene_id,</if>
|
||||
<if test="fenceType != null and fenceType != ''">fence_type,</if>
|
||||
<if test="effectiveTimeFlag != null and effectiveTimeFlag != ''">effective_time_flag,</if>
|
||||
<if test="timeZone != null">time_zone,</if>
|
||||
<if test="effectiveTime != null and effectiveTime != ''">effective_time,</if>
|
||||
<if test="triggerStatus != null and triggerStatus != ''">trigger_status,</if>
|
||||
<if test="areaShapeFlag != null and areaShapeFlag != ''">area_shape_flag,</if>
|
||||
<if test="areaRange != null">area_range,</if>
|
||||
<if test="fencePushFlag != null and fencePushFlag != ''">fence_push_flag,</if>
|
||||
<if test="fencePushContent != null">fence_push_content,</if>
|
||||
<if test="fenceRecoverContent != null">fence_recover_content,</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="fenceField != null">fence_field,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="electronicFenceName != null and electronicFenceName != ''">#{electronicFenceName},</if>
|
||||
<if test="sceneId != null">#{sceneId},</if>
|
||||
<if test="fenceType != null and fenceType != ''">#{fenceType},</if>
|
||||
<if test="effectiveTimeFlag != null and effectiveTimeFlag != ''">#{effectiveTimeFlag},</if>
|
||||
<if test="timeZone != null">#{timeZone},</if>
|
||||
<if test="effectiveTime != null and effectiveTime != ''">#{effectiveTime},</if>
|
||||
<if test="triggerStatus != null and triggerStatus != ''">#{triggerStatus},</if>
|
||||
<if test="areaShapeFlag != null and areaShapeFlag != ''">#{areaShapeFlag},</if>
|
||||
<if test="areaRange != null">#{areaRange},</if>
|
||||
<if test="fencePushFlag != null and fencePushFlag != ''">#{fencePushFlag},</if>
|
||||
<if test="fencePushContent != null">#{fencePushContent},</if>
|
||||
<if test="fenceRecoverContent != null">#{fenceRecoverContent},</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="fenceField != null">#{fenceField},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateHwElectronicFence" parameterType="HwElectronicFence">
|
||||
update hw_electronic_fence
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="electronicFenceName != null and electronicFenceName != ''">electronic_fence_name = #{electronicFenceName},</if>
|
||||
<if test="sceneId != null">scene_id = #{sceneId},</if>
|
||||
<if test="fenceType != null and fenceType != ''">fence_type = #{fenceType},</if>
|
||||
<if test="effectiveTimeFlag != null and effectiveTimeFlag != ''">effective_time_flag = #{effectiveTimeFlag},</if>
|
||||
<if test="timeZone != null">time_zone = #{timeZone},</if>
|
||||
<if test="effectiveTime != null and effectiveTime != ''">effective_time = #{effectiveTime},</if>
|
||||
<if test="triggerStatus != null and triggerStatus != ''">trigger_status = #{triggerStatus},</if>
|
||||
<if test="areaShapeFlag != null and areaShapeFlag != ''">area_shape_flag = #{areaShapeFlag},</if>
|
||||
<if test="areaRange != null">area_range = #{areaRange},</if>
|
||||
<if test="fencePushFlag != null and fencePushFlag != ''">fence_push_flag = #{fencePushFlag},</if>
|
||||
<if test="fencePushContent != null">fence_push_content = #{fencePushContent},</if>
|
||||
<if test="fenceRecoverContent != null">fence_recover_content = #{fenceRecoverContent},</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="fenceField != null">fence_field = #{fenceField},</if>
|
||||
</trim>
|
||||
where electronic_fence_id = #{electronicFenceId}
|
||||
</update>
|
||||
|
||||
<delete id="deleteHwElectronicFenceByElectronicFenceId" parameterType="Long">
|
||||
delete from hw_electronic_fence where electronic_fence_id = #{electronicFenceId}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteHwElectronicFenceByElectronicFenceIds" parameterType="String">
|
||||
delete from hw_electronic_fence where electronic_fence_id in
|
||||
<foreach item="electronicFenceId" collection="array" open="(" separator="," close=")">
|
||||
#{electronicFenceId}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
||||
@ -0,0 +1,63 @@
|
||||
<?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.ruoyi.business.mapper.HwFenceTargetMapper">
|
||||
|
||||
<resultMap type="HwFenceTarget" id="HwFenceTargetResult">
|
||||
<result property="electronicFenceId" column="electronic_fence_id" />
|
||||
<result property="targetType" column="target_type" />
|
||||
<result property="targetId" column="target_id" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectHwFenceTargetVo">
|
||||
select electronic_fence_id, target_type, target_id from hw_fence_target
|
||||
</sql>
|
||||
|
||||
<select id="selectHwFenceTargetList" parameterType="HwFenceTarget" resultMap="HwFenceTargetResult">
|
||||
<include refid="selectHwFenceTargetVo"/>
|
||||
<where>
|
||||
<if test="electronicFenceId != null "> and electronic_fence_id = #{electronicFenceId}</if>
|
||||
<if test="targetType != null and targetType != ''"> and target_type = #{targetType}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectHwFenceTargetByTargetId" parameterType="Long" resultMap="HwFenceTargetResult">
|
||||
<include refid="selectHwFenceTargetVo"/>
|
||||
where target_id = #{targetId}
|
||||
</select>
|
||||
|
||||
<insert id="insertHwFenceTarget" parameterType="HwFenceTarget">
|
||||
insert into hw_fence_target
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="electronicFenceId != null">electronic_fence_id,</if>
|
||||
<if test="targetType != null and targetType != ''">target_type,</if>
|
||||
<if test="targetId != null">target_id,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="electronicFenceId != null">#{electronicFenceId},</if>
|
||||
<if test="targetType != null and targetType != ''">#{targetType},</if>
|
||||
<if test="targetId != null">#{targetId},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateHwFenceTarget" parameterType="HwFenceTarget">
|
||||
update hw_fence_target
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="electronicFenceId != null">electronic_fence_id = #{electronicFenceId},</if>
|
||||
<if test="targetType != null and targetType != ''">target_type = #{targetType},</if>
|
||||
</trim>
|
||||
where target_id = #{targetId}
|
||||
</update>
|
||||
|
||||
<delete id="deleteHwFenceTargetByTargetId" parameterType="Long">
|
||||
delete from hw_fence_target where target_id = #{targetId}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteHwFenceTargetByTargetIds" parameterType="String">
|
||||
delete from hw_fence_target where target_id in
|
||||
<foreach item="targetId" collection="array" open="(" separator="," close=")">
|
||||
#{targetId}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
||||
@ -0,0 +1,121 @@
|
||||
<?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.ruoyi.business.mapper.HwMonitorUnitMapper">
|
||||
|
||||
<resultMap type="HwMonitorUnit" id="HwMonitorUnitResult">
|
||||
<result property="monitorUnitId" column="monitor_unit_id" />
|
||||
<result property="monitorUnitName" column="monitor_unit_name" />
|
||||
<result property="sceneId" column="scene_id" />
|
||||
<result property="parentId" column="parent_id" />
|
||||
<result property="monitorUnitTypeId" column="monitor_unit_type_id" />
|
||||
<result property="areaId" column="area_id" />
|
||||
<result property="monitorAddress" column="monitor_address" />
|
||||
<result property="monitorPic" column="monitor_pic" />
|
||||
<result property="preserveTime" column="preserve_time" />
|
||||
<result property="remark" column="remark" />
|
||||
<result property="monitorUnitStatus" column="monitor_unit_status" />
|
||||
<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="monitorUnitField" column="monitor_unit_field" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectHwMonitorUnitVo">
|
||||
select monitor_unit_id, monitor_unit_name, scene_id, parent_id, monitor_unit_type_id, area_id, monitor_address, monitor_pic, preserve_time, remark, monitor_unit_status, create_by, create_time, update_by, update_time, monitor_unit_field from hw_monitor_unit
|
||||
</sql>
|
||||
|
||||
<select id="selectHwMonitorUnitList" parameterType="HwMonitorUnit" resultMap="HwMonitorUnitResult">
|
||||
<include refid="selectHwMonitorUnitVo"/>
|
||||
<where>
|
||||
<if test="monitorUnitName != null and monitorUnitName != ''"> and monitor_unit_name like concat('%', #{monitorUnitName}, '%')</if>
|
||||
<if test="sceneId != null "> and scene_id = #{sceneId}</if>
|
||||
<if test="parentId != null "> and parent_id = #{parentId}</if>
|
||||
<if test="monitorUnitTypeId != null "> and monitor_unit_type_id = #{monitorUnitTypeId}</if>
|
||||
<if test="areaId != null "> and area_id = #{areaId}</if>
|
||||
<if test="monitorAddress != null and monitorAddress != ''"> and monitor_address = #{monitorAddress}</if>
|
||||
<if test="monitorPic != null and monitorPic != ''"> and monitor_pic = #{monitorPic}</if>
|
||||
<if test="preserveTime != null "> and preserve_time = #{preserveTime}</if>
|
||||
<if test="monitorUnitStatus != null "> and monitor_unit_status = #{monitorUnitStatus}</if>
|
||||
<if test="monitorUnitField != null and monitorUnitField != ''"> and monitor_unit_field = #{monitorUnitField}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectHwMonitorUnitByMonitorUnitId" parameterType="Long" resultMap="HwMonitorUnitResult">
|
||||
<include refid="selectHwMonitorUnitVo"/>
|
||||
where monitor_unit_id = #{monitorUnitId}
|
||||
</select>
|
||||
|
||||
<insert id="insertHwMonitorUnit" parameterType="HwMonitorUnit" useGeneratedKeys="true" keyProperty="monitorUnitId">
|
||||
insert into hw_monitor_unit
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="monitorUnitName != null and monitorUnitName != ''">monitor_unit_name,</if>
|
||||
<if test="sceneId != null">scene_id,</if>
|
||||
<if test="parentId != null">parent_id,</if>
|
||||
<if test="monitorUnitTypeId != null">monitor_unit_type_id,</if>
|
||||
<if test="areaId != null">area_id,</if>
|
||||
<if test="monitorAddress != null">monitor_address,</if>
|
||||
<if test="monitorPic != null">monitor_pic,</if>
|
||||
<if test="preserveTime != null">preserve_time,</if>
|
||||
<if test="remark != null">remark,</if>
|
||||
<if test="monitorUnitStatus != null">monitor_unit_status,</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="monitorUnitField != null">monitor_unit_field,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="monitorUnitName != null and monitorUnitName != ''">#{monitorUnitName},</if>
|
||||
<if test="sceneId != null">#{sceneId},</if>
|
||||
<if test="parentId != null">#{parentId},</if>
|
||||
<if test="monitorUnitTypeId != null">#{monitorUnitTypeId},</if>
|
||||
<if test="areaId != null">#{areaId},</if>
|
||||
<if test="monitorAddress != null">#{monitorAddress},</if>
|
||||
<if test="monitorPic != null">#{monitorPic},</if>
|
||||
<if test="preserveTime != null">#{preserveTime},</if>
|
||||
<if test="remark != null">#{remark},</if>
|
||||
<if test="monitorUnitStatus != null">#{monitorUnitStatus},</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="monitorUnitField != null">#{monitorUnitField},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateHwMonitorUnit" parameterType="HwMonitorUnit">
|
||||
update hw_monitor_unit
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="monitorUnitName != null and monitorUnitName != ''">monitor_unit_name = #{monitorUnitName},</if>
|
||||
<if test="sceneId != null">scene_id = #{sceneId},</if>
|
||||
<if test="parentId != null">parent_id = #{parentId},</if>
|
||||
<if test="monitorUnitTypeId != null">monitor_unit_type_id = #{monitorUnitTypeId},</if>
|
||||
<if test="areaId != null">area_id = #{areaId},</if>
|
||||
<if test="monitorAddress != null">monitor_address = #{monitorAddress},</if>
|
||||
<if test="monitorPic != null">monitor_pic = #{monitorPic},</if>
|
||||
<if test="preserveTime != null">preserve_time = #{preserveTime},</if>
|
||||
<if test="remark != null">remark = #{remark},</if>
|
||||
<if test="monitorUnitStatus != null">monitor_unit_status = #{monitorUnitStatus},</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="monitorUnitField != null">monitor_unit_field = #{monitorUnitField},</if>
|
||||
</trim>
|
||||
where monitor_unit_id = #{monitorUnitId}
|
||||
</update>
|
||||
|
||||
<delete id="deleteHwMonitorUnitByMonitorUnitId" parameterType="Long">
|
||||
delete from hw_monitor_unit where monitor_unit_id = #{monitorUnitId}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteHwMonitorUnitByMonitorUnitIds" parameterType="String">
|
||||
delete from hw_monitor_unit where monitor_unit_id in
|
||||
<foreach item="monitorUnitId" collection="array" open="(" separator="," close=")">
|
||||
#{monitorUnitId}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
||||
@ -0,0 +1,111 @@
|
||||
<?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.ruoyi.business.mapper.HwMonitorUnitTypeMapper">
|
||||
|
||||
<resultMap type="HwMonitorUnitType" id="HwMonitorUnitTypeResult">
|
||||
<result property="monitorUnitTypeId" column="monitor_unit_type_id" />
|
||||
<result property="monitorUnitTypeName" column="monitor_unit_type_name" />
|
||||
<result property="vitualFlag" column="vitual_flag" />
|
||||
<result property="monitorUnitTypeStatus" column="monitor_unit_type_status" />
|
||||
<result property="languageCode" column="language_code" />
|
||||
<result property="commonFlag" column="common_flag" />
|
||||
<result property="sceneId" column="scene_id" />
|
||||
<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="unitTypeIcon" column="unit_type_icon" />
|
||||
<result property="unitTypeField" column="unit_type_field" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectHwMonitorUnitTypeVo">
|
||||
select monitor_unit_type_id, monitor_unit_type_name, vitual_flag, monitor_unit_type_status, language_code, common_flag, scene_id, remark, create_by, create_time, update_by, update_time, unit_type_icon, unit_type_field from hw_monitor_unit_type
|
||||
</sql>
|
||||
|
||||
<select id="selectHwMonitorUnitTypeList" parameterType="HwMonitorUnitType" resultMap="HwMonitorUnitTypeResult">
|
||||
<include refid="selectHwMonitorUnitTypeVo"/>
|
||||
<where>
|
||||
<if test="monitorUnitTypeName != null and monitorUnitTypeName != ''"> and monitor_unit_type_name like concat('%', #{monitorUnitTypeName}, '%')</if>
|
||||
<if test="vitualFlag != null and vitualFlag != ''"> and vitual_flag = #{vitualFlag}</if>
|
||||
<if test="monitorUnitTypeStatus != null and monitorUnitTypeStatus != ''"> and monitor_unit_type_status = #{monitorUnitTypeStatus}</if>
|
||||
<if test="languageCode != null and languageCode != ''"> and language_code = #{languageCode}</if>
|
||||
<if test="commonFlag != null and commonFlag != ''"> and common_flag = #{commonFlag}</if>
|
||||
<if test="sceneId != null "> and scene_id = #{sceneId}</if>
|
||||
<if test="unitTypeIcon != null and unitTypeIcon != ''"> and unit_type_icon = #{unitTypeIcon}</if>
|
||||
<if test="unitTypeField != null and unitTypeField != ''"> and unit_type_field = #{unitTypeField}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectHwMonitorUnitTypeByMonitorUnitTypeId" parameterType="Long" resultMap="HwMonitorUnitTypeResult">
|
||||
<include refid="selectHwMonitorUnitTypeVo"/>
|
||||
where monitor_unit_type_id = #{monitorUnitTypeId}
|
||||
</select>
|
||||
|
||||
<insert id="insertHwMonitorUnitType" parameterType="HwMonitorUnitType" useGeneratedKeys="true" keyProperty="monitorUnitTypeId">
|
||||
insert into hw_monitor_unit_type
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="monitorUnitTypeName != null and monitorUnitTypeName != ''">monitor_unit_type_name,</if>
|
||||
<if test="vitualFlag != null and vitualFlag != ''">vitual_flag,</if>
|
||||
<if test="monitorUnitTypeStatus != null and monitorUnitTypeStatus != ''">monitor_unit_type_status,</if>
|
||||
<if test="languageCode != null">language_code,</if>
|
||||
<if test="commonFlag != null and commonFlag != ''">common_flag,</if>
|
||||
<if test="sceneId != null">scene_id,</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="unitTypeIcon != null">unit_type_icon,</if>
|
||||
<if test="unitTypeField != null">unit_type_field,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="monitorUnitTypeName != null and monitorUnitTypeName != ''">#{monitorUnitTypeName},</if>
|
||||
<if test="vitualFlag != null and vitualFlag != ''">#{vitualFlag},</if>
|
||||
<if test="monitorUnitTypeStatus != null and monitorUnitTypeStatus != ''">#{monitorUnitTypeStatus},</if>
|
||||
<if test="languageCode != null">#{languageCode},</if>
|
||||
<if test="commonFlag != null and commonFlag != ''">#{commonFlag},</if>
|
||||
<if test="sceneId != null">#{sceneId},</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="unitTypeIcon != null">#{unitTypeIcon},</if>
|
||||
<if test="unitTypeField != null">#{unitTypeField},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateHwMonitorUnitType" parameterType="HwMonitorUnitType">
|
||||
update hw_monitor_unit_type
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="monitorUnitTypeName != null and monitorUnitTypeName != ''">monitor_unit_type_name = #{monitorUnitTypeName},</if>
|
||||
<if test="vitualFlag != null and vitualFlag != ''">vitual_flag = #{vitualFlag},</if>
|
||||
<if test="monitorUnitTypeStatus != null and monitorUnitTypeStatus != ''">monitor_unit_type_status = #{monitorUnitTypeStatus},</if>
|
||||
<if test="languageCode != null">language_code = #{languageCode},</if>
|
||||
<if test="commonFlag != null and commonFlag != ''">common_flag = #{commonFlag},</if>
|
||||
<if test="sceneId != null">scene_id = #{sceneId},</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="unitTypeIcon != null">unit_type_icon = #{unitTypeIcon},</if>
|
||||
<if test="unitTypeField != null">unit_type_field = #{unitTypeField},</if>
|
||||
</trim>
|
||||
where monitor_unit_type_id = #{monitorUnitTypeId}
|
||||
</update>
|
||||
|
||||
<delete id="deleteHwMonitorUnitTypeByMonitorUnitTypeId" parameterType="Long">
|
||||
delete from hw_monitor_unit_type where monitor_unit_type_id = #{monitorUnitTypeId}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteHwMonitorUnitTypeByMonitorUnitTypeIds" parameterType="String">
|
||||
delete from hw_monitor_unit_type where monitor_unit_type_id in
|
||||
<foreach item="monitorUnitTypeId" collection="array" open="(" separator="," close=")">
|
||||
#{monitorUnitTypeId}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
||||
@ -0,0 +1,101 @@
|
||||
<?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.ruoyi.business.mapper.HwSceneModeMapper">
|
||||
|
||||
<resultMap type="HwSceneMode" id="HwSceneModeResult">
|
||||
<result property="sceneModeId" column="scene_mode_id" />
|
||||
<result property="sceneModeName" column="scene_mode_name" />
|
||||
<result property="customFlag" column="custom_flag" />
|
||||
<result property="tenantId" column="tenant_id" />
|
||||
<result property="languageCode" column="language_code" />
|
||||
<result property="remark" column="remark" />
|
||||
<result property="sceneModeStatus" column="scene_mode_status" />
|
||||
<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="sceneModeField" column="scene_mode_field" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectHwSceneModeVo">
|
||||
select scene_mode_id, scene_mode_name, custom_flag, tenant_id, language_code, remark, scene_mode_status, create_by, create_time, update_by, update_time, scene_mode_field from hw_scene_mode
|
||||
</sql>
|
||||
|
||||
<select id="selectHwSceneModeList" parameterType="HwSceneMode" resultMap="HwSceneModeResult">
|
||||
<include refid="selectHwSceneModeVo"/>
|
||||
<where>
|
||||
<if test="sceneModeName != null and sceneModeName != ''"> and scene_mode_name like concat('%', #{sceneModeName}, '%')</if>
|
||||
<if test="customFlag != null "> and custom_flag = #{customFlag}</if>
|
||||
<if test="tenantId != null "> and tenant_id = #{tenantId}</if>
|
||||
<if test="languageCode != null and languageCode != ''"> and language_code = #{languageCode}</if>
|
||||
<if test="sceneModeStatus != null "> and scene_mode_status = #{sceneModeStatus}</if>
|
||||
<if test="sceneModeField != null and sceneModeField != ''"> and scene_mode_field = #{sceneModeField}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectHwSceneModeBySceneModeId" parameterType="Long" resultMap="HwSceneModeResult">
|
||||
<include refid="selectHwSceneModeVo"/>
|
||||
where scene_mode_id = #{sceneModeId}
|
||||
</select>
|
||||
|
||||
<insert id="insertHwSceneMode" parameterType="HwSceneMode" useGeneratedKeys="true" keyProperty="sceneModeId">
|
||||
insert into hw_scene_mode
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="sceneModeName != null and sceneModeName != ''">scene_mode_name,</if>
|
||||
<if test="customFlag != null">custom_flag,</if>
|
||||
<if test="tenantId != null">tenant_id,</if>
|
||||
<if test="languageCode != null and languageCode != ''">language_code,</if>
|
||||
<if test="remark != null">remark,</if>
|
||||
<if test="sceneModeStatus != null">scene_mode_status,</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="sceneModeField != null">scene_mode_field,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="sceneModeName != null and sceneModeName != ''">#{sceneModeName},</if>
|
||||
<if test="customFlag != null">#{customFlag},</if>
|
||||
<if test="tenantId != null">#{tenantId},</if>
|
||||
<if test="languageCode != null and languageCode != ''">#{languageCode},</if>
|
||||
<if test="remark != null">#{remark},</if>
|
||||
<if test="sceneModeStatus != null">#{sceneModeStatus},</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="sceneModeField != null">#{sceneModeField},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateHwSceneMode" parameterType="HwSceneMode">
|
||||
update hw_scene_mode
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="sceneModeName != null and sceneModeName != ''">scene_mode_name = #{sceneModeName},</if>
|
||||
<if test="customFlag != null">custom_flag = #{customFlag},</if>
|
||||
<if test="tenantId != null">tenant_id = #{tenantId},</if>
|
||||
<if test="languageCode != null and languageCode != ''">language_code = #{languageCode},</if>
|
||||
<if test="remark != null">remark = #{remark},</if>
|
||||
<if test="sceneModeStatus != null">scene_mode_status = #{sceneModeStatus},</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="sceneModeField != null">scene_mode_field = #{sceneModeField},</if>
|
||||
</trim>
|
||||
where scene_mode_id = #{sceneModeId}
|
||||
</update>
|
||||
|
||||
<delete id="deleteHwSceneModeBySceneModeId" parameterType="Long">
|
||||
delete from hw_scene_mode where scene_mode_id = #{sceneModeId}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteHwSceneModeBySceneModeIds" parameterType="String">
|
||||
delete from hw_scene_mode where scene_mode_id in
|
||||
<foreach item="sceneModeId" collection="array" open="(" separator="," close=")">
|
||||
#{sceneModeId}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
||||
@ -0,0 +1,131 @@
|
||||
<?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.ruoyi.business.mapper.HwTenantMapper">
|
||||
|
||||
<resultMap type="HwTenant" id="HwTenantResult">
|
||||
<result property="tenantId" column="tenant_id" />
|
||||
<result property="tenantType" column="tenant_type" />
|
||||
<result property="tenantName" column="tenant_name" />
|
||||
<result property="tenantIndustry" column="tenant_industry" />
|
||||
<result property="contactName" column="contact_name" />
|
||||
<result property="contactPhone" column="contact_phone" />
|
||||
<result property="email" column="email" />
|
||||
<result property="areaId" column="area_id" />
|
||||
<result property="contactAddress" column="contact_address" />
|
||||
<result property="remark" column="remark" />
|
||||
<result property="tenantStatus" column="tenant_status" />
|
||||
<result property="isRegister" column="is_register" />
|
||||
<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="tenantGrade" column="tenant_grade" />
|
||||
<result property="tenantField" column="tenant_field" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectHwTenantVo">
|
||||
select tenant_id, tenant_type, tenant_name, tenant_industry, contact_name, contact_phone, email, area_id, contact_address, remark, tenant_status, is_register, create_by, create_time, update_by, update_time, tenant_grade, tenant_field from hw_tenant
|
||||
</sql>
|
||||
|
||||
<select id="selectHwTenantList" parameterType="HwTenant" resultMap="HwTenantResult">
|
||||
<include refid="selectHwTenantVo"/>
|
||||
<where>
|
||||
<if test="tenantType != null and tenantType != ''"> and tenant_type = #{tenantType}</if>
|
||||
<if test="tenantName != null and tenantName != ''"> and tenant_name like concat('%', #{tenantName}, '%')</if>
|
||||
<if test="tenantIndustry != null "> and tenant_industry = #{tenantIndustry}</if>
|
||||
<if test="contactName != null and contactName != ''"> and contact_name like concat('%', #{contactName}, '%')</if>
|
||||
<if test="contactPhone != null and contactPhone != ''"> and contact_phone = #{contactPhone}</if>
|
||||
<if test="email != null and email != ''"> and email = #{email}</if>
|
||||
<if test="areaId != null "> and area_id = #{areaId}</if>
|
||||
<if test="contactAddress != null and contactAddress != ''"> and contact_address = #{contactAddress}</if>
|
||||
<if test="tenantStatus != null and tenantStatus != ''"> and tenant_status = #{tenantStatus}</if>
|
||||
<if test="isRegister != null and isRegister != ''"> and is_register = #{isRegister}</if>
|
||||
<if test="tenantGrade != null "> and tenant_grade = #{tenantGrade}</if>
|
||||
<if test="tenantField != null and tenantField != ''"> and tenant_field = #{tenantField}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectHwTenantByTenantId" parameterType="Long" resultMap="HwTenantResult">
|
||||
<include refid="selectHwTenantVo"/>
|
||||
where tenant_id = #{tenantId}
|
||||
</select>
|
||||
|
||||
<insert id="insertHwTenant" parameterType="HwTenant" useGeneratedKeys="true" keyProperty="tenantId">
|
||||
insert into hw_tenant
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="tenantType != null and tenantType != ''">tenant_type,</if>
|
||||
<if test="tenantName != null and tenantName != ''">tenant_name,</if>
|
||||
<if test="tenantIndustry != null">tenant_industry,</if>
|
||||
<if test="contactName != null and contactName != ''">contact_name,</if>
|
||||
<if test="contactPhone != null and contactPhone != ''">contact_phone,</if>
|
||||
<if test="email != null">email,</if>
|
||||
<if test="areaId != null">area_id,</if>
|
||||
<if test="contactAddress != null">contact_address,</if>
|
||||
<if test="remark != null">remark,</if>
|
||||
<if test="tenantStatus != null and tenantStatus != ''">tenant_status,</if>
|
||||
<if test="isRegister != null and isRegister != ''">is_register,</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="tenantGrade != null">tenant_grade,</if>
|
||||
<if test="tenantField != null">tenant_field,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="tenantType != null and tenantType != ''">#{tenantType},</if>
|
||||
<if test="tenantName != null and tenantName != ''">#{tenantName},</if>
|
||||
<if test="tenantIndustry != null">#{tenantIndustry},</if>
|
||||
<if test="contactName != null and contactName != ''">#{contactName},</if>
|
||||
<if test="contactPhone != null and contactPhone != ''">#{contactPhone},</if>
|
||||
<if test="email != null">#{email},</if>
|
||||
<if test="areaId != null">#{areaId},</if>
|
||||
<if test="contactAddress != null">#{contactAddress},</if>
|
||||
<if test="remark != null">#{remark},</if>
|
||||
<if test="tenantStatus != null and tenantStatus != ''">#{tenantStatus},</if>
|
||||
<if test="isRegister != null and isRegister != ''">#{isRegister},</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="tenantGrade != null">#{tenantGrade},</if>
|
||||
<if test="tenantField != null">#{tenantField},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateHwTenant" parameterType="HwTenant">
|
||||
update hw_tenant
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="tenantType != null and tenantType != ''">tenant_type = #{tenantType},</if>
|
||||
<if test="tenantName != null and tenantName != ''">tenant_name = #{tenantName},</if>
|
||||
<if test="tenantIndustry != null">tenant_industry = #{tenantIndustry},</if>
|
||||
<if test="contactName != null and contactName != ''">contact_name = #{contactName},</if>
|
||||
<if test="contactPhone != null and contactPhone != ''">contact_phone = #{contactPhone},</if>
|
||||
<if test="email != null">email = #{email},</if>
|
||||
<if test="areaId != null">area_id = #{areaId},</if>
|
||||
<if test="contactAddress != null">contact_address = #{contactAddress},</if>
|
||||
<if test="remark != null">remark = #{remark},</if>
|
||||
<if test="tenantStatus != null and tenantStatus != ''">tenant_status = #{tenantStatus},</if>
|
||||
<if test="isRegister != null and isRegister != ''">is_register = #{isRegister},</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="tenantGrade != null">tenant_grade = #{tenantGrade},</if>
|
||||
<if test="tenantField != null">tenant_field = #{tenantField},</if>
|
||||
</trim>
|
||||
where tenant_id = #{tenantId}
|
||||
</update>
|
||||
|
||||
<delete id="deleteHwTenantByTenantId" parameterType="Long">
|
||||
delete from hw_tenant where tenant_id = #{tenantId}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteHwTenantByTenantIds" parameterType="String">
|
||||
delete from hw_tenant where tenant_id in
|
||||
<foreach item="tenantId" collection="array" open="(" separator="," close=")">
|
||||
#{tenantId}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
||||
@ -0,0 +1,120 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xmlns="http://maven.apache.org/POM/4.0.0"
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<parent>
|
||||
<groupId>com.ruoyi</groupId>
|
||||
<artifactId>ruoyi-modules</artifactId>
|
||||
<version>3.6.3</version>
|
||||
</parent>
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
|
||||
<artifactId>ruoyi-modules-dataprocess</artifactId>
|
||||
|
||||
<description>
|
||||
ruoyi-modules-dataprocess数据处理模块
|
||||
</description>
|
||||
|
||||
<dependencies>
|
||||
|
||||
<!-- SpringCloud Alibaba Nacos -->
|
||||
<dependency>
|
||||
<groupId>com.alibaba.cloud</groupId>
|
||||
<artifactId>spring-cloud-starter-alibaba-nacos-discovery</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- SpringCloud Alibaba Nacos Config -->
|
||||
<dependency>
|
||||
<groupId>com.alibaba.cloud</groupId>
|
||||
<artifactId>spring-cloud-starter-alibaba-nacos-config</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- SpringCloud Alibaba Sentinel -->
|
||||
<dependency>
|
||||
<groupId>com.alibaba.cloud</groupId>
|
||||
<artifactId>spring-cloud-starter-alibaba-sentinel</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- SpringBoot Actuator -->
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-actuator</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- Swagger UI -->
|
||||
<dependency>
|
||||
<groupId>io.springfox</groupId>
|
||||
<artifactId>springfox-swagger-ui</artifactId>
|
||||
<version>${swagger.fox.version}</version>
|
||||
</dependency>
|
||||
|
||||
<!-- Mysql Connector -->
|
||||
<dependency>
|
||||
<groupId>com.mysql</groupId>
|
||||
<artifactId>mysql-connector-j</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- RuoYi Common DataSource -->
|
||||
<dependency>
|
||||
<groupId>com.ruoyi</groupId>
|
||||
<artifactId>ruoyi-common-datasource</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- RuoYi Common DataScope -->
|
||||
<dependency>
|
||||
<groupId>com.ruoyi</groupId>
|
||||
<artifactId>ruoyi-common-datascope</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- RuoYi Common Log -->
|
||||
<dependency>
|
||||
<groupId>com.ruoyi</groupId>
|
||||
<artifactId>ruoyi-common-log</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- RuoYi Common Swagger -->
|
||||
<dependency>
|
||||
<groupId>com.ruoyi</groupId>
|
||||
<artifactId>ruoyi-common-swagger</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!--Mica-Mqtt-->
|
||||
<dependency>
|
||||
<groupId>net.dreamlu</groupId>
|
||||
<artifactId>mica-mqtt-client-spring-boot-starter</artifactId>
|
||||
<version>2.1.0</version>
|
||||
</dependency>
|
||||
|
||||
<!-- HW API TDENGINE-->
|
||||
<dependency>
|
||||
<groupId>com.ruoyi</groupId>
|
||||
<artifactId>hw-api-tdengine</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.locationtech.jts</groupId>
|
||||
<artifactId>jts-core</artifactId>
|
||||
<version>1.19.0</version>
|
||||
</dependency>
|
||||
|
||||
|
||||
</dependencies>
|
||||
|
||||
<build>
|
||||
<finalName>${project.artifactId}</finalName>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-maven-plugin</artifactId>
|
||||
<executions>
|
||||
<execution>
|
||||
<goals>
|
||||
<goal>repackage</goal>
|
||||
</goals>
|
||||
</execution>
|
||||
</executions>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
|
||||
</project>
|
||||
@ -0,0 +1,34 @@
|
||||
package com.ruoyi.dataprocess;
|
||||
|
||||
import com.ruoyi.common.security.annotation.EnableCustomConfig;
|
||||
import com.ruoyi.common.security.annotation.EnableRyFeignClients;
|
||||
import com.ruoyi.common.swagger.annotation.EnableCustomSwagger2;
|
||||
import org.springframework.boot.SpringApplication;
|
||||
import org.springframework.boot.autoconfigure.SpringBootApplication;
|
||||
|
||||
/**
|
||||
* 系统模块
|
||||
*
|
||||
* @author xins
|
||||
*/
|
||||
@EnableCustomConfig
|
||||
@EnableCustomSwagger2
|
||||
@EnableRyFeignClients
|
||||
@SpringBootApplication
|
||||
public class HwDataProcessApplication
|
||||
{
|
||||
public static void main(String[] args)
|
||||
{
|
||||
SpringApplication.run(HwDataProcessApplication.class, args);
|
||||
System.out.println("(♥◠‿◠)ノ゙ 数据处理模块启动成功 ლ(´ڡ`ლ)゙ \n" +
|
||||
" .-------. ____ __ \n" +
|
||||
" | _ _ \\ \\ \\ / / \n" +
|
||||
" | ( ' ) | \\ _. / ' \n" +
|
||||
" |(_ o _) / _( )_ .' \n" +
|
||||
" | (_,_).' __ ___(_ o _)' \n" +
|
||||
" | |\\ \\ | || |(_,_)' \n" +
|
||||
" | | \\ `' /| `-' / \n" +
|
||||
" | | \\ / \\ / \n" +
|
||||
" ''-' `'-' `-..-' ");
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,24 @@
|
||||
package com.ruoyi.dataprocess.amap;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
|
||||
/**
|
||||
* @Description: 要判断的点的实体类
|
||||
* @ClassName: PositionUtils.Postion
|
||||
* @Author : xins
|
||||
* @Date :2023-09-02 12:11
|
||||
* @Version :1.0
|
||||
*/
|
||||
@Data
|
||||
public class PositionVo{
|
||||
private BigDecimal longitude;
|
||||
|
||||
private BigDecimal latitude;
|
||||
|
||||
public PositionVo(BigDecimal longitude, BigDecimal latitude) {
|
||||
this.longitude = longitude;
|
||||
this.latitude = latitude;
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,77 @@
|
||||
package com.ruoyi.dataprocess.common;
|
||||
|
||||
import org.springframework.beans.factory.DisposableBean;
|
||||
import org.springframework.context.ApplicationContext;
|
||||
import org.springframework.context.ApplicationContextAware;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
@Service
|
||||
public class SpringBeanUtils implements ApplicationContextAware, DisposableBean {
|
||||
private static ApplicationContext applicationContext = null;
|
||||
|
||||
|
||||
/**
|
||||
* 取得存储在静态变量中的ApplicationContext.
|
||||
*/
|
||||
public static ApplicationContext getApplicationContext() {
|
||||
assertContextInjected();
|
||||
return applicationContext;
|
||||
}
|
||||
|
||||
/**
|
||||
* 从静态变量applicationContext中取得Bean, 自动转型为所赋值对象的类型.
|
||||
*/
|
||||
@SuppressWarnings("unchecked")
|
||||
public static <T> T getBean(String name) {
|
||||
// log.debug("从SpringContextHolder中取出Bean:" + name);
|
||||
assertContextInjected();
|
||||
return (T) applicationContext.getBean(name);
|
||||
}
|
||||
|
||||
/**
|
||||
* 从静态变量applicationContext中取得Bean, 自动转型为所赋值对象的类型.
|
||||
*/
|
||||
public static <T> T getBean(Class<T> requiredType) {
|
||||
assertContextInjected();
|
||||
return applicationContext.getBean(requiredType);
|
||||
}
|
||||
|
||||
/**
|
||||
* 清除SpringContextHolder中的ApplicationContext为Null.
|
||||
*/
|
||||
public static void clearHolder() {
|
||||
// log.debug("清除SpringContextHolder中的ApplicationContext:"
|
||||
// + applicationContext);
|
||||
applicationContext = null;
|
||||
}
|
||||
|
||||
/**
|
||||
* 实现ApplicationContextAware接口, 注入Context到静态变量中.
|
||||
*/
|
||||
@Override
|
||||
public void setApplicationContext(ApplicationContext applicationContext) {
|
||||
|
||||
if (SpringBeanUtils.applicationContext != null) {
|
||||
// log.warn("SpringContextHolder中的ApplicationContext被覆盖, 原有ApplicationContext为:" + SpringContextHolder.applicationContext);
|
||||
}
|
||||
|
||||
SpringBeanUtils.applicationContext = applicationContext; // NOSONAR
|
||||
}
|
||||
|
||||
/**
|
||||
* 实现DisposableBean接口, 在Context关闭时清理静态变量.
|
||||
*/
|
||||
@Override
|
||||
public void destroy() throws Exception {
|
||||
SpringBeanUtils.clearHolder();
|
||||
}
|
||||
|
||||
/**
|
||||
* 检查ApplicationContext不为空.
|
||||
*/
|
||||
private static void assertContextInjected() {
|
||||
if (applicationContext == null) {
|
||||
throw new IllegalStateException("applicaitonContext属性未注入, 请在applicationContext.xml中定义SpringBeanUtils.");
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,38 @@
|
||||
package com.ruoyi.dataprocess.config;
|
||||
|
||||
import com.ruoyi.dataprocess.listener.RedisMessageListener;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.context.annotation.Bean;
|
||||
import org.springframework.context.annotation.Configuration;
|
||||
import org.springframework.data.redis.connection.RedisConnectionFactory;
|
||||
import org.springframework.data.redis.listener.PatternTopic;
|
||||
import org.springframework.data.redis.listener.RedisMessageListenerContainer;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
|
||||
@Configuration
|
||||
public class RedisMessageListenerConfig {
|
||||
|
||||
@Autowired
|
||||
private RedisMessageListener redisMessageListener;
|
||||
@Autowired
|
||||
private RedisConnectionFactory redisConnectionFactory;
|
||||
|
||||
/**
|
||||
* 配置订阅关系
|
||||
*/
|
||||
@Bean
|
||||
public RedisMessageListenerContainer container() {
|
||||
RedisMessageListenerContainer container = new RedisMessageListenerContainer();
|
||||
container.setConnectionFactory(redisConnectionFactory);
|
||||
|
||||
//订阅频道
|
||||
List<PatternTopic> topicList = Arrays.asList(new PatternTopic("life.*"),new PatternTopic("*.life"));
|
||||
container.addMessageListener(redisMessageListener, topicList);
|
||||
|
||||
return container;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@ -0,0 +1,30 @@
|
||||
package com.ruoyi.dataprocess.listener;
|
||||
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.data.redis.connection.Message;
|
||||
import org.springframework.data.redis.connection.MessageListener;
|
||||
import org.springframework.data.redis.core.RedisTemplate;
|
||||
import org.springframework.data.redis.serializer.RedisSerializer;
|
||||
import org.springframework.stereotype.Component;
|
||||
|
||||
@Component
|
||||
@Slf4j
|
||||
public class RedisMessageListener implements MessageListener {
|
||||
|
||||
@Autowired
|
||||
private RedisTemplate redisTemplate;
|
||||
|
||||
@Override
|
||||
public void onMessage(Message message, byte[] pattern) {
|
||||
|
||||
RedisSerializer keySerializer = redisTemplate.getKeySerializer();
|
||||
RedisSerializer valueSerializer = redisTemplate.getValueSerializer();
|
||||
|
||||
log.info("----------Life接收到发布者消息----------");
|
||||
log.info("|频道:{}",keySerializer.deserialize(message.getChannel()));
|
||||
log.info("|当前监听器绑定的pattern:{}",new String(pattern));
|
||||
log.info("|消息内容:{}",valueSerializer.deserialize(message.getBody()));
|
||||
log.info("---------------------------------");
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,20 @@
|
||||
package com.ruoyi.dataprocess.mapper;
|
||||
|
||||
import com.ruoyi.dataprocess.domain.HwAlarmInfo;
|
||||
|
||||
/**
|
||||
* 报警信息Mapper接口
|
||||
*
|
||||
* @author xins
|
||||
* @date 2023-09-04
|
||||
*/
|
||||
public interface HwAlarmInfoMapper {
|
||||
/**
|
||||
* 新增报警信息
|
||||
*
|
||||
* @param hwAlarmInfo 报警信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertHwAlarmInfo(HwAlarmInfo hwAlarmInfo);
|
||||
|
||||
}
|
||||
@ -0,0 +1,50 @@
|
||||
package com.ruoyi.dataprocess.mapper;
|
||||
|
||||
|
||||
import com.ruoyi.dataprocess.domain.HwElectronicFence;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Description: 电子围栏实体类
|
||||
* @ClassName: HwElectronicFenceMapper
|
||||
* @Author : xins
|
||||
* @Date :2023-09-03 11:48
|
||||
* @Version :1.0
|
||||
*/
|
||||
public interface HwElectronicFenceMapper {
|
||||
|
||||
public List<HwElectronicFence> selectSuitableElectronicFenceList(@Param("deviceId") Long deviceId,
|
||||
@Param("monitorUnitId") Long monitorUnitId,
|
||||
@Param("sceneId") Long sceneId);
|
||||
|
||||
/**
|
||||
* @param: deviceId
|
||||
* @description 根据设备ID获取电子围栏配置
|
||||
* @author xins
|
||||
* @date 2023-09-03 12:10
|
||||
* @return List<HwElectronicFence>
|
||||
*/
|
||||
public List<HwElectronicFence> selectElectronicFencesByDeviceId(Long deviceId);
|
||||
|
||||
/**
|
||||
* @param: monitorUnitId
|
||||
* @description 根据监控单元ID获取电子围栏配置
|
||||
* @author xins
|
||||
* @date 2023-09-03 12:11
|
||||
* @return List<HwElectronicFence>
|
||||
*/
|
||||
public List<HwElectronicFence> selectElectronicFencesByMonitorUnitId(Long monitorUnitId);
|
||||
|
||||
/**
|
||||
* @param: sceneId
|
||||
* @description 根据场景Id获取电子围栏配置
|
||||
* @author xins
|
||||
* @date 2023-09-03 12:11
|
||||
* @return List<HwElectronicFence>
|
||||
*/
|
||||
public List<HwElectronicFence> selectElectronicFencesBySceneId(Long sceneId);
|
||||
|
||||
|
||||
}
|
||||
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue