Merge remote-tracking branch 'origin/main'

This commit is contained in:
2025-12-10 09:38:43 +08:00
109 changed files with 6403 additions and 470 deletions

View File

@@ -267,7 +267,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
left join view_stu_info as b on a.stu_no = b.stu_no
left join srs_stu_year as c on a.stu_year_id = c.id
left join cph_teacher as d on a.fdy_no = d.employee_id
left join qgzx_teacher as e on a.dept_no = d.employee_id
left join qgzx_teacher as e on a.dept_no = e.employee_id
left join qgzx_teacher as f on a.xg_no = f.employee_id
left join qgzx_teacher as g on a.leader_no = g.employee_id
<where>

View File

@@ -192,7 +192,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<sql id="selectSrsKnrdApplyVo">
select * from srs_knrd_apply
select t.knrd_type as knlx, a.*
from srs_knrd_apply as a
left join srs_knrd_type as t
on t.stu_no = a.xh
and t.stu_year_id = a.stu_year_id
</sql>
<select id="selectSrsKnrdApplyList" parameterType="SrsKnrdApply" resultMap="SrsKnrdApplyResult">
@@ -247,11 +251,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<select id="selectSrsKnrdApplyById" parameterType="Long" resultMap="SrsKnrdApplyResult">
<include refid="selectSrsKnrdApplyVo"/>
where id = #{id}
where a.id = #{id}
</select>
<select id="selectSrsKnrdApplyBysfz" resultType="com.srs.comprehensive.domain.SrsKnrdApply">
<include refid="selectSrsKnrdApplyVo"/>
where sfzhm = #{sfzhm} and stu_year_id = #{stuYearId}
where a.sfzhm = #{sfzhm} and a.stu_year_id = #{stuYearId}
</select>
<select id="selectsfzhm" resultType="com.srs.comprehensive.domain.SrsKnrdApply">
select * from srs_student where id_card=#{sfzhm}

View File

@@ -176,4 +176,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
left join sys_dept as b on a.old_dept_id = b.dept_id
where b.dept_name = #{deptName}
</select>
<select id="getOwnMajorName" resultType="com.srs.comprehensive.domain.SrsMajors" parameterType="String">
select c.major_name
from srs_student a left join srs_class b on a.class_id=b.class_id
left join srs_majors c on a.major_id=c.major_id
where a.stu_no=#{stuNo}
</select>
</mapper>

View File

@@ -28,6 +28,7 @@
<result property="cphName" column="cphName"/>
<result property="gradeName" column="grade_name"/>
<result property="status2" column="status2"/>
<result property="deptName" column="dept_name" />
<association property="dept" column="dept_id" javaType="SysDept" resultMap="deptResult"/>
<association property="srsMajors" column="major_id" javaType="srsMajors" resultMap="SrsMajorsResult"/>
<association property="srsClass" column="class_id" javaType="srsClass" resultMap="SrsClassResult"/>
@@ -200,7 +201,7 @@
<include refid="selectSrsStudentJoin"/>
where stu_id = #{stuId}
</select>
<select id="selectSrsStudentByStuNo" parameterType="string" resultMap="SrsStudentResult">
<select id="selectSrsStudentByStuNo" parameterType="String" resultMap="SrsStudentResult">
<include refid="selectSrsStudentVo"/>
where stu_no = #{stuNo}
</select>
@@ -729,7 +730,7 @@
total_count,
male_count,
female_count
from (select left (AES_DECRYPT(UNHEX(id_card), 'zhxg'), 4) as id_card, count(1) as total_count, sum(case when gender='男' then 1 else 0 end) as male_count, sum(case when gender='女' then 1 else 0 end) as female_count
from (select left (AES_DECRYPT(UNHEX(id_card), 'zhxg'), 4) as id_card, count (1) as total_count, sum (case when gender='男' then 1 else 0 end) as male_count, sum (case when gender='女' then 1 else 0 end) as female_count
from srs_student d left join srs_class e
on d.class_id=e.class_id
left join srs_grade f on f.grade_id=e.grade_id
@@ -749,7 +750,7 @@
order by grade_code desc
</select>
<select id="getSchoolTotalCount" resultType="java.util.Map">
SELECT COUNT(1) AS TotalCount,
SELECT COUNT(1) AS TotalCount,
SUM(CASE WHEN gender = '男' THEN 1 ELSE 0 END) AS NaCount,
SUM(CASE WHEN gender = '女' THEN 1 ELSE 0 END) AS NvCount,
CONCAT(ROUND(SUM(CASE WHEN gender = '男' THEN 1 ELSE 0 END) / COUNT(*) * 100, 2), '%') AS NaZB,
@@ -781,7 +782,7 @@
total_count,
male_count,
female_count
from (select left (AES_DECRYPT(UNHEX(id_card), 'zhxg'), 4) as id_card, count(1) as total_count, sum(case when gender='男' then 1 else 0 end) as male_count, sum(case when gender='女' then 1 else 0 end) as female_count
from (select left (AES_DECRYPT(UNHEX(id_card), 'zhxg'), 4) as id_card, count (1) as total_count, sum (case when gender='男' then 1 else 0 end) as male_count, sum (case when gender='女' then 1 else 0 end) as female_count
from srs_student d left join srs_class e
on d.class_id=e.class_id
left join srs_grade f on f.grade_id=e.grade_id
@@ -790,7 +791,7 @@
where c.city is null
</select>
<select id="getMajorsCount" resultType="java.util.Map">
select d.dept_name as deptName,
select d.dept_name as deptName,
count(case when year (CURDATE())-f.grade_code=1 then '大一' end) as firstCount,
count(case when year (CURDATE())-f.grade_code=2 then '大二' end) as thirdCount,
count(case when year (CURDATE())-f.grade_code=3 then '大三' end) as secondCount
@@ -821,4 +822,37 @@
from sys_dict_data
where dict_type = 'srs_stu_status'
</select>
<select id="selectSrsStudentByStuNoNew" parameterType="String" resultType="com.srs.comprehensive.domain.SrsStudent">
select s.stu_id,
s.stu_no,
s.name,
s.gender,
s.birthday,
AES_DECRYPT(UNHEX(s.id_card), 'zhxg') as id_card,
s.dept_id,
m.major_id,
c.class_id,
s.phone,
s.address,
s.status,
s.create_by,
s.create_time,
s.update_by,
s.update_time,
s.del_flag,
s.xhk,
s.bank_addr,
d.dept_name,
f.grade_name,
h.stu_year_name,
g.need_money
from srs_student s
left join srs_class c on s.class_id = c.class_id
left join srs_majors m on c.major_id = m.major_id
left join sys_dept d on m.college_id = d.dept_id
left join srs_grade as f on f.grade_id = c.grade_id
left join dms_new_record g on s.stu_no=g.stu_no
left join srs_stu_year h on g.stu_year_id=h.id
where s.stu_no = #{stuNo}
</select>
</mapper>

View File

@@ -75,79 +75,90 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</resultMap>
<sql id="selectSrsZxjApplyVo">
select id, step, xm, xb, mz, zzmm, xh, rxsj, csny, dh, nj, xy, zy, bj, kndj, knlx, knlx2, rkzs, yzsr, rjyr, srly, jtcy, sqly, fdyqm, fdyqmrq, ejxyldqm, ejxyldqmrq, xsqm, xsqmrq, csdj, zzdj, zzls, zp,affix_id,status1,status2,status3,dz,yb,xxyjrq,apply_year,locked,level,
EXISTS(SELECT application_id FROM rt_stu_disciplinary_application rsda WHERE rsda.stu_no = srs_zxj_apply.xh and (penalty_status = 0 or penalty_status = 2)) as penalty_status0,
EXISTS(SELECT application_id FROM rt_stu_disciplinary_application rsda WHERE rsda.stu_no = srs_zxj_apply.xh and (penalty_status = 1 )) as penalty_status1,
EXISTS(SELECT application_id FROM rt_stu_disciplinary_application rsda WHERE rsda.stu_no = srs_zxj_apply.xh and (penalty_status = 3 )) as penalty_status3,
sfzhm,
gyhd,
bankCard,
bankAddr,
rjnsr,
bjyj,
bjyjdj,
ejxyyj,
ejxyyjdj,
xxyj,
xxqm,
stu_year_id,fdygh,fdymc,ejxyldmc,ejxyldgh,xxmc,xxgh
from srs_zxj_apply
select a.id, a.step, a.xm, a.xb, a.mz, a.zzmm, a.xh, a.rxsj, a.csny, a.dh, a.nj, a.xy, a.zy, a.bj, a.kndj,
t.knrd_type as knlx,
a.knlx2, a.rkzs, a.yzsr, a.rjyr, a.srly, a.jtcy, a.sqly, a.fdyqm, a.fdyqmrq, a.ejxyldqm, a.ejxyldqmrq,
a.xsqm, a.xsqmrq, a.csdj, a.zzdj, a.zzls, a.zp, a.affix_id, a.status1, a.status2, a.status3, a.dz, a.yb,
a.xxyjrq, a.apply_year, a.locked, a.level,
EXISTS(SELECT application_id FROM rt_stu_disciplinary_application rsda WHERE rsda.stu_no = a.xh and (penalty_status = 0 or penalty_status = 2)) as penalty_status0,
EXISTS(SELECT application_id FROM rt_stu_disciplinary_application rsda WHERE rsda.stu_no = a.xh and (penalty_status = 1 )) as penalty_status1,
EXISTS(SELECT application_id FROM rt_stu_disciplinary_application rsda WHERE rsda.stu_no = a.xh and (penalty_status = 3 )) as penalty_status3,
a.sfzhm,
a.gyhd,
a.bankCard,
a.bankAddr,
a.rjnsr,
a.bjyj,
a.bjyjdj,
a.ejxyyj,
a.ejxyyjdj,
a.xxyj,
a.xxqm,
a.stu_year_id, a.fdygh, a.fdymc, a.ejxyldmc, a.ejxyldgh, a.xxmc, a.xxgh
from srs_zxj_apply as a
left join srs_knrd_type as t
on t.stu_no = a.xh
and t.stu_year_id = a.stu_year_id
</sql>
<select id="selectSrsZxjApplyList" parameterType="SrsZxjApply" resultMap="SrsZxjApplyResult">
<include refid="selectSrsZxjApplyVo"/>
<where>
<if test="step != null "> and step = #{step}</if>
<if test="xm != null and xm != ''"> and xm = #{xm}</if>
<if test="xb != null and xb != ''"> and xb = #{xb}</if>
<if test="mz != null and mz != ''"> and mz = #{mz}</if>
<if test="zzmm != null and zzmm != ''"> and zzmm = #{zzmm}</if>
<if test="xh != null and xh != ''"> and xh = #{xh}</if>
<if test="rxsj != null and rxsj != ''"> and rxsj = #{rxsj}</if>
<if test="csny != null and csny != ''"> and csny = #{csny}</if>
<if test="dh != null and dh != ''"> and dh = #{dh}</if>
<if test="nj != null and nj != ''"> and nj = #{nj}</if>
<if test="xy != null and xy != ''"> and xy = #{xy}</if>
<if test="zy != null and zy != ''"> and zy = #{zy}</if>
<if test="bj != null and bj != ''"> and bj = #{bj}</if>
<if test="kndj != null and kndj != ''"> and kndj = #{kndj}</if>
<if test="knlx != null and knlx != ''"> and knlx = #{knlx}</if>
<if test="knlx2 != null and knlx2 != ''"> and knlx2 = #{knlx2}</if>
<if test="rkzs != null and rkzs != ''"> and rkzs = #{rkzs}</if>
<if test="yzsr != null and yzsr != ''"> and yzsr = #{yzsr}</if>
<if test="rjyr != null and rjyr != ''"> and rjyr = #{rjyr}</if>
<if test="srly != null and srly != ''"> and srly = #{srly}</if>
<if test="jtcy != null and jtcy != ''"> and jtcy = #{jtcy}</if>
<if test="sqly != null and sqly != ''"> and sqly = #{sqly}</if>
<if test="fdyqm != null and fdyqm != ''"> and fdyqm = #{fdyqm}</if>
<if test="fdyqmrq != null and fdyqmrq != ''"> and fdyqmrq = #{fdyqmrq}</if>
<if test="ejxyldqm != null and ejxyldqm != ''"> and ejxyldqm = #{ejxyldqm}</if>
<if test="ejxyldqmrq != null and ejxyldqmrq != ''"> and ejxyldqmrq = #{ejxyldqmrq}</if>
<if test="xsqm != null and xsqm != ''"> and xsqm = #{xsqm}</if>
<if test="xsqmrq != null and xsqmrq != ''"> and xsqmrq = #{xsqmrq}</if>
<if test="csdj != null and csdj != ''"> and csdj = #{csdj}</if>
<if test="zzdj != null and zzdj != ''"> and zzdj = #{zzdj}</if>
<if test="zzls != null and zzls != ''"> and zzls = #{zzls}</if>
<if test="zp != null and zp != ''"> and zp = #{zp}</if>
<if test="affixId != null and affixId != ''"> and affix_id = #{affixId}</if>
<if test="status1 != null and status1 != ''"> and status1 = #{status1}</if>
<if test="status2 != null and status2 != ''"> and status2 = #{status2}</if>
<if test="status3 != null and status3 != ''"> and status3 = #{status3}</if>
<if test="dz != null and dz != ''"> and dz = #{dz}</if>
<if test="yb != null and yb != ''"> and yb = #{yb}</if>
<if test="xxyjrq != null and xxyjrq != ''"> and xxyjrq = #{xxyjrq}</if>
<if test="applyYear != null and applyYear != ''"> and apply_year = #{applyYear}</if>
<if test="stuYearId != null and stuYearId != ''"> and stu_year_id = #{stuYearId}</if>
<if test="step != null "> and a.step = #{step}</if>
<if test="xm != null and xm != ''"> and a.xm = #{xm}</if>
<if test="xb != null and xb != ''"> and a.xb = #{xb}</if>
<if test="mz != null and mz != ''"> and a.mz = #{mz}</if>
<if test="zzmm != null and zzmm != ''"> and a.zzmm = #{zzmm}</if>
<if test="xh != null and xh != ''"> and a.xh = #{xh}</if>
<if test="rxsj != null and rxsj != ''"> and a.rxsj = #{rxsj}</if>
<if test="csny != null and csny != ''"> and a.csny = #{csny}</if>
<if test="dh != null and dh != ''"> and a.dh = #{dh}</if>
<if test="nj != null and nj != ''"> and a.nj = #{nj}</if>
<if test="xy != null and xy != ''"> and a.xy = #{xy}</if>
<if test="zy != null and zy != ''"> and a.zy = #{zy}</if>
<if test="bj != null and bj != ''"> and a.bj = #{bj}</if>
<if test="kndj != null and kndj != ''"> and a.kndj = #{kndj}</if>
<if test="knlx != null and knlx != ''"> and t.knrd_type = #{knlx}</if>
<if test="knlx2 != null and knlx2 != ''"> and a.knlx2 = #{knlx2}</if>
<if test="rkzs != null and rkzs != ''"> and a.rkzs = #{rkzs}</if>
<if test="yzsr != null and yzsr != ''"> and a.yzsr = #{yzsr}</if>
<if test="rjyr != null and rjyr != ''"> and a.rjyr = #{rjyr}</if>
<if test="srly != null and srly != ''"> and a.srly = #{srly}</if>
<if test="jtcy != null and jtcy != ''"> and a.jtcy = #{jtcy}</if>
<if test="sqly != null and sqly != ''"> and a.sqly = #{sqly}</if>
<if test="fdyqm != null and fdyqm != ''"> and a.fdyqm = #{fdyqm}</if>
<if test="fdyqmrq != null and fdyqmrq != ''"> and a.fdyqmrq = #{fdyqmrq}</if>
<if test="ejxyldqm != null and ejxyldqm != ''"> and a.ejxyldqm = #{ejxyldqm}</if>
<if test="ejxyldqmrq != null and ejxyldqmrq != ''"> and a.ejxyldqmrq = #{ejxyldqmrq}</if>
<if test="xsqm != null and xsqm != ''"> and a.xsqm = #{xsqm}</if>
<if test="xsqmrq != null and xsqmrq != ''"> and a.xsqmrq = #{xsqmrq}</if>
<if test="csdj != null and csdj != ''"> and a.csdj = #{csdj}</if>
<if test="zzdj != null and zzdj != ''"> and a.zzdj = #{zzdj}</if>
<if test="zzls != null and zzls != ''"> and a.zzls = #{zzls}</if>
<if test="zp != null and zp != ''"> and a.zp = #{zp}</if>
<if test="affixId != null and affixId != ''"> and a.affix_id = #{affixId}</if>
<if test="status1 != null and status1 != ''"> and a.status1 = #{status1}</if>
<if test="status2 != null and status2 != ''"> and a.status2 = #{status2}</if>
<if test="status3 != null and status3 != ''"> and a.status3 = #{status3}</if>
<if test="dz != null and dz != ''"> and a.dz = #{dz}</if>
<if test="yb != null and yb != ''"> and a.yb = #{yb}</if>
<if test="xxyjrq != null and xxyjrq != ''"> and a.xxyjrq = #{xxyjrq}</if>
<if test="applyYear != null and applyYear != ''"> and a.apply_year = #{applyYear}</if>
<if test="stuYearId != null and stuYearId != ''"> and a.stu_year_id = #{stuYearId}</if>
</where>
</select>
<select id="selectSrsZxjApplyById" parameterType="Long" resultMap="SrsZxjApplyResult">
<include refid="selectSrsZxjApplyVo"/>
where id = #{id}
where a.id = #{id}
</select>
<!-- 仅更新申请理由sqly -->
<update id="updateSqly">
update srs_zxj_apply
set sqly = #{sqly}
where id = #{id}
</update>
<!-- 获取下一个未审批的-->
<select id="nextApply" parameterType="CphSearch" resultMap="SrsZxjApplyResult">
select a.*
@@ -245,7 +256,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
a.zy as zy,
a.bj as bj,
a.kndj as kndj,
a.knlx as knlx,
t.knrd_type as knlx,
a.knlx2 as knlx2,
a.rkzs as rkzs,
a.yzsr as yzsr,
@@ -291,6 +302,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
left join srs_class as c on b.class_id = c.class_id
left join srs_majors as d on c.major_id = d.major_id
left join cph_teacher as e on c.teacher_id = e.teacher_id
left join srs_knrd_type as t on t.stu_no = a.xh and t.stu_year_id = a.stu_year_id
left join (
SELECT * FROM (
SELECT *,

View File

@@ -81,6 +81,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
right join srs_zxj_approval_record as r on r.apply_id = a.id
where
r.step != 0 and r.step != 1
and a.step != 0
<if test="step != null "> and r.step = #{step}</if>
<if test="tNo != null "> and e.employee_id = #{tNo}</if>
<if test="deptId != null "> and d.college_id = #{deptId}</if>