You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
udi-wms-java/src/main/resources/mybatis/mapper/inout/IoOrderUploadLogDao.xml

52 lines
2.2 KiB
XML

<?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.glxp.api.dao.inout.IoOrderUploadLogDao">
<resultMap id="BaseResultMap" autoMapping="true" type="com.glxp.api.entity.inout.IoOrderUploadLogEntity">
<!--@mbg.generated-->
<!--@Table io_order_upload_log-->
<!-- <id column="id" jdbcType="INTEGER" property="id"/>-->
<result column="billNo" jdbcType="VARCHAR" property="billNo"/>
<result column="billDate" jdbcType="TIMESTAMP" property="billDate"/>
<result column="billType" jdbcType="VARCHAR" property="billType"/>
<result column="thrBillNo" jdbcType="VARCHAR" property="thrBillNo"/>
<result column="submitTime" jdbcType="TIMESTAMP" property="submitTime"/>
<result column="status" jdbcType="INTEGER" property="status"/>
<result column="result" jdbcType="VARCHAR" property="result"/>
<result column="fromType" jdbcType="TINYINT" property="fromType"/>
</resultMap>
<sql id="Base_Column_List">
<!--@mbg.generated-->
id,
billNo,
billDate,
billType,
thrBillNo,
submitTime,
`status`,
`result`,
fromType
</sql>
<select id="filterList" resultType="com.glxp.api.res.thrsys.ThrOrderUploadLogResponse">
select log.*, (select `name` from basic_bussiness_type where action = log.billType) billTypeName
from io_order_upload_log log
<where>
<if test="billNo != null and billNo != ''">
AND log.billNo like concat('%', #{billNo}, '%')
</if>
<if test="thirdBillNo != null and thirdBillNo != ''">
AND log.thrBillNo like concat('%', #{thirdBillNo}, '%')
</if>
<if test="submitTime != null">
AND date_format(log.submitTime, '%Y-%m-%d') = date_format(#{submitTime}, '%Y-%m-%d')
</if>
<if test="status != null">
AND log.status = #{status}
</if>
<if test="fromType != null">
AND log.fromType = #{fromType}
</if>
</where>
order by log.submitTime desc
</select>
</mapper>