|
|
@@ -871,26 +871,94 @@
|
|
|
) f ON f.partnerCompaniesId = a.partner_companies_id
|
|
|
<where>
|
|
|
1=1
|
|
|
- <if test="agreementType !=null and agreementType!='' ">
|
|
|
- AND pa.agreement_type =#{agreementType}
|
|
|
+ <if test="startDate !=null and startDate!='' and endDate !=null and endDate !=''">
|
|
|
+ and DATE_FORMAT( a.signdate, '%Y-%m-%d') between DATE_FORMAT(#{startDate}, '%Y-%m-%d') and DATE_FORMAT(#{endDate}, '%Y-%m-%d')
|
|
|
</if>
|
|
|
- <if test="year !=null and year !=''">
|
|
|
- AND YEAR(a.signdate) =#{year}
|
|
|
+ <if test="agreementType !=null and agreementType !=''">
|
|
|
+ and pa.agreement_type =#{agreementType}
|
|
|
</if>
|
|
|
- <if test="isOther !=null and isOther !=''">
|
|
|
- and a.is_not_documentary =#{isOther}
|
|
|
+
|
|
|
+ <if test="signDateEnd !=null and signDateEnd!='' and signDateStart !=null and signDateStart !=''">
|
|
|
+ and a.signdate between #{signDateStart} and #{signDateEnd}
|
|
|
+ </if>
|
|
|
+
|
|
|
+ <if test="handlingFeesStatus !=null and handlingFeesStatus !=''">
|
|
|
+ and a.handling_fees_status =#{handlingFeesStatus}
|
|
|
+ </if>
|
|
|
+
|
|
|
+ <if test="dockingPerson !=null and dockingPerson !=''">
|
|
|
+ and pa.docking_person =#{dockingPerson}
|
|
|
</if>
|
|
|
+
|
|
|
+ <if test="orderno !=null and orderno !=''">
|
|
|
+ and a.orderno =#{orderno}
|
|
|
+ </if>
|
|
|
+ <if test="companyName !=null and companyName !=''">
|
|
|
+ and a.company_id =#{companyName}
|
|
|
+ </if>
|
|
|
+
|
|
|
+ <if test="policyno !=null and policyno !=''">
|
|
|
+ and a.policyno =#{policyno}
|
|
|
+ </if>
|
|
|
+ <if test="documentaryFeesStatus !=null and documentaryFeesStatus !=''">
|
|
|
+ and a.documentary_fees_status =#{documentaryFeesStatus}
|
|
|
+ </if>
|
|
|
+
|
|
|
<if test="isNotCar !=null and isNotCar !=''">
|
|
|
and a.is_not_car =#{isNotCar}
|
|
|
</if>
|
|
|
+
|
|
|
+ <if test="isOther !=null and isOther !=''">
|
|
|
+ and a.is_not_documentary =#{isOther}
|
|
|
+ </if>
|
|
|
+ <if test="licenseno != null and licenseno != ''">
|
|
|
+ and a.licenseno =#{licenseno}
|
|
|
+ </if>
|
|
|
+ <if test="syPolicyno != null and syPolicyno != ''">
|
|
|
+ and a.sy_policyno =#{syPolicyno}
|
|
|
+ </if>
|
|
|
+
|
|
|
+ <if test="noPolicyno != null and noPolicyno != ''">
|
|
|
+ and a.no_policyno =#{noPolicyno}
|
|
|
+ </if>
|
|
|
+ <if test="signdate !=null and signdate !=''">
|
|
|
+ AND a.signdate =#{signdate}
|
|
|
+ </if>
|
|
|
+ <if test="partnerCompaniesId !=null and partnerCompaniesId !=''">
|
|
|
+ AND a.partner_companies_id =#{partnerCompaniesId}
|
|
|
+ </if>
|
|
|
+
|
|
|
+ <if test="partnerCompaniesName !=null and partnerCompaniesName !=''">
|
|
|
+ AND a.partner_companies_name =#{partnerCompaniesName}
|
|
|
+ </if>
|
|
|
+
|
|
|
+ <if test="createTime !=null and createTime !=''">
|
|
|
+ AND a.create_time =#{createTime}
|
|
|
+ </if>
|
|
|
+ <if test="settlementTime !=null and settlementTime !=''">
|
|
|
+ AND a.settlement_time =#{settlementTime}
|
|
|
+ </if>
|
|
|
+
|
|
|
+ <if test="userId !=null and userId !=''">
|
|
|
+ and a.userId =#{userId}
|
|
|
+ </if>
|
|
|
+ <if test="companyId !=null and companyId !=''">
|
|
|
+ and a.company_id =#{companyId}
|
|
|
+ </if>
|
|
|
+ <if test="riskcode !=null and riskcode !=''">
|
|
|
+ and a.riskcode =#{riskcode}
|
|
|
+ </if>
|
|
|
+ <if test="year !=null and year !=''">
|
|
|
+ AND YEAR(a.signdate) =#{year}
|
|
|
+ </if>
|
|
|
<if test="month !=null and month !=''">
|
|
|
AND month(a.signdate) =#{month}
|
|
|
</if>
|
|
|
<if test="day !=null and day !=''">
|
|
|
AND day(a.signdate) =#{day}
|
|
|
</if>
|
|
|
- <if test="documentaryFeesStatus != null and documentaryFeesStatus != '' ">
|
|
|
- AND a.documentary_fees_status = #{documentaryFeesStatus}
|
|
|
+ <if test="insuredName !=null and insuredName !=''">
|
|
|
+ AND a.insured_name =#{insuredName}
|
|
|
</if>
|
|
|
</where>
|
|
|
GROUP BY
|