完善了之前的通知管理功能,支持对发送的通知的批量更改和删除;在学生证补办模块增加了完成制作功能。

This commit is contained in:
MDSMO
2025-08-11 15:25:53 +08:00
parent 28383d3a94
commit dd51721e4e
20 changed files with 510 additions and 178 deletions

View File

@@ -8,7 +8,7 @@ import org.apache.ibatis.annotations.Mapper;
/**
* 消息Mapper接口
*
*
* @author srs
* @date 2023-07-12
*/
@@ -17,7 +17,7 @@ public interface CphMsgMapper extends BaseMapper<CphMsg>
{
/**
* 查询消息
*
*
* @param id 消息主键
* @return 消息
*/
@@ -25,7 +25,7 @@ public interface CphMsgMapper extends BaseMapper<CphMsg>
/**
* 查询消息列表
*
*
* @param cphMsg 消息
* @return 消息集合
*/
@@ -33,7 +33,7 @@ public interface CphMsgMapper extends BaseMapper<CphMsg>
/**
* 新增消息
*
*
* @param cphMsg 消息
* @return 结果
*/
@@ -41,7 +41,7 @@ public interface CphMsgMapper extends BaseMapper<CphMsg>
/**
* 修改消息
*
*
* @param cphMsg 消息
* @return 结果
*/
@@ -49,7 +49,7 @@ public interface CphMsgMapper extends BaseMapper<CphMsg>
/**
* 删除消息
*
*
* @param id 消息主键
* @return 结果
*/
@@ -57,9 +57,18 @@ public interface CphMsgMapper extends BaseMapper<CphMsg>
/**
* 批量删除消息
*
*
* @param ids 需要删除的数据主键集合
* @return 结果
*/
public int deleteCphMsgByIds(Long[] ids);
/**
* 根据学号查询用户ID
*
* @param stuNo 学号
* @return 用户ID
*/
public Long getUserIdByStuNo(String stuNo);
}

View File

@@ -5,15 +5,15 @@ import com.srs.comprehensive.domain.CphMsg;
/**
* 消息Service接口
*
*
* @author srs
* @date 2023-07-12
*/
public interface ICphMsgService
public interface ICphMsgService
{
/**
* 查询消息
*
*
* @param id 消息主键
* @return 消息
*/
@@ -21,7 +21,7 @@ public interface ICphMsgService
/**
* 查询消息列表
*
*
* @param cphMsg 消息
* @return 消息集合
*/
@@ -29,7 +29,7 @@ public interface ICphMsgService
/**
* 新增消息
*
*
* @param cphMsg 消息
* @return 结果
*/
@@ -37,7 +37,7 @@ public interface ICphMsgService
/**
* 修改消息
*
*
* @param cphMsg 消息
* @return 结果
*/
@@ -45,7 +45,7 @@ public interface ICphMsgService
/**
* 批量删除消息
*
*
* @param ids 需要删除的消息主键集合
* @return 结果
*/
@@ -53,9 +53,17 @@ public interface ICphMsgService
/**
* 删除消息信息
*
*
* @param id 消息主键
* @return 结果
*/
public int deleteCphMsgById(Long id);
/**
* 根据学号查询用户ID
*
* @param stuNo 学号
* @return 用户ID
*/
public Long getUserIdByStuNo(String stuNo);
}

View File

@@ -12,7 +12,7 @@ import com.srs.comprehensive.service.ICphMsgService;
/**
* 消息Service业务层处理
*
*
* @author srs
* @date 2023-07-12
*/
@@ -24,7 +24,7 @@ public class CphMsgServiceImpl extends ServiceImpl<CphMsgMapper,CphMsg> implemen
/**
* 查询消息
*
*
* @param id 消息主键
* @return 消息
*/
@@ -36,7 +36,7 @@ public class CphMsgServiceImpl extends ServiceImpl<CphMsgMapper,CphMsg> implemen
/**
* 查询消息列表
*
*
* @param cphMsg 消息
* @return 消息
*/
@@ -48,7 +48,7 @@ public class CphMsgServiceImpl extends ServiceImpl<CphMsgMapper,CphMsg> implemen
/**
* 新增消息
*
*
* @param cphMsg 消息
* @return 结果
*/
@@ -61,7 +61,7 @@ public class CphMsgServiceImpl extends ServiceImpl<CphMsgMapper,CphMsg> implemen
/**
* 修改消息
*
*
* @param cphMsg 消息
* @return 结果
*/
@@ -74,7 +74,7 @@ public class CphMsgServiceImpl extends ServiceImpl<CphMsgMapper,CphMsg> implemen
/**
* 批量删除消息
*
*
* @param ids 需要删除的消息主键
* @return 结果
*/
@@ -86,7 +86,7 @@ public class CphMsgServiceImpl extends ServiceImpl<CphMsgMapper,CphMsg> implemen
/**
* 删除消息信息
*
*
* @param id 消息主键
* @return 结果
*/
@@ -95,4 +95,16 @@ public class CphMsgServiceImpl extends ServiceImpl<CphMsgMapper,CphMsg> implemen
{
return cphMsgMapper.deleteCphMsgById(id);
}
/**
* 根据学号查询用户ID
*
* @param stuNo 学号
* @return 用户ID
*/
@Override
public Long getUserIdByStuNo(String stuNo)
{
return cphMsgMapper.getUserIdByStuNo(stuNo);
}
}

View File

@@ -1,9 +1,9 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.srs.comprehensive.mapper.CphMsgMapper">
<resultMap type="CphMsg" id="CphMsgResult">
<result property="id" column="id" />
<result property="sender" column="sender" />
@@ -21,19 +21,19 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<select id="selectCphMsgList" parameterType="CphMsg" resultMap="CphMsgResult">
<include refid="selectCphMsgVo"/>
<where>
<where>
<if test="sender != null "> and sender = #{sender}</if>
<if test="receiver != null "> and receiver = #{receiver}</if>
<if test="content != null and content != ''"> and content = #{content}</if>
</where>
order by id desc
</select>
<select id="selectCphMsgById" parameterType="Long" resultMap="CphMsgResult">
<include refid="selectCphMsgVo"/>
where id = #{id}
</select>
<insert id="insertCphMsg" parameterType="CphMsg" useGeneratedKeys="true" keyProperty="id">
insert into cph_msg
<trim prefix="(" suffix=")" suffixOverrides=",">
@@ -44,7 +44,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="createTime != null">create_time,</if>
<if test="updateBy != null">update_by,</if>
<if test="updateTime != null">update_time,</if>
</trim>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="sender != null">#{sender},</if>
<if test="receiver != null">#{receiver},</if>
@@ -53,7 +53,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="createTime != null">#{createTime},</if>
<if test="updateBy != null">#{updateBy},</if>
<if test="updateTime != null">#{updateTime},</if>
</trim>
</trim>
</insert>
<update id="updateCphMsg" parameterType="CphMsg">
@@ -75,9 +75,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</delete>
<delete id="deleteCphMsgByIds" parameterType="String">
delete from cph_msg where id in
delete from cph_msg where id in
<foreach item="id" collection="array" open="(" separator="," close=")">
#{id}
</foreach>
</delete>
</mapper>
<select id="getUserIdByStuNo" parameterType="String" resultType="Long">
select user_id from sys_user where user_name = #{stuNo}
</select>
</mapper>