20200604-zlp-1
一日流程管理
This commit is contained in:
@ -1,47 +1,47 @@
|
||||
<?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">
|
||||
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.ruoyi.project.benyi.mapper.ByDayFlowDetailMapper">
|
||||
|
||||
|
||||
<resultMap type="ByDayFlowDetail" id="ByDayFlowDetailResult">
|
||||
<result property="id" column="id" />
|
||||
<result property="sortNumber" column="sort_number" />
|
||||
<result property="targetCount" column="target_count" />
|
||||
<result property="name" column="name" />
|
||||
<result property="content" column="content" />
|
||||
<result property="note" column="note" />
|
||||
<result property="flowType" column="flow_type" />
|
||||
<result property="createUser" column="create_user" />
|
||||
<result property="updateUser" column="update_user" />
|
||||
<result property="createTime" column="create_time" />
|
||||
<result property="updateTime" column="update_time" />
|
||||
<result property="id" column="id"/>
|
||||
<result property="sortNumber" column="sort_number"/>
|
||||
<result property="targetCount" column="target_count"/>
|
||||
<result property="name" column="name"/>
|
||||
<result property="content" column="content"/>
|
||||
<result property="note" column="note"/>
|
||||
<result property="flowType" column="flow_type"/>
|
||||
<result property="createUser" column="create_user"/>
|
||||
<result property="updateUser" column="update_user"/>
|
||||
<result property="createTime" column="create_time"/>
|
||||
<result property="updateTime" column="update_time"/>
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectByDayFlowDetailVo">
|
||||
select id, sort_number, target_count, name, content, note, flow_type, create_user, update_user, create_time, update_time
|
||||
select id, sort_number, (select count(*) from by_day_flow_task where detail_id=id) target_count, name, content, note, flow_type, create_user, update_user, create_time, update_time
|
||||
from by_day_flow_detail
|
||||
</sql>
|
||||
|
||||
<select id="selectByDayFlowDetailList" parameterType="ByDayFlowDetail" resultMap="ByDayFlowDetailResult">
|
||||
<include refid="selectByDayFlowDetailVo"/>
|
||||
<where>
|
||||
<if test="sortNumber != null "> and sort_number = #{sortNumber}</if>
|
||||
<if test="targetCount != null "> and target_count = #{targetCount}</if>
|
||||
<if test="name != null and name != ''"> and name like concat('%', #{name}, '%')</if>
|
||||
<if test="content != null and content != ''"> and content = #{content}</if>
|
||||
<if test="note != null and note != ''"> and note = #{note}</if>
|
||||
<if test="flowType != null "> and flow_type = #{flowType}</if>
|
||||
<if test="createUser != null "> and create_user = #{createUser}</if>
|
||||
<if test="updateUser != null "> and update_user = #{updateUser}</if>
|
||||
<where>
|
||||
<if test="sortNumber != null ">and sort_number = #{sortNumber}</if>
|
||||
<if test="targetCount != null ">and target_count = #{targetCount}</if>
|
||||
<if test="name != null and name != ''">and name like concat('%', #{name}, '%')</if>
|
||||
<if test="content != null and content != ''">and content = #{content}</if>
|
||||
<if test="note != null and note != ''">and note = #{note}</if>
|
||||
<if test="flowType != null ">and flow_type = #{flowType}</if>
|
||||
<if test="createUser != null ">and create_user = #{createUser}</if>
|
||||
<if test="updateUser != null ">and update_user = #{updateUser}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
|
||||
<select id="selectByDayFlowDetailById" parameterType="Long" resultMap="ByDayFlowDetailResult">
|
||||
<include refid="selectByDayFlowDetailVo"/>
|
||||
where id = #{id}
|
||||
</select>
|
||||
|
||||
|
||||
<insert id="insertByDayFlowDetail" parameterType="ByDayFlowDetail" useGeneratedKeys="true" keyProperty="id">
|
||||
insert into by_day_flow_detail
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
@ -55,7 +55,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
<if test="updateUser != null ">update_user,</if>
|
||||
<if test="createTime != null ">create_time,</if>
|
||||
<if test="updateTime != null ">update_time,</if>
|
||||
</trim>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="sortNumber != null ">#{sortNumber},</if>
|
||||
<if test="targetCount != null ">#{targetCount},</if>
|
||||
@ -67,7 +67,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
<if test="updateUser != null ">#{updateUser},</if>
|
||||
<if test="createTime != null ">#{createTime},</if>
|
||||
<if test="updateTime != null ">#{updateTime},</if>
|
||||
</trim>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateByDayFlowDetail" parameterType="ByDayFlowDetail">
|
||||
@ -92,10 +92,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
</delete>
|
||||
|
||||
<delete id="deleteByDayFlowDetailByIds" parameterType="String">
|
||||
delete from by_day_flow_detail where id in
|
||||
delete from by_day_flow_detail where id in
|
||||
<foreach item="id" collection="array" open="(" separator="," close=")">
|
||||
#{id}
|
||||
</foreach>
|
||||
</delete>
|
||||
|
||||
|
||||
</mapper>
|
@ -1,34 +1,37 @@
|
||||
<?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">
|
||||
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.ruoyi.project.benyi.mapper.ByDayFlowStandardMapper">
|
||||
|
||||
<resultMap type="ByDayFlowStandard" id="ByDayFlowStandardResult">
|
||||
<result property="id" column="id" />
|
||||
<result property="taskCode" column="task_code" />
|
||||
<result property="standardTitle" column="standard_title" />
|
||||
<result property="standardSort" column="standard_sort" />
|
||||
<result property="createuser" column="createuser" />
|
||||
<result property="createtime" column="createtime" />
|
||||
<result property="updateuser" column="updateuser" />
|
||||
<result property="updatetime" column="updatetime" />
|
||||
<result property="id" column="id"/>
|
||||
<result property="taskCode" column="task_code"/>
|
||||
<result property="standardTitle" column="standard_title"/>
|
||||
<result property="standardSort" column="standard_sort"/>
|
||||
<result property="unscrambleCount" column="unscramble_count"/>
|
||||
<result property="createuser" column="createuser"/>
|
||||
<result property="createtime" column="createtime"/>
|
||||
<result property="updateuser" column="updateuser"/>
|
||||
<result property="updatetime" column="updatetime"/>
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectByDayFlowStandardVo">
|
||||
select id, task_code, standard_title, standard_sort, createuser, createtime, updateuser, updatetime from by_day_flow_standard
|
||||
select id, task_code, standard_title, standard_sort,(select count(*) from by_day_flow_unscramble where standard_id=by_day_flow_standard.id) unscramble_count, createuser, createtime, updateuser, updatetime from by_day_flow_standard
|
||||
</sql>
|
||||
|
||||
<select id="selectByDayFlowStandardList" parameterType="ByDayFlowStandard" resultMap="ByDayFlowStandardResult">
|
||||
<include refid="selectByDayFlowStandardVo"/>
|
||||
<where>
|
||||
<if test="taskCode != null "> and task_code = #{taskCode}</if>
|
||||
<if test="standardTitle != null and standardTitle != ''"> and standard_title = #{standardTitle}</if>
|
||||
<if test="standardSort != null "> and standard_sort = #{standardSort}</if>
|
||||
<if test="createuser != null "> and createuser = #{createuser}</if>
|
||||
<if test="createtime != null "> and createtime = #{createtime}</if>
|
||||
<if test="updateuser != null "> and updateuser = #{updateuser}</if>
|
||||
<if test="updatetime != null "> and updatetime = #{updatetime}</if>
|
||||
<if test="taskCode != null ">and task_code = #{taskCode}</if>
|
||||
<if test="standardTitle != null and standardTitle != ''">and standard_title like concat('%',
|
||||
#{standardTitle}, '%')
|
||||
</if>
|
||||
<if test="standardSort != null ">and standard_sort = #{standardSort}</if>
|
||||
<if test="createuser != null ">and createuser = #{createuser}</if>
|
||||
<if test="createtime != null ">and createtime = #{createtime}</if>
|
||||
<if test="updateuser != null ">and updateuser = #{updateuser}</if>
|
||||
<if test="updatetime != null ">and updatetime = #{updatetime}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
|
@ -10,6 +10,7 @@
|
||||
<result property="detailId" column="detail_id" />
|
||||
<result property="taskContent" column="task_content" />
|
||||
<result property="taskSort" column="task_sort" />
|
||||
<result property="standardCount" column="standard_count"/>
|
||||
<result property="label" column="label" />
|
||||
<result property="createuser" column="createuser" />
|
||||
<result property="updateuser" column="updateuser" />
|
||||
@ -19,7 +20,7 @@
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectByDayFlowTaskVo">
|
||||
select code, task_lable, detail_id, task_content, task_sort, label, createuser, updateuser, createtime, updatetime, remark from by_day_flow_task
|
||||
select code, task_lable, detail_id, task_content, task_sort,(select count(*) from by_day_flow_standard where task_code=code) standard_count, label, createuser, updateuser, createtime, updatetime, remark from by_day_flow_task
|
||||
</sql>
|
||||
|
||||
<select id="selectByDayFlowTaskList" parameterType="ByDayFlowTask" resultMap="ByDayFlowTaskResult">
|
||||
|
@ -0,0 +1,81 @@
|
||||
<?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.ruoyi.project.benyi.mapper.ByDayFlowUnscrambleMapper">
|
||||
|
||||
<resultMap type="ByDayFlowUnscramble" id="ByDayFlowUnscrambleResult">
|
||||
<result property="id" column="id"/>
|
||||
<result property="standardId" column="standard_id"/>
|
||||
<result property="content" column="content"/>
|
||||
<result property="sort" column="sort"/>
|
||||
<result property="remark" column="remark"/>
|
||||
<result property="createuserid" column="createuserid"/>
|
||||
<result property="createTime" column="create_time"/>
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectByDayFlowUnscrambleVo">
|
||||
select id, standard_id, content, sort, remark, createuserid, create_time from by_day_flow_unscramble
|
||||
</sql>
|
||||
|
||||
<select id="selectByDayFlowUnscrambleList" parameterType="ByDayFlowUnscramble"
|
||||
resultMap="ByDayFlowUnscrambleResult">
|
||||
<include refid="selectByDayFlowUnscrambleVo"/>
|
||||
<where>
|
||||
<if test="standardId != null ">and standard_id = #{standardId}</if>
|
||||
<if test="content != null and content != ''">and content = #{content}</if>
|
||||
<if test="sort != null ">and sort = #{sort}</if>
|
||||
<if test="createuserid != null ">and createuserid = #{createuserid}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectByDayFlowUnscrambleById" parameterType="Long" resultMap="ByDayFlowUnscrambleResult">
|
||||
<include refid="selectByDayFlowUnscrambleVo"/>
|
||||
where id = #{id}
|
||||
</select>
|
||||
|
||||
<insert id="insertByDayFlowUnscramble" parameterType="ByDayFlowUnscramble" useGeneratedKeys="true" keyProperty="id">
|
||||
insert into by_day_flow_unscramble
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="standardId != null ">standard_id,</if>
|
||||
<if test="content != null and content != ''">content,</if>
|
||||
<if test="sort != null ">sort,</if>
|
||||
<if test="remark != null and remark != ''">remark,</if>
|
||||
<if test="createuserid != null ">createuserid,</if>
|
||||
<if test="createTime != null ">create_time,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="standardId != null ">#{standardId},</if>
|
||||
<if test="content != null and content != ''">#{content},</if>
|
||||
<if test="sort != null ">#{sort},</if>
|
||||
<if test="remark != null and remark != ''">#{remark},</if>
|
||||
<if test="createuserid != null ">#{createuserid},</if>
|
||||
<if test="createTime != null ">#{createTime},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateByDayFlowUnscramble" parameterType="ByDayFlowUnscramble">
|
||||
update by_day_flow_unscramble
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="standardId != null ">standard_id = #{standardId},</if>
|
||||
<if test="content != null and content != ''">content = #{content},</if>
|
||||
<if test="sort != null ">sort = #{sort},</if>
|
||||
<if test="remark != null and remark != ''">remark = #{remark},</if>
|
||||
<if test="createuserid != null ">createuserid = #{createuserid},</if>
|
||||
<if test="createTime != null ">create_time = #{createTime},</if>
|
||||
</trim>
|
||||
where id = #{id}
|
||||
</update>
|
||||
|
||||
<delete id="deleteByDayFlowUnscrambleById" parameterType="Long">
|
||||
delete from by_day_flow_unscramble where id = #{id}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteByDayFlowUnscrambleByIds" parameterType="String">
|
||||
delete from by_day_flow_unscramble where id in
|
||||
<foreach item="id" collection="array" open="(" separator="," close=")">
|
||||
#{id}
|
||||
</foreach>
|
||||
</delete>
|
||||
|
||||
</mapper>
|
Reference in New Issue
Block a user