|
@ -3206,6 +3206,37 @@ public class ImService {
|
|
|
imUtil.sendMessage(sender, reciver, contentType, content);
|
|
|
}
|
|
|
|
|
|
//发送在线候诊室消息
|
|
|
public void sendConstomerImg(String patientCode,String outpatientId,String outpatientType,String doctorCode){
|
|
|
try {
|
|
|
//808080eb8223c9e50182249cd6ff0000_guidance_26
|
|
|
String session_id26 = patientCode +"_guidance_26";
|
|
|
String session_id27 = patientCode +"_guidance_27";
|
|
|
BaseDoctorDO doctorDO = baseDoctorDao.findByIdAndDel(doctorCode);
|
|
|
String msg = "您好,"+doctorDO.getName()+"医生已接诊,请您及时进入诊室与您的医生沟通。医生将会与您详细讨论病情,并为您提供专业的治疗建议。我们将竭诚为您服务,为您的健康保驾护航。";
|
|
|
JSONObject json = new JSONObject();
|
|
|
json.put("outpatientId",outpatientId);
|
|
|
json.put("outpatientType",outpatientType);
|
|
|
json.put("msg",msg);
|
|
|
WlyyHospitalSysDictDO dictDO = hospitalSysDictDao.findById("customer").orElse(null);
|
|
|
String sender_id = "customer";
|
|
|
String sender_name = "客服";
|
|
|
if(dictDO!=null){
|
|
|
sender_id = dictDO.getDictCode();
|
|
|
sender_name = dictDO.getDictValue();
|
|
|
}
|
|
|
if(imUtil.sessionIsExist(session_id26)){
|
|
|
imUtil.sendImMsg(sender_id, sender_name, session_id26, "51", json.toJSONString(), "2", null);
|
|
|
}
|
|
|
if(imUtil.sessionIsExist(session_id27)){
|
|
|
imUtil.sendImMsg(sender_id, sender_name, session_id27, "51", json.toJSONString(), "2", null);
|
|
|
}
|
|
|
|
|
|
}catch (Exception e){
|
|
|
e.printStackTrace();
|
|
|
}
|
|
|
}
|
|
|
|
|
|
/**
|
|
|
* 导诊的咨询对话
|
|
|
*
|