<?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.yami.trading.dao.ats.StockAtsMapper">
|
|
|
<select id="getListByAdmin" resultType="com.yami.trading.bean.ats.dto.StockAtsDto" parameterType="map">
|
SELECT
|
a.*,u.user_code,u.user_name
|
FROM t_stock_ats a
|
LEFT JOIN tz_user u ON u.user_id = a.user_id
|
WHERE 1=1
|
<if test="keyWords != null and keyWords != '' ">
|
AND (
|
u.user_name LIKE CONCAT('%', #{keyWords}, '%')
|
OR u.user_code LIKE CONCAT('%', #{keyWords}, '%')
|
)
|
</if>
|
<if test="state != null and state != '' ">
|
AND a.state =#{state}
|
</if>
|
ORDER BY a.add_time DESC
|
</select>
|
|
|
</mapper>
|