Please wait. This can take some minutes ...
Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance.
Project price only 1 $
You can buy this project and download/modify it how often you want.
mappings.modules.JobDao.xml Maven / Gradle / Ivy
<?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.yqjr.modules.job.dao.JobDao">
<resultMap id="BaseResultMap" type="com.yqjr.modules.job.entity.Job">
<!-- WARNING - @mbg.generated This element is automatically generated by
MyBatis Generator, do not modify. This element was generated on Tue May 16
17:13:46 CST 2017. -->
<result column="ID" jdbcType="DECIMAL" property="id" />
<result column="JOB_NAME" jdbcType="VARCHAR" property="jobName" />
<result column="JOB_NEXTEXECTIME" jdbcType="TIMESTAMP"
property="jobNextExectime" typeHandler="DateHandler" />
<result column="JOB_STATUS" jdbcType="DECIMAL" property="jobStatus" />
<result column="JOB_CRON" jdbcType="VARCHAR" property="jobCron" />
<result column="JOB_EXECSTATUS" jdbcType="DECIMAL" property="jobExecStatus" />
<result column="JOB_EXECRESULT" jdbcType="VARCHAR" property="jobExecResult" />
<result column="JOB_EXECNODE" jdbcType="VARCHAR" property="jobExecNode" />
<result column="JOB_EXECCOST" jdbcType="DECIMAL" property="jobExecCost" />
<result column="JOB_CLASS" jdbcType="VARCHAR" property="jobClass" />
<result column="CREATEBY" jdbcType="DECIMAL" property="createBy.id" />
<result column="CREATEDATE" jdbcType="TIMESTAMP" property="createDate"
typeHandler="DateHandler" />
<result column="UPDATEBY" jdbcType="DECIMAL" property="updateBy.id" />
<result column="UPDATEDATE" jdbcType="TIMESTAMP" property="updateDate"
typeHandler="DateHandler" />
<result column="REMARKS" jdbcType="VARCHAR" property="remarks" />
<result column="FREQUENCY" jdbcType="VARCHAR" property="frequency" />
<result column="EXECTIME" jdbcType="VARCHAR" property="exectime" />
<result column="EXECWEEKS" jdbcType="VARCHAR" property="execWeeks" />
<result column="EXECDAYS" jdbcType="VARCHAR" property="execDays" />
</resultMap>
<sql id="Base_Column_List">
<!-- WARNING - @mbg.generated This element is automatically generated by
MyBatis Generator, do not modify. This element was generated on Tue May 16
17:13:46 CST 2017. -->
ID, JOB_NAME, JOB_NEXTEXECTIME, JOB_STATUS, JOB_CRON, JOB_EXECSTATUS,
JOB_EXECRESULT,
JOB_EXECNODE, JOB_EXECCOST, JOB_CLASS, CREATEBY, CREATEDATE, UPDATEBY, UPDATEDATE,
REMARKS,FREQUENCY,EXECTIME,EXECWEEKS,EXECDAYS
</sql>
<sql id="Base_Where_Condition">
<where>
<if test="id != null">
and ID = #{id,jdbcType=DECIMAL}
</if>
<if test="jobName != null">
and JOB_NAME = #{jobName,jdbcType=VARCHAR}
</if>
<if test="jobNextExectime != null">
and JOB_NEXTEXECTIME =
#{jobNextExectime,jdbcType=TIMESTAMP,typeHandler=DateHandler}
</if>
<if test="jobStatus != null">
and JOB_STATUS = #{jobStatus,jdbcType=DECIMAL}
</if>
<if test="jobCron != null">
and JOB_CRON = #{jobCron,jdbcType=VARCHAR}
</if>
<if test="jobExecStatus != null">
and JOB_EXECSTATUS = #{jobExecStatus,jdbcType=DECIMAL}
</if>
<if test="jobExecResult != null">
and JOB_EXECRESULT = #{jobExecResult,jdbcType=VARCHAR}
</if>
<if test="jobExecNode != null">
and JOB_EXECNODE = #{jobExecNode,jdbcType=VARCHAR}
</if>
<if test="jobExecCost != null">
and JOB_EXECCOST = #{jobExecCost,jdbcType=DECIMAL}
</if>
<if test="jobClass != null">
and JOB_CLASS = #{jobClass,jdbcType=VARCHAR}
</if>
<if test="createBy != null">
and CREATEBY = #{createBy.id}
</if>
<if test="createDate != null">
and CREATEDATE =
#{createDate,jdbcType=TIMESTAMP,typeHandler=DateHandler}
</if>
<if test="updateBy != null">
and UPDATEBY = #{updateBy.id}
</if>
<if test="updateDate != null">
and UPDATEDATE =
#{updateDate,jdbcType=TIMESTAMP,typeHandler=DateHandler}
</if>
<if test="remarks != null">
and REMARKS = #{remarks,jdbcType=VARCHAR}
</if>
</where>
</sql>
<insert id="insert" parameterType="com.yqjr.modules.job.entity.Job">
<!-- WARNING - @mbg.generated This element is automatically generated by
MyBatis Generator, do not modify. This element was generated on Tue May 16
17:13:46 CST 2017. -->
insert into FMK_JOB
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">
ID,
</if>
<if test="jobName != null">
JOB_NAME,
</if>
<if test="jobNextExectime != null">
JOB_NEXTEXECTIME,
</if>
<if test="jobStatus != null">
JOB_STATUS,
</if>
<if test="jobCron != null">
JOB_CRON,
</if>
<if test="jobExecStatus != null">
JOB_EXECSTATUS,
</if>
<if test="jobExecResult != null">
JOB_EXECRESULT,
</if>
<if test="jobExecNode != null">
JOB_EXECNODE,
</if>
<if test="jobExecCost != null">
JOB_EXECCOST,
</if>
<if test="jobClass != null">
JOB_CLASS,
</if>
<if test="createBy != null">
CREATEBY,
</if>
<if test="createDate != null">
CREATEDATE,
</if>
<if test="updateBy != null">
UPDATEBY,
</if>
<if test="updateDate != null">
UPDATEDATE,
</if>
<if test="remarks != null">
REMARKS,
</if>
<if test="frequency != null">
frequency,
</if>
<if test="exectime != null">
exectime,
</if>
<if test="execWeeks != null">
execWeeks,
</if>
<if test="execDays != null">
execDays,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">
#{id,jdbcType=DECIMAL},
</if>
<if test="jobName != null">
#{jobName,jdbcType=VARCHAR},
</if>
<if test="jobNextExectime != null">
#{jobNextExectime,jdbcType=TIMESTAMP,typeHandler=DateHandler},
</if>
<if test="jobStatus != null">
#{jobStatus,jdbcType=DECIMAL},
</if>
<if test="jobCron != null">
#{jobCron,jdbcType=VARCHAR},
</if>
<if test="jobExecStatus != null">
#{jobExecStatus,jdbcType=DECIMAL},
</if>
<if test="jobExecResult != null">
#{jobExecResult,jdbcType=VARCHAR},
</if>
<if test="jobExecNode != null">
#{jobExecNode,jdbcType=VARCHAR},
</if>
<if test="jobExecCost != null">
#{jobExecCost,jdbcType=DECIMAL},
</if>
<if test="jobClass != null">
#{jobClass,jdbcType=VARCHAR},
</if>
<if test="createBy != null">
#{createBy.id},
</if>
<if test="createDate != null">
#{createDate,jdbcType=TIMESTAMP,typeHandler=DateHandler},
</if>
<if test="updateBy != null">
#{updateBy.id},
</if>
<if test="updateDate != null">
#{updateDate,jdbcType=TIMESTAMP,typeHandler=DateHandler},
</if>
<if test="remarks != null">
#{remarks,jdbcType=VARCHAR},
</if>
<if test="frequency != null">
#{frequency,jdbcType=VARCHAR},
</if>
<if test="exectime != null">
#{exectime,jdbcType=VARCHAR},
</if>
<if test="execWeeks != null">
#{execWeeks,jdbcType=VARCHAR},
</if>
<if test="execDays != null">
#{execDays,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="update" parameterType="com.yqjr.modules.job.entity.Job">
<!-- WARNING - @mbg.generated This element is automatically generated by
MyBatis Generator, do not modify. This element was generated on Tue May 16
17:13:46 CST 2017. -->
update FMK_JOB
<set>
<if test="jobName != null">
JOB_NAME = #{jobName,jdbcType=VARCHAR},
</if>
<if test="jobNextExectime != null">
JOB_NEXTEXECTIME = #{jobNextExectime,jdbcType=TIMESTAMP,typeHandler=DateHandler},
</if>
<if test="jobStatus != null">
JOB_STATUS = #{jobStatus,jdbcType=DECIMAL},
</if>
<if test="jobCron != null">
JOB_CRON = #{jobCron,jdbcType=VARCHAR},
</if>
<if test="jobExecStatus != null">
JOB_EXECSTATUS = #{jobExecStatus,jdbcType=DECIMAL},
</if>
<if test="jobExecResult != null">
JOB_EXECRESULT = #{jobExecResult,jdbcType=VARCHAR},
</if>
<if test="jobExecNode != null">
JOB_EXECNODE = #{jobExecNode,jdbcType=VARCHAR},
</if>
<if test="jobExecCost != null">
JOB_EXECCOST = #{jobExecCost,jdbcType=DECIMAL},
</if>
<if test="jobClass != null">
JOB_CLASS = #{jobClass,jdbcType=VARCHAR},
</if>
<if test="createBy != null">
CREATEBY = #{createBy.id},
</if>
<if test="createDate != null">
CREATEDATE = #{createDate,jdbcType=TIMESTAMP,typeHandler=DateHandler},
</if>
<if test="updateBy != null">
UPDATEBY = #{updateBy.id},
</if>
<if test="updateDate != null">
UPDATEDATE = #{updateDate,jdbcType=TIMESTAMP,typeHandler=DateHandler},
</if>
<if test="remarks != null">
REMARKS = #{remarks,jdbcType=VARCHAR},
</if>
<if test="frequency != null">
frequency = #{frequency,jdbcType=VARCHAR},
</if>
<if test="exectime != null">
exectime = #{exectime,jdbcType=VARCHAR},
</if>
<if test="execWeeks != null">
execWeeks = #{execWeeks,jdbcType=VARCHAR},
</if>
<if test="execDays != null">
execDays = #{execDays,jdbcType=VARCHAR},
</if>
</set>
<where>
id = #{id}
</where>
</update>
<update id="delete" parameterType="com.yqjr.modules.job.entity.Job">
<!-- WARNING - @mbg.generated This element is automatically generated by
MyBatis Generator, do not modify. This element was generated on Tue May 16
17:13:46 CST 2017. -->
update FMK_JOB
<set>
JOB_STATUS = 0,
<if test="updateBy != null">
updateBy = #{updateBy.id},
</if>
<if test="updateDate != null">
updateDate = #{updateDate,jdbcType=TIMESTAMP,typeHandler=DateHandler}
</if>
</set>
<where>
id = #{id}
</where>
</update>
<select id="id" resultMap="BaseResultMap">
<!-- WARNING - @mbg.generated This element is automatically generated by
MyBatis Generator, do not modify. This element was generated on Tue May 16
17:13:46 CST 2017. -->
select
<include refid="Base_Column_List" />
from FMK_JOB
<if test="_parameter != null">
where id = #{id}
</if>
</select>
<select id="get" parameterType="com.yqjr.modules.job.entity.Job"
resultMap="BaseResultMap">
<!-- WARNING - @mbg.generated This element is automatically generated by
MyBatis Generator, do not modify. This element was generated on Tue May 16
17:13:46 CST 2017. -->
select
<include refid="Base_Column_List" />
from FMK_JOB
<if test="_parameter != null">
<include refid="Base_Where_Condition" />
</if>
</select>
<select id="findList" parameterType="com.yqjr.modules.job.entity.Job"
resultMap="BaseResultMap">
<!-- WARNING - @mbg.generated This element is automatically generated by
MyBatis Generator, do not modify. This element was generated on Tue May 16
17:13:46 CST 2017. -->
select
<include refid="Base_Column_List" />
from FMK_JOB
<if test="_parameter != null">
<include refid="Base_Where_Condition" />
</if>
</select>
<select id="findByCondition" parameterType="com.yqjr.modules.job.condition.JobCondition"
resultMap="BaseResultMap">
<!-- WARNING - @mbg.generated This element is automatically generated by
MyBatis Generator, do not modify. This element was generated on Tue May 16
17:13:46 CST 2017. -->
select
<include refid="Base_Column_List" />
from FMK_JOB
<if test="_parameter != null">
<where>
<if test="jobName != null">
and JOB_NAME = #{jobName,jdbcType=VARCHAR}
</if>
<if test="jobNextExectime != null">
and JOB_NEXTEXECTIME =
#{jobNextExectime,jdbcType=TIMESTAMP,typeHandler=DateHandler}
</if>
<if test="jobStatus != null">
and JOB_STATUS = #{jobStatus,jdbcType=DECIMAL}
</if>
<if test="jobCron != null">
and JOB_CRON = #{jobCron,jdbcType=VARCHAR}
</if>
<if test="jobExecStatus != null">
and JOB_EXECSTATUS = #{jobExecStatus,jdbcType=DECIMAL}
</if>
<if test="jobExecResult != null">
and JOB_EXECRESULT = #{jobExecResult,jdbcType=VARCHAR}
</if>
<if test="jobExecNode != null">
and JOB_EXECNODE = #{jobExecNode,jdbcType=VARCHAR}
</if>
<if test="jobExecCost != null">
and JOB_EXECCOST = #{jobExecCost,jdbcType=DECIMAL}
</if>
<if test="jobClass != null">
and JOB_CLASS = #{jobClass,jdbcType=VARCHAR}
</if>
<if test="startDate != null">
<![CDATA[ and updateDate >= to_date(#{startDate},'yyyy-mm-dd') ]]>
</if>
<if test="endDate != null">
<![CDATA[ and updateDate < to_date(#{endDate},'yyyy-mm-dd')+1 ]]>
</if>
<if test="userId > 0">
and createBy = #{userId}
</if>
</where>
</if>
</select>
<select id="queryJobs" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from FMK_JOB
where
JOB_STATUS = 1
</select>
</mapper>