Merge branch 'wvp-28181-2.0' into wvp-pro-record

# Conflicts:
#	src/main/java/com/genersoft/iot/vmp/gb28181/transmit/cmd/impl/SIPCommanderFroPlatform.java
This commit is contained in:
648540858
2022-03-02 12:52:37 +08:00
12 changed files with 117 additions and 76 deletions

View File

@@ -216,26 +216,21 @@ public class PlatformController {
if (updateResult) {
// 保存时启用就发送注册
if (parentPlatform.isEnable()) {
// 保存时启用就发送注册
if (parentPlatform.isEnable()) {
if (parentPlatformOld.isStatus()) {
commanderForPlatform.unregister(parentPlatformOld, null, null);
try {
Thread.sleep(500);
} catch (InterruptedException e) {
e.printStackTrace();
}
// 只要保存就发送注册
commanderForPlatform.register(parentPlatform, null, null);
}else {
// 只要保存就发送注册
commanderForPlatform.register(parentPlatform, null, null);
}
} else if (parentPlatformOld != null && parentPlatformOld.isEnable() && !parentPlatform.isEnable()){ // 关闭启用时注销
if (parentPlatformOld.isStatus()) {
commanderForPlatform.unregister(parentPlatformOld, null, null);
try {
Thread.sleep(500);
} catch (InterruptedException e) {
e.printStackTrace();
}
// 只要保存就发送注册
commanderForPlatform.register(parentPlatform, null, null);
}else {
// 只要保存就发送注册
commanderForPlatform.register(parentPlatform, null, null);
}
} else if (parentPlatformOld != null && parentPlatformOld.isEnable() && !parentPlatform.isEnable()){ // 关闭启用时注销
commanderForPlatform.unregister(parentPlatform, null, null);
commanderForPlatform.unregister(parentPlatformOld, null, null);
}
wvpResult.setCode(0);
wvpResult.setMsg("success");