|
@@ -171,41 +171,31 @@
|
|
|
'备案数' NAME,
|
|
|
count( id ) num
|
|
|
FROM
|
|
|
- lawenforcement_record a
|
|
|
- left join ${database_system}.sys_dept d on d.dept_id = a.dept_id
|
|
|
- where 1 = 1 ${params.dataScope} UNION ALL
|
|
|
+ lawenforcement_record a UNION ALL
|
|
|
SELECT
|
|
|
'已执法' NAME,
|
|
|
count( id ) num
|
|
|
FROM
|
|
|
lawenforcement_record a
|
|
|
- left join ${database_system}.sys_dept d on d.dept_id = a.dept_id
|
|
|
- WHERE record_status not IN ( 'lawenforcement_type_1', 'lawenforcement_type_9')
|
|
|
- ${params.dataScope} UNION ALL
|
|
|
+ WHERE record_status not IN ( 'lawenforcement_type_1', 'lawenforcement_type_9') UNION ALL
|
|
|
SELECT
|
|
|
'转立案' NAME,
|
|
|
count( id ) num
|
|
|
FROM
|
|
|
- lawenforcement_case a
|
|
|
- left join ${database_system}.sys_dept d on d.dept_id = a.dept_id
|
|
|
- where 1 = 1 ${params.dataScope} UNION ALL
|
|
|
+ lawenforcement_case a UNION ALL
|
|
|
SELECT
|
|
|
'受理完成' NAME,
|
|
|
count( id ) num
|
|
|
FROM
|
|
|
lawenforcement_case a
|
|
|
- left join ${database_system}.sys_dept d on d.dept_id = a.dept_id
|
|
|
- WHERE state IN ( 'state_3', 'state_4' )
|
|
|
- ${params.dataScope} UNION ALL
|
|
|
+ WHERE state IN ( 'state_3', 'state_4' ) UNION ALL
|
|
|
SELECT
|
|
|
'协商一致' NAME,
|
|
|
count( id ) num
|
|
|
FROM
|
|
|
lawenforcement_case a
|
|
|
- left join ${database_system}.sys_dept d on d.dept_id = a.dept_id
|
|
|
WHERE
|
|
|
state = 'state_5'
|
|
|
- ${params.dataScope}
|
|
|
</select>
|
|
|
|
|
|
<select id="getLawenforcement" parameterType="LawenforcementViewBO" resultType="map">
|
|
@@ -224,7 +214,6 @@
|
|
|
FROM
|
|
|
lawenforcement_record a
|
|
|
LEFT JOIN ${database_system}.sys_dict_data b ON a.job_type = b.dict_value AND b.dict_type = 'lawenforcement_jobType'
|
|
|
- left join ${database_system}.sys_dept d on d.dept_id = a.dept_id
|
|
|
where
|
|
|
a.id = #{recordId}
|
|
|
</select>
|
|
@@ -253,7 +242,6 @@
|
|
|
FROM
|
|
|
lawenforcement_record a
|
|
|
left join lawenforcement_person b on a.id = b.record_id and b.main_person = '1'
|
|
|
- left join ${database_system}.sys_dept d on d.dept_id = a.dept_id
|
|
|
WHERE 1=1
|
|
|
<choose>
|
|
|
<when test="deviceId != null and deviceId != ''">
|
|
@@ -261,7 +249,6 @@
|
|
|
</when>
|
|
|
<otherwise>and a.record_status in ('lawenforcement_type_4','lawenforcement_type_6')</otherwise>
|
|
|
</choose>
|
|
|
- ${params.dataScope}
|
|
|
<if test="deviceId != null and deviceId != ''"> LIMIT 5 </if>
|
|
|
</select>
|
|
|
|