九公司定位系统配置文件更新
							parent
							
								
									304a261c35
								
							
						
					
					
						commit
						d390ea419f
					
				|  | @ -91,7 +91,8 @@ public class DwController extends BaseController { | |||
|     @RequestMapping(value = "getAllMessage") | ||||
|     public Object getAllMessage() throws Exception { | ||||
|         PageData pd = this.getPageData(); | ||||
|         return dwService.getAllMessage(); | ||||
|         TraceGet dto = JSONObject.parseObject(JSONObject.toJSONString(pd), TraceGet.class); | ||||
|         return dwService.getAllMessage(dto); | ||||
|     } | ||||
| 
 | ||||
| 
 | ||||
|  |  | |||
|  | @ -3,6 +3,7 @@ package com.zcloud.controller.map; | |||
| import com.alibaba.fastjson.JSONObject; | ||||
| import com.alibaba.fastjson.TypeReference; | ||||
| import com.zcloud.controller.base.BaseController; | ||||
| import com.zcloud.controller.map.testDto.TestDto; | ||||
| import com.zcloud.entity.Page; | ||||
| import com.zcloud.entity.PageData; | ||||
| import com.zcloud.service.bus.CorpInfoService; | ||||
|  | @ -910,16 +911,22 @@ public class MapController extends BaseController { | |||
|         Map<String, Object> map = new HashMap<String, Object>(); | ||||
|         PageData pd = this.getPageData(); | ||||
|         // TODO 判断是否是公司人员定位
 | ||||
|         if (true){ | ||||
|         if ("035958e685cf4850bc40151c5e0617a6".equals(pd.getString("corpId"))) { | ||||
|             TraceGet mapInfo = new TraceGet(); | ||||
|             mapInfo.setId(pd.getString("id")); | ||||
|             return dwService.getTrace(mapInfo); | ||||
|         }else { | ||||
|             PageData value = usersService.getPersonByCardNo(pd); | ||||
|             map.put("result", "success"); | ||||
|             map.put("pd", value); | ||||
|             return map; | ||||
|         } | ||||
| 
 | ||||
|         if ("21590a00ea5e462e9ee44dd332dddc26".equals(pd.getString("corpId"))){ | ||||
|             TraceGet mapInfo = new TraceGet(); | ||||
|             mapInfo.setId(pd.getString("id")); | ||||
|             return dwService.getLtTrace(mapInfo); | ||||
|         } | ||||
|         PageData value = usersService.getPersonByCardNo(pd); | ||||
|         map.put("result", "success"); | ||||
|         map.put("pd", value); | ||||
|         return map; | ||||
| 
 | ||||
|     } | ||||
| 
 | ||||
|     @RequestMapping(value = "/getAllDwMessage") | ||||
|  | @ -927,7 +934,7 @@ public class MapController extends BaseController { | |||
|     public Object getAllDwMessage() throws Exception { | ||||
|         Map<String, Object> map = new HashMap<String, Object>(); | ||||
|         PageData pd = this.getPageData(); | ||||
|         // TODO 判断是否是公司人员定位
 | ||||
|         // 一公司人员定位系统
 | ||||
|         if (pd.get("corpId") != null && "035958e685cf4850bc40151c5e0617a6".equals(pd.getString("corpId"))) { | ||||
|             AlarmGet alarmGet = new AlarmGet(); | ||||
|             alarmGet.setPage(new com.zcloud.service.dw.dto.Page()); | ||||
|  | @ -935,15 +942,35 @@ public class MapController extends BaseController { | |||
|             alarmGet.getPage().setSize("12"); | ||||
|             alarmGet.setCorpId(pd.getString("corpId")); | ||||
|             map.put("result", "success"); | ||||
|             map.put("alarmList",dwService.getAlarmList(alarmGet)); | ||||
|             map.put("orthermessage",dwService.getAllMessage()); | ||||
|             map.put("alarmList", dwService.getAlarmList(alarmGet)); | ||||
|             TraceGet get = new TraceGet(); | ||||
|             get.setCorpId("035958e685cf4850bc40151c5e0617a6"); | ||||
|             map.put("orthermessage", dwService.getAllMessage(get)); | ||||
|             return map; | ||||
|         }else { | ||||
|             // 九公司人员定位系统
 | ||||
|         } else if (pd.get("corpId") != null && "21590a00ea5e462e9ee44dd332dddc26".equals(pd.getString("corpId"))) { | ||||
|             AlarmGet alarmGet = new AlarmGet(); | ||||
|             alarmGet.setPage(new com.zcloud.service.dw.dto.Page()); | ||||
|             alarmGet.getPage().setCurrent("1"); | ||||
|             alarmGet.getPage().setSize("12"); | ||||
|             alarmGet.setCorpId(pd.getString("corpId")); | ||||
|             map.put("result", "success"); | ||||
|             map.put("alarmList", new ArrayList<>()); | ||||
| //            HashMap<String,Object> info = new HashMap<>();
 | ||||
| //            info.put("infoList",TestDto.getTestInfo());
 | ||||
| //            info.put("onlineDeviceNum", "0");
 | ||||
|             TraceGet get = new TraceGet(); | ||||
|             get.setCorpId("21590a00ea5e462e9ee44dd332dddc26"); | ||||
|             map.put("orthermessage",dwService.getAllMessage(get)); | ||||
|             return map; | ||||
|         } else { | ||||
|             PageData value = usersService.getPersonByCardNo(pd); | ||||
|             map.put("result", "success"); | ||||
|             map.put("pd", value); | ||||
|             return map; | ||||
|         } | ||||
| 
 | ||||
| 
 | ||||
|     } | ||||
| 
 | ||||
|     /** | ||||
|  | @ -961,10 +988,14 @@ public class MapController extends BaseController { | |||
|             GetLastPropDto dto = new GetLastPropDto(); | ||||
|             dto.setDeviceCode(pd.getString("CARDNO")); | ||||
|             return dwService.getLastProp(dto); | ||||
|         }else { | ||||
|             // TODO 其他系统有待开发
 | ||||
|             return null; | ||||
|         } | ||||
|         if (pd.get("corpId") != null && "21590a00ea5e462e9ee44dd332dddc26".equals(pd.getString("corpId"))) { | ||||
|             GetLastPropDto dto = new GetLastPropDto(); | ||||
|             dto.setDeviceCode(pd.getString("CARDNO")); | ||||
|             return dwService.getLtLastProp(dto); | ||||
|         } | ||||
|         // TODO 其他系统有待开发
 | ||||
|         return null; | ||||
|     } | ||||
| 
 | ||||
|     @RequestMapping(value = "/getCameraList") | ||||
|  |  | |||
|  | @ -0,0 +1,34 @@ | |||
| package com.zcloud.controller.map.testDto; | ||||
| 
 | ||||
| 
 | ||||
| import java.util.HashMap; | ||||
| import java.util.Map; | ||||
| 
 | ||||
| public class TestDto { | ||||
|     public static Map<String,Object> getTestInfo() { | ||||
|         HashMap<String, Object> map = new HashMap<>(); | ||||
|         HashMap<String, String> UwbBQ = new HashMap<>(); | ||||
|         HashMap<String, String> UwbJiZhan = new HashMap<>(); | ||||
|         HashMap<String, String> HKcamera = new HashMap<>(); | ||||
|         HashMap<String, String> tklyr = new HashMap<>(); | ||||
|         UwbBQ.put("name", "UWB-BQ"); | ||||
|         UwbBQ.put("code", "0"); | ||||
|         UwbBQ.put("num", "0"); | ||||
|         UwbJiZhan.put("name", "UWB-基站"); | ||||
|         UwbJiZhan.put("code", "0"); | ||||
|         UwbJiZhan.put("num", "0"); | ||||
|         HKcamera.put("name", "海康摄像头"); | ||||
|         HKcamera.put("code", "0"); | ||||
|         HKcamera.put("num", "0"); | ||||
|         tklyr.put("name", "天坑路沿人"); | ||||
|         tklyr.put("code", "0"); | ||||
|         tklyr.put("num", "0"); | ||||
|         map.put("UwbBQ", UwbBQ); | ||||
|         map.put("UwbJiZhan", UwbJiZhan); | ||||
|         map.put("HKcamera", HKcamera); | ||||
|         map.put("tklyr", tklyr); | ||||
|         return map; | ||||
|     } | ||||
| 
 | ||||
| 
 | ||||
| } | ||||
|  | @ -14,6 +14,7 @@ public interface DwService { | |||
|     @Deprecated | ||||
|     Object saveOrUpdateMap(MapInfo param) throws Exception; | ||||
|     Object getTrace(TraceGet param) throws Exception; | ||||
|     Object getLtTrace(TraceGet mapInfo); | ||||
|     Object getAlarmList(AlarmGet param) throws Exception; | ||||
|     Object manageAlarm(AlarmManageDto param) throws Exception; | ||||
|     // 废弃
 | ||||
|  | @ -24,8 +25,10 @@ public interface DwService { | |||
|     Object deleteMap(DeleteDto deleteDto); | ||||
|     // 第二版定位接口
 | ||||
|     Object getLastProp(GetLastPropDto dto) throws Exception; | ||||
|     Object getAllMessage() throws Exception; | ||||
|     Object getLtLastProp(GetLastPropDto dto) throws Exception; | ||||
|     Object getAllMessage(TraceGet param) throws Exception; | ||||
|     Object getCameraList(GetCameraListDto dto) throws Exception; | ||||
|     Object getCameraInfo(GetCameraInfoDto dto) throws Exception; | ||||
| 
 | ||||
| 
 | ||||
| } | ||||
|  |  | |||
|  | @ -6,6 +6,7 @@ import lombok.Data; | |||
| public class TraceGet { | ||||
|     private String user_id; | ||||
|     private String id; | ||||
|     private String corpId; | ||||
|     private String startTime; | ||||
|     private String endTime; | ||||
| } | ||||
|  |  | |||
|  | @ -48,6 +48,11 @@ public class DwServiceImpl implements DwService { | |||
|         return HttpUtil.post(url + "dw/getTrace", param); | ||||
|     } | ||||
| 
 | ||||
|     @Override | ||||
|     public Object getLtTrace(TraceGet param) { | ||||
|         return HttpUtil.post(url + "dw/LtGetTrace", param); | ||||
|     } | ||||
| 
 | ||||
|     @Override | ||||
|     public Object getAlarmList(AlarmGet param) throws Exception { | ||||
|         return HttpUtil.post(url + "dw/getAlarmList", param); | ||||
|  | @ -74,8 +79,13 @@ public class DwServiceImpl implements DwService { | |||
|     } | ||||
| 
 | ||||
|     @Override | ||||
|     public Object getAllMessage() throws Exception { | ||||
|         return HttpUtil.post(url + "dw/getAllMessage",null); | ||||
|     public Object getLtLastProp(GetLastPropDto dto) throws Exception { | ||||
|         return HttpUtil.post(url + "dw/getLtLastProp", dto); | ||||
|     } | ||||
| 
 | ||||
|     @Override | ||||
|     public Object getAllMessage(TraceGet param) throws Exception { | ||||
|         return HttpUtil.post(url + "dw/getAllMessage",param); | ||||
|     } | ||||
| 
 | ||||
|     @Override | ||||
|  |  | |||
		Loading…
	
		Reference in New Issue