|
|
@@ -714,10 +714,10 @@ select
|
|
|
and a.process_state in(5,9) and a.status !=4
|
|
|
</if>
|
|
|
<if test="complete ==1 and processState == 7">
|
|
|
- and a.process_state = 7 and a.status != 4
|
|
|
+ and a.process_state = 7 and a.status != 4 and a.status !=2
|
|
|
</if>
|
|
|
<if test="complete ==1 and processState == 8">
|
|
|
- and a.process_state = #{processState} and a.status != 4
|
|
|
+ and a.process_state = #{processState} and a.status != 4 and a.status !=2
|
|
|
</if>
|
|
|
<if test="complete ==2 and processState != 5 and processState != 7 and processState != 8">
|
|
|
and a.process_state > #{processState}
|
|
|
@@ -726,10 +726,10 @@ select
|
|
|
and (a.process_state > 5 and a.process_state < 9) or (a.process_state =9 and a.status=4)
|
|
|
</if>
|
|
|
<if test="complete ==2 and processState == 7">
|
|
|
- and ((a.process_state = 7 and a.status = 4)or a.process_state > 7)
|
|
|
+ and ((a.process_state = 7 and (a.status = 4 or a.status = 2)or a.process_state > 7)
|
|
|
</if>
|
|
|
<if test="complete ==2 and processState == 8">
|
|
|
- and a.process_state = 8 and a.status = 4
|
|
|
+ and a.process_state = 8 and (a.status = 4 or a.status = 2)
|
|
|
</if>
|
|
|
order by a.create_time
|
|
|
<if test="page_sql != null">
|
|
|
@@ -776,7 +776,7 @@ select
|
|
|
and d.name like concat('%',#{salesmanName},'%')
|
|
|
</if>
|
|
|
<if test="complete ==0 and processState != 8">
|
|
|
- and a.process_state >= #{processState}
|
|
|
+ and a.process_state > = #{processState}
|
|
|
</if>
|
|
|
<if test="complete ==0 and processState == 8">
|
|
|
and a.process_state >= #{processState} and a.process_state < 9
|
|
|
@@ -788,22 +788,22 @@ select
|
|
|
and a.process_state in(5,9) and a.status !=4
|
|
|
</if>
|
|
|
<if test="complete ==1 and processState == 7">
|
|
|
- and a.process_state = 7 and a.status != 4
|
|
|
+ and a.process_state = 7 and a.status != 4 and a.status !=2
|
|
|
</if>
|
|
|
<if test="complete ==1 and processState == 8">
|
|
|
- and a.process_state = #{processState} and a.status != 4
|
|
|
+ and a.process_state = #{processState} and a.status != 4 and a.status !=2
|
|
|
</if>
|
|
|
<if test="complete ==2 and processState != 5 and processState != 7 and processState != 8">
|
|
|
and a.process_state > #{processState}
|
|
|
</if>
|
|
|
<if test="complete ==2 and processState == 5">
|
|
|
- and ((a.process_state > 5 and a.status != 4)or (a.process_state in (5,9) and a.status = 4))
|
|
|
+ and (a.process_state > 5 and a.process_state < 9) or (a.process_state =9 and a.status=4)
|
|
|
</if>
|
|
|
<if test="complete ==2 and processState == 7">
|
|
|
- and ((a.process_state = 7 and a.status = 4)or a.process_state > 7)
|
|
|
+ and ((a.process_state = 7 and (a.status = 4 or a.status = 2)or a.process_state > 7)
|
|
|
</if>
|
|
|
<if test="complete ==2 and processState == 8">
|
|
|
- and a.process_state = 8 and a.status = 4
|
|
|
+ and a.process_state = 8 and (a.status = 4 or a.status = 2)
|
|
|
</if>
|
|
|
</select>
|
|
|
<update id="addRefundInvoice" >
|