|
@ -240,6 +240,29 @@ public class EmergencyAssistanceEndpoint extends EnvelopRestEndpoint {
|
|
|
}
|
|
|
}
|
|
|
|
|
|
@PostMapping(value = "updatePatientLocation")
|
|
|
@ApiOperation(value = "更新医生定位信息")
|
|
|
@ObserverRequired
|
|
|
public ObjEnvelop updatePatientLocation(@ApiParam(name="patient",value = "patient")
|
|
|
@RequestParam(value = "patient") String patient,
|
|
|
@ApiParam(name="patientAddress",value = "患者地址描述")
|
|
|
@RequestParam(value = "patientAddress") String patientAddress,
|
|
|
@ApiParam(name="patientLat",value = "患者当前定位纬度")
|
|
|
@RequestParam(value = "patientLat") String patientLat,
|
|
|
@ApiParam(name="patientLon",value = "患者当前定位经度")
|
|
|
@RequestParam(value = "patientLon") String patientLon){
|
|
|
try {
|
|
|
JSONObject result = assistanceService.updatePatientLocation(patient,patientAddress,patientLat,patientLon);
|
|
|
if (result.getIntValue(ResponseContant.resultFlag) == ResponseContant.fail) {
|
|
|
return ObjEnvelop.getError(result.getString(ResponseContant.resultMsg));
|
|
|
}
|
|
|
return ObjEnvelop.getSuccess("定位更新成功",result.getJSONObject("resultMsg"));
|
|
|
}catch (Exception e){
|
|
|
e.printStackTrace();
|
|
|
return ObjEnvelop.getError("定位更新失败"+e.getMessage());
|
|
|
}
|
|
|
}
|
|
|
|
|
|
|
|
|
@PostMapping(value = "sendQuickMessage")
|
|
|
@ApiOperation(value = "患者发送快捷消息")
|