|
@@ -124,7 +124,8 @@
|
|
|
total_amount, settlement_amount, refund_amount, order_status, liquidation_status,
|
|
total_amount, settlement_amount, refund_amount, order_status, liquidation_status,
|
|
|
process_status, project_status, approval, order_remarks, delete_sign, salesman_id,
|
|
process_status, project_status, approval, order_remarks, delete_sign, salesman_id,
|
|
|
finance_id, technician_id, sign_time, settlement_time, contract_no, contract_type,
|
|
finance_id, technician_id, sign_time, settlement_time, contract_no, contract_type,
|
|
|
- contacts, contact_mobile, legal_person, legal_person_tel, proof_count, proof_aid
|
|
|
|
|
|
|
+ contacts, contact_mobile, legal_person, legal_person_tel, proof_count, proof_aid,
|
|
|
|
|
+ proof_time, proof_status
|
|
|
</sql>
|
|
</sql>
|
|
|
<sql id="Blob_Column_List">
|
|
<sql id="Blob_Column_List">
|
|
|
<!--
|
|
<!--
|
|
@@ -1060,7 +1061,6 @@
|
|
|
where a.delete_sign = 0
|
|
where a.delete_sign = 0
|
|
|
<if test="specially == 0">
|
|
<if test="specially == 0">
|
|
|
and a.order_status not in(3,5,6) and a.approval !=3
|
|
and a.order_status not in(3,5,6) and a.approval !=3
|
|
|
- and a.salesman_id = #{aid,jdbcType=VARCHAR}
|
|
|
|
|
</if>
|
|
</if>
|
|
|
<if test="specially == 1">
|
|
<if test="specially == 1">
|
|
|
and a.process_status =1 and a.order_status=1
|
|
and a.process_status =1 and a.order_status=1
|
|
@@ -1074,15 +1074,16 @@
|
|
|
<if test="specially == 4">
|
|
<if test="specially == 4">
|
|
|
and a.process_status in (4,5,6)
|
|
and a.process_status in (4,5,6)
|
|
|
</if>
|
|
</if>
|
|
|
- <if test="specially == 4">
|
|
|
|
|
- and c.department_id=(select department_id from admin where id= #{aid,jdbcType=VARCHAR})
|
|
|
|
|
- </if>
|
|
|
|
|
<if test="distribution == 1">
|
|
<if test="distribution == 1">
|
|
|
and a.process_status = 5
|
|
and a.process_status = 5
|
|
|
</if>
|
|
</if>
|
|
|
<if test="distribution == 2">
|
|
<if test="distribution == 2">
|
|
|
and a.process_status = 6
|
|
and a.process_status = 6
|
|
|
</if>
|
|
</if>
|
|
|
|
|
+
|
|
|
|
|
+ <if test="aid != null">
|
|
|
|
|
+ and a.salesman_id = #{aid,jdbcType=VARCHAR}
|
|
|
|
|
+ </if>
|
|
|
<if test="name != null">
|
|
<if test="name != null">
|
|
|
and b.nickname like CONCAT('%',#{name,jdbcType=VARCHAR},'%')
|
|
and b.nickname like CONCAT('%',#{name,jdbcType=VARCHAR},'%')
|
|
|
</if>
|
|
</if>
|
|
@@ -1102,6 +1103,7 @@
|
|
|
select
|
|
select
|
|
|
count(*)
|
|
count(*)
|
|
|
from t_order_new a left join `user` b on a.buyer_id=b.id
|
|
from t_order_new a left join `user` b on a.buyer_id=b.id
|
|
|
|
|
+ from t_order_new a left join `user` b on a.buyer_id=b.id
|
|
|
left join admin c on a.salesman_id=c.id
|
|
left join admin c on a.salesman_id=c.id
|
|
|
left join admin d on a.finance_id=d.id
|
|
left join admin d on a.finance_id=d.id
|
|
|
<if test="specially == 2">
|
|
<if test="specially == 2">
|
|
@@ -1115,7 +1117,6 @@
|
|
|
where a.delete_sign = 0
|
|
where a.delete_sign = 0
|
|
|
<if test="specially == 0">
|
|
<if test="specially == 0">
|
|
|
and a.order_status not in(3,5,6) and a.approval !=3
|
|
and a.order_status not in(3,5,6) and a.approval !=3
|
|
|
- and a.salesman_id = #{aid,jdbcType=VARCHAR}
|
|
|
|
|
</if>
|
|
</if>
|
|
|
<if test="specially == 1">
|
|
<if test="specially == 1">
|
|
|
and a.process_status =1 and a.order_status=1
|
|
and a.process_status =1 and a.order_status=1
|
|
@@ -1129,15 +1130,16 @@
|
|
|
<if test="specially == 4">
|
|
<if test="specially == 4">
|
|
|
and a.process_status in (4,5,6)
|
|
and a.process_status in (4,5,6)
|
|
|
</if>
|
|
</if>
|
|
|
- <if test="specially == 4">
|
|
|
|
|
- and c.department_id=(select department_id from admin where id= #{aid,jdbcType=VARCHAR})
|
|
|
|
|
- </if>
|
|
|
|
|
<if test="distribution == 1">
|
|
<if test="distribution == 1">
|
|
|
and a.process_status = 5
|
|
and a.process_status = 5
|
|
|
</if>
|
|
</if>
|
|
|
<if test="distribution == 2">
|
|
<if test="distribution == 2">
|
|
|
and a.process_status = 6
|
|
and a.process_status = 6
|
|
|
</if>
|
|
</if>
|
|
|
|
|
+
|
|
|
|
|
+ <if test="aid != null">
|
|
|
|
|
+ and a.salesman_id = #{aid,jdbcType=VARCHAR}
|
|
|
|
|
+ </if>
|
|
|
<if test="name != null">
|
|
<if test="name != null">
|
|
|
and b.nickname like CONCAT('%',#{name,jdbcType=VARCHAR},'%')
|
|
and b.nickname like CONCAT('%',#{name,jdbcType=VARCHAR},'%')
|
|
|
</if>
|
|
</if>
|
|
@@ -1267,4 +1269,4 @@
|
|
|
left join t_order_new b on a.order_no=b.order_no
|
|
left join t_order_new b on a.order_no=b.order_no
|
|
|
where a.id= #{id,jdbcType=INTEGER}
|
|
where a.id= #{id,jdbcType=INTEGER}
|
|
|
</select>
|
|
</select>
|
|
|
-</mapper>
|
|
|
|
|
|
|
+</mapper>
|