All Downloads are FREE. Search and download functionalities are using the official Maven repository.

mapper.base.SysTaskJobMapper.xml Maven / Gradle / Ivy

There is a newer version: 1.6.7
Show newest version
<?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="system.mapper.SysTaskJobMapper">
  <resultMap id="BaseResultMap" type="system.entity.SysTaskJob">
    <!--
      WARNING - @mbg.generated
    -->
    <id column="id" jdbcType="BIGINT" property="id" />
    <result column="name" jdbcType="VARCHAR" property="name" />
    <result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
    <result column="start_time" jdbcType="TIMESTAMP" property="startTime" />
    <result column="expire_time" jdbcType="TIMESTAMP" property="expireTime" />
    <result column="group_name" jdbcType="VARCHAR" property="groupName" />
    <result column="description" jdbcType="VARCHAR" property="description" />
    <result column="actuator" jdbcType="VARCHAR" property="actuator" />
    <result column="schedule" jdbcType="VARCHAR" property="schedule" />
    <result column="instruction" jdbcType="VARCHAR" property="instruction" />
    <result column="param" jdbcType="VARCHAR" property="param" />
    <result column="status" jdbcType="VARCHAR" property="status" />
    <result column="hostname" jdbcType="VARCHAR" property="hostname" />
    <result column="env_name" jdbcType="VARCHAR" property="envName" />
  </resultMap>
  <sql id="Base_Column_List">
    <!--
      WARNING - @mbg.generated
    -->
    id, name, create_time, start_time, expire_time, group_name, description, actuator, 
    schedule, instruction, param, status, hostname, env_name
  </sql>
  <sql id="All_Column_List">
    id, name, create_time, start_time, expire_time, group_name, description, actuator, schedule, 
    instruction, param, status, hostname, env_name
  </sql>
  <sql id="whereAll">
    <if test="id != null ">
       AND id = #{id,jdbcType=BIGINT}
    </if>
    <if test="name != null and name != '' ">
       AND name = #{name,jdbcType=VARCHAR}
    </if>
    <if test="createTime != null ">
       AND create_time = #{createTime,jdbcType=TIMESTAMP}
    </if>
    <if test="startTime != null ">
       AND start_time = #{startTime,jdbcType=TIMESTAMP}
    </if>
    <if test="expireTime != null ">
       AND expire_time = #{expireTime,jdbcType=TIMESTAMP}
    </if>
    <if test="groupName != null and groupName != '' ">
       AND group_name = #{groupName,jdbcType=VARCHAR}
    </if>
    <if test="description != null and description != '' ">
       AND description = #{description,jdbcType=VARCHAR}
    </if>
    <if test="actuator != null and actuator != '' ">
       AND actuator = #{actuator,jdbcType=VARCHAR}
    </if>
    <if test="schedule != null and schedule != '' ">
       AND schedule = #{schedule,jdbcType=VARCHAR}
    </if>
    <if test="instruction != null ">
       AND instruction = #{instruction,jdbcType=VARCHAR}
    </if>
    <if test="param != null and param != '' ">
       AND param = #{param,jdbcType=VARCHAR}
    </if>
    <if test="status != null ">
       AND status = #{status,jdbcType=VARCHAR}
    </if>
    <if test="hostname != null and hostname != '' ">
       AND hostname = #{hostname,jdbcType=VARCHAR}
    </if>
    <if test="envName != null and envName != '' ">
       AND env_name = #{envName,jdbcType=VARCHAR}
    </if>
  </sql>
  <sql id="setAll">
    <if test="name != null ">
      name = #{name,jdbcType=VARCHAR},
    </if>
    <if test="createTime != null ">
      create_time = #{createTime,jdbcType=TIMESTAMP},
    </if>
    <if test="startTime != null ">
      start_time = #{startTime,jdbcType=TIMESTAMP},
    </if>
    <if test="expireTime != null ">
      expire_time = #{expireTime,jdbcType=TIMESTAMP},
    </if>
    <if test="groupName != null ">
      group_name = #{groupName,jdbcType=VARCHAR},
    </if>
    <if test="description != null ">
      description = #{description,jdbcType=VARCHAR},
    </if>
    <if test="actuator != null ">
      actuator = #{actuator,jdbcType=VARCHAR},
    </if>
    <if test="schedule != null ">
      schedule = #{schedule,jdbcType=VARCHAR},
    </if>
    <if test="instruction != null ">
      instruction = #{instruction,jdbcType=VARCHAR},
    </if>
    <if test="param != null ">
      param = #{param,jdbcType=VARCHAR},
    </if>
    <if test="status != null ">
      status = #{status,jdbcType=VARCHAR},
    </if>
    <if test="hostname != null ">
      hostname = #{hostname,jdbcType=VARCHAR},
    </if>
    <if test="envName != null ">
      env_name = #{envName,jdbcType=VARCHAR},
    </if>
  </sql>
  <sql id="conditionFields">
    <if test="id != null ">
      id,
    </if>
    <if test="name != null ">
      name,
    </if>
    <if test="createTime != null ">
      create_time,
    </if>
    <if test="startTime != null ">
      start_time,
    </if>
    <if test="expireTime != null ">
      expire_time,
    </if>
    <if test="groupName != null ">
      group_name,
    </if>
    <if test="description != null ">
      description,
    </if>
    <if test="actuator != null ">
      actuator,
    </if>
    <if test="schedule != null ">
      schedule,
    </if>
    <if test="instruction != null ">
      instruction,
    </if>
    <if test="param != null ">
      param,
    </if>
    <if test="status != null ">
      status,
    </if>
    <if test="hostname != null ">
      hostname,
    </if>
    <if test="envName != null ">
      env_name,
    </if>
  </sql>
  <sql id="conditionValues">
    <if test="id != null ">
      #{id,jdbcType=BIGINT},
    </if>
    <if test="name != null ">
      #{name,jdbcType=VARCHAR},
    </if>
    <if test="createTime != null ">
      #{createTime,jdbcType=TIMESTAMP},
    </if>
    <if test="startTime != null ">
      #{startTime,jdbcType=TIMESTAMP},
    </if>
    <if test="expireTime != null ">
      #{expireTime,jdbcType=TIMESTAMP},
    </if>
    <if test="groupName != null ">
      #{groupName,jdbcType=VARCHAR},
    </if>
    <if test="description != null ">
      #{description,jdbcType=VARCHAR},
    </if>
    <if test="actuator != null ">
      #{actuator,jdbcType=VARCHAR},
    </if>
    <if test="schedule != null ">
      #{schedule,jdbcType=VARCHAR},
    </if>
    <if test="instruction != null ">
      #{instruction,jdbcType=VARCHAR},
    </if>
    <if test="param != null ">
      #{param,jdbcType=VARCHAR},
    </if>
    <if test="status != null ">
      #{status,jdbcType=VARCHAR},
    </if>
    <if test="hostname != null ">
      #{hostname,jdbcType=VARCHAR},
    </if>
    <if test="envName != null ">
      #{envName,jdbcType=VARCHAR},
    </if>
  </sql>
  <select id="loadByIds" resultType="system.entity.SysTaskJob">
    SELECT
    <include refid="All_Column_List" />
    FROM sys_task_job
    <where>
        <choose>
            <when test="ids != null and ids.size() != 0">
                id IN 
                <foreach collection="ids" item="id" index="index" open="(" close=")" separator=",">#{id}</foreach>
            </when>
            <otherwise>
                1 = 0
            </otherwise>
        </choose>
    </where>
  </select>
  <select id="loadByNotIds" resultType="system.entity.SysTaskJob">
    SELECT
    <include refid="All_Column_List" />
    FROM sys_task_job
    <where>
        <choose>
            <when test="ids != null and ids.size() != 0">
                id NOT IN 
                <foreach collection="ids" item="id" index="index" open="(" close=")" separator=",">#{id}</foreach>
            </when>
            <otherwise>
                1 = 0
            </otherwise>
        </choose>
    </where>
  </select>
  <delete id="deleteByIds">
    DELETE FROM sys_task_job 
    <where>
        <choose>
            <when test="ids != null and ids.size() != 0">
                id IN 
                <foreach collection="ids" item="id" index="index" open="(" close=")" separator=",">#{id}</foreach>
            </when>
            <otherwise>
                1 = 0
            </otherwise>
        </choose>
    </where>
  </delete>
  <delete id="deleteByNotIds">
    DELETE FROM sys_task_job 
    <where>
        <choose>
            <when test="ids != null and ids.size() != 0">
                id NOT IN 
                <foreach collection="ids" item="id" index="index" open="(" close=")" separator=",">#{id}</foreach>
            </when>
            <otherwise>
                1 = 0
            </otherwise>
        </choose>
    </where>
  </delete>
</mapper>




© 2015 - 2024 Weber Informatics LLC | Privacy Policy