魏超 5 anos atrás
pai
commit
05a0510a4e

+ 6
- 6
src/main/resources/mapper/TaPersonVisitRecordMapper.xml Ver arquivo

@@ -195,7 +195,7 @@
195 195
                 where t.event_type = 'building'
196 196
                 and t.consultant_id = #{userId}
197 197
                 and t.org_id = #{orgId}
198
-                and t.`event` = 'share' order by t.visit_time desc
198
+                and t.`event` = 'share' order by t.visit_time desc limit 9999
199 199
             ) t
200 200
             group by t.target_id
201 201
 
@@ -216,7 +216,7 @@
216 216
         where t.event_type = 'activity'
217 217
         and t.consultant_id = #{userId}
218 218
         and t.org_id = #{orgId}
219
-        and t.`event` = 'share' order by t.visit_time desc
219
+        and t.`event` = 'share' order by t.visit_time desc limit 9999
220 220
         ) t
221 221
         group by t.target_id
222 222
 
@@ -237,7 +237,7 @@
237 237
         where t.event_type = 'help'
238 238
         and t.consultant_id = #{userId}
239 239
         and t.org_id = #{orgId}
240
-        and t.`event` = 'share' order by t.visit_time desc
240
+        and t.`event` = 'share' order by t.visit_time desc limit 9999
241 241
         ) t
242 242
         group by t.target_id
243 243
 
@@ -259,7 +259,7 @@
259 259
         and t.consultant_id = #{userId}
260 260
         and t.org_id = #{orgId}
261 261
         and t.`event` = 'share'
262
-        group by t.target_id order by t.visit_time desc
262
+        group by t.target_id order by t.visit_time desc limit 9999
263 263
         ) t
264 264
 
265 265
         union all
@@ -279,7 +279,7 @@
279 279
         where t.event_type = 'news'
280 280
         and t.consultant_id = #{userId}
281 281
         and t.org_id = #{orgId}
282
-        and t.`event` = 'share' order by t.visit_time desc
282
+        and t.`event` = 'share' order by t.visit_time desc limit 9999
283 283
         ) t
284 284
         group by t.target_id
285 285
 
@@ -300,7 +300,7 @@
300 300
             where t.event_type = 'h5'
301 301
             and t.consultant_id = #{userId}
302 302
             and t.org_id = #{orgId}
303
-            and t.`event` = 'share' order by t.visit_time desc
303
+            and t.`event` = 'share' order by t.visit_time desc limit 9999
304 304
             ) t
305 305
             group by t.target_id
306 306
         ) t