dao/src/main/java/com/sandu/ximon/dao/domain/LightTaskPoleRelation.java
@@ -1,22 +1,23 @@ package com.sandu.ximon.dao.domain; import com.baomidou.mybatisplus.annotation.IdType; import com.baomidou.mybatisplus.annotation.TableField; import com.baomidou.mybatisplus.annotation.TableId; import com.baomidou.mybatisplus.annotation.TableName; import com.fasterxml.jackson.annotation.JsonIgnore; import lombok.Data; import java.io.Serializable; import java.time.LocalDateTime; import lombok.Data; /** * 路灯任务和灯杆关系表 * * @TableName light_task_pole_relation */ @TableName(value ="light_task_pole_relation") @TableName(value = "light_task_pole_relation") @Data public class LightTaskPoleRelation implements Serializable { /** * * */ // @TableId(type = IdType.AUTO) private Long id; @@ -41,13 +42,31 @@ */ private Integer issueStatus; /** * mac */ @JsonIgnore private String deviceCode; /** * 系统定时 */ private String sysScheduled; /** * 硬件定时 */ private String deviceScheduled; /** * 创建时间 */ private LocalDateTime createTime; /** * * 更新时间 */ private LocalDateTime updateTime; dao/src/main/resources/mapper/LightTaskPoleRelationMapper.xml
@@ -9,6 +9,9 @@ <result property="taskId" column="task_id" jdbcType="BIGINT"/> <result property="poleId" column="pole_id" jdbcType="BIGINT"/> <result property="lightAddress" column="light_address" jdbcType="VARCHAR"/> <result property="deviceCode" column="device_code" jdbcType="VARCHAR"/> <result property="sysScheduled" column="sys_scheduled" jdbcType="VARCHAR"/> <result property="deviceScheduled" column="device_scheduled" jdbcType="VARCHAR"/> <result property="issueStatus" column="issue_status" jdbcType="INTEGER"/> <result property="createTime" column="create_time" jdbcType="TIMESTAMP"/> <result property="updateTime" column="update_time" jdbcType="TIMESTAMP"/> @@ -27,7 +30,7 @@ light_task_pole_relation t1 LEFT JOIN pole t2 ON t1.pole_id = t2.id <where> t1.task_id = #{taskId} t1.task_id = #{taskId} </where> GROUP BY t2.id </select>