优化虚拟卡占用逻辑,占用时写入取水口编号,解除占用时清空虚拟卡编号;工单使用的4个表
4个文件已修改
9个文件已添加
962 ■■■■ 已修改文件
pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/command/ComSupport.java 59 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/daoOp/OpeApproveResultMapper.java 27 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/daoOp/OpeProcessingResultMapper.java 27 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/daoOp/OpeTaskTypeMapper.java 27 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/daoOp/OpeWorkOrderMapper.java 7 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/pojoOp/OpeApproveResult.java 71 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/pojoOp/OpeProcessingResult.java 109 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/pojoOp/OpeTaskType.java 44 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/pojoOp/OpeWorkOrder.java 65 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pipIrr-platform/pipIrr-global/src/main/resources/mapper/OpeApproveResultMapper.xml 127 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pipIrr-platform/pipIrr-global/src/main/resources/mapper/OpeProcessingResultMapper.xml 197 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pipIrr-platform/pipIrr-global/src/main/resources/mapper/OpeTaskTypeMapper.xml 80 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pipIrr-platform/pipIrr-global/src/main/resources/mapper/OpeWorkOrderMapper.xml 122 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/command/ComSupport.java
@@ -329,19 +329,20 @@
         * 如果是开关阀:更改虚拟卡状态:是否使用中、最后操作、最后操作时间
         * 更新执行结果、返回结果时间、结果内容
         * 返回回调内容
         * ***************************** 虚拟卡使用状态不依赖开关阀意愿,依赖开关阀成功与否
         */
        if (comType != null) {
            SeVirtualCard virtualCard = new SeVirtualCard();
            virtualCard.setId(vcId);
            if (comType == 1) {
                virtualCard.setInUse((byte) 1);
            } else {
                virtualCard.setInUse((byte) 0);
            }
            virtualCard.setLastOperate(LastOperateENUM.OPEN_VALVE.getCode());
            virtualCard.setLastOperateTime(new Date());
            seVirtualCardMapper.updateByPrimaryKeySelective(virtualCard);
        }
        //if (comType != null) {
        //    SeVirtualCard virtualCard = new SeVirtualCard();
        //    virtualCard.setId(vcId);
        //    if (comType == 1) {
        //        virtualCard.setInUse((byte) 1);
        //    } else {
        //        virtualCard.setInUse((byte) 0);
        //    }
        //    virtualCard.setLastOperate(LastOperateENUM.OPEN_VALVE.getCode());
        //    virtualCard.setLastOperateTime(new Date());
        //    seVirtualCardMapper.updateByPrimaryKeySelective(virtualCard);
        //}
        // 如果是开发命令(92-平台开阀,91-小程序开阀),返回结果中添加阀控器地址、虚拟卡编号、订单号
        //if(commandCode.equals("92") || commandCode.equals("97")) {
@@ -353,11 +354,45 @@
            JSONObject job_data = job_response.getJSONObject("content").getJSONObject("data");
            if(!job_data.getBoolean("success")) {
                // 开关阀失败
                // 开阀失败则解除占用,关阀失败则占用
                if (comType != null) {
                    SeVirtualCard virtualCard = new SeVirtualCard();
                    virtualCard.setId(vcId);
                    if (comType == 1) {
                        virtualCard.setInUse((byte) 0);
                        virtualCard.setIntakeId(null);
                    } else {
                        virtualCard.setInUse((byte) 1);
                        virtualCard.setIntakeId(intakeId);
                    }
                    virtualCard.setLastOperate(LastOperateENUM.OPEN_VALVE.getCode());
                    virtualCard.setLastOperateTime(new Date());
                    seVirtualCardMapper.updateByPrimaryKeySelective(virtualCard);
                }
                response_CallBack.setCode("10003");
                response_CallBack.setMsg(CommandResultCode.OPEN_CLOSE_FAIL.getMessage());
                response_CallBack.setSuccess(false);
            }else {
                // 开关阀成功
                // 开阀成功则占用,关阀成功不占用
                if (comType != null) {
                    SeVirtualCard virtualCard = new SeVirtualCard();
                    virtualCard.setId(vcId);
                    if (comType == 1) {
                        virtualCard.setInUse((byte) 1);
                        virtualCard.setIntakeId(intakeId);
                    } else {
                        virtualCard.setInUse((byte) 0);
                        virtualCard.setIntakeId(null);
                    }
                    virtualCard.setLastOperate(LastOperateENUM.OPEN_VALVE.getCode());
                    virtualCard.setLastOperateTime(new Date());
                    seVirtualCardMapper.updateByPrimaryKeySelective(virtualCard);
                }
                job_data.remove("success");
                job_data.put("intakeId", intakeId);
                job_data.put("rtuAddr", rtuAddr);
pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/daoOp/OpeApproveResultMapper.java
New file
@@ -0,0 +1,27 @@
package com.dy.pipIrrGlobal.daoOp;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.dy.pipIrrGlobal.pojoOp.OpeApproveResult;
import org.apache.ibatis.annotations.Mapper;
/**
 * @author ZhuBaoMin
 * @date 2024-11-06 11:49
 * @LastEditTime 2024-11-06 11:49
 * @Description
 */
@Mapper
public interface OpeApproveResultMapper extends BaseMapper<OpeApproveResult> {
    int deleteByPrimaryKey(Long id);
    int insert(OpeApproveResult record);
    int insertSelective(OpeApproveResult record);
    OpeApproveResult selectByPrimaryKey(Long id);
    int updateByPrimaryKeySelective(OpeApproveResult record);
    int updateByPrimaryKey(OpeApproveResult record);
}
pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/daoOp/OpeProcessingResultMapper.java
New file
@@ -0,0 +1,27 @@
package com.dy.pipIrrGlobal.daoOp;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.dy.pipIrrGlobal.pojoOp.OpeProcessingResult;
import org.apache.ibatis.annotations.Mapper;
/**
 * @author ZhuBaoMin
 * @date 2024-11-06 11:39
 * @LastEditTime 2024-11-06 11:39
 * @Description
 */
@Mapper
public interface OpeProcessingResultMapper extends BaseMapper<OpeProcessingResult> {
    int deleteByPrimaryKey(Long id);
    int insert(OpeProcessingResult record);
    int insertSelective(OpeProcessingResult record);
    OpeProcessingResult selectByPrimaryKey(Long id);
    int updateByPrimaryKeySelective(OpeProcessingResult record);
    int updateByPrimaryKey(OpeProcessingResult record);
}
pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/daoOp/OpeTaskTypeMapper.java
New file
@@ -0,0 +1,27 @@
package com.dy.pipIrrGlobal.daoOp;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.dy.pipIrrGlobal.pojoOp.OpeTaskType;
import org.apache.ibatis.annotations.Mapper;
/**
 * @author ZhuBaoMin
 * @date 2024-11-06 11:25
 * @LastEditTime 2024-11-06 11:25
 * @Description
 */
@Mapper
public interface OpeTaskTypeMapper extends BaseMapper<OpeTaskType> {
    int deleteByPrimaryKey(Long id);
    int insert(OpeTaskType record);
    int insertSelective(OpeTaskType record);
    OpeTaskType selectByPrimaryKey(Long id);
    int updateByPrimaryKeySelective(OpeTaskType record);
    int updateByPrimaryKey(OpeTaskType record);
}
pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/daoOp/OpeWorkOrderMapper.java
@@ -5,11 +5,12 @@
import org.apache.ibatis.annotations.Mapper;
/**
 * @author :WuZeYu
 * @Date :2024/8/6  8:47
 * @LastEditTime :2024/8/6  8:47
 * @author ZhuBaoMin
 * @date 2024-11-06 11:33
 * @LastEditTime 2024-11-06 11:33
 * @Description
 */
@Mapper
public interface OpeWorkOrderMapper extends BaseMapper<OpeWorkOrder> {
    int deleteByPrimaryKey(Long id);
pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/pojoOp/OpeApproveResult.java
New file
@@ -0,0 +1,71 @@
package com.dy.pipIrrGlobal.pojoOp;
import com.alibaba.fastjson2.annotation.JSONField;
import com.alibaba.fastjson2.writer.ObjectWriterImplToString;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.dy.common.po.BaseEntity;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.*;
import java.util.Date;
/**
 * @author ZhuBaoMin
 * @date 2024-11-06 11:49
 * @LastEditTime 2024-11-06 11:49
 * @Description 处理结果审核实体类
 */
@TableName(value="ope_approve_result", autoResultMap = true)
@Data
@Builder
@ToString
@NoArgsConstructor
@AllArgsConstructor
public class OpeApproveResult implements BaseEntity {
    public static final long serialVersionUID = 202411061152001L;
    /**
    * 主键
    */
    @JSONField(serializeUsing= ObjectWriterImplToString.class)
    @TableId(type = IdType.INPUT)
    private Long id;
    /**
    * 工单ID
    */
    @JSONField(serializeUsing= ObjectWriterImplToString.class)
    private Long workOrderId;
    /**
    * 处理结果ID
    */
    @JSONField(serializeUsing= ObjectWriterImplToString.class)
    private Long processingResultId;
    /**
    * 审核人ID
    */
    @JSONField(serializeUsing= ObjectWriterImplToString.class)
    private Long approverId;
    /**
    * 审核时间
    */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date approveTime;
    /**
    * 审核结果;1-通过,2-驳回
    */
    private Byte approveResult;
    /**
    * 逻辑删除标识;未删除为0,已删除为删除时间
    */
    @JSONField(serializeUsing= ObjectWriterImplToString.class)
    private Long deleted;
}
pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/pojoOp/OpeProcessingResult.java
New file
@@ -0,0 +1,109 @@
package com.dy.pipIrrGlobal.pojoOp;
import com.alibaba.fastjson2.JSONArray;
import com.alibaba.fastjson2.annotation.JSONField;
import com.alibaba.fastjson2.writer.ObjectWriterImplToString;
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.baomidou.mybatisplus.extension.handlers.JacksonTypeHandler;
import com.dy.common.po.BaseEntity;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.*;
import java.math.BigDecimal;
import java.util.Date;
/**
 * @author ZhuBaoMin
 * @date 2024-11-06 11:39
 * @LastEditTime 2024-11-06 11:39
 * @Description 处理结果实体类
 */
@TableName(value="ope_processing_result", autoResultMap = true)
@Data
@Builder
@ToString
@NoArgsConstructor
@AllArgsConstructor
public class OpeProcessingResult implements BaseEntity {
    public static final long serialVersionUID = 202411061146001L;
    /**
    * 主键
    */
    @JSONField(serializeUsing= ObjectWriterImplToString.class)
    @TableId(type = IdType.INPUT)
    private Long id;
    /**
    * 工单ID
    */
    @JSONField(serializeUsing= ObjectWriterImplToString.class)
    private Long workOrderId;
    /**
    * 巡检员ID
    */
    @JSONField(serializeUsing= ObjectWriterImplToString.class)
    private Long inspectorId;
    /**
    * 结果内容
    */
    private String content;
    /**
    * 照片列表
    */
    @TableField(typeHandler = JacksonTypeHandler.class)
    private JSONArray images;
    /**
    * 音频列表
    */
    @TableField(typeHandler = JacksonTypeHandler.class)
    private JSONArray audios;
    /**
    * 视频列表
    */
    @TableField(typeHandler = JacksonTypeHandler.class)
    private JSONArray videos;
    /**
    * 经度
    */
    private BigDecimal lng;
    /**
    * 纬度
    */
    private BigDecimal lat;
    /**
    * 任务完成时间;精确到分
    */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm")
    private Date completeTime;
    /**
    * 上报时间
    */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date reportTime;
    /**
    * 状态;1-草稿,2-已上报,3-已通过,4-已驳回
    */
    private Byte state;
    /**
    * 逻辑删除标识;未删除为0,已删除为删除时间
    */
    @JSONField(serializeUsing= ObjectWriterImplToString.class)
    private Long deleted;
}
pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/pojoOp/OpeTaskType.java
New file
@@ -0,0 +1,44 @@
package com.dy.pipIrrGlobal.pojoOp;
import com.alibaba.fastjson2.annotation.JSONField;
import com.alibaba.fastjson2.writer.ObjectWriterImplToString;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.dy.common.po.BaseEntity;
import lombok.*;
/**
 * @author ZhuBaoMin
 * @date 2024-11-06 11:25
 * @LastEditTime 2024-11-06 11:25
 * @Description 任务类型实体类
 */
@TableName(value = "ope_task_type", autoResultMap = true)
@Data
@Builder
@ToString
@NoArgsConstructor
@AllArgsConstructor
public class OpeTaskType implements BaseEntity {
    public static final long serialVersionUID = 202411061128001L;
    /**
    * 主键
    */
    @JSONField(serializeUsing= ObjectWriterImplToString.class)
    @TableId(type = IdType.INPUT)
    private Long id;
    /**
    * 任务类型
    */
    private String taskType;
    /**
    * 逻辑删除标识;未删除为0,已删除为删除时间
    */
    @JSONField(serializeUsing= ObjectWriterImplToString.class)
    private Long deleted;
}
pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/pojoOp/OpeWorkOrder.java
@@ -7,31 +7,26 @@
import com.baomidou.mybatisplus.annotation.TableName;
import com.dy.common.po.BaseEntity;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.v3.oas.annotations.media.Schema;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.NotNull;
import lombok.*;
import org.springframework.format.annotation.DateTimeFormat;
import java.util.Date;
/**
 * @author :WuZeYu
 * @Date :2024/8/6  8:47
 * @LastEditTime :2024/8/6  8:47
 * @Description
 * @author ZhuBaoMin
 * @date 2024-11-06 11:33
 * @LastEditTime 2024-11-06 11:33
 * @Description 工单实体类
 */
/**
 * 工单表
 */
@TableName(value="ope_feedback", autoResultMap = true)
@TableName(value = "ope_work_order", autoResultMap = true)
@Data
@ToString
@Builder
@ToString
@NoArgsConstructor
@AllArgsConstructor
@Schema(name = "工单表")
public class OpeWorkOrder implements BaseEntity {
    public static final long serialVersionUID = 202411061136001L;
    /**
    * 主键
    */
@@ -43,25 +38,23 @@
    * 派单人ID
    */
    @JSONField(serializeUsing= ObjectWriterImplToString.class)
    @NotNull
    private Long dispatcher;
    private Long dispatcherId;
    /**
    * 巡检员ID
    */
    @JSONField(serializeUsing= ObjectWriterImplToString.class)
    @NotNull
    private Long inspector;
    private Long inspectorId;
    /**
    * 任务类型;1-漏损处理,2-报警处理,3-反馈处理,4-其他
    * 任务类型ID
    */
    private Byte taskType;
    @JSONField(serializeUsing= ObjectWriterImplToString.class)
    private Long taskTypeId;
    /**
    * 任务内容
    */
    @NotBlank
    private String taskContent;
    /**
@@ -72,38 +65,34 @@
    /**
    * 要求完成时间;精确到分
    */
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm")
    private Date deadLine;
    /**
    * 任务完成时间;精确到分
    */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm")
    private Date completeTime;
    /**
    * 派单时间
    */
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date dispatchTime;
    /**
    * 处理结果;1-完成,2-未完成
    * 状态;1-未完成,2-已完成
    */
    private Byte taskResult;
    private Byte state;
    /**
    * 结果照片
    * 驳回次数
    */
    private String photos;
    /**
    * 完工时间
    */
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date completeTime;
    private Integer rejectTimes;
    /**
    * 逻辑删除标识;未删除为0,已删除为删除时间
    */
    @JSONField(serializeUsing= ObjectWriterImplToString.class)
    private Long deleted;
}
pipIrr-platform/pipIrr-global/src/main/resources/mapper/OpeApproveResultMapper.xml
New file
@@ -0,0 +1,127 @@
<?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.dy.pipIrrGlobal.daoOp.OpeApproveResultMapper">
  <resultMap id="BaseResultMap" type="com.dy.pipIrrGlobal.pojoOp.OpeApproveResult">
    <!--@mbg.generated-->
    <!--@Table ope_approve_result-->
    <id column="id" jdbcType="BIGINT" property="id" />
    <result column="work_order_id" jdbcType="BIGINT" property="workOrderId" />
    <result column="processing_result_id" jdbcType="BIGINT" property="processingResultId" />
    <result column="approver_id" jdbcType="BIGINT" property="approverId" />
    <result column="approve_time" jdbcType="TIMESTAMP" property="approveTime" />
    <result column="approve_result" jdbcType="TINYINT" property="approveResult" />
    <result column="deleted" jdbcType="BIGINT" property="deleted" />
  </resultMap>
  <sql id="Base_Column_List">
    <!--@mbg.generated-->
    id, work_order_id, processing_result_id, approver_id, approve_time, approve_result,
    deleted
  </sql>
  <select id="selectByPrimaryKey" parameterType="java.lang.Long" resultMap="BaseResultMap">
    <!--@mbg.generated-->
    select
    <include refid="Base_Column_List" />
    from ope_approve_result
    where id = #{id,jdbcType=BIGINT}
  </select>
  <delete id="deleteByPrimaryKey" parameterType="java.lang.Long">
    <!--@mbg.generated-->
    delete from ope_approve_result
    where id = #{id,jdbcType=BIGINT}
  </delete>
  <insert id="insert" parameterType="com.dy.pipIrrGlobal.pojoOp.OpeApproveResult">
    <!--@mbg.generated-->
    insert into ope_approve_result (id, work_order_id, processing_result_id,
      approver_id, approve_time, approve_result,
      deleted)
    values (#{id,jdbcType=BIGINT}, #{workOrderId,jdbcType=BIGINT}, #{processingResultId,jdbcType=BIGINT},
      #{approverId,jdbcType=BIGINT}, #{approveTime,jdbcType=TIMESTAMP}, #{approveResult,jdbcType=TINYINT},
      #{deleted,jdbcType=BIGINT})
  </insert>
  <insert id="insertSelective" parameterType="com.dy.pipIrrGlobal.pojoOp.OpeApproveResult">
    <!--@mbg.generated-->
    insert into ope_approve_result
    <trim prefix="(" suffix=")" suffixOverrides=",">
      <if test="id != null">
        id,
      </if>
      <if test="workOrderId != null">
        work_order_id,
      </if>
      <if test="processingResultId != null">
        processing_result_id,
      </if>
      <if test="approverId != null">
        approver_id,
      </if>
      <if test="approveTime != null">
        approve_time,
      </if>
      <if test="approveResult != null">
        approve_result,
      </if>
      <if test="deleted != null">
        deleted,
      </if>
    </trim>
    <trim prefix="values (" suffix=")" suffixOverrides=",">
      <if test="id != null">
        #{id,jdbcType=BIGINT},
      </if>
      <if test="workOrderId != null">
        #{workOrderId,jdbcType=BIGINT},
      </if>
      <if test="processingResultId != null">
        #{processingResultId,jdbcType=BIGINT},
      </if>
      <if test="approverId != null">
        #{approverId,jdbcType=BIGINT},
      </if>
      <if test="approveTime != null">
        #{approveTime,jdbcType=TIMESTAMP},
      </if>
      <if test="approveResult != null">
        #{approveResult,jdbcType=TINYINT},
      </if>
      <if test="deleted != null">
        #{deleted,jdbcType=BIGINT},
      </if>
    </trim>
  </insert>
  <update id="updateByPrimaryKeySelective" parameterType="com.dy.pipIrrGlobal.pojoOp.OpeApproveResult">
    <!--@mbg.generated-->
    update ope_approve_result
    <set>
      <if test="workOrderId != null">
        work_order_id = #{workOrderId,jdbcType=BIGINT},
      </if>
      <if test="processingResultId != null">
        processing_result_id = #{processingResultId,jdbcType=BIGINT},
      </if>
      <if test="approverId != null">
        approver_id = #{approverId,jdbcType=BIGINT},
      </if>
      <if test="approveTime != null">
        approve_time = #{approveTime,jdbcType=TIMESTAMP},
      </if>
      <if test="approveResult != null">
        approve_result = #{approveResult,jdbcType=TINYINT},
      </if>
      <if test="deleted != null">
        deleted = #{deleted,jdbcType=BIGINT},
      </if>
    </set>
    where id = #{id,jdbcType=BIGINT}
  </update>
  <update id="updateByPrimaryKey" parameterType="com.dy.pipIrrGlobal.pojoOp.OpeApproveResult">
    <!--@mbg.generated-->
    update ope_approve_result
    set work_order_id = #{workOrderId,jdbcType=BIGINT},
      processing_result_id = #{processingResultId,jdbcType=BIGINT},
      approver_id = #{approverId,jdbcType=BIGINT},
      approve_time = #{approveTime,jdbcType=TIMESTAMP},
      approve_result = #{approveResult,jdbcType=TINYINT},
      deleted = #{deleted,jdbcType=BIGINT}
    where id = #{id,jdbcType=BIGINT}
  </update>
</mapper>
pipIrr-platform/pipIrr-global/src/main/resources/mapper/OpeProcessingResultMapper.xml
New file
@@ -0,0 +1,197 @@
<?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.dy.pipIrrGlobal.daoOp.OpeProcessingResultMapper">
  <resultMap id="BaseResultMap" type="com.dy.pipIrrGlobal.pojoOp.OpeProcessingResult">
    <!--@mbg.generated-->
    <!--@Table ope_processing_result-->
    <id column="id" jdbcType="BIGINT" property="id" />
    <result column="work_order_id" jdbcType="BIGINT" property="workOrderId" />
    <result column="inspector_id" jdbcType="BIGINT" property="inspectorId" />
    <result column="content" jdbcType="VARCHAR" property="content" />
    <result column="images" jdbcType="JAVA_OBJECT" typeHandler="com.baomidou.mybatisplus.extension.handlers.JacksonTypeHandler" property="images" />
    <result column="audios" jdbcType="JAVA_OBJECT" typeHandler="com.baomidou.mybatisplus.extension.handlers.JacksonTypeHandler" property="audios" />
    <result column="videos" jdbcType="JAVA_OBJECT" typeHandler="com.baomidou.mybatisplus.extension.handlers.JacksonTypeHandler" property="videos" />
    <result column="lng" jdbcType="DECIMAL" property="lng" />
    <result column="lat" jdbcType="DECIMAL" property="lat" />
    <result column="complete_time" jdbcType="TIMESTAMP" property="completeTime" />
    <result column="report_time" jdbcType="TIMESTAMP" property="reportTime" />
    <result column="state" jdbcType="TINYINT" property="state" />
    <result column="deleted" jdbcType="BIGINT" property="deleted" />
  </resultMap>
  <sql id="Base_Column_List">
    <!--@mbg.generated-->
    id, work_order_id, inspector_id, content, images, audios, videos, lng, lat, complete_time,
    report_time, `state`, deleted
  </sql>
  <select id="selectByPrimaryKey" parameterType="java.lang.Long" resultMap="BaseResultMap">
    <!--@mbg.generated-->
    select
    <include refid="Base_Column_List" />
    from ope_processing_result
    where id = #{id,jdbcType=BIGINT}
  </select>
  <delete id="deleteByPrimaryKey" parameterType="java.lang.Long">
    <!--@mbg.generated-->
    delete from ope_processing_result
    where id = #{id,jdbcType=BIGINT}
  </delete>
  <insert id="insert" parameterType="com.dy.pipIrrGlobal.pojoOp.OpeProcessingResult">
    <!--@mbg.generated-->
    insert into ope_processing_result (id, work_order_id, inspector_id,
      content, images, audios,
      videos, lng, lat, complete_time,
      report_time, `state`, deleted
      )
    values (#{id,jdbcType=BIGINT}, #{workOrderId,jdbcType=BIGINT}, #{inspectorId,jdbcType=BIGINT},
      #{content,jdbcType=VARCHAR}, #{images,jdbcType=JAVA_OBJECT, typeHandler=com.baomidou.mybatisplus.extension.handlers.JacksonTypeHandler}, #{audios,jdbcType=JAVA_OBJECT, typeHandler=com.baomidou.mybatisplus.extension.handlers.JacksonTypeHandler},
      #{videos,jdbcType=JAVA_OBJECT, typeHandler=com.baomidou.mybatisplus.extension.handlers.JacksonTypeHandler}, #{lng,jdbcType=DECIMAL}, #{lat,jdbcType=DECIMAL}, #{completeTime,jdbcType=TIMESTAMP},
      #{reportTime,jdbcType=TIMESTAMP}, #{state,jdbcType=TINYINT}, #{deleted,jdbcType=BIGINT}
      )
  </insert>
  <insert id="insertSelective" parameterType="com.dy.pipIrrGlobal.pojoOp.OpeProcessingResult">
    <!--@mbg.generated-->
    insert into ope_processing_result
    <trim prefix="(" suffix=")" suffixOverrides=",">
      <if test="id != null">
        id,
      </if>
      <if test="workOrderId != null">
        work_order_id,
      </if>
      <if test="inspectorId != null">
        inspector_id,
      </if>
      <if test="content != null">
        content,
      </if>
      <if test="images != null">
        images,
      </if>
      <if test="audios != null">
        audios,
      </if>
      <if test="videos != null">
        videos,
      </if>
      <if test="lng != null">
        lng,
      </if>
      <if test="lat != null">
        lat,
      </if>
      <if test="completeTime != null">
        complete_time,
      </if>
      <if test="reportTime != null">
        report_time,
      </if>
      <if test="state != null">
        `state`,
      </if>
      <if test="deleted != null">
        deleted,
      </if>
    </trim>
    <trim prefix="values (" suffix=")" suffixOverrides=",">
      <if test="id != null">
        #{id,jdbcType=BIGINT},
      </if>
      <if test="workOrderId != null">
        #{workOrderId,jdbcType=BIGINT},
      </if>
      <if test="inspectorId != null">
        #{inspectorId,jdbcType=BIGINT},
      </if>
      <if test="content != null">
        #{content,jdbcType=VARCHAR},
      </if>
      <if test="images != null">
        #{images,jdbcType=JAVA_OBJECT, typeHandler=com.baomidou.mybatisplus.extension.handlers.JacksonTypeHandler},
      </if>
      <if test="audios != null">
        #{audios,jdbcType=JAVA_OBJECT, typeHandler=com.baomidou.mybatisplus.extension.handlers.JacksonTypeHandler},
      </if>
      <if test="videos != null">
        #{videos,jdbcType=JAVA_OBJECT, typeHandler=com.baomidou.mybatisplus.extension.handlers.JacksonTypeHandler},
      </if>
      <if test="lng != null">
        #{lng,jdbcType=DECIMAL},
      </if>
      <if test="lat != null">
        #{lat,jdbcType=DECIMAL},
      </if>
      <if test="completeTime != null">
        #{completeTime,jdbcType=TIMESTAMP},
      </if>
      <if test="reportTime != null">
        #{reportTime,jdbcType=TIMESTAMP},
      </if>
      <if test="state != null">
        #{state,jdbcType=TINYINT},
      </if>
      <if test="deleted != null">
        #{deleted,jdbcType=BIGINT},
      </if>
    </trim>
  </insert>
  <update id="updateByPrimaryKeySelective" parameterType="com.dy.pipIrrGlobal.pojoOp.OpeProcessingResult">
    <!--@mbg.generated-->
    update ope_processing_result
    <set>
      <if test="workOrderId != null">
        work_order_id = #{workOrderId,jdbcType=BIGINT},
      </if>
      <if test="inspectorId != null">
        inspector_id = #{inspectorId,jdbcType=BIGINT},
      </if>
      <if test="content != null">
        content = #{content,jdbcType=VARCHAR},
      </if>
      <if test="images != null">
        images = #{images,jdbcType=JAVA_OBJECT, typeHandler=com.baomidou.mybatisplus.extension.handlers.JacksonTypeHandler},
      </if>
      <if test="audios != null">
        audios = #{audios,jdbcType=JAVA_OBJECT, typeHandler=com.baomidou.mybatisplus.extension.handlers.JacksonTypeHandler},
      </if>
      <if test="videos != null">
        videos = #{videos,jdbcType=JAVA_OBJECT, typeHandler=com.baomidou.mybatisplus.extension.handlers.JacksonTypeHandler},
      </if>
      <if test="lng != null">
        lng = #{lng,jdbcType=DECIMAL},
      </if>
      <if test="lat != null">
        lat = #{lat,jdbcType=DECIMAL},
      </if>
      <if test="completeTime != null">
        complete_time = #{completeTime,jdbcType=TIMESTAMP},
      </if>
      <if test="reportTime != null">
        report_time = #{reportTime,jdbcType=TIMESTAMP},
      </if>
      <if test="state != null">
        `state` = #{state,jdbcType=TINYINT},
      </if>
      <if test="deleted != null">
        deleted = #{deleted,jdbcType=BIGINT},
      </if>
    </set>
    where id = #{id,jdbcType=BIGINT}
  </update>
  <update id="updateByPrimaryKey" parameterType="com.dy.pipIrrGlobal.pojoOp.OpeProcessingResult">
    <!--@mbg.generated-->
    update ope_processing_result
    set work_order_id = #{workOrderId,jdbcType=BIGINT},
      inspector_id = #{inspectorId,jdbcType=BIGINT},
      content = #{content,jdbcType=VARCHAR},
      images = #{images,jdbcType=JAVA_OBJECT, typeHandler=com.baomidou.mybatisplus.extension.handlers.JacksonTypeHandler},
      audios = #{audios,jdbcType=JAVA_OBJECT, typeHandler=com.baomidou.mybatisplus.extension.handlers.JacksonTypeHandler},
      videos = #{videos,jdbcType=JAVA_OBJECT, typeHandler=com.baomidou.mybatisplus.extension.handlers.JacksonTypeHandler},
      lng = #{lng,jdbcType=DECIMAL},
      lat = #{lat,jdbcType=DECIMAL},
      complete_time = #{completeTime,jdbcType=TIMESTAMP},
      report_time = #{reportTime,jdbcType=TIMESTAMP},
      `state` = #{state,jdbcType=TINYINT},
      deleted = #{deleted,jdbcType=BIGINT}
    where id = #{id,jdbcType=BIGINT}
  </update>
</mapper>
pipIrr-platform/pipIrr-global/src/main/resources/mapper/OpeTaskTypeMapper.xml
New file
@@ -0,0 +1,80 @@
<?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.dy.pipIrrGlobal.daoOp.OpeTaskTypeMapper">
  <resultMap id="BaseResultMap" type="com.dy.pipIrrGlobal.pojoOp.OpeTaskType">
    <!--@mbg.generated-->
    <!--@Table ope_task_type-->
    <id column="id" jdbcType="BIGINT" property="id" />
    <result column="task_type" jdbcType="VARCHAR" property="taskType" />
    <result column="deleted" jdbcType="BIGINT" property="deleted" />
  </resultMap>
  <sql id="Base_Column_List">
    <!--@mbg.generated-->
    id, task_type, deleted
  </sql>
  <select id="selectByPrimaryKey" parameterType="java.lang.Long" resultMap="BaseResultMap">
    <!--@mbg.generated-->
    select
    <include refid="Base_Column_List" />
    from ope_task_type
    where id = #{id,jdbcType=BIGINT}
  </select>
  <delete id="deleteByPrimaryKey" parameterType="java.lang.Long">
    <!--@mbg.generated-->
    delete from ope_task_type
    where id = #{id,jdbcType=BIGINT}
  </delete>
  <insert id="insert" parameterType="com.dy.pipIrrGlobal.pojoOp.OpeTaskType">
    <!--@mbg.generated-->
    insert into ope_task_type (id, task_type, deleted
      )
    values (#{id,jdbcType=BIGINT}, #{taskType,jdbcType=VARCHAR}, #{deleted,jdbcType=BIGINT}
      )
  </insert>
  <insert id="insertSelective" parameterType="com.dy.pipIrrGlobal.pojoOp.OpeTaskType">
    <!--@mbg.generated-->
    insert into ope_task_type
    <trim prefix="(" suffix=")" suffixOverrides=",">
      <if test="id != null">
        id,
      </if>
      <if test="taskType != null">
        task_type,
      </if>
      <if test="deleted != null">
        deleted,
      </if>
    </trim>
    <trim prefix="values (" suffix=")" suffixOverrides=",">
      <if test="id != null">
        #{id,jdbcType=BIGINT},
      </if>
      <if test="taskType != null">
        #{taskType,jdbcType=VARCHAR},
      </if>
      <if test="deleted != null">
        #{deleted,jdbcType=BIGINT},
      </if>
    </trim>
  </insert>
  <update id="updateByPrimaryKeySelective" parameterType="com.dy.pipIrrGlobal.pojoOp.OpeTaskType">
    <!--@mbg.generated-->
    update ope_task_type
    <set>
      <if test="taskType != null">
        task_type = #{taskType,jdbcType=VARCHAR},
      </if>
      <if test="deleted != null">
        deleted = #{deleted,jdbcType=BIGINT},
      </if>
    </set>
    where id = #{id,jdbcType=BIGINT}
  </update>
  <update id="updateByPrimaryKey" parameterType="com.dy.pipIrrGlobal.pojoOp.OpeTaskType">
    <!--@mbg.generated-->
    update ope_task_type
    set task_type = #{taskType,jdbcType=VARCHAR},
      deleted = #{deleted,jdbcType=BIGINT}
    where id = #{id,jdbcType=BIGINT}
  </update>
</mapper>
pipIrr-platform/pipIrr-global/src/main/resources/mapper/OpeWorkOrderMapper.xml
@@ -5,22 +5,22 @@
    <!--@mbg.generated-->
    <!--@Table ope_work_order-->
    <id column="id" jdbcType="BIGINT" property="id" />
    <result column="dispatcher" jdbcType="BIGINT" property="dispatcher" />
    <result column="inspector" jdbcType="BIGINT" property="inspector" />
    <result column="task_type" jdbcType="TINYINT" property="taskType" />
    <result column="dispatcher_id" jdbcType="BIGINT" property="dispatcherId" />
    <result column="inspector_id" jdbcType="BIGINT" property="inspectorId" />
    <result column="task_type_id" jdbcType="BIGINT" property="taskTypeId" />
    <result column="task_content" jdbcType="VARCHAR" property="taskContent" />
    <result column="complete_criteria" jdbcType="VARCHAR" property="completeCriteria" />
    <result column="dead_line" jdbcType="TIMESTAMP" property="deadLine" />
    <result column="dispatch_time" jdbcType="TIMESTAMP" property="dispatchTime" />
    <result column="task_result" jdbcType="TINYINT" property="taskResult" />
    <result column="photos" jdbcType="VARCHAR" property="photos" />
    <result column="complete_time" jdbcType="TIMESTAMP" property="completeTime" />
    <result column="dispatch_time" jdbcType="TIMESTAMP" property="dispatchTime" />
    <result column="state" jdbcType="TINYINT" property="state" />
    <result column="reject_times" jdbcType="INTEGER" property="rejectTimes" />
    <result column="deleted" jdbcType="BIGINT" property="deleted" />
  </resultMap>
  <sql id="Base_Column_List">
    <!--@mbg.generated-->
    id, dispatcher, inspector, task_type, task_content, complete_criteria, dead_line,
    dispatch_time, task_result, photos, complete_time, deleted
    id, dispatcher_id, inspector_id, task_type_id, task_content, complete_criteria, dead_line,
    complete_time, dispatch_time, `state`, reject_times, deleted
  </sql>
  <select id="selectByPrimaryKey" parameterType="java.lang.Long" resultMap="BaseResultMap">
    <!--@mbg.generated-->
@@ -36,15 +36,15 @@
  </delete>
  <insert id="insert" parameterType="com.dy.pipIrrGlobal.pojoOp.OpeWorkOrder">
    <!--@mbg.generated-->
    insert into ope_work_order (id, dispatcher, inspector,
      task_type, task_content, complete_criteria,
      dead_line, dispatch_time, task_result,
      photos, complete_time, deleted
    insert into ope_work_order (id, dispatcher_id, inspector_id,
      task_type_id, task_content, complete_criteria,
      dead_line, complete_time, dispatch_time,
      `state`, reject_times, deleted
      )
    values (#{id,jdbcType=BIGINT}, #{dispatcher,jdbcType=BIGINT}, #{inspector,jdbcType=BIGINT},
      #{taskType,jdbcType=TINYINT}, #{taskContent,jdbcType=VARCHAR}, #{completeCriteria,jdbcType=VARCHAR},
      #{deadLine,jdbcType=TIMESTAMP}, #{dispatchTime,jdbcType=TIMESTAMP}, #{taskResult,jdbcType=TINYINT},
      #{photos,jdbcType=VARCHAR}, #{completeTime,jdbcType=TIMESTAMP}, #{deleted,jdbcType=BIGINT}
    values (#{id,jdbcType=BIGINT}, #{dispatcherId,jdbcType=BIGINT}, #{inspectorId,jdbcType=BIGINT},
      #{taskTypeId,jdbcType=BIGINT}, #{taskContent,jdbcType=VARCHAR}, #{completeCriteria,jdbcType=VARCHAR},
      #{deadLine,jdbcType=TIMESTAMP}, #{completeTime,jdbcType=TIMESTAMP}, #{dispatchTime,jdbcType=TIMESTAMP},
      #{state,jdbcType=TINYINT}, #{rejectTimes,jdbcType=INTEGER}, #{deleted,jdbcType=BIGINT}
      )
  </insert>
  <insert id="insertSelective" parameterType="com.dy.pipIrrGlobal.pojoOp.OpeWorkOrder">
@@ -54,14 +54,14 @@
      <if test="id != null">
        id,
      </if>
      <if test="dispatcher != null">
        dispatcher,
      <if test="dispatcherId != null">
        dispatcher_id,
      </if>
      <if test="inspector != null">
        inspector,
      <if test="inspectorId != null">
        inspector_id,
      </if>
      <if test="taskType != null">
        task_type,
      <if test="taskTypeId != null">
        task_type_id,
      </if>
      <if test="taskContent != null">
        task_content,
@@ -72,17 +72,17 @@
      <if test="deadLine != null">
        dead_line,
      </if>
      <if test="completeTime != null">
        complete_time,
      </if>
      <if test="dispatchTime != null">
        dispatch_time,
      </if>
      <if test="taskResult != null">
        task_result,
      <if test="state != null">
        `state`,
      </if>
      <if test="photos != null">
        photos,
      </if>
      <if test="completeTime != null">
        complete_time,
      <if test="rejectTimes != null">
        reject_times,
      </if>
      <if test="deleted != null">
        deleted,
@@ -92,14 +92,14 @@
      <if test="id != null">
        #{id,jdbcType=BIGINT},
      </if>
      <if test="dispatcher != null">
        #{dispatcher,jdbcType=BIGINT},
      <if test="dispatcherId != null">
        #{dispatcherId,jdbcType=BIGINT},
      </if>
      <if test="inspector != null">
        #{inspector,jdbcType=BIGINT},
      <if test="inspectorId != null">
        #{inspectorId,jdbcType=BIGINT},
      </if>
      <if test="taskType != null">
        #{taskType,jdbcType=TINYINT},
      <if test="taskTypeId != null">
        #{taskTypeId,jdbcType=BIGINT},
      </if>
      <if test="taskContent != null">
        #{taskContent,jdbcType=VARCHAR},
@@ -110,17 +110,17 @@
      <if test="deadLine != null">
        #{deadLine,jdbcType=TIMESTAMP},
      </if>
      <if test="completeTime != null">
        #{completeTime,jdbcType=TIMESTAMP},
      </if>
      <if test="dispatchTime != null">
        #{dispatchTime,jdbcType=TIMESTAMP},
      </if>
      <if test="taskResult != null">
        #{taskResult,jdbcType=TINYINT},
      <if test="state != null">
        #{state,jdbcType=TINYINT},
      </if>
      <if test="photos != null">
        #{photos,jdbcType=VARCHAR},
      </if>
      <if test="completeTime != null">
        #{completeTime,jdbcType=TIMESTAMP},
      <if test="rejectTimes != null">
        #{rejectTimes,jdbcType=INTEGER},
      </if>
      <if test="deleted != null">
        #{deleted,jdbcType=BIGINT},
@@ -131,14 +131,14 @@
    <!--@mbg.generated-->
    update ope_work_order
    <set>
      <if test="dispatcher != null">
        dispatcher = #{dispatcher,jdbcType=BIGINT},
      <if test="dispatcherId != null">
        dispatcher_id = #{dispatcherId,jdbcType=BIGINT},
      </if>
      <if test="inspector != null">
        inspector = #{inspector,jdbcType=BIGINT},
      <if test="inspectorId != null">
        inspector_id = #{inspectorId,jdbcType=BIGINT},
      </if>
      <if test="taskType != null">
        task_type = #{taskType,jdbcType=TINYINT},
      <if test="taskTypeId != null">
        task_type_id = #{taskTypeId,jdbcType=BIGINT},
      </if>
      <if test="taskContent != null">
        task_content = #{taskContent,jdbcType=VARCHAR},
@@ -149,17 +149,17 @@
      <if test="deadLine != null">
        dead_line = #{deadLine,jdbcType=TIMESTAMP},
      </if>
      <if test="completeTime != null">
        complete_time = #{completeTime,jdbcType=TIMESTAMP},
      </if>
      <if test="dispatchTime != null">
        dispatch_time = #{dispatchTime,jdbcType=TIMESTAMP},
      </if>
      <if test="taskResult != null">
        task_result = #{taskResult,jdbcType=TINYINT},
      <if test="state != null">
        `state` = #{state,jdbcType=TINYINT},
      </if>
      <if test="photos != null">
        photos = #{photos,jdbcType=VARCHAR},
      </if>
      <if test="completeTime != null">
        complete_time = #{completeTime,jdbcType=TIMESTAMP},
      <if test="rejectTimes != null">
        reject_times = #{rejectTimes,jdbcType=INTEGER},
      </if>
      <if test="deleted != null">
        deleted = #{deleted,jdbcType=BIGINT},
@@ -170,16 +170,16 @@
  <update id="updateByPrimaryKey" parameterType="com.dy.pipIrrGlobal.pojoOp.OpeWorkOrder">
    <!--@mbg.generated-->
    update ope_work_order
    set dispatcher = #{dispatcher,jdbcType=BIGINT},
      inspector = #{inspector,jdbcType=BIGINT},
      task_type = #{taskType,jdbcType=TINYINT},
    set dispatcher_id = #{dispatcherId,jdbcType=BIGINT},
      inspector_id = #{inspectorId,jdbcType=BIGINT},
      task_type_id = #{taskTypeId,jdbcType=BIGINT},
      task_content = #{taskContent,jdbcType=VARCHAR},
      complete_criteria = #{completeCriteria,jdbcType=VARCHAR},
      dead_line = #{deadLine,jdbcType=TIMESTAMP},
      dispatch_time = #{dispatchTime,jdbcType=TIMESTAMP},
      task_result = #{taskResult,jdbcType=TINYINT},
      photos = #{photos,jdbcType=VARCHAR},
      complete_time = #{completeTime,jdbcType=TIMESTAMP},
      dispatch_time = #{dispatchTime,jdbcType=TIMESTAMP},
      `state` = #{state,jdbcType=TINYINT},
      reject_times = #{rejectTimes,jdbcType=INTEGER},
      deleted = #{deleted,jdbcType=BIGINT}
    where id = #{id,jdbcType=BIGINT}
  </update>