|
@@ -0,0 +1,37 @@
|
|
|
+<?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">
|
|
|
+<mapper namespace="com.fire.admin.mapper.LogInfoMapper">
|
|
|
+
|
|
|
+ <resultMap id="logInfoResultMap" type="com.fire.dto.LogInfo">
|
|
|
+ <id column="id" property="id"/>
|
|
|
+ <result column="create_time" property="createTime"/>
|
|
|
+ <result column="opt_user" property="optUser"/>
|
|
|
+ <result column="opt_info" property="optInfo"/>
|
|
|
+ <result column="interface_desc" property="interfaceDesc"/>
|
|
|
+ <result column="type" property="type"/>
|
|
|
+ </resultMap>
|
|
|
+
|
|
|
+ <sql id="common_field">
|
|
|
+ id
|
|
|
+ ,create_time,opt_user,opt_info,interface_desc,type
|
|
|
+ </sql>
|
|
|
+
|
|
|
+ <select id="getLogInfoList" resultMap="logInfoResultMap">
|
|
|
+ SELECT
|
|
|
+ <include refid="common_field"/>
|
|
|
+ FROM log_info
|
|
|
+ <where>
|
|
|
+ <if test="createTime != null and createTime.trim() != ''">
|
|
|
+ BETWEEN create_time = #{startTime} AND create_time = #{endTime}
|
|
|
+ </if>
|
|
|
+ <if test="optUser != null and optUser.trim() != ''">
|
|
|
+ AND opt_user LIKE CONCAT('%' #{optUser},'%')
|
|
|
+ </if>
|
|
|
+ <if test="type != null and type.trim() != ''">
|
|
|
+ AND type = #{type}
|
|
|
+ </if>
|
|
|
+ </where>
|
|
|
+ ORDER BY create_time DESC
|
|
|
+ </select>
|
|
|
+
|
|
|
+</mapper>
|