diff --git a/ruoyi-system/src/main/java/com/ruoyi/system/fantang/controller/ClientPatientController.java b/ruoyi-system/src/main/java/com/ruoyi/system/fantang/controller/ClientPatientController.java index 4278ed536..0469c5e21 100644 --- a/ruoyi-system/src/main/java/com/ruoyi/system/fantang/controller/ClientPatientController.java +++ b/ruoyi-system/src/main/java/com/ruoyi/system/fantang/controller/ClientPatientController.java @@ -28,8 +28,6 @@ public class ClientPatientController extends BaseController { SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd"); String createAt = sdf.format(new Date()); - FtPatientVo reportMealsToday = iFtPatientDaoService.getReportMealsToday("2020-12-29", patientId); - - return AjaxResult.success(reportMealsToday); + return AjaxResult.success(iFtPatientDaoService.getReportMealsToday("2020-12-29", patientId)); } } diff --git a/ruoyi-system/src/main/java/com/ruoyi/system/fantang/mapper/FtPatientDaoMapper.java b/ruoyi-system/src/main/java/com/ruoyi/system/fantang/mapper/FtPatientDaoMapper.java index a5f7314e8..99cd81d8e 100644 --- a/ruoyi-system/src/main/java/com/ruoyi/system/fantang/mapper/FtPatientDaoMapper.java +++ b/ruoyi-system/src/main/java/com/ruoyi/system/fantang/mapper/FtPatientDaoMapper.java @@ -51,5 +51,5 @@ public interface FtPatientDaoMapper extends BaseMapper { @Select("select a.hospital_id, a.name, a.depart_name, a.bed_id, b.depart_id, c.hospital_id as old_hospital_id, c.name as old_name, a.depart_name as old_depart_name, c.bed_id as old_bed_id, c.depart_id as old_depart_id, c.patient_id as patient_id from ft_sync a LEFT JOIN ft_depart b on a.depart_name = b.depart_name LEFT JOIN ft_patient c on a.hospital_id = c.hospital_id where b.depart_id = c.depart_id and a.bed_id = c.bed_id and a.name = c.name and c.hospital_id!=a.hospital_id") List syncConflictOtherAllEqual(); - FtPatientVo getReportMealsToday(@Param("createAt") String createAt, @Param("patientId") Long patientId); + List getReportMealsToday(@Param("createAt") String createAt, @Param("patientId") Long patientId); } diff --git a/ruoyi-system/src/main/java/com/ruoyi/system/fantang/service/IFtPatientDaoService.java b/ruoyi-system/src/main/java/com/ruoyi/system/fantang/service/IFtPatientDaoService.java index f287fc973..9c56fcc6d 100644 --- a/ruoyi-system/src/main/java/com/ruoyi/system/fantang/service/IFtPatientDaoService.java +++ b/ruoyi-system/src/main/java/com/ruoyi/system/fantang/service/IFtPatientDaoService.java @@ -1,5 +1,6 @@ package com.ruoyi.system.fantang.service; +import com.ruoyi.common.core.domain.AjaxResult; import com.ruoyi.system.fantang.domain.FtPatientDao; import com.baomidou.mybatisplus.extension.service.IService; import com.ruoyi.system.fantang.vo.FtPatientVo; @@ -14,5 +15,5 @@ import java.util.List; */ public interface IFtPatientDaoService extends IService { - FtPatientVo getReportMealsToday(String createAt, Long patientId ); + AjaxResult getReportMealsToday(String createAt, Long patientId ); } diff --git a/ruoyi-system/src/main/java/com/ruoyi/system/fantang/service/impl/FtPatientDaoServiceImpl.java b/ruoyi-system/src/main/java/com/ruoyi/system/fantang/service/impl/FtPatientDaoServiceImpl.java index 7db547a4f..24037d32a 100644 --- a/ruoyi-system/src/main/java/com/ruoyi/system/fantang/service/impl/FtPatientDaoServiceImpl.java +++ b/ruoyi-system/src/main/java/com/ruoyi/system/fantang/service/impl/FtPatientDaoServiceImpl.java @@ -1,5 +1,6 @@ package com.ruoyi.system.fantang.service.impl; +import com.ruoyi.common.core.domain.AjaxResult; import com.ruoyi.system.fantang.vo.FtPatientVo; import org.springframework.stereotype.Service; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; @@ -19,7 +20,7 @@ import java.util.List; public class FtPatientDaoServiceImpl extends ServiceImpl implements IFtPatientDaoService { @Override - public FtPatientVo getReportMealsToday(String createAt, Long patientId) { - return this.baseMapper.getReportMealsToday(createAt, patientId); + public AjaxResult getReportMealsToday(String createAt, Long patientId) { + return AjaxResult.success(this.baseMapper.getReportMealsToday(createAt, patientId)); } } diff --git a/ruoyi-system/src/main/resources/mapper/fantang/FtPatientDaoMapper.xml b/ruoyi-system/src/main/resources/mapper/fantang/FtPatientDaoMapper.xml index 3e4309da1..62b99a957 100644 --- a/ruoyi-system/src/main/resources/mapper/fantang/FtPatientDaoMapper.xml +++ b/ruoyi-system/src/main/resources/mapper/fantang/FtPatientDaoMapper.xml @@ -3,7 +3,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> - + @@ -14,6 +14,21 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" + + + + + + + + + + \ No newline at end of file