| | |
| | | |
| | | <sql id="statisticsCirculation-wherePart"> |
| | | and t3.sync_status = 0 |
| | | and t3.input_way = 1 |
| | | <if test="terms != null"> |
| | | <if test="terms.queProv != null and terms.queProv !=''"> |
| | | and t1.prov = #{terms.queProv} |
| | |
| | | ) s |
| | | WHERE rn = 1 |
| | | group by s.case_id) t4 on t2.id = t4.case_id |
| | | where t1.delete_status = 0 and t3.delete_status = 0 |
| | | where t3.delete_status = 0 |
| | | <include refid="statisticsCirculation-wherePart"/> |
| | | group by |
| | | <include refid="groupPart"/> |
| | |
| | | ) s |
| | | WHERE rn = 1 |
| | | group by s.case_id) t4 on t2.id = t4.case_id |
| | | where t1.delete_status = 0 and t3.delete_status = 0 |
| | | where t3.delete_status = 0 |
| | | <if test="terms.caseStatus != null and terms.caseStatus == 1"> |
| | | and t3.zxsl_status = 1 |
| | | </if> |