发布等

This commit is contained in:
2025-01-08 09:04:13 +08:00
parent fdef054baf
commit 75a119a130
113 changed files with 5911 additions and 400 deletions

View File

@ -74,51 +74,51 @@
</if>
<if test="qo.searchVal == 'WGB' ">
and s.status = 'closed'
and s.closedBy= #{qo.userName}
and s.status != 'closed'
</if>
<if test="qo.searchVal == 'ZGW' ">
<if test="qo.searchVal != null and qo.searchVal == 'ZGW' ">
and s.assignedTo= #{qo.userName}
</if>
<if test="qo.searchVal == 'WCJ' ">
<if test="qo.searchVal != null and qo.searchVal == 'WCJ' ">
and s.openedBy= #{qo.userName}
</if>
<if test="qo.searchVal == 'YWPS' ">
<if test="qo.searchVal != null and qo.searchVal == 'YWPS' ">
and v.reviewer = #{qo.userName}
and s.status ='reviewing'
and v.result = ''
</if>
<if test="qo.searchVal == 'JH' ">
<if test="qo.searchVal != null and qo.searchVal == 'JH' ">
and s.status = 'active'
</if>
<if test="qo.searchVal == 'YGB' ">
<if test="qo.searchVal != null and qo.searchVal == 'YGB' ">
and s.status = 'closed'
</if>
<if test="qo.searchVal == 'DGB' ">
<if test="qo.searchVal != null and qo.searchVal == 'DGB' ">
and s.stage = 'verified'
and s.ys_flag =1
</if>
<if test="qo.searchVal == 'BGZ' ">
<if test="qo.searchVal != null and qo.searchVal == 'BGZ' ">
and s.status = '11'
</if>
<if test="qo.searchVal == 'WZP' ">
<if test="qo.searchVal != null and qo.searchVal == 'WZP' ">
and s.status = '11'
</if>
<if test="qo.searchVal == 'WPS' ">
<if test="qo.searchVal != null and qo.searchVal == 'WPS' ">
and s.reviewedBy like concat('%', #{qo.userName}, '%')
</if>
<if test="qo.searchVal == 'PSZ' ">
<if test="qo.searchVal != null and qo.searchVal == 'PSZ' ">
and s.status = 'reviewing'
</if>
<if test="qo.searchVal == 'DYS' ">
<if test="qo.searchVal != null and qo.searchVal == 'DYS' ">
and s.stage = 'verified'
and s.ys_flag =0
</if>
@ -133,10 +133,38 @@
and s.module = #{qo.module}
</if>
<if test="qo.searchVal != null and qo.searchVal == 'YWGB' ">
and s.status ='closed'
and closedBy =#{qo.userName}
</if>
group by s.id
order by id desc
<choose>
<when test="qo.orderName != '' and qo.orderName != null ">
<choose>
<when test="qo.orderSort != '' and qo.orderSort != null ">
order by s.${qo.orderName} ${qo.orderSort}
</when>
<otherwise>
order by s.id desc
</otherwise>
</choose>
</when>
<otherwise>
order by s.id desc
</otherwise>
</choose>
-- order by id desc
</select>
@ -148,6 +176,9 @@
select s.*,sp.spec ,sp.verify,sp.files from (zt_story s,zt_projectstory ps ) left join zt_storyspec sp on s.id = sp.story
left join zt_storyreview v on s.id = v.story and s.version = v.version
left join zt_projectstory pstory on s.id = pstory.story and pstory.execution =0
left join zt_project pj on pstory.project = pj.id
WHERE s.id = ps.story
<if test="qo.project != null ">
and ps.project =#{qo.project}
@ -168,9 +199,13 @@
and s.assignedTo = #{qo.userName}
</if>
<if test="qo.searchVal != null and qo.searchVal == 'INDEX' ">
<if test="qo.kfz == 1 ">
<if test="qo.userName != null and qo.userName != '' ">
and s.assignedTo = #{qo.userName}
or s.openedBy = #{qo.userName}
</if>
</if>
<if test="qo.searchVal != null and qo.searchVal == 'WCJ' ">
@ -183,8 +218,343 @@
</if>
<if test="qo.searchVal == 'JH' ">
and s.status = 'active'
</if>
<if test="qo.searchVal == 'YGB' ">
and s.status = 'closed'
</if>
<if test="qo.searchVal == 'DGB' ">
and s.stage = 'verified'
and s.ys_flag =1
</if>
<if test="qo.searchVal == 'BGZ' ">
and s.status = '11'
</if>
<if test="qo.searchVal == 'WZP' ">
and s.status = '11'
</if>
<if test="qo.searchVal == 'WPS' ">
and s.reviewedBy like concat('%', #{qo.userName}, '%')
</if>
<if test="qo.searchVal == 'PSZ' ">
and s.status = 'reviewing'
</if>
<if test="qo.searchVal == 'DYS' ">
and s.stage = 'verified'
and s.ys_flag =0
</if>
<if test="qo.searchVal != null and qo.searchVal == 'YWGB' ">
and s.status ='closed'
and closedBy =#{qo.userName}
</if>
<if test="qo.searchCode != null and qo.searchCode != '' ">
-- //项目名称
<if test="qo.searchCode=='xmmc' and qo.searchValue != null and qo.searchValue != '' ">
and pj.name like concat('%', #{qo.searchValue}, '%')
</if>
-- 项目id
<if test="qo.searchCode=='xmid' and qo.searchValue != null and qo.searchValue != '' ">
and pj.id =#{qo.searchValue}
</if>
-- //需求名称
<if test="qo.searchCode=='xqmc' and qo.searchValue != null and qo.searchValue != '' ">
and s.title like concat('%', #{qo.searchValue}, '%')
</if>
-- 需求id
<if test="qo.searchCode=='xqid' and qo.searchValue != null and qo.searchValue != '' ">
and s.id =#{qo.searchValue}
</if>
-- 状态
<if test="qo.searchCode=='zt' and qo.searchValue != null and qo.searchValue != '' ">
and s.stage =#{qo.searchValue}
</if>
-- 项目描述
<if test="qo.searchCode=='xmms' and qo.searchValue != null and qo.searchValue != '' ">
and sp.`spec` =#{qo.searchValue}
</if>
-- 负责人
<if test="qo.searchCode=='fzr' and qo.searchValue != null and qo.searchValue != '' ">
and s.assignedTo =#{qo.searchValue}
</if>
<if test="qo.searchCode=='jhwc' and qo.searchValue != null and qo.searchValue != '' ">
and s.plan_end_date ${qo.searchValue}
</if>
<if test="qo.searchCode=='sjks' and qo.searchValue != null and qo.searchValue != '' ">
and s.start_date ${qo.searchValue}
</if>
<if test="qo.searchCode=='sjwc' and qo.searchValue != null and qo.searchValue != '' ">
and s.end_date ${qo.searchValue}
</if>
<if test="qo.searchCode=='yscj' and qo.searchValue != null and qo.searchValue != '' ">
and s.openedBy = #{qo.searchValue}
</if>
<if test="qo.searchCode=='ysgb' and qo.searchValue != null and qo.searchValue != '' ">
and s.closedBy = #{qo.searchValue}
</if>
</if>
group by s.id
order by s.id desc
<choose>
<when test="qo.orderName != '' and qo.orderName != null ">
<choose>
<when test="qo.orderSort != '' and qo.orderSort != null ">
order by s.${qo.orderName} ${qo.orderSort}
</when>
<otherwise>
order by s.id desc
</otherwise>
</choose>
</when>
<otherwise>
order by s.id desc
</otherwise>
</choose>
</select>
<select id="getPrdById" resultType="com.sa.zentao.entity.ZtStory">
SELECT * from zt_story WHERE id = #{id}
</select>
<select id="allStoryPageList" resultType="com.sa.zentao.dao.ZtStoryDTO">
select s.*,sp.spec ,sp.verify,sp.files from zt_story s left join zt_storyspec sp on s.id = sp.story
left join zt_storyreview v on s.id = v.story and s.version = v.version
WHERE 1=1
<if test="qo.project != null ">
and ps.project =#{qo.project}
</if>
<if test="qo.execution != null ">
and ps.execution =#{qo.execution}
</if>
<if test="qo.module != null ">
and s.module =#{qo.module}
</if>
<if test="qo.searchVal != null and qo.searchVal == 'ALL' ">
</if>
<if test="qo.searchVal != null and qo.searchVal == 'WGB' ">
and s.status !='closed'
</if>
<if test="qo.searchVal != null and qo.searchVal == 'ZGW' ">
and s.assignedTo = #{qo.userName}
</if>
<if test="qo.searchVal != null and qo.searchVal == 'INDEX' ">
<if test="qo.userName != null and qo.userName != '' ">
and s.assignedTo = #{qo.userName}
or s.openedBy = #{qo.userName}
</if>
</if>
<if test="qo.searchVal != null and qo.searchVal == 'WCJ' ">
and s.openedBy = #{qo.userName}
</if>
<if test="qo.searchVal != null and qo.searchVal == 'YWPS' ">
and v.reviewer = #{qo.userName}
and s.status ='reviewing'
and v.result = ''
</if>
<if test="qo.searchVal == 'JH' ">
and s.status = 'active'
</if>
<if test="qo.searchVal == 'YGB' ">
and s.status = 'closed'
</if>
<if test="qo.searchVal == 'DGB' ">
and s.stage = 'verified'
and s.ys_flag =1
</if>
<if test="qo.searchVal == 'BGZ' ">
and s.status = '11'
</if>
<if test="qo.searchVal == 'WZP' ">
and s.status = '11'
</if>
<if test="qo.searchVal == 'WPS' ">
and s.reviewedBy like concat('%', #{qo.userName}, '%')
</if>
<if test="qo.searchVal == 'PSZ' ">
and s.status = 'reviewing'
</if>
<if test="qo.searchVal == 'DYS' ">
and s.stage = 'verified'
and s.ys_flag =0
</if>
<if test="qo.searchVal != null and qo.searchVal == 'YWGB' ">
and s.status ='closed'
and closedBy =#{qo.userName}
</if>
group by s.id
<choose>
<when test="qo.orderName != '' and qo.orderName != null ">
<choose>
<when test="qo.orderSort != '' and qo.orderSort != null ">
order by s.${qo.orderName} ${qo.orderSort}
</when>
<otherwise>
order by s.id desc
</otherwise>
</choose>
</when>
<otherwise>
order by s.id desc
</otherwise>
</choose>
</select>
<select id="myStoryPageList" resultType="com.sa.zentao.dao.ZtStoryDTO">
select s.*,sp.spec ,sp.verify,sp.files from zt_story s left join zt_storyspec sp on s.id = sp.story
left join zt_storyreview v on s.id = v.story and s.version = v.version
WHERE 1=1
<if test="qo.productIds != null and qo.productIds.size() > 0">
and s.product in
<foreach collection="qo.productIds" item="id" index="index"
open="(" close=")" separator=",">
#{id}
</foreach>
</if>
<if test="qo.project != null ">
and ps.project =#{qo.project}
</if>
<if test="qo.execution != null ">
and ps.execution =#{qo.execution}
</if>
<if test="qo.module != null ">
and s.module =#{qo.module}
</if>
<if test="qo.searchVal != null and qo.searchVal == 'ALL' ">
</if>
<if test="qo.searchVal != null and qo.searchVal == 'WGB' ">
and s.status !='closed'
</if>
<if test="qo.searchVal != null and qo.searchVal == 'ZGW' ">
and s.assignedTo = #{qo.userName}
</if>
<if test="qo.searchVal != null and qo.searchVal == 'INDEX' ">
<if test="qo.userName != null and qo.userName != '' ">
and s.assignedTo = #{qo.userName}
or s.openedBy = #{qo.userName}
</if>
</if>
<if test="qo.searchVal != null and qo.searchVal == 'WCJ' ">
and s.openedBy = #{qo.userName}
</if>
<if test="qo.searchVal != null and qo.searchVal == 'YWPS' ">
and v.reviewer = #{qo.userName}
and s.status ='reviewing'
and v.result = ''
</if>
<if test="qo.searchVal == 'JH' ">
and s.status = 'active'
</if>
<if test="qo.searchVal == 'YGB' ">
and s.status = 'closed'
</if>
<if test="qo.searchVal == 'DGB' ">
and s.stage = 'verified'
and s.ys_flag =1
</if>
<if test="qo.searchVal == 'BGZ' ">
and s.status = '11'
</if>
<if test="qo.searchVal == 'WZP' ">
and s.status = '11'
</if>
<if test="qo.searchVal == 'WPS' ">
and s.reviewedBy like concat('%', #{qo.userName}, '%')
</if>
<if test="qo.searchVal == 'PSZ' ">
and s.status = 'reviewing'
</if>
<if test="qo.searchVal == 'DYS' ">
and s.stage = 'verified'
and s.ys_flag =0
</if>
<if test="qo.searchVal != null and qo.searchVal == 'YWGB' ">
and s.status ='closed'
and closedBy =#{qo.userName}
</if>
group by s.id
<choose>
<when test="qo.orderName != '' and qo.orderName != null ">
<choose>
<when test="qo.orderSort != '' and qo.orderSort != null ">
order by s.${qo.orderName} ${qo.orderSort}
</when>
<otherwise>
order by s.id desc
</otherwise>
</choose>
</when>
<otherwise>
order by s.id desc
</otherwise>
</choose>
</select>
<select id="storyPageListByIds" resultType="com.sa.zentao.dao.ZtStoryDTO">
select s.*,sp.spec ,sp.verify,sp.files from zt_story s left join zt_storyspec sp on s.id = sp.story
left join zt_storyreview v on s.id = v.story and s.version = v.version
WHERE 1=1
<if test="ids != null and ids.size() > 0">
and s.id in
<foreach collection="ids" item="id" index="index"
open="(" close=")" separator=",">
#{id}
</foreach>
</if>
order by s.id desc
</select>
</mapper>