Bladeren bron

更新清空命令接口以及列表接口和下发报文注释代码

wutt 5 jaren geleden
bovenliggende
commit
424a10770b

+ 142 - 0
cloud-model/src/main/java/com/hssx/cloudmodel/entity/EquipmentSendCommand.java

@@ -0,0 +1,142 @@
+package com.hssx.cloudmodel.entity;
+
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.extension.activerecord.Model;
+import com.baomidou.mybatisplus.annotation.TableId;
+import java.time.LocalDateTime;
+import com.baomidou.mybatisplus.annotation.TableField;
+import com.fasterxml.jackson.annotation.JsonFormat;
+
+import java.io.Serializable;
+
+/**
+ * <p>
+ * 
+ * </p>
+ *
+ * @author 吴涛涛
+ * @since 2020-03-19
+ */
+public class EquipmentSendCommand extends Model<EquipmentSendCommand> {
+
+    private static final long serialVersionUID=1L;
+
+    /**
+     * 清空次数表主键
+     */
+    @TableId(value = "id", type = IdType.AUTO)
+    private Integer id;
+
+    /**
+     * 设备编号
+     */
+    @TableField("equipment_no")
+    private String equipmentNo;
+
+    /**
+     * 设置下发人的id
+     */
+    @TableField("uid")
+    private Integer uid;
+
+    /**
+     * 设置下发命令的时间
+     */
+    @TableField("indate")
+    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
+    private LocalDateTime indate;
+
+    /**
+     * 实际下发的时间
+     */
+    @TableField("send_time")
+    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
+    private LocalDateTime sendTime;
+
+    /**
+     * 操作状态0-清空,1-。。。
+     */
+    @TableField("state")
+    private Integer state;
+
+    /**
+     * 是否已下发0-未,1-已
+     */
+    @TableField("is_send")
+    private Integer isSend;
+
+
+    public Integer getId() {
+        return id;
+    }
+
+    public void setId(Integer id) {
+        this.id = id;
+    }
+
+    public String getEquipmentNo() {
+        return equipmentNo;
+    }
+
+    public void setEquipmentNo(String equipmentNo) {
+        this.equipmentNo = equipmentNo;
+    }
+
+    public Integer getUid() {
+        return uid;
+    }
+
+    public void setUid(Integer uid) {
+        this.uid = uid;
+    }
+
+    public LocalDateTime getIndate() {
+        return indate;
+    }
+
+    public void setIndate(LocalDateTime indate) {
+        this.indate = indate;
+    }
+
+    public LocalDateTime getSendTime() {
+        return sendTime;
+    }
+
+    public void setSendTime(LocalDateTime sendTime) {
+        this.sendTime = sendTime;
+    }
+
+    public Integer getState() {
+        return state;
+    }
+
+    public void setState(Integer state) {
+        this.state = state;
+    }
+
+    public Integer getIsSend() {
+        return isSend;
+    }
+
+    public void setIsSend(Integer isSend) {
+        this.isSend = isSend;
+    }
+
+    @Override
+    protected Serializable pkVal() {
+        return this.id;
+    }
+
+    @Override
+    public String toString() {
+        return "EquipmentSendCommand{" +
+        "id=" + id +
+        ", equipmentNo=" + equipmentNo +
+        ", uid=" + uid +
+        ", indate=" + indate +
+        ", sendTime=" + sendTime +
+        ", state=" + state +
+        ", isSend=" + isSend +
+        "}";
+    }
+}

+ 22 - 0
cloud-model/src/main/java/com/hssx/cloudmodel/mapper/EquipmentSendCommandMapper.java

@@ -0,0 +1,22 @@
+package com.hssx.cloudmodel.mapper;
+
+import com.hssx.cloudmodel.entity.EquipmentSendCommand;
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import org.apache.ibatis.annotations.Param;
+
+import javax.validation.constraints.Pattern;
+import java.util.List;
+import java.util.Map;
+
+/**
+ * <p>
+ *  Mapper 接口
+ * </p>
+ *
+ * @author 吴涛涛
+ * @since 2020-03-19
+ */
+public interface EquipmentSendCommandMapper extends BaseMapper<EquipmentSendCommand> {
+
+    List<Map<String,Object>> getList(@Param("list") List<String>equipmentSendCommand);
+}

+ 24 - 0
cloud-model/src/main/java/com/hssx/cloudmodel/service/EquipmentSendCommandService.java

@@ -0,0 +1,24 @@
+package com.hssx.cloudmodel.service;
+
+import com.hssx.cloudmodel.entity.EquipmentSendCommand;
+import com.baomidou.mybatisplus.extension.service.IService;
+import com.hssx.cloudmodel.mapper.EquipmentSendCommandMapper;
+import com.hssx.cloudmodel.util.HttpRespMsg;
+import com.hssx.cloudmodel.util.PageUtil;
+
+import javax.annotation.Resource;
+
+/**
+ * <p>
+ *  服务类
+ * </p>
+ *
+ * @author 吴涛涛
+ * @since 2020-03-19
+ */
+public interface EquipmentSendCommandService extends IService<EquipmentSendCommand> {
+
+    HttpRespMsg sendCommand(EquipmentSendCommand equipmentSendCommand);
+
+    HttpRespMsg sendCommandList(EquipmentSendCommand equipmentSendCommand, PageUtil page, String token);
+}

+ 133 - 0
cloud-model/src/main/java/com/hssx/cloudmodel/service/impl/EquipmentSendCommandServiceImpl.java

@@ -0,0 +1,133 @@
+package com.hssx.cloudmodel.service.impl;
+
+import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
+import com.github.pagehelper.PageHelper;
+import com.github.pagehelper.PageInfo;
+import com.hssx.cloudmodel.constant.Constant;
+import com.hssx.cloudmodel.entity.*;
+import com.hssx.cloudmodel.entity.vo.MouldVO;
+import com.hssx.cloudmodel.mapper.*;
+import com.hssx.cloudmodel.service.EquipmentSendCommandService;
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import com.hssx.cloudmodel.util.HttpRespMsg;
+import com.hssx.cloudmodel.util.PageUtil;
+import org.springframework.stereotype.Service;
+import org.springframework.transaction.annotation.Transactional;
+import org.springframework.util.CollectionUtils;
+
+import javax.annotation.Resource;
+import java.util.ArrayList;
+import java.util.List;
+import java.util.Map;
+import java.util.stream.Collectors;
+
+/**
+ * <p>
+ * 服务实现类
+ * </p>
+ *
+ * @author 吴涛涛
+ * @since 2020-03-19
+ */
+@Transactional
+@Service
+public class EquipmentSendCommandServiceImpl extends ServiceImpl<EquipmentSendCommandMapper, EquipmentSendCommand> implements EquipmentSendCommandService {
+
+    @Resource
+    private EquipmentSendCommandMapper equipmentSendCommandMapper;
+    @Resource
+    private UserMapper userMapper;
+    @Resource
+    ProjectMapper projectMapper;
+    @Resource
+    ProjectUserMapper projectUserMapper;
+    @Resource
+    CustomCompanyMapper customCompanyMapper;
+    @Resource
+    MouldMapper mouldMapper;
+    @Resource
+    ProjectApproveMapper projectApproveMapper;
+    @Resource
+    private MouldEquipmentMapper mouldEquipmentMapper;
+
+
+    @Override
+    public HttpRespMsg sendCommand(EquipmentSendCommand equipmentSendCommand) {
+        HttpRespMsg msg = new HttpRespMsg();
+        equipmentSendCommandMapper.insert(equipmentSendCommand);
+        return msg;
+    }
+
+    @Override
+    public HttpRespMsg sendCommandList(EquipmentSendCommand equipmentSendCommand, PageUtil page, String token) {
+        HttpRespMsg msg = new HttpRespMsg();
+        User user = userMapper.selectOne(new QueryWrapper<User>().eq("head_imgurl", token));
+        if (user == null) {
+            msg.setError("用户不存在");
+            return msg;
+        }
+        List<Integer> set = new ArrayList<>();
+        List<Mould> moulds = new ArrayList<>();
+        //用於接受最後數據的集合
+        List<Map<String, Object>> list = new ArrayList<>();
+        //分頁接受的數據
+        PageInfo<Map<String,Object>> pageInfo = new PageInfo<Map<String,Object>>();
+        //资产方管理员,获取他公司下的所有模具
+        if (Constant.SYS_PARENT_ID.equals(user.getParentId())) {
+            //超级管理员,获取平台所有模具
+            moulds = mouldMapper.selectList(null);
+        } else if (Constant.SYS_ID.equals(user.getParentId())) {
+            if (Constant.ASSETS_COMPANY.equals(user.getSubordinateType())) {
+                //资产方管理员
+                moulds = mouldMapper.selectList(new QueryWrapper<Mould>().eq("company_id", user.getCompanyId()));
+            } else if (Constant.PRODUCER_COMPANY.equals(user.getSubordinateType())) {
+                set = customCompanyMapper.selectList(new QueryWrapper<CustomCompany>().eq("company_id", user.getCompanyId())).stream().map(CustomCompany::getProjectId).collect(Collectors.toList());
+                set.add(-1);
+                moulds = mouldMapper.selectList(new QueryWrapper<Mould>().in("project_id", set));
+            }
+        } else {
+            //普通用户或者项目经理
+            //充当项目经理参与的项目
+//                if (userVO.getProjectId() != -1) {
+//                    set.add(userVO.getProjectId());
+//                    set.add(-1);
+//                    moulds = mouldMapper.selectListByConditionByProject(userVO, set);
+//                } else {
+            QueryWrapper<Project> qw = new QueryWrapper<>();
+            qw.eq("manager_id", user.getId());
+            List<Project> projects = projectMapper.selectList(qw);
+            if (projects.size() > 0) {
+                for (Project project : projects) {
+                    set.add(project.getId());
+                }
+            }
+//                //充当普通人员参与的项目
+            List<ProjectUser> projectUsers = projectUserMapper.selectList(new QueryWrapper<ProjectUser>().eq("user_id", user.getId()));
+            if (projectUsers.size() > 0) {
+                for (ProjectUser projectUser : projectUsers) {
+                    set.add(projectUser.getProjectId());
+                }
+            }
+//                //充当审批人员参与的项目
+            List<ProjectApprove> projectss = projectApproveMapper.selectList(new QueryWrapper<ProjectApprove>().eq("approver_id", user.getId()));
+            if (projectss.size() > 0) {
+                for (ProjectApprove projectUser : projectss) {
+                    set.add(projectUser.getProjectId());
+                }
+            }
+            set.add(-1);
+            moulds = mouldMapper.selectList(new QueryWrapper<Mould>().in("project_id", set));
+        }
+        List<Integer> equipmentIds = moulds.stream().map(Mould::getEquipmentId).collect(Collectors.toList());
+        if(!CollectionUtils.isEmpty(equipmentIds)){
+            List<String> quipmentNOs = mouldEquipmentMapper.selectList(new QueryWrapper<MouldEquipment>().in("id", equipmentIds)).stream().map(MouldEquipment::getEquipmentNo).collect(Collectors.toList());
+            System.out.println("quipmentNOs"+quipmentNOs);
+            PageHelper.startPage(page.getPageNum(), page.getPageSize());
+            List<Map<String, Object>> equipmentSendCommandList = equipmentSendCommandMapper.getList(quipmentNOs);
+            pageInfo = new PageInfo<Map<String, Object>>(equipmentSendCommandList);
+            msg.data = equipmentSendCommandList;
+        }
+
+        return msg;
+    }
+}

+ 39 - 0
cloud-model/src/main/resources/mapper/EquipmentSendCommandMapper.xml

@@ -0,0 +1,39 @@
+<?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.hssx.cloudmodel.mapper.EquipmentSendCommandMapper">
+
+    <!-- 通用查询映射结果 -->
+    <resultMap id="BaseResultMap" type="com.hssx.cloudmodel.entity.EquipmentSendCommand">
+        <id column="id" property="id" />
+        <result column="equipment_no" property="equipmentNo" />
+        <result column="uid" property="uid" />
+        <result column="indate" property="indate" />
+        <result column="send_time" property="sendTime" />
+        <result column="state" property="state" />
+        <result column="is_send" property="isSend" />
+    </resultMap>
+
+    <!-- 通用查询结果列 -->
+    <sql id="Base_Column_List">
+        id, equipment_no, uid, indate, send_time, state, is_send
+    </sql>
+
+    <select id="getList" resultType="java.util.Map">
+        select
+            esc.id, esc.equipment_no, esc.uid, DATE_FORMAT(esc.indate,'%Y-%m-%d %H:%m:%s') indate, DATE_FORMAT(esc.send_time,'%Y-%m-%d %H:%m:%s') send_time, esc.state, esc.is_send, tu.username
+        from
+            equipment_send_command esc
+        left join
+            tb_user tu
+        on
+            tu.id = esc.uid
+        <where>
+            esc.equipment_no in
+                <foreach collection="list" separator="," item="item" index="index" open="(" close=")">
+                    #{item}
+                </foreach>
+        </where>
+            order by indate desc
+    </select>
+
+</mapper>

+ 96 - 0
cloud-socket/src/com/js/kbt/mapper/EquipmentSendCommandMapper.java

@@ -0,0 +1,96 @@
+package com.js.kbt.mapper;
+
+import com.js.kbt.model.EquipmentSendCommand;
+import com.js.kbt.model.EquipmentSendCommandExample;
+import java.util.List;
+import org.apache.ibatis.annotations.Param;
+
+public interface EquipmentSendCommandMapper {
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table equipment_send_command
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    long countByExample(EquipmentSendCommandExample example);
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table equipment_send_command
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    int deleteByExample(EquipmentSendCommandExample example);
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table equipment_send_command
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    int deleteByPrimaryKey(Integer id);
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table equipment_send_command
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    int insert(EquipmentSendCommand record);
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table equipment_send_command
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    int insertSelective(EquipmentSendCommand record);
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table equipment_send_command
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    List<EquipmentSendCommand> selectByExample(EquipmentSendCommandExample example);
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table equipment_send_command
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    EquipmentSendCommand selectByPrimaryKey(Integer id);
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table equipment_send_command
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    int updateByExampleSelective(@Param("record") EquipmentSendCommand record, @Param("example") EquipmentSendCommandExample example);
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table equipment_send_command
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    int updateByExample(@Param("record") EquipmentSendCommand record, @Param("example") EquipmentSendCommandExample example);
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table equipment_send_command
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    int updateByPrimaryKeySelective(EquipmentSendCommand record);
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table equipment_send_command
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    int updateByPrimaryKey(EquipmentSendCommand record);
+}

+ 318 - 0
cloud-socket/src/com/js/kbt/mapper/EquipmentSendCommandMapper.xml

@@ -0,0 +1,318 @@
+<?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.js.kbt.mapper.EquipmentSendCommandMapper">
+  <resultMap id="BaseResultMap" type="com.js.kbt.model.EquipmentSendCommand">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Thu Mar 19 13:16:30 CST 2020.
+    -->
+    <id column="id" jdbcType="INTEGER" property="id" />
+    <result column="equipment_no" jdbcType="VARCHAR" property="equipmentNo" />
+    <result column="uid" jdbcType="INTEGER" property="uid" />
+    <result column="indate" jdbcType="TIMESTAMP" property="indate" />
+    <result column="send_time" jdbcType="TIMESTAMP" property="sendTime" />
+    <result column="state" jdbcType="INTEGER" property="state" />
+    <result column="is_send" jdbcType="INTEGER" property="isSend" />
+  </resultMap>
+  <sql id="Example_Where_Clause">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Thu Mar 19 13:16:30 CST 2020.
+    -->
+    <where>
+      <foreach collection="oredCriteria" item="criteria" separator="or">
+        <if test="criteria.valid">
+          <trim prefix="(" prefixOverrides="and" suffix=")">
+            <foreach collection="criteria.criteria" item="criterion">
+              <choose>
+                <when test="criterion.noValue">
+                  and ${criterion.condition}
+                </when>
+                <when test="criterion.singleValue">
+                  and ${criterion.condition} #{criterion.value}
+                </when>
+                <when test="criterion.betweenValue">
+                  and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
+                </when>
+                <when test="criterion.listValue">
+                  and ${criterion.condition}
+                  <foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
+                    #{listItem}
+                  </foreach>
+                </when>
+              </choose>
+            </foreach>
+          </trim>
+        </if>
+      </foreach>
+    </where>
+  </sql>
+  <sql id="Update_By_Example_Where_Clause">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Thu Mar 19 13:16:30 CST 2020.
+    -->
+    <where>
+      <foreach collection="example.oredCriteria" item="criteria" separator="or">
+        <if test="criteria.valid">
+          <trim prefix="(" prefixOverrides="and" suffix=")">
+            <foreach collection="criteria.criteria" item="criterion">
+              <choose>
+                <when test="criterion.noValue">
+                  and ${criterion.condition}
+                </when>
+                <when test="criterion.singleValue">
+                  and ${criterion.condition} #{criterion.value}
+                </when>
+                <when test="criterion.betweenValue">
+                  and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
+                </when>
+                <when test="criterion.listValue">
+                  and ${criterion.condition}
+                  <foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
+                    #{listItem}
+                  </foreach>
+                </when>
+              </choose>
+            </foreach>
+          </trim>
+        </if>
+      </foreach>
+    </where>
+  </sql>
+  <sql id="Base_Column_List">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Thu Mar 19 13:16:30 CST 2020.
+    -->
+    id, equipment_no, uid, indate, send_time, state, is_send
+  </sql>
+  <select id="selectByExample" parameterType="com.js.kbt.model.EquipmentSendCommandExample" resultMap="BaseResultMap">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Thu Mar 19 13:16:30 CST 2020.
+    -->
+    select
+    <if test="distinct">
+      distinct
+    </if>
+    <include refid="Base_Column_List" />
+    from equipment_send_command
+    <if test="_parameter != null">
+      <include refid="Example_Where_Clause" />
+    </if>
+    <if test="orderByClause != null">
+      order by ${orderByClause}
+    </if>
+  </select>
+  <select id="selectByPrimaryKey" parameterType="java.lang.Integer" resultMap="BaseResultMap">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Thu Mar 19 13:16:30 CST 2020.
+    -->
+    select 
+    <include refid="Base_Column_List" />
+    from equipment_send_command
+    where id = #{id,jdbcType=INTEGER}
+  </select>
+  <delete id="deleteByPrimaryKey" parameterType="java.lang.Integer">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Thu Mar 19 13:16:30 CST 2020.
+    -->
+    delete from equipment_send_command
+    where id = #{id,jdbcType=INTEGER}
+  </delete>
+  <delete id="deleteByExample" parameterType="com.js.kbt.model.EquipmentSendCommandExample">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Thu Mar 19 13:16:30 CST 2020.
+    -->
+    delete from equipment_send_command
+    <if test="_parameter != null">
+      <include refid="Example_Where_Clause" />
+    </if>
+  </delete>
+  <insert id="insert" parameterType="com.js.kbt.model.EquipmentSendCommand">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Thu Mar 19 13:16:30 CST 2020.
+    -->
+    <selectKey keyProperty="id" order="AFTER" resultType="java.lang.Integer">
+      SELECT LAST_INSERT_ID()
+    </selectKey>
+    insert into equipment_send_command (equipment_no, uid, indate, 
+      send_time, state, is_send
+      )
+    values (#{equipmentNo,jdbcType=VARCHAR}, #{uid,jdbcType=INTEGER}, #{indate,jdbcType=TIMESTAMP}, 
+      #{sendTime,jdbcType=TIMESTAMP}, #{state,jdbcType=INTEGER}, #{isSend,jdbcType=INTEGER}
+      )
+  </insert>
+  <insert id="insertSelective" parameterType="com.js.kbt.model.EquipmentSendCommand">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Thu Mar 19 13:16:30 CST 2020.
+    -->
+    <selectKey keyProperty="id" order="AFTER" resultType="java.lang.Integer">
+      SELECT LAST_INSERT_ID()
+    </selectKey>
+    insert into equipment_send_command
+    <trim prefix="(" suffix=")" suffixOverrides=",">
+      <if test="equipmentNo != null">
+        equipment_no,
+      </if>
+      <if test="uid != null">
+        uid,
+      </if>
+      <if test="indate != null">
+        indate,
+      </if>
+      <if test="sendTime != null">
+        send_time,
+      </if>
+      <if test="state != null">
+        state,
+      </if>
+      <if test="isSend != null">
+        is_send,
+      </if>
+    </trim>
+    <trim prefix="values (" suffix=")" suffixOverrides=",">
+      <if test="equipmentNo != null">
+        #{equipmentNo,jdbcType=VARCHAR},
+      </if>
+      <if test="uid != null">
+        #{uid,jdbcType=INTEGER},
+      </if>
+      <if test="indate != null">
+        #{indate,jdbcType=TIMESTAMP},
+      </if>
+      <if test="sendTime != null">
+        #{sendTime,jdbcType=TIMESTAMP},
+      </if>
+      <if test="state != null">
+        #{state,jdbcType=INTEGER},
+      </if>
+      <if test="isSend != null">
+        #{isSend,jdbcType=INTEGER},
+      </if>
+    </trim>
+  </insert>
+  <select id="countByExample" parameterType="com.js.kbt.model.EquipmentSendCommandExample" resultType="java.lang.Long">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Thu Mar 19 13:16:30 CST 2020.
+    -->
+    select count(*) from equipment_send_command
+    <if test="_parameter != null">
+      <include refid="Example_Where_Clause" />
+    </if>
+  </select>
+  <update id="updateByExampleSelective" parameterType="map">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Thu Mar 19 13:16:30 CST 2020.
+    -->
+    update equipment_send_command
+    <set>
+      <if test="record.id != null">
+        id = #{record.id,jdbcType=INTEGER},
+      </if>
+      <if test="record.equipmentNo != null">
+        equipment_no = #{record.equipmentNo,jdbcType=VARCHAR},
+      </if>
+      <if test="record.uid != null">
+        uid = #{record.uid,jdbcType=INTEGER},
+      </if>
+      <if test="record.indate != null">
+        indate = #{record.indate,jdbcType=TIMESTAMP},
+      </if>
+      <if test="record.sendTime != null">
+        send_time = #{record.sendTime,jdbcType=TIMESTAMP},
+      </if>
+      <if test="record.state != null">
+        state = #{record.state,jdbcType=INTEGER},
+      </if>
+      <if test="record.isSend != null">
+        is_send = #{record.isSend,jdbcType=INTEGER},
+      </if>
+    </set>
+    <if test="_parameter != null">
+      <include refid="Update_By_Example_Where_Clause" />
+    </if>
+  </update>
+  <update id="updateByExample" parameterType="map">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Thu Mar 19 13:16:30 CST 2020.
+    -->
+    update equipment_send_command
+    set id = #{record.id,jdbcType=INTEGER},
+      equipment_no = #{record.equipmentNo,jdbcType=VARCHAR},
+      uid = #{record.uid,jdbcType=INTEGER},
+      indate = #{record.indate,jdbcType=TIMESTAMP},
+      send_time = #{record.sendTime,jdbcType=TIMESTAMP},
+      state = #{record.state,jdbcType=INTEGER},
+      is_send = #{record.isSend,jdbcType=INTEGER}
+    <if test="_parameter != null">
+      <include refid="Update_By_Example_Where_Clause" />
+    </if>
+  </update>
+  <update id="updateByPrimaryKeySelective" parameterType="com.js.kbt.model.EquipmentSendCommand">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Thu Mar 19 13:16:30 CST 2020.
+    -->
+    update equipment_send_command
+    <set>
+      <if test="equipmentNo != null">
+        equipment_no = #{equipmentNo,jdbcType=VARCHAR},
+      </if>
+      <if test="uid != null">
+        uid = #{uid,jdbcType=INTEGER},
+      </if>
+      <if test="indate != null">
+        indate = #{indate,jdbcType=TIMESTAMP},
+      </if>
+      <if test="sendTime != null">
+        send_time = #{sendTime,jdbcType=TIMESTAMP},
+      </if>
+      <if test="state != null">
+        state = #{state,jdbcType=INTEGER},
+      </if>
+      <if test="isSend != null">
+        is_send = #{isSend,jdbcType=INTEGER},
+      </if>
+    </set>
+    where id = #{id,jdbcType=INTEGER}
+  </update>
+  <update id="updateByPrimaryKey" parameterType="com.js.kbt.model.EquipmentSendCommand">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Thu Mar 19 13:16:30 CST 2020.
+    -->
+    update equipment_send_command
+    set equipment_no = #{equipmentNo,jdbcType=VARCHAR},
+      uid = #{uid,jdbcType=INTEGER},
+      indate = #{indate,jdbcType=TIMESTAMP},
+      send_time = #{sendTime,jdbcType=TIMESTAMP},
+      state = #{state,jdbcType=INTEGER},
+      is_send = #{isSend,jdbcType=INTEGER}
+    where id = #{id,jdbcType=INTEGER}
+  </update>
+</mapper>

+ 236 - 0
cloud-socket/src/com/js/kbt/model/EquipmentSendCommand.java

@@ -0,0 +1,236 @@
+package com.js.kbt.model;
+
+import java.util.Date;
+
+public class EquipmentSendCommand {
+    /**
+     *
+     * This field was generated by MyBatis Generator.
+     * This field corresponds to the database column equipment_send_command.id
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    private Integer id;
+
+    /**
+     *
+     * This field was generated by MyBatis Generator.
+     * This field corresponds to the database column equipment_send_command.equipment_no
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    private String equipmentNo;
+
+    /**
+     *
+     * This field was generated by MyBatis Generator.
+     * This field corresponds to the database column equipment_send_command.uid
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    private Integer uid;
+
+    /**
+     *
+     * This field was generated by MyBatis Generator.
+     * This field corresponds to the database column equipment_send_command.indate
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    private Date indate;
+
+    /**
+     *
+     * This field was generated by MyBatis Generator.
+     * This field corresponds to the database column equipment_send_command.send_time
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    private Date sendTime;
+
+    /**
+     *
+     * This field was generated by MyBatis Generator.
+     * This field corresponds to the database column equipment_send_command.state
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    private Integer state;
+
+    /**
+     *
+     * This field was generated by MyBatis Generator.
+     * This field corresponds to the database column equipment_send_command.is_send
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    private Integer isSend;
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method returns the value of the database column equipment_send_command.id
+     *
+     * @return the value of equipment_send_command.id
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    public Integer getId() {
+        return id;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method sets the value of the database column equipment_send_command.id
+     *
+     * @param id the value for equipment_send_command.id
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    public void setId(Integer id) {
+        this.id = id;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method returns the value of the database column equipment_send_command.equipment_no
+     *
+     * @return the value of equipment_send_command.equipment_no
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    public String getEquipmentNo() {
+        return equipmentNo;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method sets the value of the database column equipment_send_command.equipment_no
+     *
+     * @param equipmentNo the value for equipment_send_command.equipment_no
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    public void setEquipmentNo(String equipmentNo) {
+        this.equipmentNo = equipmentNo;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method returns the value of the database column equipment_send_command.uid
+     *
+     * @return the value of equipment_send_command.uid
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    public Integer getUid() {
+        return uid;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method sets the value of the database column equipment_send_command.uid
+     *
+     * @param uid the value for equipment_send_command.uid
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    public void setUid(Integer uid) {
+        this.uid = uid;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method returns the value of the database column equipment_send_command.indate
+     *
+     * @return the value of equipment_send_command.indate
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    public Date getIndate() {
+        return indate;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method sets the value of the database column equipment_send_command.indate
+     *
+     * @param indate the value for equipment_send_command.indate
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    public void setIndate(Date indate) {
+        this.indate = indate;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method returns the value of the database column equipment_send_command.send_time
+     *
+     * @return the value of equipment_send_command.send_time
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    public Date getSendTime() {
+        return sendTime;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method sets the value of the database column equipment_send_command.send_time
+     *
+     * @param sendTime the value for equipment_send_command.send_time
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    public void setSendTime(Date sendTime) {
+        this.sendTime = sendTime;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method returns the value of the database column equipment_send_command.state
+     *
+     * @return the value of equipment_send_command.state
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    public Integer getState() {
+        return state;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method sets the value of the database column equipment_send_command.state
+     *
+     * @param state the value for equipment_send_command.state
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    public void setState(Integer state) {
+        this.state = state;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method returns the value of the database column equipment_send_command.is_send
+     *
+     * @return the value of equipment_send_command.is_send
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    public Integer getIsSend() {
+        return isSend;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method sets the value of the database column equipment_send_command.is_send
+     *
+     * @param isSend the value for equipment_send_command.is_send
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    public void setIsSend(Integer isSend) {
+        this.isSend = isSend;
+    }
+}

+ 733 - 0
cloud-socket/src/com/js/kbt/model/EquipmentSendCommandExample.java

@@ -0,0 +1,733 @@
+package com.js.kbt.model;
+
+import java.util.ArrayList;
+import java.util.Date;
+import java.util.List;
+
+public class EquipmentSendCommandExample {
+    /**
+     * This field was generated by MyBatis Generator.
+     * This field corresponds to the database table equipment_send_command
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    protected String orderByClause;
+
+    /**
+     * This field was generated by MyBatis Generator.
+     * This field corresponds to the database table equipment_send_command
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    protected boolean distinct;
+
+    /**
+     * This field was generated by MyBatis Generator.
+     * This field corresponds to the database table equipment_send_command
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    protected List<Criteria> oredCriteria;
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table equipment_send_command
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    public EquipmentSendCommandExample() {
+        oredCriteria = new ArrayList<Criteria>();
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table equipment_send_command
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    public void setOrderByClause(String orderByClause) {
+        this.orderByClause = orderByClause;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table equipment_send_command
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    public String getOrderByClause() {
+        return orderByClause;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table equipment_send_command
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    public void setDistinct(boolean distinct) {
+        this.distinct = distinct;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table equipment_send_command
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    public boolean isDistinct() {
+        return distinct;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table equipment_send_command
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    public List<Criteria> getOredCriteria() {
+        return oredCriteria;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table equipment_send_command
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    public void or(Criteria criteria) {
+        oredCriteria.add(criteria);
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table equipment_send_command
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    public Criteria or() {
+        Criteria criteria = createCriteriaInternal();
+        oredCriteria.add(criteria);
+        return criteria;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table equipment_send_command
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    public Criteria createCriteria() {
+        Criteria criteria = createCriteriaInternal();
+        if (oredCriteria.size() == 0) {
+            oredCriteria.add(criteria);
+        }
+        return criteria;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table equipment_send_command
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    protected Criteria createCriteriaInternal() {
+        Criteria criteria = new Criteria();
+        return criteria;
+    }
+
+    /**
+     * This method was generated by MyBatis Generator.
+     * This method corresponds to the database table equipment_send_command
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    public void clear() {
+        oredCriteria.clear();
+        orderByClause = null;
+        distinct = false;
+    }
+
+    /**
+     * This class was generated by MyBatis Generator.
+     * This class corresponds to the database table equipment_send_command
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    protected abstract static class GeneratedCriteria {
+        protected List<Criterion> criteria;
+
+        protected GeneratedCriteria() {
+            super();
+            criteria = new ArrayList<Criterion>();
+        }
+
+        public boolean isValid() {
+            return criteria.size() > 0;
+        }
+
+        public List<Criterion> getAllCriteria() {
+            return criteria;
+        }
+
+        public List<Criterion> getCriteria() {
+            return criteria;
+        }
+
+        protected void addCriterion(String condition) {
+            if (condition == null) {
+                throw new RuntimeException("Value for condition cannot be null");
+            }
+            criteria.add(new Criterion(condition));
+        }
+
+        protected void addCriterion(String condition, Object value, String property) {
+            if (value == null) {
+                throw new RuntimeException("Value for " + property + " cannot be null");
+            }
+            criteria.add(new Criterion(condition, value));
+        }
+
+        protected void addCriterion(String condition, Object value1, Object value2, String property) {
+            if (value1 == null || value2 == null) {
+                throw new RuntimeException("Between values for " + property + " cannot be null");
+            }
+            criteria.add(new Criterion(condition, value1, value2));
+        }
+
+        public Criteria andIdIsNull() {
+            addCriterion("id is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdIsNotNull() {
+            addCriterion("id is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdEqualTo(Integer value) {
+            addCriterion("id =", value, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdNotEqualTo(Integer value) {
+            addCriterion("id <>", value, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdGreaterThan(Integer value) {
+            addCriterion("id >", value, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdGreaterThanOrEqualTo(Integer value) {
+            addCriterion("id >=", value, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdLessThan(Integer value) {
+            addCriterion("id <", value, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdLessThanOrEqualTo(Integer value) {
+            addCriterion("id <=", value, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdIn(List<Integer> values) {
+            addCriterion("id in", values, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdNotIn(List<Integer> values) {
+            addCriterion("id not in", values, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdBetween(Integer value1, Integer value2) {
+            addCriterion("id between", value1, value2, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andIdNotBetween(Integer value1, Integer value2) {
+            addCriterion("id not between", value1, value2, "id");
+            return (Criteria) this;
+        }
+
+        public Criteria andEquipmentNoIsNull() {
+            addCriterion("equipment_no is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andEquipmentNoIsNotNull() {
+            addCriterion("equipment_no is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andEquipmentNoEqualTo(String value) {
+            addCriterion("equipment_no =", value, "equipmentNo");
+            return (Criteria) this;
+        }
+
+        public Criteria andEquipmentNoNotEqualTo(String value) {
+            addCriterion("equipment_no <>", value, "equipmentNo");
+            return (Criteria) this;
+        }
+
+        public Criteria andEquipmentNoGreaterThan(String value) {
+            addCriterion("equipment_no >", value, "equipmentNo");
+            return (Criteria) this;
+        }
+
+        public Criteria andEquipmentNoGreaterThanOrEqualTo(String value) {
+            addCriterion("equipment_no >=", value, "equipmentNo");
+            return (Criteria) this;
+        }
+
+        public Criteria andEquipmentNoLessThan(String value) {
+            addCriterion("equipment_no <", value, "equipmentNo");
+            return (Criteria) this;
+        }
+
+        public Criteria andEquipmentNoLessThanOrEqualTo(String value) {
+            addCriterion("equipment_no <=", value, "equipmentNo");
+            return (Criteria) this;
+        }
+
+        public Criteria andEquipmentNoLike(String value) {
+            addCriterion("equipment_no like", value, "equipmentNo");
+            return (Criteria) this;
+        }
+
+        public Criteria andEquipmentNoNotLike(String value) {
+            addCriterion("equipment_no not like", value, "equipmentNo");
+            return (Criteria) this;
+        }
+
+        public Criteria andEquipmentNoIn(List<String> values) {
+            addCriterion("equipment_no in", values, "equipmentNo");
+            return (Criteria) this;
+        }
+
+        public Criteria andEquipmentNoNotIn(List<String> values) {
+            addCriterion("equipment_no not in", values, "equipmentNo");
+            return (Criteria) this;
+        }
+
+        public Criteria andEquipmentNoBetween(String value1, String value2) {
+            addCriterion("equipment_no between", value1, value2, "equipmentNo");
+            return (Criteria) this;
+        }
+
+        public Criteria andEquipmentNoNotBetween(String value1, String value2) {
+            addCriterion("equipment_no not between", value1, value2, "equipmentNo");
+            return (Criteria) this;
+        }
+
+        public Criteria andUidIsNull() {
+            addCriterion("uid is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andUidIsNotNull() {
+            addCriterion("uid is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andUidEqualTo(Integer value) {
+            addCriterion("uid =", value, "uid");
+            return (Criteria) this;
+        }
+
+        public Criteria andUidNotEqualTo(Integer value) {
+            addCriterion("uid <>", value, "uid");
+            return (Criteria) this;
+        }
+
+        public Criteria andUidGreaterThan(Integer value) {
+            addCriterion("uid >", value, "uid");
+            return (Criteria) this;
+        }
+
+        public Criteria andUidGreaterThanOrEqualTo(Integer value) {
+            addCriterion("uid >=", value, "uid");
+            return (Criteria) this;
+        }
+
+        public Criteria andUidLessThan(Integer value) {
+            addCriterion("uid <", value, "uid");
+            return (Criteria) this;
+        }
+
+        public Criteria andUidLessThanOrEqualTo(Integer value) {
+            addCriterion("uid <=", value, "uid");
+            return (Criteria) this;
+        }
+
+        public Criteria andUidIn(List<Integer> values) {
+            addCriterion("uid in", values, "uid");
+            return (Criteria) this;
+        }
+
+        public Criteria andUidNotIn(List<Integer> values) {
+            addCriterion("uid not in", values, "uid");
+            return (Criteria) this;
+        }
+
+        public Criteria andUidBetween(Integer value1, Integer value2) {
+            addCriterion("uid between", value1, value2, "uid");
+            return (Criteria) this;
+        }
+
+        public Criteria andUidNotBetween(Integer value1, Integer value2) {
+            addCriterion("uid not between", value1, value2, "uid");
+            return (Criteria) this;
+        }
+
+        public Criteria andIndateIsNull() {
+            addCriterion("indate is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andIndateIsNotNull() {
+            addCriterion("indate is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andIndateEqualTo(Date value) {
+            addCriterion("indate =", value, "indate");
+            return (Criteria) this;
+        }
+
+        public Criteria andIndateNotEqualTo(Date value) {
+            addCriterion("indate <>", value, "indate");
+            return (Criteria) this;
+        }
+
+        public Criteria andIndateGreaterThan(Date value) {
+            addCriterion("indate >", value, "indate");
+            return (Criteria) this;
+        }
+
+        public Criteria andIndateGreaterThanOrEqualTo(Date value) {
+            addCriterion("indate >=", value, "indate");
+            return (Criteria) this;
+        }
+
+        public Criteria andIndateLessThan(Date value) {
+            addCriterion("indate <", value, "indate");
+            return (Criteria) this;
+        }
+
+        public Criteria andIndateLessThanOrEqualTo(Date value) {
+            addCriterion("indate <=", value, "indate");
+            return (Criteria) this;
+        }
+
+        public Criteria andIndateIn(List<Date> values) {
+            addCriterion("indate in", values, "indate");
+            return (Criteria) this;
+        }
+
+        public Criteria andIndateNotIn(List<Date> values) {
+            addCriterion("indate not in", values, "indate");
+            return (Criteria) this;
+        }
+
+        public Criteria andIndateBetween(Date value1, Date value2) {
+            addCriterion("indate between", value1, value2, "indate");
+            return (Criteria) this;
+        }
+
+        public Criteria andIndateNotBetween(Date value1, Date value2) {
+            addCriterion("indate not between", value1, value2, "indate");
+            return (Criteria) this;
+        }
+
+        public Criteria andSendTimeIsNull() {
+            addCriterion("send_time is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andSendTimeIsNotNull() {
+            addCriterion("send_time is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andSendTimeEqualTo(Date value) {
+            addCriterion("send_time =", value, "sendTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andSendTimeNotEqualTo(Date value) {
+            addCriterion("send_time <>", value, "sendTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andSendTimeGreaterThan(Date value) {
+            addCriterion("send_time >", value, "sendTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andSendTimeGreaterThanOrEqualTo(Date value) {
+            addCriterion("send_time >=", value, "sendTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andSendTimeLessThan(Date value) {
+            addCriterion("send_time <", value, "sendTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andSendTimeLessThanOrEqualTo(Date value) {
+            addCriterion("send_time <=", value, "sendTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andSendTimeIn(List<Date> values) {
+            addCriterion("send_time in", values, "sendTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andSendTimeNotIn(List<Date> values) {
+            addCriterion("send_time not in", values, "sendTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andSendTimeBetween(Date value1, Date value2) {
+            addCriterion("send_time between", value1, value2, "sendTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andSendTimeNotBetween(Date value1, Date value2) {
+            addCriterion("send_time not between", value1, value2, "sendTime");
+            return (Criteria) this;
+        }
+
+        public Criteria andStateIsNull() {
+            addCriterion("state is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andStateIsNotNull() {
+            addCriterion("state is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andStateEqualTo(Integer value) {
+            addCriterion("state =", value, "state");
+            return (Criteria) this;
+        }
+
+        public Criteria andStateNotEqualTo(Integer value) {
+            addCriterion("state <>", value, "state");
+            return (Criteria) this;
+        }
+
+        public Criteria andStateGreaterThan(Integer value) {
+            addCriterion("state >", value, "state");
+            return (Criteria) this;
+        }
+
+        public Criteria andStateGreaterThanOrEqualTo(Integer value) {
+            addCriterion("state >=", value, "state");
+            return (Criteria) this;
+        }
+
+        public Criteria andStateLessThan(Integer value) {
+            addCriterion("state <", value, "state");
+            return (Criteria) this;
+        }
+
+        public Criteria andStateLessThanOrEqualTo(Integer value) {
+            addCriterion("state <=", value, "state");
+            return (Criteria) this;
+        }
+
+        public Criteria andStateIn(List<Integer> values) {
+            addCriterion("state in", values, "state");
+            return (Criteria) this;
+        }
+
+        public Criteria andStateNotIn(List<Integer> values) {
+            addCriterion("state not in", values, "state");
+            return (Criteria) this;
+        }
+
+        public Criteria andStateBetween(Integer value1, Integer value2) {
+            addCriterion("state between", value1, value2, "state");
+            return (Criteria) this;
+        }
+
+        public Criteria andStateNotBetween(Integer value1, Integer value2) {
+            addCriterion("state not between", value1, value2, "state");
+            return (Criteria) this;
+        }
+
+        public Criteria andIsSendIsNull() {
+            addCriterion("is_send is null");
+            return (Criteria) this;
+        }
+
+        public Criteria andIsSendIsNotNull() {
+            addCriterion("is_send is not null");
+            return (Criteria) this;
+        }
+
+        public Criteria andIsSendEqualTo(Integer value) {
+            addCriterion("is_send =", value, "isSend");
+            return (Criteria) this;
+        }
+
+        public Criteria andIsSendNotEqualTo(Integer value) {
+            addCriterion("is_send <>", value, "isSend");
+            return (Criteria) this;
+        }
+
+        public Criteria andIsSendGreaterThan(Integer value) {
+            addCriterion("is_send >", value, "isSend");
+            return (Criteria) this;
+        }
+
+        public Criteria andIsSendGreaterThanOrEqualTo(Integer value) {
+            addCriterion("is_send >=", value, "isSend");
+            return (Criteria) this;
+        }
+
+        public Criteria andIsSendLessThan(Integer value) {
+            addCriterion("is_send <", value, "isSend");
+            return (Criteria) this;
+        }
+
+        public Criteria andIsSendLessThanOrEqualTo(Integer value) {
+            addCriterion("is_send <=", value, "isSend");
+            return (Criteria) this;
+        }
+
+        public Criteria andIsSendIn(List<Integer> values) {
+            addCriterion("is_send in", values, "isSend");
+            return (Criteria) this;
+        }
+
+        public Criteria andIsSendNotIn(List<Integer> values) {
+            addCriterion("is_send not in", values, "isSend");
+            return (Criteria) this;
+        }
+
+        public Criteria andIsSendBetween(Integer value1, Integer value2) {
+            addCriterion("is_send between", value1, value2, "isSend");
+            return (Criteria) this;
+        }
+
+        public Criteria andIsSendNotBetween(Integer value1, Integer value2) {
+            addCriterion("is_send not between", value1, value2, "isSend");
+            return (Criteria) this;
+        }
+    }
+
+    /**
+     * This class was generated by MyBatis Generator.
+     * This class corresponds to the database table equipment_send_command
+     *
+     * @mbg.generated do_not_delete_during_merge Thu Mar 19 13:16:30 CST 2020
+     */
+    public static class Criteria extends GeneratedCriteria {
+
+        protected Criteria() {
+            super();
+        }
+    }
+
+    /**
+     * This class was generated by MyBatis Generator.
+     * This class corresponds to the database table equipment_send_command
+     *
+     * @mbg.generated Thu Mar 19 13:16:30 CST 2020
+     */
+    public static class Criterion {
+        private String condition;
+
+        private Object value;
+
+        private Object secondValue;
+
+        private boolean noValue;
+
+        private boolean singleValue;
+
+        private boolean betweenValue;
+
+        private boolean listValue;
+
+        private String typeHandler;
+
+        public String getCondition() {
+            return condition;
+        }
+
+        public Object getValue() {
+            return value;
+        }
+
+        public Object getSecondValue() {
+            return secondValue;
+        }
+
+        public boolean isNoValue() {
+            return noValue;
+        }
+
+        public boolean isSingleValue() {
+            return singleValue;
+        }
+
+        public boolean isBetweenValue() {
+            return betweenValue;
+        }
+
+        public boolean isListValue() {
+            return listValue;
+        }
+
+        public String getTypeHandler() {
+            return typeHandler;
+        }
+
+        protected Criterion(String condition) {
+            super();
+            this.condition = condition;
+            this.typeHandler = null;
+            this.noValue = true;
+        }
+
+        protected Criterion(String condition, Object value, String typeHandler) {
+            super();
+            this.condition = condition;
+            this.value = value;
+            this.typeHandler = typeHandler;
+            if (value instanceof List<?>) {
+                this.listValue = true;
+            } else {
+                this.singleValue = true;
+            }
+        }
+
+        protected Criterion(String condition, Object value) {
+            this(condition, value, null);
+        }
+
+        protected Criterion(String condition, Object value, Object secondValue, String typeHandler) {
+            super();
+            this.condition = condition;
+            this.value = value;
+            this.secondValue = secondValue;
+            this.typeHandler = typeHandler;
+            this.betweenValue = true;
+        }
+
+        protected Criterion(String condition, Object value, Object secondValue) {
+            this(condition, value, secondValue, null);
+        }
+    }
+}