|
@@ -21,15 +21,15 @@
|
|
|
select ch.*,s.name as userName
|
|
|
from charge as ch
|
|
|
left join staff as s
|
|
|
- on ch.card = s.card
|
|
|
+ on ch.card = s.card_id
|
|
|
<where>
|
|
|
<if test="startTime != null and endTime != null">
|
|
|
- and create_time between #{startTime}
|
|
|
+ and ch.create_time between #{startTime}
|
|
|
and #{endTime}
|
|
|
</if>
|
|
|
<if test="userName !=null and userName !=''">
|
|
|
- and user_name like CONCAT('%',#{searchParam},'%')
|
|
|
- or user_account like CONCAT('%',#{searchParam},'%')
|
|
|
+ and user_name like CONCAT('%',#{userName},'%')
|
|
|
+ or user_account like CONCAT('%',#{userName},'%')
|
|
|
</if>
|
|
|
<if test="userId != null">
|
|
|
and s.id = #{userId}
|