feat(video): 完善视频评价功能,增加问题机位和标签管理

- 新增VideoReviewSourceEnum枚举,定义评价来源类型(订单、渲染)
- 添加LongListTypeHandler和StringListTypeHandler,处理数据库JSON字段与Java列表转换
- 修改VideoReviewEntity实体类,将机位评价改为问题机位ID列表和问题标签列表
- 创建AdminVideoReviewLogReqDTO和AdminVideoReviewLogRespDTO,实现管理后台评价日志查询
- 在VideoReviewController中增加管理后台分页查询评价日志接口
- 更新视频评价添加逻辑,验证来源参数并记录问题机位和标签信息
- 修改
This commit is contained in:
2026-01-27 21:28:33 +08:00
parent 1c0a506238
commit 93744510ec
15 changed files with 826 additions and 112 deletions

View File

@@ -1,6 +1,8 @@
package com.ycwl.basic.mapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.ycwl.basic.model.pc.videoreview.dto.AdminVideoReviewLogReqDTO;
import com.ycwl.basic.model.pc.videoreview.dto.AdminVideoReviewLogRespDTO;
import com.ycwl.basic.model.pc.videoreview.dto.VideoReviewListReqDTO;
import com.ycwl.basic.model.pc.videoreview.dto.VideoReviewRespDTO;
import com.ycwl.basic.model.pc.videoreview.dto.VideoReviewStatisticsRespDTO;
@@ -25,6 +27,14 @@ public interface VideoReviewMapper extends BaseMapper<VideoReviewEntity> {
*/
List<VideoReviewRespDTO> selectReviewList(VideoReviewListReqDTO reqDTO);
/**
* 管理后台分页查询评价日志(带更详细的管理信息)
*
* @param reqDTO 查询条件
* @return 评价日志列表
*/
List<AdminVideoReviewLogRespDTO> selectAdminReviewLogList(AdminVideoReviewLogReqDTO reqDTO);
/**
* 统计总评价数
*
@@ -63,9 +73,9 @@ public interface VideoReviewMapper extends BaseMapper<VideoReviewEntity> {
List<VideoReviewStatisticsRespDTO.ScenicReviewRank> countScenicRank(@Param("limit") int limit);
/**
* 查询所有机位评价数据(用于后端计算平均值)
* 查询所有问题机位ID列表(用于后端统计问题机位)
*
* @return 机位评价列表(Map结构: 机位ID -> 评分)
* @return 问题机位ID列表
*/
List<Map<String, Integer>> selectAllCameraPositionRatings();
List<List<Long>> selectAllProblemDeviceIds();
}