| 
															
																@ -1111,28 +1111,27 @@ public class PatientDeviceService extends BaseJpaService<DevicePatientDevice, Pa 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                    String safeArea=null; 
															 | 
															
															 | 
															
																                    String safeArea=null; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                    if (safeAreaDOS.size()>0){ 
															 | 
															
															 | 
															
																                    if (safeAreaDOS.size()>0){ 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                        safeArea = safeAreaDOS.get(0).getSafeAreaGz(); 
															 | 
															
															 | 
															
																                        safeArea = safeAreaDOS.get(0).getSafeAreaGz(); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                    } 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                    String[] safeAreas = safeArea.split(";"); 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                    com.alibaba.fastjson.JSONArray fenceLocation = new com.alibaba.fastjson.JSONArray(); 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                    for (String area:safeAreas){ 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                        String[] areaPoint = area.split(","); 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                        com.alibaba.fastjson.JSONObject positionTmp = new com.alibaba.fastjson.JSONObject(); 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                        Double areaLon = Double.parseDouble( areaPoint[0]); 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                        Double areaLat = Double.parseDouble( areaPoint[1]); 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																                        String[] safeAreas = safeArea.split(";"); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																                        com.alibaba.fastjson.JSONArray fenceLocation = new com.alibaba.fastjson.JSONArray(); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																                        for (String area:safeAreas){ 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																                            String[] areaPoint = area.split(","); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																                            com.alibaba.fastjson.JSONObject positionTmp = new com.alibaba.fastjson.JSONObject(); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																                            Double areaLon = Double.parseDouble( areaPoint[0]); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																                            Double areaLat = Double.parseDouble( areaPoint[1]); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																//                                com.alibaba.fastjson.JSONObject positionTmp = gpsUtil.gcj02_To_Bd09(lat,lon); 
															 | 
															
															 | 
															
																//                                com.alibaba.fastjson.JSONObject positionTmp = gpsUtil.gcj02_To_Bd09(lat,lon); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                        positionTmp.put("lat",areaLat); 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                        positionTmp.put("lon",areaLon); 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                        fenceLocation.add(positionTmp); 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                    } 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                    if (!countDistance.isInPolygon(dulon,dulat,fenceLocation)){ 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																                            positionTmp.put("lat",areaLat); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																                            positionTmp.put("lon",areaLon); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																                            fenceLocation.add(positionTmp); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																                        } 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																                        if (!countDistance.isInPolygon(dulon,dulat,fenceLocation)){ 
															 | 
														
													
												
													
														
															| 
															 | 
															
																//                        orderUtil.createSecurityOrder(sn,null,null,8,"1","yslkaqqy",null); 
															 | 
															
															 | 
															
																//                        orderUtil.createSecurityOrder(sn,null,null,8,"1","yslkaqqy",null); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                        devInfoObj.put("isTrueFalse","已超出围栏范围"); 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                        devInfoObj.put("isNotAlarm","已报警"); 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                    } else { 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                        devInfoObj.put("isTrueFalse","未超出围栏范围"); 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                        devInfoObj.put("isNotAlarm","未报警"); 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																                            devInfoObj.put("isTrueFalse","已超出围栏范围"); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																                            devInfoObj.put("isNotAlarm","已报警"); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																                        } else { 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																                            devInfoObj.put("isTrueFalse","未超出围栏范围"); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																                            devInfoObj.put("isNotAlarm","未报警"); 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																                        } 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                    } 
															 | 
															
															 | 
															
																                    } 
															 | 
														
													
												
													
														
															| 
															 | 
															
																 
															 | 
															
															 | 
															
																 
															 | 
														
													
												
													
														
															| 
															 | 
															
																                    break; 
															 | 
															
															 | 
															
																                    break; 
															 | 
														
													
												
													
														
															| 
															 | 
															
																            } 
															 | 
															
															 | 
															
																            } 
															 | 
														
													
												
													
														
															| 
															 | 
															
																//        } 
															 | 
															
															 | 
															
																//        } 
															 |