feat(monitor): 添加操作日志绩效统计功能

- 在SysOperLogService中新增绩效概览、人员绩效和模块排行接口
- 在SysOperLogMapper中添加模块统计、人员统计和全局概览查询方法
- 在SysOperLogMapper.xml中实现绩效相关的SQL查询和ResultMap
- 在SysOperLogServiceImpl中实现绩效统计业务逻辑和评分算法
- 创建OperModuleStatVO、OperPersonVO和OperSummaryVO数据传输对象
- 新增OperPerformanceController提供绩效统计API接口
- 添加前端performance页面实现数据可视化展示和图表渲染
This commit is contained in:
2026-07-01 15:43:26 +08:00
parent ad25227400
commit 9233d09edc
11 changed files with 1101 additions and 4 deletions

View File

@@ -0,0 +1,58 @@
package com.klp.web.controller.monitor;
import cn.dev33.satoken.annotation.SaCheckPermission;
import com.klp.common.core.controller.BaseController;
import com.klp.common.core.domain.R;
import com.klp.system.domain.bo.OperPerformanceQuery;
import com.klp.system.domain.vo.OperModuleStatVO;
import com.klp.system.domain.vo.OperPersonVO;
import com.klp.system.domain.vo.OperSummaryVO;
import com.klp.system.service.ISysOperLogService;
import lombok.RequiredArgsConstructor;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import java.util.List;
/**
* 绩效汇总
*
* @author Reasonix
*/
@Validated
@RequiredArgsConstructor
@RestController
@RequestMapping("/monitor/performance")
public class OperPerformanceController extends BaseController {
private final ISysOperLogService operLogService;
/**
* 绩效概览统计
*/
@SaCheckPermission("monitor:performance:list")
@GetMapping("/summary")
public R<OperSummaryVO> summary(OperPerformanceQuery query) {
return R.ok(operLogService.selectPerformanceSummary(query));
}
/**
* 人员绩效列表(含模块明细)
*/
@SaCheckPermission("monitor:performance:list")
@GetMapping("/person")
public R<List<OperPersonVO>> person(OperPerformanceQuery query) {
return R.ok(operLogService.selectPersonPerformance(query));
}
/**
* 模块使用排行
*/
@SaCheckPermission("monitor:performance:list")
@GetMapping("/module")
public R<List<OperModuleStatVO>> module(OperPerformanceQuery query) {
return R.ok(operLogService.selectModuleRanking(query));
}
}