diff --git a/ruoyi-admin/src/main/java/com/ruoyi/web/controller/pc/TRecordController.java b/ruoyi-admin/src/main/java/com/ruoyi/web/controller/pc/TRecordController.java index ce64bb5..fd0c2fa 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/web/controller/pc/TRecordController.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/web/controller/pc/TRecordController.java @@ -129,14 +129,12 @@ public class TRecordController extends BaseController if(id == null){ return AjaxResult.error("未获取到id"); } - Map> data = new HashMap<>(); - List list = new ArrayList<>(); - list.add(tRecordService.selectById(id)); - data.put("result", Collections.singletonList(list)); + Map data = new HashMap<>(); + data.put("result", tRecordService.selectById(id)); TImage tImage = new TImage(); tImage.setThirdId(id); List images = imageService.selectTImageList(tImage); - data.put("image", Collections.singletonList(images)); + data.put("image", images); return AjaxResult.success(data); } diff --git a/ruoyi-system/src/main/resources/mapper/system/TRecordMapper.xml b/ruoyi-system/src/main/resources/mapper/system/TRecordMapper.xml index 287d7d7..c65392a 100644 --- a/ruoyi-system/src/main/resources/mapper/system/TRecordMapper.xml +++ b/ruoyi-system/src/main/resources/mapper/system/TRecordMapper.xml @@ -208,7 +208,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" and td.del_flag = '0' and tp.del_flag = '0' - + and DATE_FORMAT(tp.create_time,'%Y-%m') = #{createTime} and tr.create_time >= #{startTime}