|
|
|
@ -167,28 +167,37 @@
|
|
|
|
|
</where>
|
|
|
|
|
</sql>
|
|
|
|
|
<select id="listFinal" resultType="cn.jyjz.xiaoyao.ocr.dataobject.OcrTaskchildPicture" parameterType="java.util.Map">
|
|
|
|
|
|
|
|
|
|
select tcp.*,pic.field11 reporttime from (
|
|
|
|
|
select
|
|
|
|
|
tc.*
|
|
|
|
|
from ocr_taskchild_picture tc,OA_USERFINAL_T uf
|
|
|
|
|
where tc.ID = uf.FORMID
|
|
|
|
|
<if test="thisLoginUserid != null"> and uf.USERID ${thisLoginUserid.dataOp} ${thisLoginUserid.likestar}#{thisLoginUserid.value}${thisLoginUserid.likeend}</if>
|
|
|
|
|
UNION
|
|
|
|
|
select
|
|
|
|
|
tc.*
|
|
|
|
|
from ocr_taskchild_picture tc
|
|
|
|
|
where tc.STATES = 5
|
|
|
|
|
) as tcp,ocr_picture pic
|
|
|
|
|
where tcp.PICTUREID = pic.ID
|
|
|
|
|
<include refid="Base_Where_union"></include>
|
|
|
|
|
<if test="fromuptimeStart != null"> and tcp.fromuptime >= ${fromuptimeStart} </if>
|
|
|
|
|
<if test="fromuptimeEnd != null"> and tcp.fromuptime <= ${fromuptimeEnd} </if>
|
|
|
|
|
<if test="page != null">
|
|
|
|
|
<if test="page.sortname != null"> order by tcp.${page.sortname} ${page.sortorder}</if>
|
|
|
|
|
limit ${page.start}, ${page.Pagesize}
|
|
|
|
|
</if>
|
|
|
|
|
</select>
|
|
|
|
|
select tcp.*,pic.field11 reporttime from (
|
|
|
|
|
select
|
|
|
|
|
tc.*
|
|
|
|
|
from ocr_taskchild_picture tc,OA_USERFINAL_T uf
|
|
|
|
|
where tc.ID = uf.FORMID
|
|
|
|
|
<if test="thisLoginUserid != null">
|
|
|
|
|
and uf.USERID ${thisLoginUserid.dataOp}
|
|
|
|
|
${thisLoginUserid.likestar}#{thisLoginUserid.value}${thisLoginUserid.likeend}
|
|
|
|
|
</if>
|
|
|
|
|
UNION
|
|
|
|
|
select
|
|
|
|
|
tc.*
|
|
|
|
|
from ocr_taskchild_picture tc
|
|
|
|
|
where tc.STATES = 5
|
|
|
|
|
) as tcp left join ocr_picture pic
|
|
|
|
|
on tcp.PICTUREID = pic.ID
|
|
|
|
|
<include refid="Base_Where_union">
|
|
|
|
|
</include>
|
|
|
|
|
<if test="fromuptimeStart != null">
|
|
|
|
|
and tcp.fromuptime >= ${fromuptimeStart}
|
|
|
|
|
</if>
|
|
|
|
|
<if test="fromuptimeEnd != null">
|
|
|
|
|
and tcp.fromuptime <= ${fromuptimeEnd}
|
|
|
|
|
</if>
|
|
|
|
|
<if test="page != null">
|
|
|
|
|
<if test="page.sortname != null">
|
|
|
|
|
order by tcp.${page.sortname} ${page.sortorder}
|
|
|
|
|
</if>
|
|
|
|
|
limit ${page.start}, ${page.Pagesize}
|
|
|
|
|
</if>
|
|
|
|
|
</select>
|
|
|
|
|
<select id="listFinalCount" resultType="java.lang.Long" parameterType="java.util.Map">
|
|
|
|
|
select count(tcp.ID) from (
|
|
|
|
|
select
|
|
|
|
|