|
@@ -71,6 +71,7 @@ dept_id jdId, dept_name jdName from sys_dept where post_id = 15 and parent_id =
|
|
|
<if test="jdId != null and jdId != ''"> AND jd_id = #{jdId} </if>
|
|
|
) z
|
|
|
</select>
|
|
|
+
|
|
|
<select id="kshZhongdianrenkouTotal" parameterType="ZhsqKshVo" resultType="ZhsqKshTotal">
|
|
|
SELECT
|
|
|
count(IF(per_ldsx = 1, 1, NULL)) changzhuCount,
|
|
@@ -79,11 +80,24 @@ dept_id jdId, dept_name jdName from sys_dept where post_id = 15 and parent_id =
|
|
|
count(IF(per_ldsx = 4, 1, NULL)) zanzhuCount,
|
|
|
count(IF(per_sfkg = 1, 1, NULL)) kongguaCount,
|
|
|
count(IF(per_sfkg = 2, 1, NULL)) feikongguaCount,
|
|
|
- count(IF(t.tsrq_id = 7, 1, NULL)) shangcanCount,
|
|
|
- count(IF(t.tsrq_id = 20, 1, NULL)) laolingCount
|
|
|
+ (
|
|
|
+ SELECT
|
|
|
+ count(1)
|
|
|
+ FROM
|
|
|
+ zhsq_person_tsrq
|
|
|
+ WHERE
|
|
|
+ tsrq_id = 7
|
|
|
+ ) shangcanCount,
|
|
|
+ (
|
|
|
+ SELECT
|
|
|
+ count(1)
|
|
|
+ FROM
|
|
|
+ zhsq_person_tsrq
|
|
|
+ WHERE
|
|
|
+ tsrq_id = 20
|
|
|
+ ) laolingCount
|
|
|
FROM
|
|
|
zhsq_person p
|
|
|
- LEFT JOIN zhsq_person_tsrq t ON p.per_id = t.per_id
|
|
|
WHERE
|
|
|
p.del_flag = 0
|
|
|
AND p.per_del_state = 1
|