首页固定死的统计展示

This commit is contained in:
2025-06-30 15:24:59 +08:00
parent a0b941e3f7
commit a5de881f9d
12 changed files with 264 additions and 8 deletions

View File

@ -5,10 +5,12 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<mapper namespace="com.ruoyi.dw.mapper.CjStudentMapper">
<resultMap type="CjStudent" id="CjStudentResult">
<result property="id" column="id" />
<result property="xm" column="xm" />
<result property="xb" column="xb" />
<result property="zy" column="zy" />
<result property="id" column="id" />
<result property="xm" column="xm" />
<result property="xb" column="xb" />
<result property="zy" column="zy" />
<result property="sydsh" column="sydsh" />
<result property="sydshi" column="sydshi" />
<result property="bynf" column="bynf" />
<result property="zgyl" column="zgyl" />
<result property="gzdw" column="gzdw" />
@ -18,6 +20,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result property="shjz" column="shjz" />
<result property="dbry" column="dbry" />
<result property="rysfzs" column="rysfzs" />
<result property="ry" column="ry" />
<result property="sj" column="sj" />
<result property="yx" column="yx" />
<result property="qt" column="qt" />
@ -25,7 +28,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</resultMap>
<sql id="selectCjStudentVo">
select id, xm, xb, zy, bynf, zgyl, gzdw, dwxz, dwdz, zwjb, shjz, dbry, rysfzs, sj, yx, qt, sfqr from cj_student
select id, xm,sydsh, sydshi, xb, zy, bynf, zgyl, gzdw, dwxz, dwdz, zwjb, shjz, dbry, rysfzs, ry,sj, yx, qt, sfqr from cj_student
</sql>
<select id="selectCjStudentList" parameterType="CjStudent" resultMap="CjStudentResult">
@ -34,6 +37,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="xm != null and xm != ''"> and xm = #{xm}</if>
<if test="xb != null and xb != ''"> and xb = #{xb}</if>
<if test="zy != null and zy != ''"> and zy = #{zy}</if>
<if test="sydsh != null and sydsh != ''"> and sydsh = #{sydsh}</if>
<if test="sydshi != null and sydshi != ''"> and sydshi = #{sydshi}</if>
<if test="bynf != null "> and bynf = #{bynf}</if>
<if test="zgyl != null and zgyl != ''"> and zgyl = #{zgyl}</if>
<if test="gzdw != null and gzdw != ''"> and gzdw = #{gzdw}</if>
@ -61,6 +66,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="xm != null">xm,</if>
<if test="xb != null">xb,</if>
<if test="zy != null">zy,</if>
<if test="sydsh != null">sydsh,</if>
<if test="sydshi != null">sydshi,</if>
<if test="bynf != null">bynf,</if>
<if test="zgyl != null">zgyl,</if>
<if test="gzdw != null">gzdw,</if>
@ -70,6 +77,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="shjz != null">shjz,</if>
<if test="dbry != null">dbry,</if>
<if test="rysfzs != null">rysfzs,</if>
<if test="ry != null">ry,</if>
<if test="sj != null">sj,</if>
<if test="yx != null">yx,</if>
<if test="qt != null">qt,</if>
@ -79,6 +87,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="xm != null">#{xm},</if>
<if test="xb != null">#{xb},</if>
<if test="zy != null">#{zy},</if>
<if test="sydsh != null">#{sydsh},</if>
<if test="sydshi != null">#{sydshi},</if>
<if test="bynf != null">#{bynf},</if>
<if test="zgyl != null">#{zgyl},</if>
<if test="gzdw != null">#{gzdw},</if>
@ -88,6 +98,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="shjz != null">#{shjz},</if>
<if test="dbry != null">#{dbry},</if>
<if test="rysfzs != null">#{rysfzs},</if>
<if test="ry != null">#{ry},</if>
<if test="sj != null">#{sj},</if>
<if test="yx != null">#{yx},</if>
<if test="qt != null">#{qt},</if>
@ -101,6 +112,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="xm != null">xm = #{xm},</if>
<if test="xb != null">xb = #{xb},</if>
<if test="zy != null">zy = #{zy},</if>
<if test="sydsh != null">sydsh = #{sydsh},</if>
<if test="sydshi != null">sydshi = #{sydshi},</if>
<if test="bynf != null">bynf = #{bynf},</if>
<if test="zgyl != null">zgyl = #{zgyl},</if>
<if test="gzdw != null">gzdw = #{gzdw},</if>
@ -110,6 +123,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="shjz != null">shjz = #{shjz},</if>
<if test="dbry != null">dbry = #{dbry},</if>
<if test="rysfzs != null">rysfzs = #{rysfzs},</if>
<if test="ry != null">ry = #{ry},</if>
<if test="sj != null">sj = #{sj},</if>
<if test="yx != null">yx = #{yx},</if>
<if test="qt != null">qt = #{qt},</if>

View File

@ -98,4 +98,34 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</foreach>
group by answer
</select>
<select id="selectBynf" resultType="com.ruoyi.dw.domain.vo.BynfVo">
select bynf,count(0) as bubf_count from cj_student where sfqr = 1 group by bynf order by bynf desc
</select>
<select id="selectSyd" resultType="com.ruoyi.dw.domain.vo.SydVo">
SELECT
CASE
WHEN sydsh = '山东省' THEN sydshi
ELSE '省外'
END AS city,
COUNT(*) AS student_count
FROM cj_student
where sfqr = 1
GROUP BY
CASE
WHEN sydsh = '山东省' THEN sydshi
ELSE '省外'
END
ORDER BY
CASE
WHEN syd_sheng = '山东省' THEN sydshi
ELSE sydsh
END;
</select>
<select id="selectDwxz" resultType="com.ruoyi.dw.domain.vo.DwxzVo">
select dwxz,count(0) as dwxz_count from cj_student where sfqr = 1 group by dwxz
</select>
</mapper>