人员定位中相关对接操作

pull/4/head
dearlin 2024-02-26 09:39:21 +08:00
parent acb1c9a5a2
commit af92ca1ba7
7 changed files with 97 additions and 11 deletions

View File

@ -148,7 +148,7 @@ public class AppEightWorkController extends BaseController {
ReturnMap returnMap = new ReturnMap();
PageData pd = new PageData();
pd = this.getPageData();
JSONObject body = PLSUtil.getRyRegionList(pd.getString("CORPINFO_ID"),"",1,99999);
JSONObject body = PLSUtil.getRyRegionList(pd.getString("CORPINFO_ID"),"",1,99999,0);
if (body != null) {
List<JSONObject> list = body.getJSONArray("rows").toJavaList(JSONObject.class);

View File

@ -129,7 +129,7 @@ public class MapController extends BaseController {
@RequestMapping(value = "/getFenceList")
@ResponseBody
public ReturnMap getFenceList() throws Exception {
return ReturnMap.ok().put("data", PLSUtil.getRyRegionList(Jurisdiction.getCORPINFO_ID(),"",1,999999));
return ReturnMap.ok().put("data", PLSUtil.getRyRegionList(Jurisdiction.getCORPINFO_ID(),"",1,999999,0));
}
/**

View File

@ -35,7 +35,7 @@ public class MapSettingController extends BaseController {
PageData pageData = this.getPageData();
ReturnMap returnMap = new ReturnMap();
JSONObject body = PLSUtil.getLayerList(
Jurisdiction.getCORPINFO_ID(), Integer.parseInt(pageData.getString("currentPage")), Integer.parseInt(pageData.getString("showCount")), pageData.getString("KEYWORDS"));
Jurisdiction.getCORPINFO_ID(), Integer.parseInt(pageData.getString("currentPage")), Integer.parseInt(pageData.getString("showCount")), pageData.getString("str"));
if (body != null) {
List<JSONObject> list = body.getJSONArray("rows").toJavaList(JSONObject.class);
returnMap.put("varList", list);
@ -130,7 +130,9 @@ public class MapSettingController extends BaseController {
@ResponseBody
public ReturnMap getFenceList() throws Exception {
PageData pageData = this.getPageData();
return ReturnMap.ok().put("data", PLSUtil.getRyRegionList(Jurisdiction.getCORPINFO_ID(), pageData.getString("KEYWORDS"), Integer.parseInt(pageData.getString("currentPage")), Integer.parseInt(pageData.getString("showCount"))));
return ReturnMap.ok().put("data", PLSUtil.getRyRegionList(Jurisdiction.getCORPINFO_ID(), pageData.getString("str"),
Integer.parseInt(pageData.getString("currentPage")), Integer.parseInt(pageData.getString("showCount")),
Integer.parseInt(pageData.getString("type"))));
}

View File

@ -97,12 +97,14 @@ public class PositAlarmController extends BaseController {
*/
@RequestMapping(value = "/otherRegion/list")
@ResponseBody
public ReturnMap otherRegionList() throws Exception {
public ReturnMap otherRegionList(Page page) throws Exception {
PageData pageData = this.getPageData();
ReturnMap returnMap = new ReturnMap();
JSONObject body = PLSUtil.getRyRegionList(Jurisdiction.getCORPINFO_ID(), pageData.getString("KEYWORDS"), Integer.parseInt(pageData.getString("currentPage")), Integer.parseInt(pageData.getString("showCount")));
JSONObject body = PLSUtil.getRyRegionList(Jurisdiction.getCORPINFO_ID(), pageData.getString("str"), Integer.parseInt(pageData.getString("currentPage")), Integer.parseInt(pageData.getString("showCount")),Integer.parseInt(pageData.getString("type")));
if (body != null) {
returnMap.putAll(body);
page.setTotalResult(body.getIntValue("total"));
returnMap.put("page", page);
}
return returnMap;
}
@ -253,12 +255,14 @@ public class PositAlarmController extends BaseController {
*/
@RequestMapping(value = "/electronicFence/list")
@ResponseBody
public ReturnMap electronicFenceList() throws Exception {
public ReturnMap electronicFenceList(Page page) throws Exception {
PageData pageData = this.getPageData();
ReturnMap returnMap = new ReturnMap();
JSONObject body = PLSUtil.GeneralList("/region/electronicFence/list", pageData);
if (body != null) {
returnMap.putAll(body);
page.setTotalResult(body.getIntValue("total"));
returnMap.put("page", page);
}
return returnMap;
}
@ -337,6 +341,7 @@ public class PositAlarmController extends BaseController {
JSONArray regions = JSONObject.parseArray(pageData.getString("regions"));
JSONArray regId1 = JSONObject.parseArray(pageData.getString("regId1"));
JSONArray doubles = JSONObject.parseArray(pageData.getString("doubles"));
JSONArray regGatherId = JSONObject.parseArray(pageData.getString("regGatherId"));
pageData.put("eleType", list);
pageData.put("eleDept", eleDept);
pageData.put("eleCrossed", eleCrossed);
@ -344,6 +349,7 @@ public class PositAlarmController extends BaseController {
pageData.put("regId", regId);
pageData.put("regId1", regId1);
pageData.put("doubles", doubles);
pageData.put("regGatherId", regGatherId);
ReturnMap returnMap = new ReturnMap();
JSONObject body = PLSUtil.GeneralPost("/region/electronicFence/", pageData, Jurisdiction.getCORPINFO_ID());
@ -390,4 +396,82 @@ public class PositAlarmController extends BaseController {
}
return returnMap;
}
/*
*
* */
@RequestMapping(value = "/getAlarmRecordList")
@ResponseBody
public ReturnMap getAlarmRecordList(Page page) throws Exception {
PageData pageData = this.getPageData();
ReturnMap returnMap = new ReturnMap();
// /old/gatherAlarms/regAlarmGatherList?pageNum=1&pageSize=10&status=1
JSONObject body = PLSUtil.GeneralList("/old/gatherAlarms/regAlarmGatherList", pageData);
if (body != null) {
returnMap.putAll(body);
page.setTotalResult(body.getIntValue("total"));
returnMap.put("page", page);
}
return returnMap;
}
/* 聚集概览 */
/**
* @Description:
* @Author: dearLin
* @Date: 2024/2/26/026 9:20
* @Param: [com.zcloud.entity.Page] [page]
* @Return: com.zcloud.util.ReturnMap
*/
@RequestMapping(value = "/aggregateAlarmTrends")
@ResponseBody
public ReturnMap aggregateAlarmTrends() throws Exception {
PageData pageData = this.getPageData();
ReturnMap returnMap = new ReturnMap();
// /old/gatherAlarms/aggregateAlarmTrends?type=2&time=2023-12-18
JSONObject body = PLSUtil.GeneralList("/old/gatherAlarms/aggregateAlarmTrends", pageData);
if (body != null) {
returnMap.putAll(body);
}
return returnMap;
}
/**
* @Description:
* @Author: dearLin
* @Date: 2024/2/26/026 9:20
* @Param: [com.zcloud.entity.Page] [page]
* @Return: com.zcloud.util.ReturnMap
*/
@RequestMapping(value = "/aggregateDataStatisticsByGroup")
@ResponseBody
public ReturnMap aggregateDataStatisticsByGroup() throws Exception {
PageData pageData = this.getPageData();
ReturnMap returnMap = new ReturnMap();
JSONObject body = PLSUtil.GeneralList("/old/gatherAlarms/aggregateDataStatisticsByGroup", pageData);
if (body != null) {
returnMap.putAll(body);
}
return returnMap;
}
/**
* @Description:
* @Author: dearLin
* @Date: 2024/2/26/026 9:20
* @Param: [com.zcloud.entity.Page] [page]
* @Return: com.zcloud.util.ReturnMap
*/
@RequestMapping(value = "/aggregateDataStatistics")
@ResponseBody
public ReturnMap aggregateDataStatistics() throws Exception {
PageData pageData = this.getPageData();
ReturnMap returnMap = new ReturnMap();
JSONObject body = PLSUtil.GeneralList("/old/gatherAlarms/aggregateDataStatistics", pageData);
if (body != null) {
returnMap.putAll(body);
}
return returnMap;
}
}

View File

@ -36,7 +36,7 @@ public class UserCardController extends BaseController {
ReturnMap returnMap = new ReturnMap();
page.setPd(pageData);
JSONObject body = PLSUtil.getUserCardDataList(
Jurisdiction.getCORPINFO_ID(), Integer.parseInt(pageData.getString("currentPage")), Integer.parseInt(pageData.getString("showCount")), pageData.getString("KEYWORDS"));
Jurisdiction.getCORPINFO_ID(), Integer.parseInt(pageData.getString("currentPage")), Integer.parseInt(pageData.getString("showCount")), pageData.getString("str"));
if (body != null) {
List<JSONObject> list = body.getJSONArray("rows").toJavaList(JSONObject.class);
returnMap.put("varList", list);

View File

@ -237,7 +237,7 @@ public class IdentificationPartsController extends BaseController {
PageData pageData = this.getPageData();
String KEYWORDS = (String) pageData.getOrDefault("KEYWORDS", "");
JSONObject body = PLSUtil.getRyRegionList(Jurisdiction.getCORPINFO_ID(),KEYWORDS,Integer.parseInt(pageData.getString("currentPage")),Integer.parseInt(pageData.getString("showCount")));
JSONObject body = PLSUtil.getRyRegionList(Jurisdiction.getCORPINFO_ID(),KEYWORDS,Integer.parseInt(pageData.getString("currentPage")),Integer.parseInt(pageData.getString("showCount")),0);
if (body != null) {
List<JSONObject> list = body.getJSONArray("rows").toJavaList(JSONObject.class);

View File

@ -302,11 +302,11 @@ public class PLSUtil {
* @Param: [java.lang.String, java.lang.Integer, java.lang.Integer] [keywords, currentPage, showCount]
* @Return: com.alibaba.fastjson.JSONObject
*/
public static JSONObject getRyRegionList(String CORPINFO_ID, String keywords, Integer currentPage, Integer showCount) throws Exception {
public static JSONObject getRyRegionList(String CORPINFO_ID, String keywords, Integer currentPage, Integer showCount,Integer type) throws Exception {
HttpHeaders headers = new HttpHeaders();
String url = "/region/region/list?pageNum=" +
currentPage +
"&pageSize=" + showCount + "&type=0" +
"&pageSize=" + showCount + "&type=" +type+
"&str=";
if (Tools.notEmpty(keywords)) url += keywords;
headers.set("Authorization", getToken(CORPINFO_ID));