结算维修单号去掉定损单号
This commit is contained in:
parent
5388327dbb
commit
cf935f714f
|
|
@ -1376,6 +1376,18 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
left join tm_task_agreement tta on tta.task_id = tt.task_id
|
||||
left join sys_dict_data sdd on sdd.dict_value = tt.task_status and sdd.dict_type = 'repair_task_status'
|
||||
where tta.agreement_id = #{agreementId} and tt.task_type = 4 and tt.task_status != 1
|
||||
|
||||
and tt.task_id not in ( select
|
||||
tt.task_id as taskId
|
||||
|
||||
from tm_task tt
|
||||
left join tm_task_agreement tta on tta.task_id = tt.task_id
|
||||
LEFT JOIN repair_apply_details rad on tt.task_id = rad.task_id and is_ds =1
|
||||
where tta.agreement_id = #{agreementId} and tt.task_type = 4 and tt.task_status != 1
|
||||
AND IFNULL(rad.repaired_num,0) > 0
|
||||
)
|
||||
|
||||
|
||||
<if test="repairCode != null">
|
||||
and tt.code like concat('%', #{repairCode}, '%')
|
||||
</if>
|
||||
|
|
|
|||
|
|
@ -28,7 +28,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
|
||||
<select id="selectTmTaskList" parameterType="com.bonus.material.task.domain.TmTask" resultMap="TmTaskResult">
|
||||
<include refid="selectTmTaskVo"/>
|
||||
<where>
|
||||
<where>
|
||||
<if test="taskType != null "> and task_type = #{taskType}</if>
|
||||
<if test="taskStatus != null "> and task_status = #{taskStatus}</if>
|
||||
<if test="code != null and code != ''"> and code = #{code}</if>
|
||||
|
|
@ -36,7 +36,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
<if test="companyId != null "> and company_id = #{companyId}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
|
||||
<select id="selectTmTaskByTaskId" parameterType="Long" resultMap="TmTaskResult">
|
||||
<include refid="selectTmTaskVo"/>
|
||||
where task_id = #{taskId}
|
||||
|
|
@ -50,7 +50,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
#{taskId}
|
||||
</foreach>
|
||||
</select>
|
||||
|
||||
|
||||
<insert id="insertTmTask" parameterType="com.bonus.material.task.domain.TmTask" useGeneratedKeys="true" keyProperty="taskId">
|
||||
insert into tm_task
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
|
|
@ -114,7 +114,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
</delete>
|
||||
|
||||
<delete id="deleteTmTaskByTaskIds" parameterType="String">
|
||||
delete from tm_task where task_id in
|
||||
delete from tm_task where task_id in
|
||||
<foreach item="taskId" collection="array" open="(" separator="," close=")">
|
||||
#{taskId}
|
||||
</foreach>
|
||||
|
|
@ -273,5 +273,16 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
from tm_task tt
|
||||
left join tm_task_agreement tta on tta.task_id = tt.task_id
|
||||
where tta.agreement_id = #{agreementId} and tt.task_type = 4 and tt.task_status != 1
|
||||
|
||||
and tt.task_id not in ( select
|
||||
tt.task_id as taskId
|
||||
|
||||
from tm_task tt
|
||||
left join tm_task_agreement tta on tta.task_id = tt.task_id
|
||||
LEFT JOIN repair_apply_details rad on tt.task_id = rad.task_id and is_ds =1
|
||||
where tta.agreement_id = #{agreementId} and tt.task_type = 4 and tt.task_status != 1
|
||||
AND IFNULL(rad.repaired_num,0) > 0
|
||||
)
|
||||
|
||||
</select>
|
||||
</mapper>
|
||||
</mapper>
|
||||
|
|
|
|||
Loading…
Reference in New Issue