医生微信登录接口

master
heminjian502 2 years ago
parent 060b6addea
commit 2a014dba57

@ -304,6 +304,16 @@ public class AppController extends BaseController
return getDataTable(tRecordService.selectTRecordListWithoutResult(recordResultReq)); return getDataTable(tRecordService.selectTRecordListWithoutResult(recordResultReq));
} }
@ApiOperation("首页患者列表")
@GetMapping("/home/patient/list")
public TableDataInfo queryHomePatientsList(TRecordResultReq recordResultReq)
{
// recordResultReq.setStatus("1");
//startPage();
List<TRecordResp> tRecordResps = tRecordService.queryHomePatientList(recordResultReq);
return getDataTable(tRecordResps);
}
/** /**
* *
* *

@ -141,6 +141,8 @@ public interface TRecordMapper
List<TRecordResp> selectTRecordListWithoutResult(TRecordResultReq tRecord); List<TRecordResp> selectTRecordListWithoutResult(TRecordResultReq tRecord);
List<TRecordResp> selectHomePatientList(TRecordResultReq tRecord);
TRecordResp selectById(Long id); TRecordResp selectById(Long id);
/** /**

@ -72,6 +72,8 @@ public interface ITRecordService
*/ */
List<TRecordResp> selectTRecordListWithoutResult(TRecordResultReq tRecord); List<TRecordResp> selectTRecordListWithoutResult(TRecordResultReq tRecord);
List<TRecordResp> queryHomePatientList(TRecordResultReq tRecord);
/** /**
* id * id
* *

@ -141,6 +141,12 @@ public class TRecordServiceImpl implements ITRecordService
return tRecordMapper.selectTRecordListWithoutResult(tRecord); return tRecordMapper.selectTRecordListWithoutResult(tRecord);
} }
@Override
public List<TRecordResp> queryHomePatientList(TRecordResultReq tRecord) {
List<TRecordResp> tRecordResps = tRecordMapper.selectHomePatientList(tRecord);
return tRecordResps;
}
@Override @Override
public TRecordResp selectById(Long id) public TRecordResp selectById(Long id)
{ {

@ -87,6 +87,66 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
LEFT JOIN t_patient tp ON tr.patient_id = tp.id LEFT JOIN t_patient tp ON tr.patient_id = tp.id
</sql> </sql>
<select id="selectHomePatientList" parameterType="TRecordResultReq" resultType="TRecordResp">
SELECT
t.id,
t.patientId,
t.doctorId,
t.hospitalId,
t. STATUS,
t.aiResult2,
t.updateResult2,
t.createTime,
t.updateTime,
t.uploadTime,
t.waitingTime,
t.aiResultReturnTime,
t.aiResultModifyTime,
t.responseTime,
t.doctorName,
t.identifier,
t.patientName,
t.sex,
t.age,
t.disease,
t.firstTime,
max(t.createTime)
FROM
(
SELECT
tr.id,
tr.patient_id AS patientId,
tr.doctor_id AS doctorId,
tr.hospital_id AS hospitalId,
tr. STATUS,
tr.ai_result2 AS aiResult2,
tr.update_result2 AS updateResult2,
tr.create_time AS createTime,
tr.update_time AS updateTime,
tr.upload_time AS uploadTime,
tr.create_time AS waitingTime,
tr.ai_result_return_time AS aiResultReturnTime,
tr.ai_result_modify_time AS aiResultModifyTime,
tr.response_time AS responseTime,
td. NAME AS doctorName,
tp.identifier,
tp. NAME AS patientName,
tp.sex,
tp.age,
tp.disease,
tp.create_time AS firstTime
FROM
t_record tr
LEFT JOIN t_doctor td ON tr.doctor_id = td.id
LEFT JOIN t_patient tp ON tr.patient_id = tp.id
WHERE
tr.doctor_id = #{doctorId}
AND tr.hospital_id = #{hospitalId}
) t
GROUP BY
t.patientId
</select>
<!--====================工作台相关接口=====================--> <!--====================工作台相关接口=====================-->
<select id="selectEquCount" resultType="int"> <select id="selectEquCount" resultType="int">
select count(*) from t_record select count(*) from t_record

Loading…
Cancel
Save