港股调试摄像头

pull/14/head
dearlin 2024-01-17 13:54:06 +08:00
parent aa617724f1
commit 1d87206d40
12 changed files with 1320 additions and 15 deletions

View File

@ -0,0 +1,173 @@
package com.zcloud.controller.czksmap;
import com.alibaba.fastjson.JSON;
import com.alibaba.fastjson.JSONObject;
import com.zcloud.controller.base.BaseController;
import com.zcloud.entity.PageData;
import com.zcloud.service.system.DepartmentService;
import com.zcloud.service.system.UsersService;
import com.zcloud.util.HttpRequestUtil;
import com.zcloud.util.ReturnMap;
import com.zcloud.util.examUntil.ErrorOperation;
import com.zcloud.util.hk.HKUtil;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.util.ObjectUtils;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import java.util.HashMap;
import java.util.Map;
/**
* ,
* wangxuan
* www.zcloudchina.com
*/
@Controller
@RequestMapping("/api/czks/map")
@ErrorOperation
public class ApiCzksMapController extends BaseController {
@Autowired
private UsersService usersService;
@Autowired
private DepartmentService departmentService;
/**
* @Description:
* @Author: dearLin
* @Date: 2024/1/15/015 17:22
* @Param: [] []
* @Return: com.zcloud.util.ReturnMap
*/
@RequestMapping(value = "carInOutToday")
@ResponseBody
public ReturnMap carInOutToday() throws Exception {
ReturnMap returnMap = new ReturnMap();
HashMap<String, String> hashMap = new HashMap<>();
hashMap.put("oreIn", "3252");
hashMap.put("oreOut", "2356");
hashMap.put("groceryIn", "200");
hashMap.put("groceryOut", "125");
hashMap.put("oreInAll", "33252");
hashMap.put("oreOutAll", "32356");
hashMap.put("groceryInAll", "2200");
hashMap.put("groceryOutAll", "1125");
returnMap.put("czksCarToday", hashMap);
return returnMap;
}
/**
* @Description: 线
* @Author: dearLin
* @Date: 2024/1/15/015 17:22
* @Param: [] []
* @Return: com.zcloud.util.ReturnMap
*/
@RequestMapping(value = "allPersonList")
@ResponseBody
public ReturnMap getOlinePersonCount() throws Exception {
PageData pageData = this.getPageData();
JSONObject request = new JSONObject();
request.put("pageNum", 1);
request.put("pageSize", 10);
request.put("online", "true");
// 人员定位在线
ReturnMap online = HttpRequestUtil.getPeopleApi("/person/allPerson/listPage", request.toString());
pageData.put("CORPINFO_ID", "f8da1790b1034058ae2efefd69af3284");
// 系统人员数
int userCount = usersService.getUserCount(pageData);
// 系统部门数
int departCount = departmentService.getDepartmentCount(pageData);
online.put("userCount", userCount);
online.put("departCount", departCount);
return online;
}
/**
* @Description:
* @Author: dearLin
* @Date: 2024/1/15/015 17:22
* @Param: [] []
* @Return: com.zcloud.util.ReturnMap
*/
@RequestMapping(value = "/getCzksBasicLocationInfoData")
@ResponseBody
public ReturnMap getCzksBasicLocationInfoData() {
return HttpRequestUtil.getPeopleApi("/statistics/personStatistics/todayPerson", "");
}
/**
* @Description:
* @Author: dearLin
* @Date: 2024/1/15/015 17:28
* @Param: [] []
* @Return: com.zcloud.util.ReturnMap
*/
@RequestMapping(value = "/personStaffList")
@ResponseBody
public ReturnMap getCzksPersonStaffListPage() {
PageData pageData = this.getPageData();
JSONObject request = new JSONObject();
request.put("pageNum", pageData.getString("pageNum"));
request.put("pageSize", pageData.getString("pageSize"));
// 普通员工
if ("1".equals(pageData.getString("type"))) {
return HttpRequestUtil.getPeopleApi("/person/staff/listPage", request.toString());
} else {
// 相关方 员工
return HttpRequestUtil.getPeopleApi("/person/allPerson/listPage", request.toString());
}
}
/**
* @Description:
* @Author: dearLin
* @Date: 2024/1/15/015 17:22
* @Param: [] []
* @Return: com.zcloud.util.ReturnMap
*/
@RequestMapping(value = "/getAlarmData")
@ResponseBody
public Object getAlarmData() {
return HttpRequestUtil.getPeopleApi("/statistics/alarmStatistics/todayAlarm", "");
}
/**
* @Description:
* @Author: dearLin
* @Date: 2024/1/17/017 13:44
* @Param: [] []
* @Return: java.lang.Object
*/
@RequestMapping(value="/platformList")
@ResponseBody
public Object platformList() throws Exception{
Map<String,Object> map = new HashMap<String,Object>();
PageData pd =this.getPageData();
map = HKUtil.cameraSearch(pd);
if(ObjectUtils.isEmpty(map)){
map = new HashMap<String,Object>();
}
map.put("result", "success");
return map;
}
/**
* @Description:
* @Author: dearLin
* @Date: 2024/1/15/015 17:22
* @Param: [] []
* @Return: com.zcloud.util.ReturnMap
*/
@RequestMapping(value = "/getCameraHlsPath")
@ResponseBody
public ReturnMap getCameraHlsPath() {
PageData pageData = this.getPageData();
JSONObject request = new JSONObject();
request.put("INDEXCODE", pageData.getString("INDEXCODE"));
return HttpRequestUtil.getCameraHlsPathApi("/platformvideomanagement/getHlsPath", request.toString());
}
}

View File

@ -1,5 +1,7 @@
package com.zcloud.controller.keyProjects; package com.zcloud.controller.keyProjects;
import com.alibaba.fastjson.JSON;
import com.zcloud.aspect.DockAnnotation;
import com.zcloud.controller.base.BaseController; import com.zcloud.controller.base.BaseController;
import com.zcloud.entity.Page; import com.zcloud.entity.Page;
import com.zcloud.entity.PageData; import com.zcloud.entity.PageData;
@ -33,6 +35,7 @@ public class PlatformvideomanagementController extends BaseController {
@RequestMapping(value="/savePosition") @RequestMapping(value="/savePosition")
@ResponseBody @ResponseBody
@DockAnnotation
public Object savePosition() throws Exception{ public Object savePosition() throws Exception{
Map<String,Object> map = new HashMap<String,Object>(); Map<String,Object> map = new HashMap<String,Object>();
String errInfo = "success"; String errInfo = "success";
@ -46,10 +49,12 @@ public class PlatformvideomanagementController extends BaseController {
} }
map.put("result", errInfo); map.put("result", errInfo);
map.put("dockData", JSON.toJSONString(pd));
return map; return map;
} }
@RequestMapping(value="/delLocation") @RequestMapping(value="/delLocation")
@ResponseBody @ResponseBody
@DockAnnotation
public Object delLocation() throws Exception{ public Object delLocation() throws Exception{
Map<String,Object> map = new HashMap<String,Object>(); Map<String,Object> map = new HashMap<String,Object>();
String errInfo = "success"; String errInfo = "success";
@ -57,6 +62,8 @@ public class PlatformvideomanagementController extends BaseController {
pd = this.getPageData(); pd = this.getPageData();
platformvideomanagementService.delLocation(pd); platformvideomanagementService.delLocation(pd);
map.put("result", errInfo); map.put("result", errInfo);
map.put("dockData", JSON.toJSONString(pd));
return map; return map;
} }
/** /**
@ -65,15 +72,16 @@ public class PlatformvideomanagementController extends BaseController {
*/ */
@RequestMapping(value="/add") @RequestMapping(value="/add")
@ResponseBody @ResponseBody
@DockAnnotation
public Object add() throws Exception{ public Object add() throws Exception{
Map<String,Object> map = new HashMap<String,Object>(); Map<String,Object> map = new HashMap<String,Object>();
String errInfo = "success"; String errInfo = "success";
PageData pd = new PageData(); PageData pd = this.getPageData();
pd = this.getPageData();
pd.put("PLATFORMVIDEOMANAGEMENT_ID", this.get32UUID()); //主键 pd.put("PLATFORMVIDEOMANAGEMENT_ID", this.get32UUID()); //主键
pd.put("CORPINFO_ID", Jurisdiction.getCORPINFO_ID()); //主键 pd.put("CORPINFO_ID", Jurisdiction.getCORPINFO_ID()); //主键
platformvideomanagementService.save(pd); platformvideomanagementService.save(pd);
map.put("result", errInfo); map.put("result", errInfo);
map.put("dockData", JSON.toJSONString(pd));
return map; return map;
} }
@ -117,10 +125,580 @@ public class PlatformvideomanagementController extends BaseController {
public Object platformList() throws Exception{ public Object platformList() throws Exception{
Map<String,Object> map = new HashMap<String,Object>(); Map<String,Object> map = new HashMap<String,Object>();
PageData pd =this.getPageData(); PageData pd =this.getPageData();
map = HKUtil.cameraSearch(pd);
if(ObjectUtils.isEmpty(map)){ // map = HKUtil.cameraSearch(pd);
map = new HashMap<String,Object>(); // if(ObjectUtils.isEmpty(map)){
} // map = new HashMap<String,Object>();
// }
String result = " [\n" +
"\t\t\t{\n" +
"\t\t\t\t\"regionIndexCode\": \"13097300002160000004\",\n" +
"\t\t\t\t\"regionPath\": \"@root000000@9e4f2218-ac70-4473-bebe-a1c5dbacbf2f@34030000002001000001@13097300002160000000@13097300002160000004@\",\n" +
"\t\t\t\t\"cascadeType\": 1,\n" +
"\t\t\t\t\"regionPathName\": \"沧州矿石港务有限公司/矿石作业区/矿石平台/矿石港务码头监控/堆取料机\",\n" +
"\t\t\t\t\"cascadeCode\": \"13097300002000052168\",\n" +
"\t\t\t\t\"latitude\": \"0.000000\",\n" +
"\t\t\t\t\"regionName\": \"堆取料机\",\n" +
"\t\t\t\t\"indexCode\": \"13097300001320000328\",\n" +
"\t\t\t\t\"updateTime\": \"2024-01-16T05:00:06.000+08:00\",\n" +
"\t\t\t\t\"sort\": -10005989,\n" +
"\t\t\t\t\"recordLocation\": \"0_1\",\n" +
"\t\t\t\t\"cameraType\": 0,\n" +
"\t\t\t\t\"disOrder\": -10005989,\n" +
"\t\t\t\t\"createTime\": \"2023-05-17T15:24:22.000+08:00\",\n" +
"\t\t\t\t\"name\": \"高压室二\",\n" +
"\t\t\t\t\"decodeTag\": \"ga_h264\",\n" +
"\t\t\t\t\"externalIndexCode\": \"13097300001320000328\",\n" +
"\t\t\t\t\"longitude\": \"0.000000\",\n" +
"\t\t\t\t\"resourceType\": \"camera\"\n" +
"\t\t\t},\n" +
"\t\t\t{\n" +
"\t\t\t\t\"regionIndexCode\": \"13097300002160000004\",\n" +
"\t\t\t\t\"regionPath\": \"@root000000@9e4f2218-ac70-4473-bebe-a1c5dbacbf2f@34030000002001000001@13097300002160000000@13097300002160000004@\",\n" +
"\t\t\t\t\"cascadeType\": 1,\n" +
"\t\t\t\t\"regionPathName\": \"沧州矿石港务有限公司/矿石作业区/矿石平台/矿石港务码头监控/堆取料机\",\n" +
"\t\t\t\t\"cascadeCode\": \"13097300002000052168\",\n" +
"\t\t\t\t\"latitude\": \"0.000000\",\n" +
"\t\t\t\t\"regionName\": \"堆取料机\",\n" +
"\t\t\t\t\"indexCode\": \"13097300001320000329\",\n" +
"\t\t\t\t\"updateTime\": \"2024-01-16T05:00:05.000+08:00\",\n" +
"\t\t\t\t\"sort\": -10006115,\n" +
"\t\t\t\t\"recordLocation\": \"0_1\",\n" +
"\t\t\t\t\"cameraType\": 0,\n" +
"\t\t\t\t\"disOrder\": -10006115,\n" +
"\t\t\t\t\"createTime\": \"2023-05-17T15:24:23.000+08:00\",\n" +
"\t\t\t\t\"name\": \"高压室一\",\n" +
"\t\t\t\t\"decodeTag\": \"ga_h264\",\n" +
"\t\t\t\t\"externalIndexCode\": \"13097300001320000329\",\n" +
"\t\t\t\t\"longitude\": \"0.000000\",\n" +
"\t\t\t\t\"resourceType\": \"camera\"\n" +
"\t\t\t},\n" +
"\t\t\t{\n" +
"\t\t\t\t\"regionIndexCode\": \"c8cb2047-e430-43a3-8f37-8348e6463055\",\n" +
"\t\t\t\t\"dacIndexCode\": \"--\",\n" +
"\t\t\t\t\"regionPathName\": \"沧州矿石港务有限公司/杂货作业区/综合业务调度楼\",\n" +
"\t\t\t\t\"latitude\": \"\",\n" +
"\t\t\t\t\"regionName\": \"综合业务调度楼\",\n" +
"\t\t\t\t\"indexCode\": \"4b85c88181cd4741b124d4b456bc7d14\",\n" +
"\t\t\t\t\"channelType\": \"analog\",\n" +
"\t\t\t\t\"recordLocation\": \"0\",\n" +
"\t\t\t\t\"disOrder\": 6768,\n" +
"\t\t\t\t\"capability\": \"@event_face_detect_alarm@event_audio@io@event_gis@event_rule@gis@event_ias@event_vss@record@vss@event_io@net@maintenance@event_device@status@\",\n" +
"\t\t\t\t\"parentIndexCode\": \"5405983799d345d69a6289885d7bd365\",\n" +
"\t\t\t\t\"longitude\": \"\",\n" +
"\t\t\t\t\"chanNum\": 1,\n" +
"\t\t\t\t\"regionPath\": \"@root000000@8b975d79-ef3f-4543-89a9-8c7bb314bd74@c8cb2047-e430-43a3-8f37-8348e6463055@\",\n" +
"\t\t\t\t\"cascadeType\": 0,\n" +
"\t\t\t\t\"installLocation\": \"\",\n" +
"\t\t\t\t\"updateTime\": \"2023-09-29T11:09:06.978+08:00\",\n" +
"\t\t\t\t\"sort\": 6768,\n" +
"\t\t\t\t\"cameraType\": 0,\n" +
"\t\t\t\t\"treatyType\": \"hiksdk_net\",\n" +
"\t\t\t\t\"cameraRelateTalk\": \"4c363eaefd36472297c44a239bf96003\",\n" +
"\t\t\t\t\"transType\": 1,\n" +
"\t\t\t\t\"createTime\": \"2023-07-20T12:51:52.438+08:00\",\n" +
"\t\t\t\t\"name\": \"食堂餐厅洗消间\",\n" +
"\t\t\t\t\"decodeTag\": \"hikvision\",\n" +
"\t\t\t\t\"externalIndexCode\": \"13098301581314000838\",\n" +
"\t\t\t\t\"resourceType\": \"camera\"\n" +
"\t\t\t},\n" +
"\t\t\t{\n" +
"\t\t\t\t\"regionIndexCode\": \"c8cb2047-e430-43a3-8f37-8348e6463055\",\n" +
"\t\t\t\t\"dacIndexCode\": \"--\",\n" +
"\t\t\t\t\"regionPathName\": \"沧州矿石港务有限公司/杂货作业区/综合业务调度楼\",\n" +
"\t\t\t\t\"latitude\": \"\",\n" +
"\t\t\t\t\"regionName\": \"综合业务调度楼\",\n" +
"\t\t\t\t\"indexCode\": \"e326096d6d3d4b8aab925ca05d897d46\",\n" +
"\t\t\t\t\"channelType\": \"analog\",\n" +
"\t\t\t\t\"recordLocation\": \"0\",\n" +
"\t\t\t\t\"disOrder\": 6767,\n" +
"\t\t\t\t\"capability\": \"@event_face_detect_alarm@event_audio@io@event_gis@event_rule@gis@event_ias@event_vss@record@vss@event_io@net@maintenance@event_device@status@\",\n" +
"\t\t\t\t\"parentIndexCode\": \"8c6c6329869742f8a107e059704f3d8e\",\n" +
"\t\t\t\t\"longitude\": \"\",\n" +
"\t\t\t\t\"chanNum\": 1,\n" +
"\t\t\t\t\"regionPath\": \"@root000000@8b975d79-ef3f-4543-89a9-8c7bb314bd74@c8cb2047-e430-43a3-8f37-8348e6463055@\",\n" +
"\t\t\t\t\"cascadeType\": 0,\n" +
"\t\t\t\t\"installLocation\": \"\",\n" +
"\t\t\t\t\"updateTime\": \"2023-09-29T11:09:06.979+08:00\",\n" +
"\t\t\t\t\"sort\": 6767,\n" +
"\t\t\t\t\"cameraType\": 0,\n" +
"\t\t\t\t\"treatyType\": \"hiksdk_net\",\n" +
"\t\t\t\t\"cameraRelateTalk\": \"8b8232c02a694704a761c7f3e81dbf0e\",\n" +
"\t\t\t\t\"transType\": 1,\n" +
"\t\t\t\t\"createTime\": \"2023-07-20T12:51:55.678+08:00\",\n" +
"\t\t\t\t\"name\": \"食堂餐厅南侧楼梯\",\n" +
"\t\t\t\t\"decodeTag\": \"hikvision\",\n" +
"\t\t\t\t\"externalIndexCode\": \"13098301581314000826\",\n" +
"\t\t\t\t\"resourceType\": \"camera\"\n" +
"\t\t\t},\n" +
"\t\t\t{\n" +
"\t\t\t\t\"regionIndexCode\": \"c8cb2047-e430-43a3-8f37-8348e6463055\",\n" +
"\t\t\t\t\"dacIndexCode\": \"--\",\n" +
"\t\t\t\t\"regionPathName\": \"沧州矿石港务有限公司/杂货作业区/综合业务调度楼\",\n" +
"\t\t\t\t\"latitude\": \"\",\n" +
"\t\t\t\t\"regionName\": \"综合业务调度楼\",\n" +
"\t\t\t\t\"indexCode\": \"35dced7d3467425ea833eb4320b37490\",\n" +
"\t\t\t\t\"channelType\": \"analog\",\n" +
"\t\t\t\t\"recordLocation\": \"0\",\n" +
"\t\t\t\t\"disOrder\": 6766,\n" +
"\t\t\t\t\"capability\": \"@event_face_detect_alarm@event_audio@io@event_gis@event_rule@gis@event_ias@event_vss@record@vss@event_io@net@maintenance@event_device@status@\",\n" +
"\t\t\t\t\"parentIndexCode\": \"5679d668c31f495984570370333d9b77\",\n" +
"\t\t\t\t\"longitude\": \"\",\n" +
"\t\t\t\t\"chanNum\": 1,\n" +
"\t\t\t\t\"regionPath\": \"@root000000@8b975d79-ef3f-4543-89a9-8c7bb314bd74@c8cb2047-e430-43a3-8f37-8348e6463055@\",\n" +
"\t\t\t\t\"cascadeType\": 0,\n" +
"\t\t\t\t\"installLocation\": \"\",\n" +
"\t\t\t\t\"updateTime\": \"2023-09-29T11:09:06.980+08:00\",\n" +
"\t\t\t\t\"sort\": 6766,\n" +
"\t\t\t\t\"cameraType\": 0,\n" +
"\t\t\t\t\"treatyType\": \"hiksdk_net\",\n" +
"\t\t\t\t\"cameraRelateTalk\": \"9e8c625a9a064bfb831a8140c5aeebe3\",\n" +
"\t\t\t\t\"transType\": 1,\n" +
"\t\t\t\t\"createTime\": \"2023-07-20T12:51:52.789+08:00\",\n" +
"\t\t\t\t\"name\": \"食堂餐厅南侧入口\",\n" +
"\t\t\t\t\"decodeTag\": \"hikvision\",\n" +
"\t\t\t\t\"externalIndexCode\": \"13098301581314000846\",\n" +
"\t\t\t\t\"resourceType\": \"camera\"\n" +
"\t\t\t},\n" +
"\t\t\t{\n" +
"\t\t\t\t\"regionIndexCode\": \"c8cb2047-e430-43a3-8f37-8348e6463055\",\n" +
"\t\t\t\t\"dacIndexCode\": \"--\",\n" +
"\t\t\t\t\"regionPathName\": \"沧州矿石港务有限公司/杂货作业区/综合业务调度楼\",\n" +
"\t\t\t\t\"latitude\": \"\",\n" +
"\t\t\t\t\"regionName\": \"综合业务调度楼\",\n" +
"\t\t\t\t\"indexCode\": \"0ff25bed693e444ba9540ef08c108902\",\n" +
"\t\t\t\t\"channelType\": \"analog\",\n" +
"\t\t\t\t\"recordLocation\": \"0\",\n" +
"\t\t\t\t\"disOrder\": 6735,\n" +
"\t\t\t\t\"capability\": \"@event_face_detect_alarm@event_audio@io@event_gis@event_rule@gis@event_ias@event_vss@record@vss@event_io@net@maintenance@event_device@status@\",\n" +
"\t\t\t\t\"parentIndexCode\": \"f25ae4ce23404cc0a4aa9e53fd1731f1\",\n" +
"\t\t\t\t\"longitude\": \"\",\n" +
"\t\t\t\t\"chanNum\": 1,\n" +
"\t\t\t\t\"regionPath\": \"@root000000@8b975d79-ef3f-4543-89a9-8c7bb314bd74@c8cb2047-e430-43a3-8f37-8348e6463055@\",\n" +
"\t\t\t\t\"cascadeType\": 0,\n" +
"\t\t\t\t\"installLocation\": \"\",\n" +
"\t\t\t\t\"updateTime\": \"2023-09-29T11:09:06.981+08:00\",\n" +
"\t\t\t\t\"sort\": 6735,\n" +
"\t\t\t\t\"cameraType\": 0,\n" +
"\t\t\t\t\"treatyType\": \"hiksdk_net\",\n" +
"\t\t\t\t\"cameraRelateTalk\": \"b0d6560cd494436cb9e03c36377fea2d\",\n" +
"\t\t\t\t\"transType\": 1,\n" +
"\t\t\t\t\"createTime\": \"2023-07-20T12:51:47.978+08:00\",\n" +
"\t\t\t\t\"name\": \"食堂餐厅北侧楼梯\",\n" +
"\t\t\t\t\"decodeTag\": \"hikvision\",\n" +
"\t\t\t\t\"externalIndexCode\": \"13098301581314000832\",\n" +
"\t\t\t\t\"resourceType\": \"camera\"\n" +
"\t\t\t},\n" +
"\t\t\t{\n" +
"\t\t\t\t\"regionIndexCode\": \"c8cb2047-e430-43a3-8f37-8348e6463055\",\n" +
"\t\t\t\t\"dacIndexCode\": \"--\",\n" +
"\t\t\t\t\"regionPathName\": \"沧州矿石港务有限公司/杂货作业区/综合业务调度楼\",\n" +
"\t\t\t\t\"latitude\": \"\",\n" +
"\t\t\t\t\"regionName\": \"综合业务调度楼\",\n" +
"\t\t\t\t\"indexCode\": \"72560dd84bed4dae81a9ffa6186bc1ca\",\n" +
"\t\t\t\t\"channelType\": \"analog\",\n" +
"\t\t\t\t\"recordLocation\": \"0\",\n" +
"\t\t\t\t\"disOrder\": 6734,\n" +
"\t\t\t\t\"capability\": \"@event_face_detect_alarm@event_audio@io@event_gis@event_rule@gis@event_ias@event_vss@record@vss@event_io@net@maintenance@event_device@status@\",\n" +
"\t\t\t\t\"parentIndexCode\": \"7bfda70b752b42a7a18760cd6b6a4458\",\n" +
"\t\t\t\t\"longitude\": \"\",\n" +
"\t\t\t\t\"chanNum\": 1,\n" +
"\t\t\t\t\"regionPath\": \"@root000000@8b975d79-ef3f-4543-89a9-8c7bb314bd74@c8cb2047-e430-43a3-8f37-8348e6463055@\",\n" +
"\t\t\t\t\"cascadeType\": 0,\n" +
"\t\t\t\t\"installLocation\": \"\",\n" +
"\t\t\t\t\"updateTime\": \"2023-09-29T11:09:06.982+08:00\",\n" +
"\t\t\t\t\"sort\": 6734,\n" +
"\t\t\t\t\"cameraType\": 0,\n" +
"\t\t\t\t\"treatyType\": \"hiksdk_net\",\n" +
"\t\t\t\t\"cameraRelateTalk\": \"8cb5c82f17024819979aa8da9d79d3d0\",\n" +
"\t\t\t\t\"transType\": 1,\n" +
"\t\t\t\t\"createTime\": \"2023-07-20T12:51:55.259+08:00\",\n" +
"\t\t\t\t\"name\": \"食堂餐厅北侧入口\",\n" +
"\t\t\t\t\"decodeTag\": \"hikvision\",\n" +
"\t\t\t\t\"externalIndexCode\": \"13098301581314000833\",\n" +
"\t\t\t\t\"resourceType\": \"camera\"\n" +
"\t\t\t},\n" +
"\t\t\t{\n" +
"\t\t\t\t\"regionIndexCode\": \"c8cb2047-e430-43a3-8f37-8348e6463055\",\n" +
"\t\t\t\t\"dacIndexCode\": \"--\",\n" +
"\t\t\t\t\"regionPathName\": \"沧州矿石港务有限公司/杂货作业区/综合业务调度楼\",\n" +
"\t\t\t\t\"latitude\": \"\",\n" +
"\t\t\t\t\"regionName\": \"综合业务调度楼\",\n" +
"\t\t\t\t\"indexCode\": \"2c12810d5a1144fa83caa36970fcdd0b\",\n" +
"\t\t\t\t\"channelType\": \"analog\",\n" +
"\t\t\t\t\"recordLocation\": \"0\",\n" +
"\t\t\t\t\"disOrder\": 6733,\n" +
"\t\t\t\t\"capability\": \"@event_face_detect_alarm@event_audio@io@event_gis@event_rule@gis@event_ias@event_vss@record@vss@event_io@net@maintenance@event_device@status@\",\n" +
"\t\t\t\t\"parentIndexCode\": \"3b6a0aa63c11471097c80e892931a4f2\",\n" +
"\t\t\t\t\"longitude\": \"\",\n" +
"\t\t\t\t\"chanNum\": 1,\n" +
"\t\t\t\t\"regionPath\": \"@root000000@8b975d79-ef3f-4543-89a9-8c7bb314bd74@c8cb2047-e430-43a3-8f37-8348e6463055@\",\n" +
"\t\t\t\t\"cascadeType\": 0,\n" +
"\t\t\t\t\"installLocation\": \"\",\n" +
"\t\t\t\t\"updateTime\": \"2023-09-29T11:09:06.983+08:00\",\n" +
"\t\t\t\t\"sort\": 6733,\n" +
"\t\t\t\t\"cameraType\": 0,\n" +
"\t\t\t\t\"treatyType\": \"hiksdk_net\",\n" +
"\t\t\t\t\"cameraRelateTalk\": \"a43bad8e99984d8ab07b079975cb7ad9\",\n" +
"\t\t\t\t\"transType\": 1,\n" +
"\t\t\t\t\"createTime\": \"2023-07-20T12:51:47.235+08:00\",\n" +
"\t\t\t\t\"name\": \"食堂餐厅东南角\",\n" +
"\t\t\t\t\"decodeTag\": \"hikvision\",\n" +
"\t\t\t\t\"externalIndexCode\": \"13098301581314000835\",\n" +
"\t\t\t\t\"resourceType\": \"camera\"\n" +
"\t\t\t},\n" +
"\t\t\t{\n" +
"\t\t\t\t\"regionIndexCode\": \"c8cb2047-e430-43a3-8f37-8348e6463055\",\n" +
"\t\t\t\t\"dacIndexCode\": \"--\",\n" +
"\t\t\t\t\"regionPathName\": \"沧州矿石港务有限公司/杂货作业区/综合业务调度楼\",\n" +
"\t\t\t\t\"latitude\": \"\",\n" +
"\t\t\t\t\"regionName\": \"综合业务调度楼\",\n" +
"\t\t\t\t\"indexCode\": \"6671cdcc8e494b998b4a080eafd0c721\",\n" +
"\t\t\t\t\"channelType\": \"analog\",\n" +
"\t\t\t\t\"recordLocation\": \"0\",\n" +
"\t\t\t\t\"disOrder\": 6732,\n" +
"\t\t\t\t\"capability\": \"@event_face_detect_alarm@event_audio@io@event_gis@event_rule@gis@event_ias@event_vss@record@vss@event_io@net@maintenance@event_device@status@\",\n" +
"\t\t\t\t\"parentIndexCode\": \"ac2f62430dc44729862edfdb7bf607a4\",\n" +
"\t\t\t\t\"longitude\": \"\",\n" +
"\t\t\t\t\"chanNum\": 1,\n" +
"\t\t\t\t\"regionPath\": \"@root000000@8b975d79-ef3f-4543-89a9-8c7bb314bd74@c8cb2047-e430-43a3-8f37-8348e6463055@\",\n" +
"\t\t\t\t\"cascadeType\": 0,\n" +
"\t\t\t\t\"installLocation\": \"\",\n" +
"\t\t\t\t\"updateTime\": \"2023-09-29T11:09:06.984+08:00\",\n" +
"\t\t\t\t\"sort\": 6732,\n" +
"\t\t\t\t\"cameraType\": 0,\n" +
"\t\t\t\t\"treatyType\": \"hiksdk_net\",\n" +
"\t\t\t\t\"cameraRelateTalk\": \"4556469b457f4f90a2543e1dfe0f921a\",\n" +
"\t\t\t\t\"transType\": 1,\n" +
"\t\t\t\t\"createTime\": \"2023-07-20T12:51:50.854+08:00\",\n" +
"\t\t\t\t\"name\": \"食堂餐厅东北角\",\n" +
"\t\t\t\t\"decodeTag\": \"hikvision\",\n" +
"\t\t\t\t\"externalIndexCode\": \"13098301581314000822\",\n" +
"\t\t\t\t\"resourceType\": \"camera\"\n" +
"\t\t\t},\n" +
"\t\t\t{\n" +
"\t\t\t\t\"regionIndexCode\": \"c8cb2047-e430-43a3-8f37-8348e6463055\",\n" +
"\t\t\t\t\"dacIndexCode\": \"--\",\n" +
"\t\t\t\t\"regionPathName\": \"沧州矿石港务有限公司/杂货作业区/综合业务调度楼\",\n" +
"\t\t\t\t\"latitude\": \"\",\n" +
"\t\t\t\t\"regionName\": \"综合业务调度楼\",\n" +
"\t\t\t\t\"indexCode\": \"58dc6742e9c644cca184ec4c5030d791\",\n" +
"\t\t\t\t\"channelType\": \"analog\",\n" +
"\t\t\t\t\"recordLocation\": \"0\",\n" +
"\t\t\t\t\"disOrder\": 6731,\n" +
"\t\t\t\t\"capability\": \"@event_face_detect_alarm@event_audio@io@event_gis@event_rule@gis@event_ias@event_vss@record@vss@event_io@net@maintenance@event_device@status@\",\n" +
"\t\t\t\t\"parentIndexCode\": \"a1b8b2388ebe4bdc8e0d5f90e29e0646\",\n" +
"\t\t\t\t\"longitude\": \"\",\n" +
"\t\t\t\t\"chanNum\": 1,\n" +
"\t\t\t\t\"regionPath\": \"@root000000@8b975d79-ef3f-4543-89a9-8c7bb314bd74@c8cb2047-e430-43a3-8f37-8348e6463055@\",\n" +
"\t\t\t\t\"cascadeType\": 0,\n" +
"\t\t\t\t\"installLocation\": \"\",\n" +
"\t\t\t\t\"updateTime\": \"2023-09-29T11:09:06.985+08:00\",\n" +
"\t\t\t\t\"sort\": 6731,\n" +
"\t\t\t\t\"cameraType\": 0,\n" +
"\t\t\t\t\"treatyType\": \"hiksdk_net\",\n" +
"\t\t\t\t\"cameraRelateTalk\": \"e4da9e19b5134f458b7cafaa4a15e8a0\",\n" +
"\t\t\t\t\"transType\": 1,\n" +
"\t\t\t\t\"createTime\": \"2023-07-20T12:51:56.044+08:00\",\n" +
"\t\t\t\t\"name\": \"食堂餐厅东侧\",\n" +
"\t\t\t\t\"decodeTag\": \"hikvision\",\n" +
"\t\t\t\t\"externalIndexCode\": \"13098301581314000824\",\n" +
"\t\t\t\t\"resourceType\": \"camera\"\n" +
"\t\t\t},\n" +
"\t\t\t{\n" +
"\t\t\t\t\"regionIndexCode\": \"c8cb2047-e430-43a3-8f37-8348e6463055\",\n" +
"\t\t\t\t\"dacIndexCode\": \"--\",\n" +
"\t\t\t\t\"regionPathName\": \"沧州矿石港务有限公司/杂货作业区/综合业务调度楼\",\n" +
"\t\t\t\t\"latitude\": \"\",\n" +
"\t\t\t\t\"regionName\": \"综合业务调度楼\",\n" +
"\t\t\t\t\"indexCode\": \"277b614fe37c40c79bf6f86222d3bddb\",\n" +
"\t\t\t\t\"channelType\": \"analog\",\n" +
"\t\t\t\t\"recordLocation\": \"0\",\n" +
"\t\t\t\t\"disOrder\": 6730,\n" +
"\t\t\t\t\"capability\": \"@event_face_detect_alarm@event_audio@io@event_gis@event_rule@gis@event_ias@event_vss@record@vss@event_io@net@maintenance@event_device@status@\",\n" +
"\t\t\t\t\"parentIndexCode\": \"3d38235515af45b48b7cbcc1bc5d0028\",\n" +
"\t\t\t\t\"longitude\": \"\",\n" +
"\t\t\t\t\"chanNum\": 1,\n" +
"\t\t\t\t\"regionPath\": \"@root000000@8b975d79-ef3f-4543-89a9-8c7bb314bd74@c8cb2047-e430-43a3-8f37-8348e6463055@\",\n" +
"\t\t\t\t\"cascadeType\": 0,\n" +
"\t\t\t\t\"installLocation\": \"\",\n" +
"\t\t\t\t\"updateTime\": \"2023-09-29T11:09:06.986+08:00\",\n" +
"\t\t\t\t\"sort\": 6730,\n" +
"\t\t\t\t\"cameraType\": 0,\n" +
"\t\t\t\t\"treatyType\": \"hiksdk_net\",\n" +
"\t\t\t\t\"cameraRelateTalk\": \"3c2d71bf2be045b6a8dfe4872f0d5c03\",\n" +
"\t\t\t\t\"transType\": 1,\n" +
"\t\t\t\t\"createTime\": \"2023-07-20T12:51:56.713+08:00\",\n" +
"\t\t\t\t\"name\": \"食堂菜类粗加工间\",\n" +
"\t\t\t\t\"decodeTag\": \"hikvision\",\n" +
"\t\t\t\t\"externalIndexCode\": \"13098301581314000840\",\n" +
"\t\t\t\t\"resourceType\": \"camera\"\n" +
"\t\t\t},\n" +
"\t\t\t{\n" +
"\t\t\t\t\"regionIndexCode\": \"c8cb2047-e430-43a3-8f37-8348e6463055\",\n" +
"\t\t\t\t\"dacIndexCode\": \"--\",\n" +
"\t\t\t\t\"regionPathName\": \"沧州矿石港务有限公司/杂货作业区/综合业务调度楼\",\n" +
"\t\t\t\t\"latitude\": \"\",\n" +
"\t\t\t\t\"regionName\": \"综合业务调度楼\",\n" +
"\t\t\t\t\"indexCode\": \"7bf6563bdc4a442a972633749cff4047\",\n" +
"\t\t\t\t\"channelType\": \"analog\",\n" +
"\t\t\t\t\"recordLocation\": \"0\",\n" +
"\t\t\t\t\"disOrder\": 6729,\n" +
"\t\t\t\t\"capability\": \"@event_face_detect_alarm@event_audio@io@event_gis@event_rule@gis@event_ias@event_vss@record@vss@event_io@net@maintenance@event_device@status@\",\n" +
"\t\t\t\t\"parentIndexCode\": \"ef013768f7fb4e67b9b10f22d260695c\",\n" +
"\t\t\t\t\"longitude\": \"\",\n" +
"\t\t\t\t\"chanNum\": 1,\n" +
"\t\t\t\t\"regionPath\": \"@root000000@8b975d79-ef3f-4543-89a9-8c7bb314bd74@c8cb2047-e430-43a3-8f37-8348e6463055@\",\n" +
"\t\t\t\t\"cascadeType\": 0,\n" +
"\t\t\t\t\"installLocation\": \"\",\n" +
"\t\t\t\t\"updateTime\": \"2023-09-29T11:09:06.987+08:00\",\n" +
"\t\t\t\t\"sort\": 6729,\n" +
"\t\t\t\t\"cameraType\": 0,\n" +
"\t\t\t\t\"treatyType\": \"hiksdk_net\",\n" +
"\t\t\t\t\"cameraRelateTalk\": \"74dea9993b1e4abf93534f3d9717b666\",\n" +
"\t\t\t\t\"transType\": 1,\n" +
"\t\t\t\t\"createTime\": \"2023-07-20T12:51:49.676+08:00\",\n" +
"\t\t\t\t\"name\": \"食堂肉类海产品粗加工间\",\n" +
"\t\t\t\t\"decodeTag\": \"hikvision\",\n" +
"\t\t\t\t\"externalIndexCode\": \"13098301581314000845\",\n" +
"\t\t\t\t\"resourceType\": \"camera\"\n" +
"\t\t\t},\n" +
"\t\t\t{\n" +
"\t\t\t\t\"regionIndexCode\": \"c8cb2047-e430-43a3-8f37-8348e6463055\",\n" +
"\t\t\t\t\"dacIndexCode\": \"--\",\n" +
"\t\t\t\t\"regionPathName\": \"沧州矿石港务有限公司/杂货作业区/综合业务调度楼\",\n" +
"\t\t\t\t\"latitude\": \"\",\n" +
"\t\t\t\t\"regionName\": \"综合业务调度楼\",\n" +
"\t\t\t\t\"indexCode\": \"43a9b45c9664411e941003219dca1ead\",\n" +
"\t\t\t\t\"channelType\": \"analog\",\n" +
"\t\t\t\t\"recordLocation\": \"0\",\n" +
"\t\t\t\t\"disOrder\": 6728,\n" +
"\t\t\t\t\"capability\": \"@event_face_detect_alarm@event_audio@io@event_gis@event_rule@gis@event_ias@event_vss@record@vss@event_io@net@maintenance@event_device@status@\",\n" +
"\t\t\t\t\"parentIndexCode\": \"61808f1d2fd6468caeb8326ddc3e2d6a\",\n" +
"\t\t\t\t\"longitude\": \"\",\n" +
"\t\t\t\t\"chanNum\": 1,\n" +
"\t\t\t\t\"regionPath\": \"@root000000@8b975d79-ef3f-4543-89a9-8c7bb314bd74@c8cb2047-e430-43a3-8f37-8348e6463055@\",\n" +
"\t\t\t\t\"cascadeType\": 0,\n" +
"\t\t\t\t\"installLocation\": \"\",\n" +
"\t\t\t\t\"updateTime\": \"2023-09-29T11:09:06.988+08:00\",\n" +
"\t\t\t\t\"sort\": 6728,\n" +
"\t\t\t\t\"cameraType\": 0,\n" +
"\t\t\t\t\"treatyType\": \"hiksdk_net\",\n" +
"\t\t\t\t\"cameraRelateTalk\": \"dfbd0eeec8094d919c262d65848f9cd8\",\n" +
"\t\t\t\t\"transType\": 1,\n" +
"\t\t\t\t\"createTime\": \"2023-07-20T12:51:52.089+08:00\",\n" +
"\t\t\t\t\"name\": \"食堂管理室\",\n" +
"\t\t\t\t\"decodeTag\": \"hikvision\",\n" +
"\t\t\t\t\"externalIndexCode\": \"13098301581314000828\",\n" +
"\t\t\t\t\"resourceType\": \"camera\"\n" +
"\t\t\t},\n" +
"\t\t\t{\n" +
"\t\t\t\t\"regionIndexCode\": \"c8cb2047-e430-43a3-8f37-8348e6463055\",\n" +
"\t\t\t\t\"dacIndexCode\": \"--\",\n" +
"\t\t\t\t\"regionPathName\": \"沧州矿石港务有限公司/杂货作业区/综合业务调度楼\",\n" +
"\t\t\t\t\"latitude\": \"\",\n" +
"\t\t\t\t\"regionName\": \"综合业务调度楼\",\n" +
"\t\t\t\t\"indexCode\": \"3c275a198d4c4bf5979dbae1bf9cbf0d\",\n" +
"\t\t\t\t\"channelType\": \"analog\",\n" +
"\t\t\t\t\"recordLocation\": \"0\",\n" +
"\t\t\t\t\"disOrder\": 6727,\n" +
"\t\t\t\t\"capability\": \"@event_vss@io@vss@record@ptz@remote_vss@net@maintenance@status@\",\n" +
"\t\t\t\t\"parentIndexCode\": \"e8215420e6364bf182625fc372d11022\",\n" +
"\t\t\t\t\"longitude\": \"\",\n" +
"\t\t\t\t\"chanNum\": 1,\n" +
"\t\t\t\t\"regionPath\": \"@root000000@8b975d79-ef3f-4543-89a9-8c7bb314bd74@c8cb2047-e430-43a3-8f37-8348e6463055@\",\n" +
"\t\t\t\t\"cascadeType\": 0,\n" +
"\t\t\t\t\"installLocation\": \"\",\n" +
"\t\t\t\t\"updateTime\": \"2023-09-29T11:09:06.989+08:00\",\n" +
"\t\t\t\t\"sort\": 6727,\n" +
"\t\t\t\t\"cameraType\": 0,\n" +
"\t\t\t\t\"treatyType\": \"hiksdk_net\",\n" +
"\t\t\t\t\"cameraRelateTalk\": \"2be64a34f89c4f3da3318bc7f5045cc6\",\n" +
"\t\t\t\t\"transType\": 1,\n" +
"\t\t\t\t\"createTime\": \"2023-07-20T12:51:48.926+08:00\",\n" +
"\t\t\t\t\"name\": \"食堂监控机房\",\n" +
"\t\t\t\t\"decodeTag\": \"hikvision\",\n" +
"\t\t\t\t\"externalIndexCode\": \"13098301581314000830\",\n" +
"\t\t\t\t\"resourceType\": \"camera\"\n" +
"\t\t\t},\n" +
"\t\t\t{\n" +
"\t\t\t\t\"regionIndexCode\": \"c8cb2047-e430-43a3-8f37-8348e6463055\",\n" +
"\t\t\t\t\"dacIndexCode\": \"--\",\n" +
"\t\t\t\t\"regionPathName\": \"沧州矿石港务有限公司/杂货作业区/综合业务调度楼\",\n" +
"\t\t\t\t\"latitude\": \"\",\n" +
"\t\t\t\t\"regionName\": \"综合业务调度楼\",\n" +
"\t\t\t\t\"indexCode\": \"749e994d28c2474ba7d0bdf31535a956\",\n" +
"\t\t\t\t\"channelType\": \"analog\",\n" +
"\t\t\t\t\"recordLocation\": \"0\",\n" +
"\t\t\t\t\"disOrder\": 6726,\n" +
"\t\t\t\t\"capability\": \"@event_face_detect_alarm@event_audio@io@event_gis@event_rule@gis@event_ias@event_vss@record@vss@event_io@net@maintenance@event_device@status@\",\n" +
"\t\t\t\t\"parentIndexCode\": \"d3c72e6747854832bc254cffd6cbabe4\",\n" +
"\t\t\t\t\"longitude\": \"\",\n" +
"\t\t\t\t\"chanNum\": 1,\n" +
"\t\t\t\t\"regionPath\": \"@root000000@8b975d79-ef3f-4543-89a9-8c7bb314bd74@c8cb2047-e430-43a3-8f37-8348e6463055@\",\n" +
"\t\t\t\t\"cascadeType\": 0,\n" +
"\t\t\t\t\"installLocation\": \"\",\n" +
"\t\t\t\t\"updateTime\": \"2023-09-29T11:09:06.990+08:00\",\n" +
"\t\t\t\t\"sort\": 6726,\n" +
"\t\t\t\t\"cameraType\": 0,\n" +
"\t\t\t\t\"treatyType\": \"hiksdk_net\",\n" +
"\t\t\t\t\"cameraRelateTalk\": \"0cb8471dfe534beaaabae444b6c0cd62\",\n" +
"\t\t\t\t\"transType\": 1,\n" +
"\t\t\t\t\"createTime\": \"2023-07-20T12:51:58.376+08:00\",\n" +
"\t\t\t\t\"name\": \"食堂清真厨房\",\n" +
"\t\t\t\t\"decodeTag\": \"hikvision\",\n" +
"\t\t\t\t\"externalIndexCode\": \"13098301581314000849\",\n" +
"\t\t\t\t\"resourceType\": \"camera\"\n" +
"\t\t\t},\n" +
"\t\t\t{\n" +
"\t\t\t\t\"regionIndexCode\": \"c8cb2047-e430-43a3-8f37-8348e6463055\",\n" +
"\t\t\t\t\"dacIndexCode\": \"--\",\n" +
"\t\t\t\t\"regionPathName\": \"沧州矿石港务有限公司/杂货作业区/综合业务调度楼\",\n" +
"\t\t\t\t\"latitude\": \"\",\n" +
"\t\t\t\t\"regionName\": \"综合业务调度楼\",\n" +
"\t\t\t\t\"indexCode\": \"f40b9801a09e4922bad2c3f916ee232f\",\n" +
"\t\t\t\t\"channelType\": \"analog\",\n" +
"\t\t\t\t\"recordLocation\": \"0\",\n" +
"\t\t\t\t\"disOrder\": 6725,\n" +
"\t\t\t\t\"capability\": \"@event_face_detect_alarm@event_audio@io@event_gis@event_rule@gis@event_ias@event_vss@record@vss@event_io@net@maintenance@event_device@status@\",\n" +
"\t\t\t\t\"parentIndexCode\": \"d366a48139f84550867ae0cd31fde575\",\n" +
"\t\t\t\t\"longitude\": \"\",\n" +
"\t\t\t\t\"chanNum\": 1,\n" +
"\t\t\t\t\"regionPath\": \"@root000000@8b975d79-ef3f-4543-89a9-8c7bb314bd74@c8cb2047-e430-43a3-8f37-8348e6463055@\",\n" +
"\t\t\t\t\"cascadeType\": 0,\n" +
"\t\t\t\t\"installLocation\": \"\",\n" +
"\t\t\t\t\"updateTime\": \"2023-09-29T11:09:06.991+08:00\",\n" +
"\t\t\t\t\"sort\": 6725,\n" +
"\t\t\t\t\"cameraType\": 0,\n" +
"\t\t\t\t\"treatyType\": \"hiksdk_net\",\n" +
"\t\t\t\t\"cameraRelateTalk\": \"d8131b366f0a464da807126f135bde07\",\n" +
"\t\t\t\t\"transType\": 1,\n" +
"\t\t\t\t\"createTime\": \"2023-07-20T12:51:57.419+08:00\",\n" +
"\t\t\t\t\"name\": \"食堂室外气瓶室\",\n" +
"\t\t\t\t\"decodeTag\": \"hikvision\",\n" +
"\t\t\t\t\"externalIndexCode\": \"13098301581314000827\",\n" +
"\t\t\t\t\"resourceType\": \"camera\"\n" +
"\t\t\t},\n" +
"\t\t\t{\n" +
"\t\t\t\t\"regionIndexCode\": \"c8cb2047-e430-43a3-8f37-8348e6463055\",\n" +
"\t\t\t\t\"dacIndexCode\": \"--\",\n" +
"\t\t\t\t\"regionPathName\": \"沧州矿石港务有限公司/杂货作业区/综合业务调度楼\",\n" +
"\t\t\t\t\"latitude\": \"\",\n" +
"\t\t\t\t\"regionName\": \"综合业务调度楼\",\n" +
"\t\t\t\t\"indexCode\": \"85cde34633634b28bbef88ea323a6d30\",\n" +
"\t\t\t\t\"channelType\": \"analog\",\n" +
"\t\t\t\t\"recordLocation\": \"0\",\n" +
"\t\t\t\t\"disOrder\": 6724,\n" +
"\t\t\t\t\"capability\": \"@event_face_detect_alarm@event_audio@io@event_gis@event_rule@gis@event_ias@event_vss@record@vss@event_io@net@maintenance@event_device@status@\",\n" +
"\t\t\t\t\"parentIndexCode\": \"f02324c0af874e06a4a09fd2e7b2fdc3\",\n" +
"\t\t\t\t\"longitude\": \"\",\n" +
"\t\t\t\t\"chanNum\": 1,\n" +
"\t\t\t\t\"regionPath\": \"@root000000@8b975d79-ef3f-4543-89a9-8c7bb314bd74@c8cb2047-e430-43a3-8f37-8348e6463055@\",\n" +
"\t\t\t\t\"cascadeType\": 0,\n" +
"\t\t\t\t\"installLocation\": \"\",\n" +
"\t\t\t\t\"updateTime\": \"2023-09-29T11:09:06.992+08:00\",\n" +
"\t\t\t\t\"sort\": 6724,\n" +
"\t\t\t\t\"cameraType\": 0,\n" +
"\t\t\t\t\"treatyType\": \"hiksdk_net\",\n" +
"\t\t\t\t\"cameraRelateTalk\": \"c135a232f8a94848b1398f16758a1029\",\n" +
"\t\t\t\t\"transType\": 1,\n" +
"\t\t\t\t\"createTime\": \"2023-07-20T12:51:54.602+08:00\",\n" +
"\t\t\t\t\"name\": \"食堂备餐区南侧\",\n" +
"\t\t\t\t\"decodeTag\": \"hikvision\",\n" +
"\t\t\t\t\"externalIndexCode\": \"13098301581314000825\",\n" +
"\t\t\t\t\"resourceType\": \"camera\"\n" +
"\t\t\t},\n" +
"\t\t\t{\n" +
"\t\t\t\t\"regionIndexCode\": \"c8cb2047-e430-43a3-8f37-8348e6463055\",\n" +
"\t\t\t\t\"dacIndexCode\": \"--\",\n" +
"\t\t\t\t\"regionPathName\": \"沧州矿石港务有限公司/杂货作业区/综合业务调度楼\",\n" +
"\t\t\t\t\"latitude\": \"\",\n" +
"\t\t\t\t\"regionName\": \"综合业务调度楼\",\n" +
"\t\t\t\t\"indexCode\": \"b313b0c0feca4fbea76b77f6ff510430\",\n" +
"\t\t\t\t\"channelType\": \"analog\",\n" +
"\t\t\t\t\"recordLocation\": \"0\",\n" +
"\t\t\t\t\"disOrder\": 6723,\n" +
"\t\t\t\t\"capability\": \"@event_face_detect_alarm@event_audio@io@event_gis@event_rule@gis@event_ias@event_vss@record@vss@event_io@net@maintenance@event_device@status@\",\n" +
"\t\t\t\t\"parentIndexCode\": \"bfa53c5c696a4c4788e8264490c54626\",\n" +
"\t\t\t\t\"longitude\": \"\",\n" +
"\t\t\t\t\"chanNum\": 1,\n" +
"\t\t\t\t\"regionPath\": \"@root000000@8b975d79-ef3f-4543-89a9-8c7bb314bd74@c8cb2047-e430-43a3-8f37-8348e6463055@\",\n" +
"\t\t\t\t\"cascadeType\": 0,\n" +
"\t\t\t\t\"installLocation\": \"\",\n" +
"\t\t\t\t\"updateTime\": \"2023-09-29T11:09:06.993+08:00\",\n" +
"\t\t\t\t\"sort\": 6723,\n" +
"\t\t\t\t\"cameraType\": 0,\n" +
"\t\t\t\t\"treatyType\": \"hiksdk_net\",\n" +
"\t\t\t\t\"cameraRelateTalk\": \"65996e9f1245416c9a38ff77a225b12b\",\n" +
"\t\t\t\t\"transType\": 1,\n" +
"\t\t\t\t\"createTime\": \"2023-07-20T12:51:56.371+08:00\",\n" +
"\t\t\t\t\"name\": \"食堂备餐区北侧\",\n" +
"\t\t\t\t\"decodeTag\": \"hikvision\",\n" +
"\t\t\t\t\"externalIndexCode\": \"13098301581314000836\",\n" +
"\t\t\t\t\"resourceType\": \"camera\"\n" +
"\t\t\t},\n" +
"\t\t\t{\n" +
"\t\t\t\t\"regionIndexCode\": \"c8cb2047-e430-43a3-8f37-8348e6463055\",\n" +
"\t\t\t\t\"dacIndexCode\": \"--\",\n" +
"\t\t\t\t\"regionPathName\": \"沧州矿石港务有限公司/杂货作业区/综合业务调度楼\",\n" +
"\t\t\t\t\"latitude\": \"\",\n" +
"\t\t\t\t\"regionName\": \"综合业务调度楼\",\n" +
"\t\t\t\t\"indexCode\": \"7678102b59f543d8872c048e089837e3\",\n" +
"\t\t\t\t\"channelType\": \"analog\",\n" +
"\t\t\t\t\"recordLocation\": \"0\",\n" +
"\t\t\t\t\"disOrder\": 6722,\n" +
"\t\t\t\t\"capability\": \"@event_face_detect_alarm@event_audio@io@event_gis@event_rule@gis@event_ias@event_vss@record@vss@event_io@net@maintenance@event_device@status@\",\n" +
"\t\t\t\t\"parentIndexCode\": \"b0435c02f51e4d38af98014162fc1998\",\n" +
"\t\t\t\t\"longitude\": \"\",\n" +
"\t\t\t\t\"chanNum\": 1,\n" +
"\t\t\t\t\"regionPath\": \"@root000000@8b975d79-ef3f-4543-89a9-8c7bb314bd74@c8cb2047-e430-43a3-8f37-8348e6463055@\",\n" +
"\t\t\t\t\"cascadeType\": 0,\n" +
"\t\t\t\t\"installLocation\": \"\",\n" +
"\t\t\t\t\"updateTime\": \"2023-09-29T11:09:06.994+08:00\",\n" +
"\t\t\t\t\"sort\": 6722,\n" +
"\t\t\t\t\"cameraType\": 0,\n" +
"\t\t\t\t\"treatyType\": \"hiksdk_net\",\n" +
"\t\t\t\t\"cameraRelateTalk\": \"5398df57b1df4bd6917e26ae37404a59\",\n" +
"\t\t\t\t\"transType\": 1,\n" +
"\t\t\t\t\"createTime\": \"2023-07-20T12:51:58.736+08:00\",\n" +
"\t\t\t\t\"name\": \"食堂售饭区南侧\",\n" +
"\t\t\t\t\"decodeTag\": \"hikvision\",\n" +
"\t\t\t\t\"externalIndexCode\": \"13098301581314000834\",\n" +
"\t\t\t\t\"resourceType\": \"camera\"\n" +
"\t\t\t},\n" +
"\t\t\t{\n" +
"\t\t\t\t\"regionIndexCode\": \"c8cb2047-e430-43a3-8f37-8348e6463055\",\n" +
"\t\t\t\t\"dacIndexCode\": \"--\",\n" +
"\t\t\t\t\"regionPathName\": \"沧州矿石港务有限公司/杂货作业区/综合业务调度楼\",\n" +
"\t\t\t\t\"latitude\": \"\",\n" +
"\t\t\t\t\"regionName\": \"综合业务调度楼\",\n" +
"\t\t\t\t\"indexCode\": \"60d63ac1107642889d11b568f3d62d80\",\n" +
"\t\t\t\t\"channelType\": \"analog\",\n" +
"\t\t\t\t\"recordLocation\": \"0\",\n" +
"\t\t\t\t\"disOrder\": 6721,\n" +
"\t\t\t\t\"capability\": \"@event_face_detect_alarm@event_audio@io@event_gis@event_rule@gis@event_ias@event_vss@record@vss@event_io@net@maintenance@event_device@status@\",\n" +
"\t\t\t\t\"parentIndexCode\": \"e4683b93615b4adf9b171b1316dc28b2\",\n" +
"\t\t\t\t\"longitude\": \"\",\n" +
"\t\t\t\t\"chanNum\": 1,\n" +
"\t\t\t\t\"regionPath\": \"@root000000@8b975d79-ef3f-4543-89a9-8c7bb314bd74@c8cb2047-e430-43a3-8f37-8348e6463055@\",\n" +
"\t\t\t\t\"cascadeType\": 0,\n" +
"\t\t\t\t\"installLocation\": \"\",\n" +
"\t\t\t\t\"updateTime\": \"2023-09-29T11:09:06.995+08:00\",\n" +
"\t\t\t\t\"sort\": 6721,\n" +
"\t\t\t\t\"cameraType\": 0,\n" +
"\t\t\t\t\"treatyType\": \"hiksdk_net\",\n" +
"\t\t\t\t\"cameraRelateTalk\": \"95355f0b298c4e8a9d32bd2b834e7521\",\n" +
"\t\t\t\t\"transType\": 1,\n" +
"\t\t\t\t\"createTime\": \"2023-07-20T12:51:57.071+08:00\",\n" +
"\t\t\t\t\"name\": \"食堂售饭区北侧\",\n" +
"\t\t\t\t\"decodeTag\": \"hikvision\",\n" +
"\t\t\t\t\"externalIndexCode\": \"13098301581314000831\",\n" +
"\t\t\t\t\"resourceType\": \"camera\"\n" +
"\t\t\t}\n" +
"\t\t]";
HashMap<Object, Object> data = new HashMap<>();
data.put("list", JSON.parseArray(result,PageData.class));
map.put("data", data);
map.put("result", "success"); map.put("result", "success");
return map; return map;
} }

View File

@ -13,9 +13,9 @@ public class CzksPerLocUtil {
// @Value("${perLoc.url}") // @Value("${perLoc.url}")
// 线上地址 // 线上地址
// public static String perLocUrl = "http://172.16.130.86/gateway-service"; public static String perLocUrl = "http://172.16.130.86/gateway-service";
// 线上外网映射 // 线上外网映射
public static String perLocUrl = "http://221.195.199.13:7811/gateway-service"; // public static String perLocUrl = "http://221.195.199.13:7811/gateway-service";
// @Value("${perLoc.userName}") // @Value("${perLoc.userName}")
// private String userName; // private String userName;
// @Value("${perLoc.pwd}") // @Value("${perLoc.pwd}")
@ -26,6 +26,7 @@ public class CzksPerLocUtil {
private static String code = "1"; private static String code = "1";
// token // token
private static String perLocToken = ""; private static String perLocToken = "";
public static String CameraHlsUrl = "http://221.195.199.13:7811";
public static String getToken(){ public static String getToken(){

View File

@ -6,10 +6,7 @@ import org.springframework.lang.Nullable;
import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletRequest;
import java.io.*; import java.io.*;
import java.net.HttpURLConnection; import java.net.*;
import java.net.MalformedURLException;
import java.net.URL;
import java.net.URLConnection;
import java.util.HashMap; import java.util.HashMap;
/** /**
@ -206,6 +203,7 @@ public class HttpRequestUtil {
InputStream is = null; InputStream is = null;
BufferedReader br = null; BufferedReader br = null;
try { try {
CookieHandler.setDefault(new CookieManager(null, CookiePolicy.ACCEPT_ALL));
//创建连接对象 //创建连接对象
URL url = new URL(httpUrl); URL url = new URL(httpUrl);
//创建连接 //创建连接
@ -395,6 +393,96 @@ public class HttpRequestUtil {
//设置通用的请求属性 //设置通用的请求属性
// connection.setRequestProperty("accept", "*/*"); // connection.setRequestProperty("accept", "*/*");
// connection.setRequestProperty("connection", "Keep-Alive"); // connection.setRequestProperty("connection", "Keep-Alive");
// connection.setRequestProperty("user-agent", "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1)");
connection.setRequestProperty("Content-Type", "application/json;charset=utf-8");
// 必须添加token
connection.setRequestProperty("Authorization", CzksPerLocUtil.getToken());
//拼装参数
if (null != param && !param.equals("")) {
//设置参数
os = connection.getOutputStream();
//拼装参数
os.write(param.getBytes());
}
//设置权限
//设置请求头等
//开启连接
//connection.connect();
//读取响应
if (connection.getResponseCode() == 200) {
is = connection.getInputStream();
if (null != is) {
br = new BufferedReader(new InputStreamReader(is, "UTF-8"));
String temp = null;
while (null != (temp = br.readLine())) {
result.append(temp);
result.append("\r\n");
}
}
}
} catch (MalformedURLException e) {
e.printStackTrace();
} catch (IOException e) {
e.printStackTrace();
} finally {
//关闭连接
if (br != null) {
try {
br.close();
} catch (IOException e) {
e.printStackTrace();
}
}
if (os != null) {
try {
os.close();
} catch (IOException e) {
e.printStackTrace();
}
}
if (is != null) {
try {
is.close();
} catch (IOException e) {
e.printStackTrace();
}
}
//关闭连接
connection.disconnect();
}
ReturnMap returnMap = new ReturnMap();
if (Tools.notEmpty(result.toString())) {
HashMap o = JSON.parseObject(result.toString(), HashMap.class);
returnMap.putAll(o);
}
return returnMap;
}
public static ReturnMap getCameraHlsPathApi(String httpUrl, String param) {
StringBuffer result = new StringBuffer();
//连接
HttpURLConnection connection = null;
OutputStream os = null;
InputStream is = null;
BufferedReader br = null;
try {
//创建连接对象
URL url = new URL(CzksPerLocUtil.CameraHlsUrl + httpUrl);
//创建连接
connection = (HttpURLConnection) url.openConnection();
//设置请求方法
connection.setRequestMethod("POST");
//设置连接超时时间
connection.setConnectTimeout(15000);
//设置读取超时时间
connection.setReadTimeout(15000);
//DoOutput设置是否向httpUrlConnection输出DoInput设置是否从httpUrlConnection读入此外发送post请求必须设置这两个
//设置是否可读取
connection.setDoOutput(true);
connection.setDoInput(true);
//设置通用的请求属性
// connection.setRequestProperty("accept", "*/*");
// connection.setRequestProperty("connection", "Keep-Alive");
// connection.setRequestProperty("user-agent", "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1)"); // connection.setRequestProperty("user-agent", "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1)");
connection.setRequestProperty("Content-Type", "application/json;charset=utf-8"); connection.setRequestProperty("Content-Type", "application/json;charset=utf-8");
// 必须添加token // 必须添加token

View File

@ -1,6 +1,7 @@
package com.zcloud.util; package com.zcloud.util;
import com.zcloud.util.examUntil.CodeMessageEnum;
import org.apache.http.HttpStatus; import org.apache.http.HttpStatus;
import java.util.HashMap; import java.util.HashMap;
import java.util.Map; import java.util.Map;
@ -42,7 +43,9 @@ public class ReturnMap extends HashMap<String, Object> {
return error(HttpStatus.SC_INTERNAL_SERVER_ERROR, msg); return error(HttpStatus.SC_INTERNAL_SERVER_ERROR, msg);
} }
public static ReturnMap error(CodeMessageEnum codeMessageEnum, String url) {
return error(codeMessageEnum.getCode(),codeMessageEnum.getMessage(), url);
}
/** /**
* Rcodemsg * Rcodemsg
* *

View File

@ -0,0 +1,18 @@
package com.zcloud.util.examUntil;
/**
* TODO
* wangxuan
* www.zcloudchina.com
*/
/**
* @desc
*/
public interface BaseResultInterface {
String getCode();
String getMessage();
}

View File

@ -0,0 +1,84 @@
package com.zcloud.util.examUntil;
/**
* TODO
* wangxuan
* www.zcloudchina.com
*/
public class BizException extends RuntimeException implements BaseResultInterface {
private static final long serialVersionUID = 1L;
/**
*
*/
private String code;
/**
*
*/
private String message;
public BizException() {
super();
}
public BizException(CodeMessageEnum codeMessageEnum) {
super(codeMessageEnum.getCode(),new Throwable());
this.code = codeMessageEnum.getCode();
this.message = codeMessageEnum.getMessage();
}
public BizException(CodeMessageEnum codeMessageEnum, Throwable cause) {
super(codeMessageEnum.getCode(), cause);
this.code = codeMessageEnum.getCode();
this.message = codeMessageEnum.getMessage();
}
public BizException (CodeMessageEnum codeMessageEnum, Throwable cause,String details) {
super(codeMessageEnum.getCode(), cause);
this.code = codeMessageEnum.getCode();
this.message = codeMessageEnum.getMessage() + details;
}
public BizException(CodeMessageEnum codeMessageEnum, String message, Throwable cause) {
super(codeMessageEnum.getCode(), cause);
this.code = codeMessageEnum.getCode();
this.message = message;
}
public BizException(String message) {
super(message);
this.message = message;
}
public BizException(String code, String message) {
super(code);
this.code = code;
this.message = message;
}
public BizException(String code, String message, Throwable cause) {
super(code, cause);
this.code = code;
this.message = message;
}
@Override
public Throwable fillInStackTrace() {
return this;
}
@Override
public String getCode() {
return this.code;
}
@Override
public String getMessage() {
return this.message;
}
}

View File

@ -0,0 +1,197 @@
package com.zcloud.util.examUntil;
/**
* TODO
* wangxuan
* www.zcloudchina.com
*/
public enum CodeMessageEnum implements BaseResultInterface {
/** ********* 0000成功 *************** */
SUCCESS("0000", "成功!"),
SUCCESS_LOGIN("0001", "用户登录成功"),
SUCCESS_LOGOUT("0002", "用户退出成功"),
/* 默认失败 */
COMMON_FAIL("999", "失败"),
/** ********* 1xxx系统错误 *************** */
SERVER_BUSY("1001", "服务器正忙,请稍后再试!"),
INTERNAL_SERVER_ERROR("1002", "服务器内部错误"),
NOT_FOUND("1003", "未找到该资源!"),
REQUEST_METHOD_ERROR("1004", "接口请求方法异常"),
SQL_SYNTAX_ERROR_EXCEPTION("1005", "SQL语法错误异常"),
NULL_POINT_ERROR_EXCEPTION("1006", "空指针异常信息"),
INNER_FRAME_EXCEPTION("1007", "内部框架执行异常"),
PARSE_TOKEN_EXCEPTION("1008", "解析token异常"),
TOKEN_NOT_EXIST("1009", "token不存在"),
TOKEN_SIGNATURE_EXCEPTION("1010", "token签名异常"),
TOKEN_EXPIRE("1011", "token过期请重新登录"),
IMG_TYPE_NOT_CONFIG("1012", "请配置图片类型"),
NOT_CONFIG_FILE_DIR("1013", "请配置文件路径"),
UPLOAD_FILE_ERROR("1014", "文件上传失败"),
FILE_NOT_EXIST("1015", "文件不存在"),
FILE_HAS_DELETED("1016", "文件已被删除"),
DRIVER_CLASS_NOT_FOUND("1017", "数据库的连接驱动正在加载中..."),
TRY_CONNECT_DATABASE_ERROR("1018", "尝试连接数据库失败"),
CLOSE_CONNECT_DATABASE_ERROR("1019", "关闭数据库连接失败"),
DATABASE_NAME_NOT_EXIST("1020", "数据库名称不存在"),
CLOSE_DATASOURCE_ERROR("1021", "释放数据库资源异常"),
DRUID_DATASOURCE_ERROR("1022", "数据源创建中..."),
CREATE_DATABASE_ERROR("1023", "创建数据库失败"),
CREATE_TABLE_ERROR("1024", "创建表失败"),
UPDATE_TABLE_FIELD_ERROR("1025", "更新表字段失败"),
DELETE_TABLE_FIELD_ERROR("1026", "删除表字段失败"),
QUERY_ROLE_ERROR("1027", "查询角色失败"),
UPDATE_GROUP_ERROR("1028", "更新接口组失败"),
DELETE_GROUP_ERROR("1029", "删除接口组失败"),
SAVE_INTERFACE_ERROR("1030", "保存接口信息失败"),
/**
* ******2xxx *********************
*/
BODY_NOT_MATCH("2001", "请求的数据格式不符"),
SIGNATURE_NOT_MATCH("2002", "请求的数字签名不匹配!"),
REQUEST_PATH_NOT_MATCH("2003", "当前请求路径没有权限!"),
NOT_UPLOAD_FILE_NAME_ERROR("2004", "上传的文件名不存在,请重新上传"),
NOT_SUPPORT_IMG_TYPE("2005", "图片格式不正确,请重新上传"),
NOT_SUPPORT_USERNAME_TYPE("2006", "excel用户名不能为空"),
NOT_SUPPORT_ROLE_TYPE("2007", "角色不存在"),
NOT_SUPPORT_DEPT_TYPE("2008", "部门不存在"),
SQL_INJECT_NOT_ALLOWED("2009", "参数中存在数据库关键字,请修改"),
TABLE_FIELD_NOT_EXIST("2010", "表字段不存在"),
FILE_PICTURE_IS_NULL("2011", "附件不存在"),
FILE_PICTURE_DELETE("2012", "删除附件失败"),
DIC_BIANMA_REPEAT("2013", "字典编码重复"),
/** *********** 3xxx用户错误 ******************* */
USER_NOT_LOGIN("3001", "用户未登录"),
USER_ACCOUNT_EXPIRED("3002", "账号已过期"),
USER_CREDENTIALS_ERROR("3003", "用户名或密码错误"),
USER_CREDENTIALS_EXPIRED("3004", "密码过期"),
USER_ACCOUNT_NOT_BIND_ENTERPRISE("3005", "当前账号未绑定企业"),
USER_ACCOUNT_LOCKED("3006", "账号被锁定"),
USER_ACCOUNT_NOT_EXIST("3007", "账号不存在"),
USER_ACCOUNT_ALREADY_EXIST("3008", "账号已存在"),
USER_ACCOUNT_USE_BY_OTHERS("3009", "账号下线"),
USER_NO_PERMISSION("3010", "当前账号没有此权限"),
USERNAME_NOT_BLANK("3011", "用户不能为空"),
USER_LOGIN_ERROR("3012", "用户登录失败"),
USER_LOGOUT_ERROR("3013", "用户退出失败"),
USER_ACCOUNT_USE_BY_OTHERS_ERROR("3014", "账号下线异常"),
USER_ACCESS_DENIED("3015", "权限认证失败"),
USERNAME_EXIST_ERROR("3016", "用户名重名"),
ROLE_NAME_ALREADY_EXIST("3101", "角色已存在"),
/** ********** 4xxx业务错误 *********************** */
ENTERPRISE_NOT_EXIST("4001", "当前企业不存在"),
APP_KEY_EXIST("4002", "应用key已存在"),
APP_NOT_EXIST("4003", "应用不存在"),
APP_PAGE_NAME_EXIST("4004", "当前页面名称已存在"),
APP_PAGE_KEY_EXIST("4005", "当前页面key已存在"),
APP_PAGE_NOT_EXIST("4006", "当前页面不存在,或已删除"),
APP_PAGE_TYPE_ERROR("4007", "页面类型有误"),
APP_PAGE_HOME_IS_NOT_EXIST("4008", "请设置首页"),
CAN_NOT_DELETE_HOME_PAGE("4009", "请勿删除首页"),
DELETE_PAGE_ERROR("4010", "删除页面失败"),
CONFIG_CUSTOM_ERROR("4011", "配置自定义页面失败"),
APP_PAGE_PARENT_NOT_EXIST("4012", "当前页面的父级页面不存在,或已删除"),
DATASOURCE_NAME_EXIST("4013", "当前数据源名称已经存在,请修改后重试"),
DATASOURCE_NOT_EXIST("4014", "当前数据源不存在"),
DATASOURCE_HAS_DELETED("4015", "当前数据源已删除"),
MODEL_NOT_EXIST("4016", "当前模型不存在"),
MODEL_HAS_DELETED("4017", "当前模型已删除"),
MODEL_NAME_HAS_EXIST("4018", "当前模型名称已存在"),
DATASOURCE_NOT_CONFIG("4019", "数据源配置为空,请联系管理员"),
DATASOURCE_NOT_CONFIG_DIALECT("4020", "未配置数据源的类型"),
DATASOURCE_NOT_CONFIG_DRIVER_CLASS_NAME("4021", "未配置数据源的驱动"),
DEPT_USER_EXIST("4022", "部门下存在用户"),
NOT_CONFIG_PAGE_BUTTON_TYPE("4023", "未配置按钮雷星"),
MODEL_PAGE_RELATION_MODEL("4024", "已关联当前模型页面"),
MODEL_PAGE_NOT_EXIST("4025", "模型页面不存在或已被删除"),
MODEL_HAS_RELATION_MODEL_PAGE("4026", "当前模型已关联模型页面,不允许删除"),
FORM_NOT_EXIST("4027", "模型表单不存在"),
READ_FILE_ERROR("4028", "读取模型页面的模板文件失败"),
MODEL_PAGE_CONTENT_NULL("4029", "未配置模型页面的模板文件"),
NOT_CONFIG_QUERY_SQL("4030", "未配置查询语句"),
APP_PAGE_BUTTON_OPTION_VALUE_ERROR("4031", "未配置接口"),
DELETE_COLUMN_ERROR("4032", "删除当前失败"),
INSERT_DATA_ERROR("4033", "新建数据失败"),
EDIT_DATA_ERROR("4034", "编辑数据失败"),
DATASOURCE_HAS_MODELS("4035", "当前数据源存在模型,不允许删除"),
NOT_CONFIG_FORM_API("4036", "未配置模型表单页的接口信息"),
PLEASE_WRITE_AT_LEAST_DATA("4037", "请至少填写一行数据"),
AMIS_PAGE_ERROR("4038", "分页参数异常"),
QUERY_APP_PAGE_QUERY_FIELD_ERROR("4039", "查询搜素参数异常"),
REQUEST_PARAM_NOT_IN_APP_PAGE_QUERY_FIELD("4040", "请求参数不在查询数据表中"),
STYLE_LANGUAGE_ON_CSS("4041", "自定义css中的样式语言不能为空"),
APP_CONFIG_TYPE_NOT_EXIST("4042", "不支持当前应用设置的类型"),
APP_CONFIG_NOT_EXIST_OR_DELETED("4043", "当前设置不存在或已被删除"),
APP_HAS_CONFIG_ON_THIS_TYPE("4044", "当前应用设置的类型已存在,请更新"),
NOT_SUPPORT_COMPONENT_FRAME("4045", "不支持当前组件框架"),
NOT_SUPPORT_COMPONENT_TYPE("4046", "不支持当前组件类型"),
CURRENT_APP_KEY_EXIST("4047", "当前应用的组件key已存在"),
CREATE_CUSTOM_COMPONENT_ERROR("4048", "新增自定义组件失败"),
APP_CUSTOM_COMPONENT_NOT_EXIST("4049", "当前组件不存在或已被删除"),
UPDATE_CUSTOM_COMPONENT_ERROR("4050", "更新自定义组件失败"),
DELETED_CUSTOM_COMPONENT_ERROR("4051", "删除自定义组件失败"),
INSERT_COMPONENT_DEPENDENCE_ERROR("4052", "新增自定义组件依赖项失败"),
DELETE_COMPONENT_DEPENDENCE_ERROR("4053", "删除自定义组件依赖项失败"),
CURRENT_COMPONENT_DEPENDENCE_NOT_EXIST("4054", "当前自定义组件依赖项不存在或已被删除"),
CURRENT_APP_NAME_EXIST("4055", "当前应用的组件名称已存在"),
NOT_SUPPORT_DATASOURCE_FROM("4056", "不支持当前的数据库来源"),
JDBC_CONFIG_ERROR("4057", "平台内置的数据源配置有误"),
NOT_SUPPORT_MODEL_TYPE("4058", "不支持当前的页面模板"),
NOT_SUPPORT_CUSTOM_PAGE("4059", "暂不支持自定义页面"),
FORM_PAGE_ON_DEVELOPING("4060", "自定义页面的该功能正在开发中..."),
APP_PAGE_QUERY_FIELD_NOT_EXIST("4061", "当前查询条件不存在,或已被删除"),
APP_PAGE_BUTTON_NOT_EXIST("4062", "当前页面按钮不存在,或已被删除"),
TABLE_KEY_MORE_THEN_ONE("4063", "主键超过一个"),
TABLE_KEY_LESS_THEN_ONE("4064", "主键必须存在"),
TABLE_KEY_MUST_BE_INT("4065", "主键必须为整数类型"),
TABLE_FIELD_MUST_EXIST("4066", "必须存在表字段"),
CURRENT_MODEL_PAGE_HAS_CONVERSION_CUSTOM_PAGE("4067", "当前模型页面已转成自定义页面"),
NOT_SUPPORT_RELEASE_STATUS("4068", "发布版本状态有误"),
APP_FORM_BUTTON_NOT_EXIST("4067", "当前表单按钮不存在,或已被删除"),
DATASOURCE_KEY_EXIST_ERROR("4068","数据源key已存在")
;
CodeMessageEnum(String code, String message) {
this.code = code;
this.message = message;
}
/** 返回到前端的code值 */
private String code;
/** 返回到前端的code对应的message值 */
private String message;
@Override
public String getCode() {
return this.code;
}
@Override
public String getMessage() {
return this.message;
}
// public static CodeVo getJsonObjectByCode(String code) {
// CodeVo codeVo = new CodeVo();
// if (Tools.isEmpty(code)) {
// return codeVo;
// }
// for (CodeMessageEnum enumObj : CodeMessageEnum.values()) {
// if (enumObj.getCode().equals(code)) {
// return new CodeVo(code, enumObj.message);
// }
// }
// return codeVo;
// }
}

View File

@ -0,0 +1,14 @@
package com.zcloud.util.examUntil;
import java.lang.annotation.*;
/**
* @Description:
* @Author: dearLin
* @Date: 2023/3/8
*/
@Target(ElementType.TYPE)
@Retention(RetentionPolicy.RUNTIME)
@Documented
public @interface ErrorOperation {
}

View File

@ -0,0 +1,94 @@
package com.zcloud.util.examUntil;
/**
* TODO
* wangxuan
* www.zcloudchina.com
*/
import com.zcloud.util.ReturnMap;
import org.mybatis.spring.MyBatisSystemException;
import org.springframework.web.HttpRequestMethodNotSupportedException;
import org.springframework.web.bind.annotation.ExceptionHandler;
import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.web.bind.annotation.RestControllerAdvice;
import javax.servlet.http.HttpServletRequest;
import static com.zcloud.util.examUntil.CodeMessageEnum.SERVER_BUSY;
/**
*
*/
@RestControllerAdvice(annotations = {ErrorOperation.class})
//@Slf4j
public class GlobalExceptionHandler {
/**
*
*
*/
@ExceptionHandler(value = BizException.class)
@ResponseBody
public ReturnMap bizExceptionHandler(HttpServletRequest req, BizException e) {
e.printStackTrace();
// log.error("发生业务异常: {}, 请求接口: {}", e.getMessage(), req.getRequestURI());
return ReturnMap.error("2001" ,e.getMessage(), req.getRequestURI());
}
/**
*
*
* @param e
* @param req
*/
@ExceptionHandler(value = NullPointerException.class)
@ResponseBody
public ReturnMap exceptionHandler(HttpServletRequest req, NullPointerException e) {
e.printStackTrace();
// log.error("空指针异常信息: {}, 请求接口: {}", e, req.getRequestURI());
return ReturnMap.error(SERVER_BUSY, req.getRequestURI());
}
/**
*
*
*/
@ExceptionHandler(value = HttpRequestMethodNotSupportedException.class)
@ResponseBody
public ReturnMap methodNotSupportedExceptionHandler(HttpServletRequest req, Exception e) {
e.printStackTrace();
// log.error("请求方法异常信息: {},请求接口: {}", e, req.getRequestURI());
return ReturnMap.error(SERVER_BUSY, req.getRequestURI());
}
/**
* SQL
*/
@ExceptionHandler(value = MyBatisSystemException.class)
@ResponseBody
public ReturnMap sqlSyntaxErrorExceptionHandler(HttpServletRequest req, Exception e) {
e.printStackTrace();
// log.error("MyBatis系统异常信息: {},请求接口: {}", e, req.getRequestURI());
return ReturnMap.error(SERVER_BUSY, req.getRequestURI());
}
/**
*
*
* @param req
* @param e
*/
@ExceptionHandler(value = Exception.class)
@ResponseBody
public ReturnMap exceptionHandler(HttpServletRequest req, Exception e) {
e.printStackTrace();
// log.error("未知异常: {}, 请求接口: {}", e, req.getRequestURI());
return ReturnMap.error(SERVER_BUSY, req.getRequestURI());
}
}

View File

@ -0,0 +1,54 @@
package com.zcloud.util.examUntil;
import org.apache.commons.lang.StringUtils;
import org.springframework.http.HttpHeaders;
import org.springframework.web.context.request.RequestAttributes;
import org.springframework.web.context.request.RequestContextHolder;
import org.springframework.web.context.request.ServletRequestAttributes;
import javax.servlet.http.HttpServletRequest;
import java.util.Enumeration;
import java.util.HashMap;
import java.util.Map;
/**
*
* wangxuan
* www.zcloudchina.com
*/
public class HttpContextUtils {
public static HttpServletRequest getHttpServletRequest() {
RequestAttributes requestAttributes = RequestContextHolder.getRequestAttributes();
if(requestAttributes == null){
return null;
}
return ((ServletRequestAttributes) requestAttributes).getRequest();
}
public static Map<String, String> getParameterMap(HttpServletRequest request) {
Enumeration<String> parameters = request.getParameterNames();
Map<String, String> params = new HashMap<>();
while (parameters.hasMoreElements()) {
String parameter = parameters.nextElement();
String value = request.getParameter(parameter);
if (StringUtils.isNotBlank(value)) {
params.put(parameter, value);
}
}
return params;
}
public static String getDomain(){
HttpServletRequest request = getHttpServletRequest();
StringBuffer url = request.getRequestURL();
return url.delete(url.length() - request.getRequestURI().length(), url.length()).toString();
}
public static String getOrigin(){
HttpServletRequest request = getHttpServletRequest();
return request.getHeader(HttpHeaders.ORIGIN);
}
}

View File

@ -14,8 +14,9 @@ import java.util.Map;
*/ */
public class HKUtil { public class HKUtil {
static { static {
// 代理API网关nginx服务器ip端口 // 代理API网关nginx服务器ip端口 线上
ArtemisConfig.host = "172.17.100.1:443"; ArtemisConfig.host = "172.17.100.1:443";
// ArtemisConfig.host = "221.195.199.13:7811";
// 秘钥appkey // 秘钥appkey
ArtemisConfig.appKey = "29806794"; ArtemisConfig.appKey = "29806794";
// 秘钥appSecret // 秘钥appSecret