代码提交
This commit is contained in:
parent
e5792c3e27
commit
9e2fa8109e
|
|
@ -264,16 +264,22 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
</select>
|
</select>
|
||||||
<select id="getCompletionNotRefunded" resultType="com.bonus.material.push.domain.MachineInfoBean">
|
<select id="getCompletionNotRefunded" resultType="com.bonus.material.push.domain.MachineInfoBean">
|
||||||
select
|
select
|
||||||
count(bp.pro_id) as num,
|
bp.pro_center as proCenter,
|
||||||
|
count(bp.pro_id) num,
|
||||||
|
mt2.type_id as typeId,
|
||||||
sd.dept_name as deptName,
|
sd.dept_name as deptName,
|
||||||
sd.dept_id as deptId
|
sd.dept_id as deptId
|
||||||
from bm_project bp
|
from slt_agreement_info sai
|
||||||
|
left join bm_agreement_info bai on sai.agreement_id = bai.agreement_id
|
||||||
|
left join bm_project bp on bai.project_id = bp.pro_id
|
||||||
left join sys_dept sd on bp.imp_unit = sd.dept_id
|
left join sys_dept sd on bp.imp_unit = sd.dept_id
|
||||||
where bp.external_id is not null
|
left join ma_type mt on sai.type_id = mt.type_id
|
||||||
<if test="deptName != null and deptName != ''">
|
left join ma_type mt2 on mt.parent_id = mt2.type_id
|
||||||
and sd.dept_name = #{deptName}
|
where sai.is_slt = 0 and sai.end_time is null and bp.actual_end_date is not null and bp.pro_center is not null and
|
||||||
</if>
|
<if test="deptName != null">
|
||||||
GROUP BY bp.imp_unit
|
sd.dept_name = #{deptName}
|
||||||
|
</if>
|
||||||
|
GROUP BY sd.dept_id
|
||||||
</select>
|
</select>
|
||||||
<select id="getCompletionNotRefundedDetails" resultType="com.bonus.material.push.domain.MachineInfoBean">
|
<select id="getCompletionNotRefundedDetails" resultType="com.bonus.material.push.domain.MachineInfoBean">
|
||||||
select
|
select
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue