inleft
2022-02-27 2782f3e576b56a9ca078055026394646d57440f8
commit | author | age
9bcb19 1 <?xml version="1.0" encoding="UTF-8"?>
I 2 <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
3 <mapper namespace="vip.xiaonuo.sys.modular.notice.mapper.SysNoticeMapper">
4
5     <resultMap id="sysNoticeReceiveResult" type="vip.xiaonuo.sys.modular.notice.result.SysNoticeReceiveResult">
6         <id column="id" property="id" />
7         <result column="title" property="title" />
8         <result column="content" property="content" />
9         <result column="type" property="type" />
10         <result column="public_user_id" property="publicUserId" />
11         <result column="public_user_name" property="publicUserName" />
12         <result column="public_org_id" property="publicOrgId" />
13         <result column="public_org_name" property="publicOrgName" />
14         <result column="public_time" property="publicTime" />
15         <result column="cancel_time" property="cancelTime" />
16         <result column="read_status" property="readStatus" />
17         <result column="read_time" property="readTime" />
18     </resultMap>
19
20     <select id="page" resultMap="sysNoticeReceiveResult">
21         select
22             sys_notice.*,
23             sys_notice_user.status as read_status,
24             sys_notice_user.read_time as read_time
25         from
26             sys_notice
27                 left join sys_notice_user on sys_notice.id = sys_notice_user.notice_id
28         ${ew.customSqlSegment}
29     </select>
30 </mapper>