|
|
@@ -99,19 +99,50 @@
|
|
99
|
99
|
'%')
|
|
100
|
100
|
</if>
|
|
101
|
101
|
<if test="terminalId != null ">and terminal_id = #{terminalId}</if>
|
|
|
102
|
+ <if test="terminalName != null and terminalName != ''">and terminal_name like
|
|
|
103
|
+ concat('%', #{terminalName}, '%')
|
|
|
104
|
+ </if>
|
|
102
|
105
|
<if test="areaId != null ">and area_id = #{areaId}</if>
|
|
|
106
|
+ <if test="areaName != null and areaName != ''">and area_name like
|
|
|
107
|
+ concat('%', #{areaName}, '%')
|
|
|
108
|
+ </if>
|
|
103
|
109
|
<if test="channelId != null ">and channel_id = #{channelId}</if>
|
|
|
110
|
+ <if test="channelName != null and channelName != ''">and channel_name like
|
|
|
111
|
+ concat('%', #{channelName}, '%')
|
|
|
112
|
+ </if>
|
|
104
|
113
|
<if test="reviewedUserId != null ">and reviewed_user_id = #{reviewedUserId}</if>
|
|
105
|
114
|
<if test="reviewedUserName != null and reviewedUserName != ''">and reviewed_user_name like concat('%',
|
|
106
|
115
|
#{reviewedUserName}, '%')
|
|
107
|
116
|
</if>
|
|
108
|
117
|
<if test="reviewUserId != null ">and review_user_id = #{reviewUserId}</if>
|
|
|
118
|
+ <if test="reviewUserName != null and reviewUserName != ''">and review_user_name like
|
|
|
119
|
+ concat('%', #{reviewUserName}, '%')
|
|
|
120
|
+ </if>
|
|
109
|
121
|
<if test="reviewDate != null ">and review_date = #{reviewDate}</if>
|
|
110
|
122
|
<if test="missCheckTime != null ">and DATE_FORMAT(miss_check_time, '%Y-%m-%d %H:%i') =
|
|
111
|
123
|
DATE_FORMAT(#{missCheckTime}, '%Y-%m-%d %H:%i')
|
|
112
|
124
|
</if>
|
|
113
|
125
|
<if test="difficultyLevel != null and difficultyLevel != ''">and difficulty_level = #{difficultyLevel}</if>
|
|
114
|
126
|
<if test="gender != null and gender != ''">and gender = #{gender}</if>
|
|
|
127
|
+ <if test="actingSupervisorId != null ">and acting_supervisor_id = #{actingSupervisorId}</if>
|
|
|
128
|
+ <if test="actingSupervisorName != null and actingSupervisorName != ''">and acting_supervisor_name like
|
|
|
129
|
+ concat('%', #{actingSupervisorName}, '%')
|
|
|
130
|
+ </if>
|
|
|
131
|
+ <if test="missCheckItem != null and missCheckItem != ''">and miss_check_item like
|
|
|
132
|
+ concat('%', #{missCheckItem}, '%')
|
|
|
133
|
+ </if>
|
|
|
134
|
+ <if test="supervisorId != null ">and supervisor_id = #{supervisorId}</if>
|
|
|
135
|
+ <if test="supervisorName != null and supervisorName != ''">and supervisor_name like
|
|
|
136
|
+ concat('%', #{supervisorName}, '%')
|
|
|
137
|
+ </if>
|
|
|
138
|
+ <if test="teamLeaderId != null ">and team_leader_id = #{teamLeaderId}</if>
|
|
|
139
|
+ <if test="teamLeaderName != null and teamLeaderName != ''">and team_leader_name like
|
|
|
140
|
+ concat('%', #{teamLeaderName}, '%')
|
|
|
141
|
+ </if>
|
|
|
142
|
+ <if test="startDate != null and endDate != null">
|
|
|
143
|
+ and (review_date >= #{startDate}
|
|
|
144
|
+ and review_date <![CDATA[ < ]]> date_add(#{endDate} , interval 1 day))
|
|
|
145
|
+ </if>
|
|
115
|
146
|
</where>
|
|
116
|
147
|
order by review_date desc, miss_check_time desc
|
|
117
|
148
|
</select>
|