148 lines
8.2 KiB
XML
148 lines
8.2 KiB
XML
<?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.rzdata.web.mapper.WorkflowLogMapper">
|
|
|
|
<resultMap type="WorkflowLog" id="WorkflowLogResult">
|
|
<result property="id" column="id" />
|
|
<result property="procInstId" column="proc_inst_id" />
|
|
<result property="procDefKey" column="proc_def_key" />
|
|
<result property="businessId" column="business_id" />
|
|
<result property="actDefId" column="act_def_id" />
|
|
<result property="actDefName" column="act_def_name" />
|
|
<result property="nextDefId" column="next_def_id" />
|
|
<result property="nextDefName" column="next_def_name" />
|
|
<result property="actInstId" column="act_inst_id" />
|
|
<result property="opinion" column="opinion" />
|
|
<result property="sender" column="sender" />
|
|
<result property="senderDeptId" column="sender_dept_id" />
|
|
<result property="receiver" column="receiver" />
|
|
<result property="actStatus" column="act_status" />
|
|
<result property="createTime" column="create_time" />
|
|
<result property="updateTime" column="update_time" />
|
|
<result property="pass" column="pass" />
|
|
<result property="tenantId" column="tenant_id" />
|
|
<result property="review" column="review" />
|
|
<result property="batch" column="batch" />
|
|
</resultMap>
|
|
|
|
<sql id="selectWorkflowLogVo">
|
|
select id, proc_inst_id, proc_def_key, business_id, act_def_id, act_def_name, next_def_id, next_def_name, act_inst_id, opinion, sender, sender_dept_id, receiver, act_status, create_time, update_time, pass, tenant_id, review, batch from t_workflow_log
|
|
</sql>
|
|
|
|
<select id="selectWorkflowLogList" parameterType="WorkflowLog" resultMap="WorkflowLogResult">
|
|
<include refid="selectWorkflowLogVo"/>
|
|
<where>
|
|
<if test="procInstId != null and procInstId != ''"> and proc_inst_id = #{procInstId}</if>
|
|
<if test="procDefKey != null and procDefKey != ''"> and proc_def_key = #{procDefKey}</if>
|
|
<if test="businessId != null and businessId != ''"> and business_id = #{businessId}</if>
|
|
<if test="actDefId != null and actDefId != ''"> and act_def_id = #{actDefId}</if>
|
|
<if test="actDefName != null and actDefName != ''"> and act_def_name like concat('%', #{actDefName}, '%')</if>
|
|
<if test="nextDefId != null and nextDefId != ''"> and next_def_id = #{nextDefId}</if>
|
|
<if test="nextDefName != null and nextDefName != ''"> and next_def_name like concat('%', #{nextDefName}, '%')</if>
|
|
<if test="actInstId != null and actInstId != ''"> and act_inst_id = #{actInstId}</if>
|
|
<if test="opinion != null and opinion != ''"> and opinion = #{opinion}</if>
|
|
<if test="sender != null and sender != ''"> and sender = #{sender}</if>
|
|
<if test="senderDeptId != null and senderDeptId != ''"> and sender_dept_id = #{senderDeptId}</if>
|
|
<if test="receiver != null and receiver != ''"> and receiver = #{receiver}</if>
|
|
<if test="actStatus != null and actStatus != ''"> and act_status = #{actStatus}</if>
|
|
<if test="pass != null "> and pass = #{pass}</if>
|
|
<if test="tenantId != null and tenantId != ''"> and tenant_id = #{tenantId}</if>
|
|
<if test="review != null "> and review = #{review}</if>
|
|
<if test="batch != null and batch != ''"> and batch = #{batch}</if>
|
|
</where>
|
|
order by create_time desc
|
|
</select>
|
|
|
|
<select id="selectWorkflowLogById" parameterType="String" resultMap="WorkflowLogResult">
|
|
<include refid="selectWorkflowLogVo"/>
|
|
where id = #{id}
|
|
</select>
|
|
|
|
<insert id="insertWorkflowLog" parameterType="WorkflowLog">
|
|
insert into t_workflow_log
|
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
|
<if test="id != null">id,</if>
|
|
<if test="procInstId != null">proc_inst_id,</if>
|
|
<if test="procDefKey != null">proc_def_key,</if>
|
|
<if test="businessId != null">business_id,</if>
|
|
<if test="actDefId != null">act_def_id,</if>
|
|
<if test="actDefName != null">act_def_name,</if>
|
|
<if test="nextDefId != null">next_def_id,</if>
|
|
<if test="nextDefName != null">next_def_name,</if>
|
|
<if test="actInstId != null">act_inst_id,</if>
|
|
<if test="opinion != null">opinion,</if>
|
|
<if test="sender != null">sender,</if>
|
|
<if test="senderDeptId != null">sender_dept_id,</if>
|
|
<if test="receiver != null">receiver,</if>
|
|
<if test="actStatus != null">act_status,</if>
|
|
<if test="createTime != null">create_time,</if>
|
|
<if test="updateTime != null">update_time,</if>
|
|
<if test="pass != null">pass,</if>
|
|
<if test="tenantId != null">tenant_id,</if>
|
|
<if test="review != null">review,</if>
|
|
<if test="batch != null">batch,</if>
|
|
</trim>
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
<if test="id != null">#{id},</if>
|
|
<if test="procInstId != null">#{procInstId},</if>
|
|
<if test="procDefKey != null">#{procDefKey},</if>
|
|
<if test="businessId != null">#{businessId},</if>
|
|
<if test="actDefId != null">#{actDefId},</if>
|
|
<if test="actDefName != null">#{actDefName},</if>
|
|
<if test="nextDefId != null">#{nextDefId},</if>
|
|
<if test="nextDefName != null">#{nextDefName},</if>
|
|
<if test="actInstId != null">#{actInstId},</if>
|
|
<if test="opinion != null">#{opinion},</if>
|
|
<if test="sender != null">#{sender},</if>
|
|
<if test="senderDeptId != null">#{senderDeptId},</if>
|
|
<if test="receiver != null">#{receiver},</if>
|
|
<if test="actStatus != null">#{actStatus},</if>
|
|
<if test="createTime != null">#{createTime},</if>
|
|
<if test="updateTime != null">#{updateTime},</if>
|
|
<if test="pass != null">#{pass},</if>
|
|
<if test="tenantId != null">#{tenantId},</if>
|
|
<if test="review != null">#{review},</if>
|
|
<if test="batch != null">#{batch},</if>
|
|
</trim>
|
|
</insert>
|
|
|
|
<update id="updateWorkflowLog" parameterType="WorkflowLog">
|
|
update t_workflow_log
|
|
<trim prefix="SET" suffixOverrides=",">
|
|
<if test="procInstId != null">proc_inst_id = #{procInstId},</if>
|
|
<if test="procDefKey != null">proc_def_key = #{procDefKey},</if>
|
|
<if test="businessId != null">business_id = #{businessId},</if>
|
|
<if test="actDefId != null">act_def_id = #{actDefId},</if>
|
|
<if test="actDefName != null">act_def_name = #{actDefName},</if>
|
|
<if test="nextDefId != null">next_def_id = #{nextDefId},</if>
|
|
<if test="nextDefName != null">next_def_name = #{nextDefName},</if>
|
|
<if test="actInstId != null">act_inst_id = #{actInstId},</if>
|
|
<if test="opinion != null">opinion = #{opinion},</if>
|
|
<if test="sender != null">sender = #{sender},</if>
|
|
<if test="senderDeptId != null">sender_dept_id = #{senderDeptId},</if>
|
|
<if test="receiver != null">receiver = #{receiver},</if>
|
|
<if test="actStatus != null">act_status = #{actStatus},</if>
|
|
<if test="createTime != null">create_time = #{createTime},</if>
|
|
<if test="updateTime != null">update_time = #{updateTime},</if>
|
|
<if test="pass != null">pass = #{pass},</if>
|
|
<if test="tenantId != null">tenant_id = #{tenantId},</if>
|
|
<if test="review != null">review = #{review},</if>
|
|
<if test="batch != null">batch = #{batch},</if>
|
|
</trim>
|
|
where id = #{id}
|
|
</update>
|
|
|
|
<delete id="deleteWorkflowLogById" parameterType="String">
|
|
delete from t_workflow_log where id = #{id}
|
|
</delete>
|
|
|
|
<delete id="deleteWorkflowLogByIds" parameterType="String">
|
|
delete from t_workflow_log where id in
|
|
<foreach item="id" collection="array" open="(" separator="," close=")">
|
|
#{id}
|
|
</foreach>
|
|
</delete>
|
|
</mapper>
|