|
@ -481,6 +481,30 @@ public class EmergencyAssistanceService extends BaseJpaService<EmergencyAssistan
|
|
return result;
|
|
return result;
|
|
}
|
|
}
|
|
|
|
|
|
|
|
public JSONObject updatePatientLocation(String patient,String patientAddress,String patientLat,String patientLon){
|
|
|
|
JSONObject result = new JSONObject();
|
|
|
|
BasePatientDO patientDO = patientDao.findById(patient);
|
|
|
|
if (patientDO==null){
|
|
|
|
String failMsg = "患者不存在";
|
|
|
|
result.put(ResponseContant.resultFlag, ResponseContant.fail);
|
|
|
|
result.put(ResponseContant.resultMsg,failMsg);
|
|
|
|
return result;
|
|
|
|
}
|
|
|
|
EmergencyAssistanceDO assistanceDO = emergencyAssistanceDao.findByPatientAndStatus(patient,1);
|
|
|
|
if (assistanceDO!=null){
|
|
|
|
assistanceDO.setServeAddress(patientAddress);
|
|
|
|
assistanceDO.setServeLat(patientLat);
|
|
|
|
assistanceDO.setServeLon(patientLon);
|
|
|
|
emergencyAssistanceDao.save(assistanceDO);
|
|
|
|
return getOrderDetail(assistanceDO.getId());
|
|
|
|
}
|
|
|
|
else {
|
|
|
|
result.put(ResponseContant.resultFlag, ResponseContant.success);
|
|
|
|
result.put(ResponseContant.resultMsg,null);
|
|
|
|
}
|
|
|
|
return result;
|
|
|
|
}
|
|
|
|
|
|
public JSONObject sendQuickMessage(String orderId,String patient,String content){
|
|
public JSONObject sendQuickMessage(String orderId,String patient,String content){
|
|
JSONObject result = new JSONObject();
|
|
JSONObject result = new JSONObject();
|
|
ConsultTeamDo consultTeam = consultTeamDao.queryByRelationCode(orderId);
|
|
ConsultTeamDo consultTeam = consultTeamDao.queryByRelationCode(orderId);
|