Browse Source

添加节点类型、标签等

master
陈裕财 4 years ago
parent
commit
dca0de44c2
  1. 12
      xm-core/src/main/resources/mybatis/mapper/xm/core/dao/XmMenuMapper.xml
  2. 5
      xm-core/src/main/resources/mybatis/mapper/xm/core/dao/XmTaskMapper.xml

12
xm-core/src/main/resources/mybatis/mapper/xm/core/dao/XmMenuMapper.xml

@ -22,10 +22,10 @@
</foreach> </foreach>
</if> </if>
<if test=' iterationFilterType!=null and iterationFilterType!=""'> <if test=' iterationFilterType!=null and iterationFilterType!=""'>
<if test='iterationFilterType=="not-join-any-iteration"'> and (res.iteration_id is null or res.iteration_id ='') </if>
<if test='iterationFilterType=="join-any-iteration"'> and ( res.iteration_id is not null and res.iteration_id !='' ) </if>
<if test='iterationFilterType=="not-join-any-iteration"'> and (res.iteration_id is null ) </if>
<if test='iterationFilterType=="join-any-iteration"'> and ( res.iteration_id is not null ) </if>
<if test='iterationFilterType=="join-curr-iteration"'> and res.iteration_id=#{filterIterationId} </if> <if test='iterationFilterType=="join-curr-iteration"'> and res.iteration_id=#{filterIterationId} </if>
<if test='iterationFilterType=="not-join-curr-iteration"'> and res.iteration_id!=#{filterIterationId} </if>
<if test='iterationFilterType=="not-join-curr-iteration"'> and (res.iteration_id!=#{filterIterationId} or res.iteration_id is null) </if>
</if> </if>
<if test=' taskFilterType!=null and taskFilterType!="" '> <if test=' taskFilterType!=null and taskFilterType!="" '>
<if test='taskFilterType=="not-join-curr-project"'> <if test='taskFilterType=="not-join-curr-project"'>
@ -42,12 +42,12 @@
</if> </if>
</if> </if>
<if test="key != null and key !='' "> and res.menu_name like #{key} </if> <if test="key != null and key !='' "> and res.menu_name like #{key} </if>
<if test="isTop!=null and isTop!=''"> and (res.pmenu_id is null or res.pmenu_id = '')</if>
<if test="isTop!=null and isTop!=''"> and (res.pmenu_id is null )</if>
<if test=" linkProjectId!=null and linkProjectId!=''"> and <if test=" linkProjectId!=null and linkProjectId!=''"> and
exists (select 1 from xm_product_project_link link where link.product_id=res.product_id and link.project_id=#{linkProjectId}) exists (select 1 from xm_product_project_link link where link.product_id=res.product_id and link.project_id=#{linkProjectId})
</if> </if>
<if test=" linkIterationId!=null and linkIterationId!=''"> and <if test=" linkIterationId!=null and linkIterationId!=''"> and
exists (select 1 from xm_iteration_link link where link.pro_id=res.product_id and link.iteration_id=#{linkIterationId})
exists (select 1 from xm_iteration_link link where link.pro_id=res.product_id and link.iteration_id=#{linkIterationId} and link.ltype='1')
</if> </if>
</sql> </sql>
@ -188,7 +188,7 @@
<!-- 通过条件查询获取数据列表 返回list<map> --> <!-- 通过条件查询获取数据列表 返回list<map> -->
<select id="selectListMapByWhere" parameterType="HashMap" resultType="HashMap"> <select id="selectListMapByWhere" parameterType="HashMap" resultType="HashMap">
select (select sum(1) from xm_menu m where m.pmenu_id=res.menu_id ) as children_cnt,res.* from xm_menu res left join xm_iteration i on res.iteration_id=i.id
select (select sum(1) from xm_menu m where m.pmenu_id=res.menu_id ) as children_cnt,res.*,i.iteration_name from xm_menu res left join xm_iteration i on res.iteration_id=i.id
<where> <where>
<include refid="whereForMap"/> <include refid="whereForMap"/>
<include refid="where"/> <include refid="where"/>

5
xm-core/src/main/resources/mybatis/mapper/xm/core/dao/XmTaskMapper.xml

@ -351,9 +351,8 @@
<!-- 通过条件查询获取数据列表 返回list<map> --> <!-- 通过条件查询获取数据列表 返回list<map> -->
<select id="selectListMapByWhere" parameterType="HashMap" resultType="HashMap"> <select id="selectListMapByWhere" parameterType="HashMap" resultType="HashMap">
select (select sum(1) from xm_task t where t.parent_taskid=res.id) as children_cnt, res.*,pa.proc_inst_id,pa.assignee,pa.assignee_name,pa.main_title,pa.flow_branch_id,pa.task_name,pa.agree,pa.flow_last_time,pa.comment_msg,pa.proc_def_id,pa.flow_state
from xm_task res left join xm_task_process_approva pa on res.id=pa.xm_task_id and res.biz_proc_inst_id=pa.proc_inst_id
left join xm_project p on p.id=res.project_id
select (select sum(1) from xm_task t where t.parent_taskid=res.id) as children_cnt, res.*
from xm_task res
<where> <where>
<include refid="whereForMap"/> <include refid="whereForMap"/>
<include refid="where"/> <include refid="where"/>

Loading…
Cancel
Save