<?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.ruoyi.account.mapper.BalanceChangeRecordMapper">
|
|
<select id="pageList" resultType="com.ruoyi.account.api.model.BalanceChangeRecord">
|
select t1.*,t2.name as userName,t2.phone as userPhone
|
from t_balance_change_record t1
|
left join t_app_user t2 on t1.app_user_id = t2.id
|
<where>
|
<if test="agentQuery.name != null and agentQuery.name != ''">
|
and t2.name like concat('%',#{agentQuery.name},'%')
|
</if>
|
<if test="agentQuery.phone != null and agentQuery.phone != ''">
|
and t2.phone like concat('%',#{agentQuery.phone},'%')
|
</if>
|
<if test="agentQuery.changeType != null">
|
and t1.change_type = #{agentQuery.changeType}
|
</if>
|
<if test="agentQuery.localDate1 != null">
|
and DATE(t1.create_time) between #{agentQuery.localDate1} and #{agentQuery.localDate2}
|
</if>
|
</where>
|
</select>
|
</mapper>
|