L11 RuoYi_数据分页的总条数分析

作业

image

过程

选择:系统管理->日志管理->操作日志
image

访问日志页面发起了三次请求
image

sys_oper_type:返回10种操作类型
image

sys_common_status:返回系统两种状态
image

list?pageNum=1&pageSize=10:返回10条操作数据
image

关注位置
image

在list?pageNum=1&pageSize=10
image

前端页面

位置:
image

image

发出请求位置
image

后端

image

先执行分页
image

获取总数量
image

image

下面为执行的查询语句与结果
22:10:12.762 [http-nio-8080-exec-46] DEBUG c.r.s.m.S.selectOperLogList - [debug,135] - ==> Preparing: select oper_id, title, business_type, method, request_method, operator_type, oper_name, dept_name, oper_url, oper_ip, oper_location, oper_param, json_result, status, error_msg, oper_time, cost_time from sys_oper_log order by oper_id desc LIMIT ?
22:10:12.763 [http-nio-8080-exec-46] DEBUG c.r.s.m.S.selectOperLogList - [debug,135] - ==> Parameters: 10(Integer)
22:10:12.766 [http-nio-8080-exec-46] DEBUG c.r.s.m.S.selectOperLogList - [debug,135] - <== Total: 10

image

代码中未发现执行函数,就出现了total值,在MyBatis中进行了操作
image

日志中未打印,但是已经执行并查找了全部的操作数量
image

LIMIT为限制返回的数量
image

posted @ 2025-11-18 22:33  The_Fool_l  阅读(7)  评论(0)    收藏  举报