From f635f9c3003ae10f7be8e934b81bc480c82617ba Mon Sep 17 00:00:00 2001
From: xiaoxie <hotcoffie@163.com>
Date: 星期三, 20 四月 2022 13:56:30 +0800
Subject: [PATCH] 修复录像列表:实测部分厂家(TP-Link IPC43AW)录像列表接口,返回的xml报文数据中有多余的空格,导致解析String为Integer失败,增加trim修复这个问题

---
 src/main/java/com/genersoft/iot/vmp/storager/impl/VideoManagerStorageImpl.java |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/main/java/com/genersoft/iot/vmp/storager/impl/VideoManagerStorageImpl.java b/src/main/java/com/genersoft/iot/vmp/storager/impl/VideoManagerStorageImpl.java
index 6d680bc..fbb6e38 100644
--- a/src/main/java/com/genersoft/iot/vmp/storager/impl/VideoManagerStorageImpl.java
+++ b/src/main/java/com/genersoft/iot/vmp/storager/impl/VideoManagerStorageImpl.java
@@ -524,7 +524,7 @@
 			parentPlatform.setCatalogGroup(1);
 		}
 		if (parentPlatform.getAdministrativeDivision() == null) {
-			parentPlatform.setAdministrativeDivision(parentPlatform.getDeviceGBId().substring(0,6));
+			parentPlatform.setAdministrativeDivision(parentPlatform.getAdministrativeDivision());
 		}
 		ParentPlatformCatch parentPlatformCatch = redisCatchStorage.queryPlatformCatchInfo(parentPlatform.getServerGBId()); // .getDeviceGBId());
 		if (parentPlatform.getId() == null ) {
@@ -1081,7 +1081,7 @@
 		deviceChannel.setParentId(catalog.getParentId());
 		deviceChannel.setRegisterWay(1);
 		// 琛屾斂鍖哄垝搴旇鏄疍omain鐨勫墠鍏綅
-		deviceChannel.setCivilCode(parentPlatByServerGBId.getDeviceGBId().substring(0,6));
+		deviceChannel.setCivilCode(parentPlatByServerGBId.getAdministrativeDivision());
 		deviceChannel.setModel("live");
 		deviceChannel.setOwner("wvp-pro");
 		deviceChannel.setSecrecy("0");

--
Gitblit v1.8.0