Merge remote-tracking branch 'origin/jihan_0920_护理服务、商城、积分兑换、在线问诊功能分支' into jihan_0920_护理服务、商城、积分兑换、在线问诊功能分支
This commit is contained in:
commit
afc139a881
@ -3,7 +3,10 @@ package com.xinelu.web.controller.fd;
|
|||||||
import com.alibaba.fastjson2.JSONObject;
|
import com.alibaba.fastjson2.JSONObject;
|
||||||
import com.github.pagehelper.PageHelper;
|
import com.github.pagehelper.PageHelper;
|
||||||
import com.github.pagehelper.PageInfo;
|
import com.github.pagehelper.PageInfo;
|
||||||
|
import com.xinelu.common.core.controller.BaseController;
|
||||||
import com.xinelu.common.core.domain.R;
|
import com.xinelu.common.core.domain.R;
|
||||||
|
import com.xinelu.common.core.page.TableDataInfo;
|
||||||
|
import com.xinelu.common.exception.ServiceException;
|
||||||
import com.xinelu.familydoctor.applet.pojo.body.ApprovalBody;
|
import com.xinelu.familydoctor.applet.pojo.body.ApprovalBody;
|
||||||
import com.xinelu.familydoctor.applet.pojo.body.SyncHospitalPersonInfoBody;
|
import com.xinelu.familydoctor.applet.pojo.body.SyncHospitalPersonInfoBody;
|
||||||
import com.xinelu.familydoctor.applet.pojo.query.ApplyQuery;
|
import com.xinelu.familydoctor.applet.pojo.query.ApplyQuery;
|
||||||
@ -13,8 +16,11 @@ import com.xinelu.familydoctor.applet.pojo.vo.ResidentSignApplyVo;
|
|||||||
import com.xinelu.familydoctor.applet.service.IResidentRescindApplyService;
|
import com.xinelu.familydoctor.applet.service.IResidentRescindApplyService;
|
||||||
import com.xinelu.familydoctor.applet.service.IResidentServiceAppletService;
|
import com.xinelu.familydoctor.applet.service.IResidentServiceAppletService;
|
||||||
import com.xinelu.familydoctor.applet.service.IResidentSignAppletService;
|
import com.xinelu.familydoctor.applet.service.IResidentSignAppletService;
|
||||||
|
import com.xinelu.manage.domain.chatRecord.ChatRecord;
|
||||||
import com.xinelu.manage.domain.hospitalinfo.HospitalInfo;
|
import com.xinelu.manage.domain.hospitalinfo.HospitalInfo;
|
||||||
import com.xinelu.manage.domain.hospitalpersoninfo.HospitalPersonInfo;
|
import com.xinelu.manage.domain.hospitalpersoninfo.HospitalPersonInfo;
|
||||||
|
import com.xinelu.manage.dto.chatrecord.MessageSearchDto;
|
||||||
|
import com.xinelu.manage.mapper.chatrecord.ChatRecordMapper;
|
||||||
import com.xinelu.manage.service.hospitalinfo.IHospitalInfoService;
|
import com.xinelu.manage.service.hospitalinfo.IHospitalInfoService;
|
||||||
import com.xinelu.manage.service.hospitalpersoninfo.IHospitalPersonInfoService;
|
import com.xinelu.manage.service.hospitalpersoninfo.IHospitalPersonInfoService;
|
||||||
import com.xinelu.manage.service.patientinfo.IPatientInfoService;
|
import com.xinelu.manage.service.patientinfo.IPatientInfoService;
|
||||||
@ -30,7 +36,7 @@ import javax.annotation.Resource;
|
|||||||
@Api(tags = "家医调用接口")
|
@Api(tags = "家医调用接口")
|
||||||
@RestController
|
@RestController
|
||||||
@RequestMapping("/applet/fd")
|
@RequestMapping("/applet/fd")
|
||||||
public class FDController {
|
public class FDController extends BaseController {
|
||||||
@Resource
|
@Resource
|
||||||
private IResidentRescindApplyService residentRescindApplyService;
|
private IResidentRescindApplyService residentRescindApplyService;
|
||||||
@Resource
|
@Resource
|
||||||
@ -43,6 +49,8 @@ public class FDController {
|
|||||||
private IHospitalPersonInfoService hospitalPersonInfoService;
|
private IHospitalPersonInfoService hospitalPersonInfoService;
|
||||||
@Resource
|
@Resource
|
||||||
private IHospitalInfoService hospitalInfoService;
|
private IHospitalInfoService hospitalInfoService;
|
||||||
|
@Resource
|
||||||
|
private ChatRecordMapper chatRecordMapper;
|
||||||
|
|
||||||
|
|
||||||
@ApiOperation("服务申请列表")
|
@ApiOperation("服务申请列表")
|
||||||
@ -191,4 +199,32 @@ public class FDController {
|
|||||||
}
|
}
|
||||||
return R.ok();
|
return R.ok();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ApiOperation(value = "获取居民消息推送列表", notes = "山东通APP消息通知模块中的消息提醒用")
|
||||||
|
@GetMapping("/getNotice/{identity}")
|
||||||
|
public TableDataInfo noticDel(@PathVariable String identity) {
|
||||||
|
// 获取注册信息
|
||||||
|
PatientInfoVO patientInfo = patientInfoService.selectPatientInfoByCardNo(identity);
|
||||||
|
if (patientInfo == null) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
MessageSearchDto query = new MessageSearchDto();
|
||||||
|
query.setRecipientId(patientInfo.getId());
|
||||||
|
query.setMessageCategory("4");
|
||||||
|
startPage();
|
||||||
|
return getDataTable(chatRecordMapper.selectMegList(query));
|
||||||
|
}
|
||||||
|
|
||||||
|
@ApiOperation(value = "获取居民消息推送最后一次记录", notes = "山东通APP消息通知模块中的消息提醒用")
|
||||||
|
@GetMapping("/getLastNotice/{identity}")
|
||||||
|
public R<ChatRecord> getLastNotice(@PathVariable String identity) {
|
||||||
|
PatientInfoVO patientInfo = patientInfoService.selectPatientInfoByCardNo(identity);
|
||||||
|
if (patientInfo == null) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
MessageSearchDto query = new MessageSearchDto();
|
||||||
|
query.setRecipientId(patientInfo.getId());
|
||||||
|
query.setMessageCategory("4");
|
||||||
|
return R.ok(chatRecordMapper.getLast(query));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -86,6 +86,14 @@ public class ChatRecord extends BaseEntity implements Serializable {
|
|||||||
@Excel(name = "发送时间,时间格式:yyyy-MM-dd HH:mm:ss", width = 30, dateFormat = "yyyy-MM-dd")
|
@Excel(name = "发送时间,时间格式:yyyy-MM-dd HH:mm:ss", width = 30, dateFormat = "yyyy-MM-dd")
|
||||||
private Date sendTime;
|
private Date sendTime;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 发送时间,时间格式:yyyy-MM-dd HH:mm:ss
|
||||||
|
*/
|
||||||
|
@ApiModelProperty(value = "发送时间,时间格式:yyyy-MM-dd HH:mm:ss")
|
||||||
|
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||||
|
@Excel(name = "发送时间,时间格式:yyyy-MM-dd HH:mm:ss", width = 30, dateFormat = "yyyy-MM-dd")
|
||||||
|
private Date sendTime1;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 接收人
|
* 接收人
|
||||||
*/
|
*/
|
||||||
|
|||||||
@ -118,4 +118,12 @@ public interface ChatRecordMapper {
|
|||||||
|
|
||||||
List<ChatRecord> getList(ChatRecord chatRecord);
|
List<ChatRecord> getList(ChatRecord chatRecord);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Author mengkuiliang
|
||||||
|
* @Description 查询最后一次通知记录
|
||||||
|
* @Date 2023-12-06 006 14:53
|
||||||
|
* @Param [query]
|
||||||
|
* @return com.xinelu.manage.domain.chatRecord.ChatRecord
|
||||||
|
**/
|
||||||
|
ChatRecord getLast(MessageSearchDto query);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -451,4 +451,17 @@
|
|||||||
</if>
|
</if>
|
||||||
ORDER BY send_time desc
|
ORDER BY send_time desc
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
|
<!-- 查询最后一次通知记录 -->
|
||||||
|
<select id="getLast" resultType="com.xinelu.manage.domain.chatRecord.ChatRecord">
|
||||||
|
select
|
||||||
|
message_no,message_category,source_type,consultation_id,crowds,crowds_name,sender_id,
|
||||||
|
sender_name,send_time as send_time1,recipient_id,
|
||||||
|
recipient_name,message_type,title,content,content_id,
|
||||||
|
read_status,title
|
||||||
|
from chat_record
|
||||||
|
where del_flag = '0' and message_category = #{messageCategory} and recipient_id = #{recipientId}
|
||||||
|
order by send_time desc
|
||||||
|
limit 1
|
||||||
|
</select>
|
||||||
</mapper>
|
</mapper>
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user