|
@@ -17,8 +17,8 @@
|
|
|
<result property="status" column="status" />
|
|
<result property="status" column="status" />
|
|
|
<result property="deptId" column="dept_id" />
|
|
<result property="deptId" column="dept_id" />
|
|
|
<result property="deptName" column="dept_name" />
|
|
<result property="deptName" column="dept_name" />
|
|
|
- <result property="createUserid" column="create_userid" />
|
|
|
|
|
- <result property="createUsername" column="create_username" />
|
|
|
|
|
|
|
+ <result property="userId" column="user_id" />
|
|
|
|
|
+ <result property="createBy" column="create_by" />
|
|
|
<result property="createTime" column="create_time" />
|
|
<result property="createTime" column="create_time" />
|
|
|
<result property="updateUserid" column="update_userid" />
|
|
<result property="updateUserid" column="update_userid" />
|
|
|
<result property="updateUsername" column="update_username" />
|
|
<result property="updateUsername" column="update_username" />
|
|
@@ -38,8 +38,8 @@
|
|
|
<result property="status" column="status" />
|
|
<result property="status" column="status" />
|
|
|
<result property="deptId" column="dept_id" />
|
|
<result property="deptId" column="dept_id" />
|
|
|
<result property="deptName" column="dept_name" />
|
|
<result property="deptName" column="dept_name" />
|
|
|
- <result property="createUserid" column="create_userid" />
|
|
|
|
|
- <result property="createUsername" column="create_username" />
|
|
|
|
|
|
|
+ <result property="userId" column="user_id" />
|
|
|
|
|
+ <result property="createBy" column="create_by" />
|
|
|
<result property="createTime" column="create_time" />
|
|
<result property="createTime" column="create_time" />
|
|
|
<result property="updateUserid" column="update_userid" />
|
|
<result property="updateUserid" column="update_userid" />
|
|
|
<result property="updateUsername" column="update_username" />
|
|
<result property="updateUsername" column="update_username" />
|
|
@@ -48,73 +48,75 @@
|
|
|
|
|
|
|
|
<sql id="selectLabNotifyplanVo">
|
|
<sql id="selectLabNotifyplanVo">
|
|
|
select id, title, notify_type, type, content_name, content_url, content, company,con_abstract,
|
|
select id, title, notify_type, type, content_name, content_url, content, company,con_abstract,
|
|
|
- status,dept_id,dept_name, create_userid, user_id,create_username,
|
|
|
|
|
- create_time, update_userid, update_username, update_time, DATE_FORMAT(create_time,'%Y-%m-%d %H:%i') time from
|
|
|
|
|
- (select t.*,t.create_userid user_id from lab_notifyplan t) t
|
|
|
|
|
|
|
+ status,dept_id,dept_name, user_id,create_by,
|
|
|
|
|
+ create_time, update_userid, update_username, update_time, DATE_FORMAT(create_time,'%Y-%m-%d %H:%i') time
|
|
|
|
|
+ from lab_notifyplan t
|
|
|
</sql>
|
|
</sql>
|
|
|
<sql id="selectLabNotifyplanListVo">
|
|
<sql id="selectLabNotifyplanListVo">
|
|
|
select t.id, t.title, t.notify_type, t.type, t.content_name, t.content_url, t.content,
|
|
select t.id, t.title, t.notify_type, t.type, t.content_name, t.content_url, t.content,
|
|
|
- t.company,t.con_abstract, t.status,t.dept_id,t.dept_name, t.create_userid,user_id,
|
|
|
|
|
- t.create_username, t.create_time, t.update_userid, t.update_username, t.update_time ,DATE_FORMAT(t.create_time,'%Y-%m-%d %H:%i') time
|
|
|
|
|
- from (select t.*,t.create_userid user_id from lab_notifyplan t) as t
|
|
|
|
|
|
|
+ t.company,t.con_abstract, t.status,t.dept_id,t.dept_name, t.user_id,
|
|
|
|
|
+ t.create_by, t.create_time, t.update_userid, t.update_username, t.update_time ,DATE_FORMAT(t.create_time,'%Y-%m-%d %H:%i') time
|
|
|
|
|
+ from lab_notifyplan t
|
|
|
|
|
+ left join sys_dept d on t.dept_id=d.dept_id
|
|
|
|
|
+ left join sys_user u on t.user_id=u.user_id
|
|
|
</sql>
|
|
</sql>
|
|
|
<select id="selectLabNotifyplanList" parameterType="com.zd.laboratory.domain.LabNotifyplan" resultMap="LabNotifyplanResult">
|
|
<select id="selectLabNotifyplanList" parameterType="com.zd.laboratory.domain.LabNotifyplan" resultMap="LabNotifyplanResult">
|
|
|
<include refid="selectLabNotifyplanVo"/>
|
|
<include refid="selectLabNotifyplanVo"/>
|
|
|
<where>
|
|
<where>
|
|
|
- <if test="title != null and title != ''"> and title like concat('%', #{title}, '%')</if>
|
|
|
|
|
- <if test="notifyType != null "> and notify_type = #{notifyType}</if>
|
|
|
|
|
- <if test="type != null "> and type = #{type}</if>
|
|
|
|
|
- <if test="contentName != null and contentName != ''"> and content_name like concat('%', #{contentName}, '%')</if>
|
|
|
|
|
- <if test="contentUrl != null and contentUrl != ''"> and content_url = #{contentUrl}</if>
|
|
|
|
|
- <if test="content != null and content != ''"> and content = #{content}</if>
|
|
|
|
|
- <if test="company != null and company != ''"> and company = #{company}</if>
|
|
|
|
|
- <if test="conAbstract != null and conAbstract != ''"> and con_abstract = #{conAbstract}</if>
|
|
|
|
|
- <if test="status != null "> and status = #{status}</if>
|
|
|
|
|
- <if test="deptId != null "> and dept_id = #{deptId}</if>
|
|
|
|
|
- <if test="deptName != null "> and dept_name = #{deptName}</if>
|
|
|
|
|
- <if test="createUserid != null "> and create_userid = #{createUserid}</if>
|
|
|
|
|
- <if test="createUsername != null and createUsername != ''"> and create_username like concat('%', #{createUsername}, '%')</if>
|
|
|
|
|
- <if test="updateUserid != null "> and update_userid = #{updateUserid}</if>
|
|
|
|
|
- <if test="updateUsername != null and updateUsername != ''"> and update_username like concat('%', #{updateUsername}, '%')</if>
|
|
|
|
|
|
|
+ <if test="title != null and title != ''"> and t.title like concat('%', #{title}, '%')</if>
|
|
|
|
|
+ <if test="notifyType != null "> and t.notify_type = #{notifyType}</if>
|
|
|
|
|
+ <if test="type != null "> and t.type = #{type}</if>
|
|
|
|
|
+ <if test="contentName != null and contentName != ''"> and t.content_name like concat('%', #{contentName}, '%')</if>
|
|
|
|
|
+ <if test="contentUrl != null and contentUrl != ''"> and t.content_url = #{contentUrl}</if>
|
|
|
|
|
+ <if test="content != null and content != ''"> and t.content = #{content}</if>
|
|
|
|
|
+ <if test="company != null and company != ''"> and t.company = #{company}</if>
|
|
|
|
|
+ <if test="conAbstract != null and conAbstract != ''"> and t.con_abstract = #{conAbstract}</if>
|
|
|
|
|
+ <if test="status != null "> and t.status = #{status}</if>
|
|
|
|
|
+ <if test="deptId != null "> and t.dept_id = #{deptId}</if>
|
|
|
|
|
+ <if test="deptName != null "> and t.dept_name = #{deptName}</if>
|
|
|
|
|
+ <if test="userId != null "> and t.user_id = #{userId}</if>
|
|
|
|
|
+ <if test="createBy != null and createBy != ''"> and t.create_by like concat('%', #{createBy}, '%')</if>
|
|
|
|
|
+ <if test="updateUserid != null "> and t.update_userid = #{updateUserid}</if>
|
|
|
|
|
+ <if test="updateUsername != null and updateUsername != ''"> and t.update_username like concat('%', #{updateUsername}, '%')</if>
|
|
|
</where>
|
|
</where>
|
|
|
- order by create_time desc
|
|
|
|
|
|
|
+ order by t.create_time desc
|
|
|
</select>
|
|
</select>
|
|
|
|
|
|
|
|
<select id="selectLabNotifyplanListVO" parameterType="com.zd.laboratory.domain.vo.LabNotifyplanVO" resultMap="LabNotifyplanResultVO">
|
|
<select id="selectLabNotifyplanListVO" parameterType="com.zd.laboratory.domain.vo.LabNotifyplanVO" resultMap="LabNotifyplanResultVO">
|
|
|
- <include refid="selectLabNotifyplanVo"/>
|
|
|
|
|
|
|
+ <include refid="selectLabNotifyplanListVo"/>
|
|
|
<where>
|
|
<where>
|
|
|
- <if test="title != null and title != ''"> and title like concat('%', #{title}, '%')</if>
|
|
|
|
|
- <if test="notifyType != null "> and notify_type = #{notifyType}</if>
|
|
|
|
|
- <if test="type != null "> and type = #{type}</if>
|
|
|
|
|
- <if test="contentName != null and contentName != ''"> and content_name like concat('%', #{contentName}, '%')</if>
|
|
|
|
|
- <if test="contentUrl != null and contentUrl != ''"> and content_url = #{contentUrl}</if>
|
|
|
|
|
- <if test="content != null and content != ''"> and content = #{content}</if>
|
|
|
|
|
- <if test="company != null and company != ''"> and company like concat('%', #{company}, '%')</if>
|
|
|
|
|
- <if test="conAbstract != null and conAbstract != ''"> and con_abstract like concat('%', #{conAbstract}, '%')</if>
|
|
|
|
|
- <if test="status != null "> and status = #{status}</if>
|
|
|
|
|
- <if test="deptId != null "> and dept_id = #{deptId}</if>
|
|
|
|
|
- <if test="deptName != null "> and dept_name = #{deptName}</if>
|
|
|
|
|
- <if test="createUserid != null "> and create_userid = #{createUserid}</if>
|
|
|
|
|
- <if test="createUsername != null and createUsername != ''"> and create_username like concat('%', #{createUsername}, '%')</if>
|
|
|
|
|
- <if test="updateUserid != null "> and update_userid = #{updateUserid}</if>
|
|
|
|
|
- <if test="updateUsername != null and updateUsername != ''"> and update_username like concat('%', #{updateUsername}, '%')</if>
|
|
|
|
|
|
|
+ <if test="title != null and title != ''"> and t.title like concat('%', #{title}, '%')</if>
|
|
|
|
|
+ <if test="notifyType != null "> and t.notify_type = #{notifyType}</if>
|
|
|
|
|
+ <if test="type != null "> and t.type = #{type}</if>
|
|
|
|
|
+ <if test="contentName != null and contentName != ''"> and t.content_name like concat('%', #{contentName}, '%')</if>
|
|
|
|
|
+ <if test="contentUrl != null and contentUrl != ''"> and t.content_url = #{contentUrl}</if>
|
|
|
|
|
+ <if test="content != null and content != ''"> and t.content = #{content}</if>
|
|
|
|
|
+ <if test="company != null and company != ''"> and t.company like concat('%', #{company}, '%')</if>
|
|
|
|
|
+ <if test="conAbstract != null and conAbstract != ''"> and t.con_abstract like concat('%', #{conAbstract}, '%')</if>
|
|
|
|
|
+ <if test="status != null "> and t.status = #{status}</if>
|
|
|
|
|
+ <if test="deptId != null "> and t.dept_id = #{deptId}</if>
|
|
|
|
|
+ <if test="deptName != null "> and t.dept_name = #{deptName}</if>
|
|
|
|
|
+ <if test="userId != null "> and t.user_id = #{userId}</if>
|
|
|
|
|
+ <if test="createBy != null and createBy != ''"> and t.create_by like concat('%', #{createBy}, '%')</if>
|
|
|
|
|
+ <if test="updateUserid != null "> and t.update_userid = #{updateUserid}</if>
|
|
|
|
|
+ <if test="updateUsername != null and updateUsername != ''"> and t.update_username like concat('%', #{updateUsername}, '%')</if>
|
|
|
<if test="beginTime != null and beginTime != ''"><!-- 开始时间检索 -->
|
|
<if test="beginTime != null and beginTime != ''"><!-- 开始时间检索 -->
|
|
|
- and str_to_date(date_format(create_time,'%Y-%m-%d'),'%Y-%m-%d') >= str_to_date(#{beginTime},'%Y-%m-%d')
|
|
|
|
|
|
|
+ and str_to_date(t.date_format(create_time,'%Y-%m-%d'),'%Y-%m-%d') >= str_to_date(#{beginTime},'%Y-%m-%d')
|
|
|
</if>
|
|
</if>
|
|
|
<if test="endTime != null and endTime != ''"><!-- 结束时间检索 -->
|
|
<if test="endTime != null and endTime != ''"><!-- 结束时间检索 -->
|
|
|
- and str_to_date(date_format(create_time,'%Y-%m-%d'),'%Y-%m-%d') <= str_to_date(#{endTime},'%Y-%m-%d')
|
|
|
|
|
|
|
+ and str_to_date(t.date_format(create_time,'%Y-%m-%d'),'%Y-%m-%d') <= str_to_date(#{endTime},'%Y-%m-%d')
|
|
|
</if>
|
|
</if>
|
|
|
<if test="searchValue != null and searchValue != ''">
|
|
<if test="searchValue != null and searchValue != ''">
|
|
|
and (
|
|
and (
|
|
|
- title like concat('%', #{searchValue}, '%') or
|
|
|
|
|
- company like concat('%', #{searchValue}, '%') or
|
|
|
|
|
- create_username like concat('%', #{searchValue}, '%')
|
|
|
|
|
|
|
+ t.title like concat('%', #{searchValue}, '%') or
|
|
|
|
|
+ t.company like concat('%', #{searchValue}, '%') or
|
|
|
|
|
+ t.create_by like concat('%', #{searchValue}, '%')
|
|
|
)
|
|
)
|
|
|
</if>
|
|
</if>
|
|
|
<!-- 数据范围过滤 -->
|
|
<!-- 数据范围过滤 -->
|
|
|
${params.dataScope}
|
|
${params.dataScope}
|
|
|
</where>
|
|
</where>
|
|
|
- order by create_time desc
|
|
|
|
|
|
|
+ order by t.create_time desc
|
|
|
</select>
|
|
</select>
|
|
|
|
|
|
|
|
<select id="selectLabNotifyplanById" resultMap="LabNotifyplanResultVO">
|
|
<select id="selectLabNotifyplanById" resultMap="LabNotifyplanResultVO">
|
|
@@ -147,9 +149,9 @@
|
|
|
|
|
|
|
|
<if test="deptName != null">dept_name,</if>
|
|
<if test="deptName != null">dept_name,</if>
|
|
|
|
|
|
|
|
- <if test="createUserid != null">create_userid,</if>
|
|
|
|
|
|
|
+ <if test="userId != null">user_id,</if>
|
|
|
|
|
|
|
|
- <if test="createUsername != null">create_username,</if>
|
|
|
|
|
|
|
+ <if test="createBy != null">create_by,</if>
|
|
|
|
|
|
|
|
<if test="createTime != null">create_time,</if>
|
|
<if test="createTime != null">create_time,</if>
|
|
|
|
|
|
|
@@ -172,8 +174,8 @@
|
|
|
<if test="status != null">#{status},</if>
|
|
<if test="status != null">#{status},</if>
|
|
|
<if test="deptId != null">#{deptId},</if>
|
|
<if test="deptId != null">#{deptId},</if>
|
|
|
<if test="deptName != null">#{deptName},</if>
|
|
<if test="deptName != null">#{deptName},</if>
|
|
|
- <if test="createUserid != null">#{createUserid},</if>
|
|
|
|
|
- <if test="createUsername != null">#{createUsername},</if>
|
|
|
|
|
|
|
+ <if test="userId != null">#{userId},</if>
|
|
|
|
|
+ <if test="createBy != null">#{createBy},</if>
|
|
|
<if test="createTime != null">#{createTime},</if>
|
|
<if test="createTime != null">#{createTime},</if>
|
|
|
<if test="updateUserid != null">#{updateUserid},</if>
|
|
<if test="updateUserid != null">#{updateUserid},</if>
|
|
|
<if test="updateUsername != null">#{updateUsername},</if>
|
|
<if test="updateUsername != null">#{updateUsername},</if>
|
|
@@ -195,8 +197,8 @@
|
|
|
<if test="status != null">status = #{status},</if>
|
|
<if test="status != null">status = #{status},</if>
|
|
|
<if test="deptId != null">dept_id = #{deptId},</if>
|
|
<if test="deptId != null">dept_id = #{deptId},</if>
|
|
|
<if test="deptName != null">dept_name = #{deptName},</if>
|
|
<if test="deptName != null">dept_name = #{deptName},</if>
|
|
|
- <if test="createUserid != null">create_userid = #{createUserid},</if>
|
|
|
|
|
- <if test="createUsername != null">create_username = #{createUsername},</if>
|
|
|
|
|
|
|
+ <if test="userId != null">user_id = #{userId},</if>
|
|
|
|
|
+ <if test="createBy != null">create_by = #{createBy},</if>
|
|
|
<if test="createTime != null">create_time = #{createTime},</if>
|
|
<if test="createTime != null">create_time = #{createTime},</if>
|
|
|
<if test="updateUserid != null">update_userid = #{updateUserid},</if>
|
|
<if test="updateUserid != null">update_userid = #{updateUserid},</if>
|
|
|
<if test="updateUsername != null">update_username = #{updateUsername},</if>
|
|
<if test="updateUsername != null">update_username = #{updateUsername},</if>
|