Commit 9e28923b8c1c333df8ce3caf741b0e16da2ed48a
Committed by
GitHub
Merge branch 'wvp-28181-2.0' into wvp-28181-2.0
Showing
35 changed files
with
4111 additions
and
632 deletions
sql/2.6.8升级2.6.9.sql
| @@ -38,7 +38,7 @@ alter table device | @@ -38,7 +38,7 @@ alter table device | ||
| 38 | change geoCoordSys geo_coord_sys varchar(50) not null; | 38 | change geoCoordSys geo_coord_sys varchar(50) not null; |
| 39 | 39 | ||
| 40 | alter table device | 40 | alter table device |
| 41 | - change treeType tree_type varchar(50) not null; | 41 | + drop column treeType; |
| 42 | 42 | ||
| 43 | alter table device | 43 | alter table device |
| 44 | change mediaServerId media_server_id varchar(50) default 'auto' null; | 44 | change mediaServerId media_server_id varchar(50) default 'auto' null; |
| @@ -297,7 +297,7 @@ alter table parent_platform | @@ -297,7 +297,7 @@ alter table parent_platform | ||
| 297 | change updateTime update_time varchar(50) null; | 297 | change updateTime update_time varchar(50) null; |
| 298 | 298 | ||
| 299 | alter table parent_platform | 299 | alter table parent_platform |
| 300 | - change treeType tree_type varchar(50) not null; | 300 | + drop column treeType; |
| 301 | 301 | ||
| 302 | alter table parent_platform | 302 | alter table parent_platform |
| 303 | change asMessageChannel as_message_channel bool default false; | 303 | change asMessageChannel as_message_channel bool default false; |
sql/初始化.sql
| @@ -24,7 +24,6 @@ create table wvp_device ( | @@ -24,7 +24,6 @@ create table wvp_device ( | ||
| 24 | charset character varying(50), | 24 | charset character varying(50), |
| 25 | ssrc_check bool default false, | 25 | ssrc_check bool default false, |
| 26 | geo_coord_sys character varying(50), | 26 | geo_coord_sys character varying(50), |
| 27 | - tree_type character varying(50), | ||
| 28 | media_server_id character varying(50), | 27 | media_server_id character varying(50), |
| 29 | custom_name character varying(255), | 28 | custom_name character varying(255), |
| 30 | sdp_ip character varying(50), | 29 | sdp_ip character varying(50), |
| @@ -187,7 +186,6 @@ create table wvp_platform ( | @@ -187,7 +186,6 @@ create table wvp_platform ( | ||
| 187 | catalog_group integer, | 186 | catalog_group integer, |
| 188 | create_time character varying(50), | 187 | create_time character varying(50), |
| 189 | update_time character varying(50), | 188 | update_time character varying(50), |
| 190 | - tree_type character varying(50), | ||
| 191 | as_message_channel bool default false, | 189 | as_message_channel bool default false, |
| 192 | constraint uk_platform_unique_server_gb_id unique (server_gb_id) | 190 | constraint uk_platform_unique_server_gb_id unique (server_gb_id) |
| 193 | ); | 191 | ); |
src/main/java/com/genersoft/iot/vmp/common/CivilCodePo.java
0 → 100644
| 1 | +package com.genersoft.iot.vmp.common; | ||
| 2 | + | ||
| 3 | +public class CivilCodePo { | ||
| 4 | + | ||
| 5 | + private String code; | ||
| 6 | + | ||
| 7 | + private String name; | ||
| 8 | + | ||
| 9 | + private String parentCode; | ||
| 10 | + | ||
| 11 | + public static CivilCodePo getInstance(String[] infoArray) { | ||
| 12 | + CivilCodePo civilCodePo = new CivilCodePo(); | ||
| 13 | + civilCodePo.setCode(infoArray[0]); | ||
| 14 | + civilCodePo.setName(infoArray[1]); | ||
| 15 | + civilCodePo.setParentCode(infoArray[2]); | ||
| 16 | + return civilCodePo; | ||
| 17 | + } | ||
| 18 | + | ||
| 19 | + public String getCode() { | ||
| 20 | + return code; | ||
| 21 | + } | ||
| 22 | + | ||
| 23 | + public void setCode(String code) { | ||
| 24 | + this.code = code; | ||
| 25 | + } | ||
| 26 | + | ||
| 27 | + public String getName() { | ||
| 28 | + return name; | ||
| 29 | + } | ||
| 30 | + | ||
| 31 | + public void setName(String name) { | ||
| 32 | + this.name = name; | ||
| 33 | + } | ||
| 34 | + | ||
| 35 | + public String getParentCode() { | ||
| 36 | + return parentCode; | ||
| 37 | + } | ||
| 38 | + | ||
| 39 | + public void setParentCode(String parentCode) { | ||
| 40 | + this.parentCode = parentCode; | ||
| 41 | + } | ||
| 42 | +} |
src/main/java/com/genersoft/iot/vmp/conf/CivilCodeFileConf.java
0 → 100644
| 1 | +package com.genersoft.iot.vmp.conf; | ||
| 2 | + | ||
| 3 | +import com.genersoft.iot.vmp.common.CivilCodePo; | ||
| 4 | +import org.ehcache.impl.internal.concurrent.ConcurrentHashMap; | ||
| 5 | +import org.slf4j.Logger; | ||
| 6 | +import org.slf4j.LoggerFactory; | ||
| 7 | +import org.springframework.beans.factory.annotation.Autowired; | ||
| 8 | +import org.springframework.boot.CommandLineRunner; | ||
| 9 | +import org.springframework.context.annotation.Configuration; | ||
| 10 | +import org.springframework.context.annotation.Lazy; | ||
| 11 | +import org.springframework.core.annotation.Order; | ||
| 12 | +import org.springframework.core.io.ClassPathResource; | ||
| 13 | +import org.springframework.util.ObjectUtils; | ||
| 14 | + | ||
| 15 | +import java.io.*; | ||
| 16 | +import java.nio.file.Files; | ||
| 17 | +import java.util.Map; | ||
| 18 | + | ||
| 19 | +/** | ||
| 20 | + * 启动时读取行政区划表 | ||
| 21 | + */ | ||
| 22 | +@Configuration | ||
| 23 | +@Order(value=14) | ||
| 24 | +public class CivilCodeFileConf implements CommandLineRunner { | ||
| 25 | + | ||
| 26 | + private final static Logger logger = LoggerFactory.getLogger(CivilCodeFileConf.class); | ||
| 27 | + | ||
| 28 | + private final Map<String, CivilCodePo> civilCodeMap= new ConcurrentHashMap<>(); | ||
| 29 | + | ||
| 30 | + @Autowired | ||
| 31 | + @Lazy | ||
| 32 | + private UserSetting userSetting; | ||
| 33 | + | ||
| 34 | + @Override | ||
| 35 | + public void run(String... args) throws Exception { | ||
| 36 | + if (ObjectUtils.isEmpty(userSetting.getCivilCodeFile())) { | ||
| 37 | + logger.warn("[行政区划] 文件未设置,可能造成目录刷新结果不完整"); | ||
| 38 | + return; | ||
| 39 | + } | ||
| 40 | + InputStream inputStream; | ||
| 41 | + if (userSetting.getCivilCodeFile().startsWith("classpath:")){ | ||
| 42 | + String filePath = userSetting.getCivilCodeFile().substring("classpath:".length()); | ||
| 43 | + ClassPathResource civilCodeFile = new ClassPathResource(filePath); | ||
| 44 | + if (!civilCodeFile.exists()) { | ||
| 45 | + logger.warn("[行政区划] 文件<{}>不存在,可能造成目录刷新结果不完整", userSetting.getCivilCodeFile()); | ||
| 46 | + return; | ||
| 47 | + } | ||
| 48 | + inputStream = civilCodeFile.getInputStream(); | ||
| 49 | + | ||
| 50 | + }else { | ||
| 51 | + File civilCodeFile = new File(userSetting.getCivilCodeFile()); | ||
| 52 | + if (!civilCodeFile.exists()) { | ||
| 53 | + logger.warn("[行政区划] 文件<{}>不存在,可能造成目录刷新结果不完整", userSetting.getCivilCodeFile()); | ||
| 54 | + return; | ||
| 55 | + } | ||
| 56 | + inputStream = Files.newInputStream(civilCodeFile.toPath()); | ||
| 57 | + } | ||
| 58 | + | ||
| 59 | + BufferedReader inputStreamReader = new BufferedReader(new InputStreamReader(inputStream)); | ||
| 60 | + int index = -1; | ||
| 61 | + String line; | ||
| 62 | + while ((line = inputStreamReader.readLine()) != null) { | ||
| 63 | + index ++; | ||
| 64 | + if (index == 0) { | ||
| 65 | + continue; | ||
| 66 | + } | ||
| 67 | + String[] infoArray = line.split(","); | ||
| 68 | + CivilCodePo civilCodePo = CivilCodePo.getInstance(infoArray); | ||
| 69 | + civilCodeMap.put(civilCodePo.getCode(), civilCodePo); | ||
| 70 | + } | ||
| 71 | + inputStreamReader.close(); | ||
| 72 | + inputStream.close(); | ||
| 73 | + if (civilCodeMap.size() == 0) { | ||
| 74 | + logger.warn("[行政区划] 文件内容为空,可能造成目录刷新结果不完整"); | ||
| 75 | + }else { | ||
| 76 | + logger.info("[行政区划] 加载成功,共加载数据{}条", civilCodeMap.size()); | ||
| 77 | + } | ||
| 78 | + } | ||
| 79 | + | ||
| 80 | + public CivilCodePo getParentCode(String code) { | ||
| 81 | + if (code.length() > 8) { | ||
| 82 | + return null; | ||
| 83 | + } | ||
| 84 | + if (code.length() == 8) { | ||
| 85 | + String parentCode = code.substring(0, 6); | ||
| 86 | + return civilCodeMap.get(parentCode); | ||
| 87 | + }else { | ||
| 88 | + CivilCodePo civilCodePo = civilCodeMap.get(code); | ||
| 89 | + if (civilCodePo == null){ | ||
| 90 | + return null; | ||
| 91 | + } | ||
| 92 | + String parentCode = civilCodePo.getParentCode(); | ||
| 93 | + if (parentCode == null) { | ||
| 94 | + return null; | ||
| 95 | + } | ||
| 96 | + return civilCodeMap.get(parentCode); | ||
| 97 | + } | ||
| 98 | + | ||
| 99 | + } | ||
| 100 | + | ||
| 101 | +} |
src/main/java/com/genersoft/iot/vmp/conf/DynamicTask.java
| @@ -45,6 +45,7 @@ public class DynamicTask { | @@ -45,6 +45,7 @@ public class DynamicTask { | ||
| 45 | * @return | 45 | * @return |
| 46 | */ | 46 | */ |
| 47 | public void startCron(String key, Runnable task, int cycleForCatalog) { | 47 | public void startCron(String key, Runnable task, int cycleForCatalog) { |
| 48 | + System.out.println(cycleForCatalog); | ||
| 48 | ScheduledFuture<?> future = futureMap.get(key); | 49 | ScheduledFuture<?> future = futureMap.get(key); |
| 49 | if (future != null) { | 50 | if (future != null) { |
| 50 | if (future.isCancelled()) { | 51 | if (future.isCancelled()) { |
src/main/java/com/genersoft/iot/vmp/conf/SipPlatformRunner.java
| @@ -56,7 +56,7 @@ public class SipPlatformRunner implements CommandLineRunner { | @@ -56,7 +56,7 @@ public class SipPlatformRunner implements CommandLineRunner { | ||
| 56 | } | 56 | } |
| 57 | 57 | ||
| 58 | // 设置所有平台离线 | 58 | // 设置所有平台离线 |
| 59 | - platformService.offline(parentPlatform, true); | 59 | + platformService.offline(parentPlatform, false); |
| 60 | } | 60 | } |
| 61 | } | 61 | } |
| 62 | } | 62 | } |
src/main/java/com/genersoft/iot/vmp/conf/UserSetting.java
| @@ -63,7 +63,7 @@ public class UserSetting { | @@ -63,7 +63,7 @@ public class UserSetting { | ||
| 63 | 63 | ||
| 64 | private String thirdPartyGBIdReg = "[\\s\\S]*"; | 64 | private String thirdPartyGBIdReg = "[\\s\\S]*"; |
| 65 | 65 | ||
| 66 | - | 66 | + private String civilCodeFile = "classpath:civilCode.csv"; |
| 67 | 67 | ||
| 68 | private List<String> interfaceAuthenticationExcludes = new ArrayList<>(); | 68 | private List<String> interfaceAuthenticationExcludes = new ArrayList<>(); |
| 69 | 69 | ||
| @@ -71,6 +71,10 @@ public class UserSetting { | @@ -71,6 +71,10 @@ public class UserSetting { | ||
| 71 | 71 | ||
| 72 | private int maxNotifyCountQueue = 10000; | 72 | private int maxNotifyCountQueue = 10000; |
| 73 | 73 | ||
| 74 | + private int registerAgainAfterTime = 60; | ||
| 75 | + | ||
| 76 | + private boolean registerKeepIntDialog = false; | ||
| 77 | + | ||
| 74 | public Boolean getSavePositionHistory() { | 78 | public Boolean getSavePositionHistory() { |
| 75 | return savePositionHistory; | 79 | return savePositionHistory; |
| 76 | } | 80 | } |
| @@ -299,9 +303,27 @@ public class UserSetting { | @@ -299,9 +303,27 @@ public class UserSetting { | ||
| 299 | this.sqlLog = sqlLog; | 303 | this.sqlLog = sqlLog; |
| 300 | } | 304 | } |
| 301 | 305 | ||
| 306 | + public String getCivilCodeFile() { | ||
| 307 | + return civilCodeFile; | ||
| 308 | + } | ||
| 302 | 309 | ||
| 310 | + public void setCivilCodeFile(String civilCodeFile) { | ||
| 311 | + this.civilCodeFile = civilCodeFile; | ||
| 312 | + } | ||
| 303 | 313 | ||
| 314 | + public int getRegisterAgainAfterTime() { | ||
| 315 | + return registerAgainAfterTime; | ||
| 316 | + } | ||
| 304 | 317 | ||
| 318 | + public void setRegisterAgainAfterTime(int registerAgainAfterTime) { | ||
| 319 | + this.registerAgainAfterTime = registerAgainAfterTime; | ||
| 320 | + } | ||
| 305 | 321 | ||
| 322 | + public boolean isRegisterKeepIntDialog() { | ||
| 323 | + return registerKeepIntDialog; | ||
| 324 | + } | ||
| 306 | 325 | ||
| 326 | + public void setRegisterKeepIntDialog(boolean registerKeepIntDialog) { | ||
| 327 | + this.registerKeepIntDialog = registerKeepIntDialog; | ||
| 328 | + } | ||
| 307 | } | 329 | } |
src/main/java/com/genersoft/iot/vmp/gb28181/bean/Device.java
| @@ -173,12 +173,6 @@ public class Device { | @@ -173,12 +173,6 @@ public class Device { | ||
| 173 | @Schema(description = "地理坐标系, 目前支持 WGS84,GCJ02") | 173 | @Schema(description = "地理坐标系, 目前支持 WGS84,GCJ02") |
| 174 | private String geoCoordSys; | 174 | private String geoCoordSys; |
| 175 | 175 | ||
| 176 | - /** | ||
| 177 | - * 树类型 国标规定了两种树的展现方式 行政区划:CivilCode 和业务分组:BusinessGroup | ||
| 178 | - */ | ||
| 179 | - @Schema(description = "树类型 国标规定了两种树的展现方式 行政区划:CivilCode 和业务分组:BusinessGroup") | ||
| 180 | - private String treeType; | ||
| 181 | - | ||
| 182 | @Schema(description = "密码") | 176 | @Schema(description = "密码") |
| 183 | private String password; | 177 | private String password; |
| 184 | 178 | ||
| @@ -408,14 +402,6 @@ public class Device { | @@ -408,14 +402,6 @@ public class Device { | ||
| 408 | this.geoCoordSys = geoCoordSys; | 402 | this.geoCoordSys = geoCoordSys; |
| 409 | } | 403 | } |
| 410 | 404 | ||
| 411 | - public String getTreeType() { | ||
| 412 | - return treeType; | ||
| 413 | - } | ||
| 414 | - | ||
| 415 | - public void setTreeType(String treeType) { | ||
| 416 | - this.treeType = treeType; | ||
| 417 | - } | ||
| 418 | - | ||
| 419 | public String getPassword() { | 405 | public String getPassword() { |
| 420 | return password; | 406 | return password; |
| 421 | } | 407 | } |
src/main/java/com/genersoft/iot/vmp/gb28181/bean/ParentPlatform.java
| @@ -183,12 +183,6 @@ public class ParentPlatform { | @@ -183,12 +183,6 @@ public class ParentPlatform { | ||
| 183 | @Schema(description = "创建时间") | 183 | @Schema(description = "创建时间") |
| 184 | private String createTime; | 184 | private String createTime; |
| 185 | 185 | ||
| 186 | - /** | ||
| 187 | - * 树类型 国标规定了两种树的展现方式 行政区划 CivilCode 和业务分组:BusinessGroup | ||
| 188 | - */ | ||
| 189 | - @Schema(description = "树类型 国标规定了两种树的展现方式 行政区划 CivilCode 和业务分组:BusinessGrou") | ||
| 190 | - private String treeType; | ||
| 191 | - | ||
| 192 | @Schema(description = "是否作为消息通道") | 186 | @Schema(description = "是否作为消息通道") |
| 193 | private boolean asMessageChannel; | 187 | private boolean asMessageChannel; |
| 194 | 188 | ||
| @@ -424,14 +418,6 @@ public class ParentPlatform { | @@ -424,14 +418,6 @@ public class ParentPlatform { | ||
| 424 | this.createTime = createTime; | 418 | this.createTime = createTime; |
| 425 | } | 419 | } |
| 426 | 420 | ||
| 427 | - public String getTreeType() { | ||
| 428 | - return treeType; | ||
| 429 | - } | ||
| 430 | - | ||
| 431 | - public void setTreeType(String treeType) { | ||
| 432 | - this.treeType = treeType; | ||
| 433 | - } | ||
| 434 | - | ||
| 435 | public boolean isAsMessageChannel() { | 421 | public boolean isAsMessageChannel() { |
| 436 | return asMessageChannel; | 422 | return asMessageChannel; |
| 437 | } | 423 | } |
src/main/java/com/genersoft/iot/vmp/gb28181/bean/TreeType.java deleted
100644 → 0
src/main/java/com/genersoft/iot/vmp/gb28181/transmit/cmd/impl/SIPCommanderFroPlatform.java
| @@ -209,59 +209,149 @@ public class SIPCommanderFroPlatform implements ISIPCommanderForPlatform { | @@ -209,59 +209,149 @@ public class SIPCommanderFroPlatform implements ISIPCommanderForPlatform { | ||
| 209 | // 行政区划分组只需要这两项就可以 | 209 | // 行政区划分组只需要这两项就可以 |
| 210 | catalogXml.append("<DeviceID>" + channel.getChannelId() + "</DeviceID>\r\n"); | 210 | catalogXml.append("<DeviceID>" + channel.getChannelId() + "</DeviceID>\r\n"); |
| 211 | catalogXml.append("<Name>" + channel.getName() + "</Name>\r\n"); | 211 | catalogXml.append("<Name>" + channel.getName() + "</Name>\r\n"); |
| 212 | - if (channel.getParentId() != null) { | ||
| 213 | - // 业务分组加上这一项即可,提高兼容性, | ||
| 214 | - catalogXml.append("<ParentID>" + channel.getParentId() + "</ParentID>\r\n"); | ||
| 215 | -// catalogXml.append("<ParentID>" + parentPlatform.getDeviceGBId() + "/" + channel.getParentId() + "</ParentID>\r\n"); | ||
| 216 | - } | ||
| 217 | - if (channel.getChannelId().length() == 20 && Integer.parseInt(channel.getChannelId().substring(10, 13)) == 216) { | ||
| 218 | - // 虚拟组织增加BusinessGroupID字段 | ||
| 219 | - catalogXml.append("<BusinessGroupID>" + channel.getParentId() + "</BusinessGroupID>\r\n"); | ||
| 220 | - } | ||
| 221 | - if (!channel.getChannelId().equals(parentPlatform.getDeviceGBId())) { | ||
| 222 | - catalogXml.append("<Parental>" + channel.getParental() + "</Parental>\r\n"); | ||
| 223 | - if (channel.getParental() == 0) { | ||
| 224 | - catalogXml.append("<Status>" + (channel.isStatus() ? "ON" : "OFF") + "</Status>\r\n"); | 212 | + if (channel.getChannelId().length() <= 8) { |
| 213 | + catalogXml.append("</Item>\r\n"); | ||
| 214 | + continue; | ||
| 215 | + }else { | ||
| 216 | + if (channel.getChannelId().length() != 20) { | ||
| 217 | + continue; | ||
| 225 | } | 218 | } |
| 226 | - } | ||
| 227 | - if (channel.getParental() == 0) { | ||
| 228 | - // 通道项 | ||
| 229 | - catalogXml.append("<Manufacturer>" + channel.getManufacture() + "</Manufacturer>\r\n"); | ||
| 230 | - catalogXml.append("<Secrecy>" + channel.getSecrecy() + "</Secrecy>\r\n"); | ||
| 231 | - catalogXml.append("<RegisterWay>" + channel.getRegisterWay() + "</RegisterWay>\r\n"); | ||
| 232 | - String civilCode = channel.getCivilCode() == null?parentPlatform.getAdministrativeDivision() : channel.getCivilCode(); | ||
| 233 | - if (channel.getChannelType() != 2) { // 业务分组/虚拟组织/行政区划 不设置以下属性 | ||
| 234 | - catalogXml.append("<Model>" + channel.getModel() + "</Model>\r\n"); | ||
| 235 | - catalogXml.append("<Owner>" + parentPlatform.getDeviceGBId()+ "</Owner>\r\n"); | ||
| 236 | - catalogXml.append("<CivilCode>" + civilCode + "</CivilCode>\r\n"); | ||
| 237 | - if (channel.getAddress() == null) { | ||
| 238 | - catalogXml.append("<Address></Address>\r\n"); | ||
| 239 | - }else { | ||
| 240 | - catalogXml.append("<Address>" + channel.getAddress() + "</Address>\r\n"); | ||
| 241 | - } | ||
| 242 | - catalogXml.append("<Block>" + channel.getBlock() + "</Block>\r\n"); | ||
| 243 | - catalogXml.append("<SafetyWay>" + channel.getSafetyWay() + "</SafetyWay>\r\n"); | ||
| 244 | - catalogXml.append("<CertNum>" + channel.getCertNum() + "</CertNum>\r\n"); | ||
| 245 | - catalogXml.append("<Certifiable>" + channel.getCertifiable() + "</Certifiable>\r\n"); | ||
| 246 | - catalogXml.append("<ErrCode>" + channel.getErrCode() + "</ErrCode>\r\n"); | ||
| 247 | - catalogXml.append("<EndTime>" + channel.getEndTime() + "</EndTime>\r\n"); | ||
| 248 | - catalogXml.append("<Secrecy>" + channel.getSecrecy() + "</Secrecy>\r\n"); | ||
| 249 | - catalogXml.append("<IPAddress>" + channel.getIpAddress() + "</IPAddress>\r\n"); | ||
| 250 | - catalogXml.append("<Port>" + channel.getPort() + "</Port>\r\n"); | ||
| 251 | - catalogXml.append("<Password>" + channel.getPort() + "</Password>\r\n"); | ||
| 252 | - catalogXml.append("<PTZType>" + channel.getPTZType() + "</PTZType>\r\n"); | ||
| 253 | - catalogXml.append("<Status>" + (channel.isStatus() ? "ON":"OFF") + "</Status>\r\n"); | ||
| 254 | - catalogXml.append("<Longitude>" + | ||
| 255 | - (channel.getLongitudeWgs84() != 0? channel.getLongitudeWgs84():channel.getLongitude()) | ||
| 256 | - + "</Longitude>\r\n"); | ||
| 257 | - catalogXml.append("<Latitude>" + | ||
| 258 | - (channel.getLatitudeWgs84() != 0? channel.getLatitudeWgs84():channel.getLatitude()) | ||
| 259 | - + "</Latitude>\r\n"); | ||
| 260 | - | 219 | + switch (Integer.parseInt(channel.getChannelId().substring(10, 13))){ |
| 220 | + case 200: | ||
| 221 | +// catalogXml.append("<Manufacturer>三永华通</Manufacturer>\r\n"); | ||
| 222 | +// GitUtil gitUtil = SpringBeanFactory.getBean("gitUtil"); | ||
| 223 | +// String model = (gitUtil == null || gitUtil.getBuildVersion() == null)?"1.0": gitUtil.getBuildVersion(); | ||
| 224 | +// catalogXml.append("<Model>" + model + "</Manufacturer>\r\n"); | ||
| 225 | +// catalogXml.append("<Owner>三永华通</Owner>\r\n"); | ||
| 226 | + if (channel.getCivilCode() != null) { | ||
| 227 | + catalogXml.append("<CivilCode>"+channel.getCivilCode()+"</CivilCode>\r\n"); | ||
| 228 | + }else { | ||
| 229 | + catalogXml.append("<CivilCode></CivilCode>\r\n"); | ||
| 230 | + } | ||
| 231 | + | ||
| 232 | + catalogXml.append("<RegisterWay>1</RegisterWay>\r\n"); | ||
| 233 | + catalogXml.append("<Secrecy>0</Secrecy>\r\n"); | ||
| 234 | + break; | ||
| 235 | + case 215: | ||
| 236 | + if (!ObjectUtils.isEmpty(channel.getParentId())) { | ||
| 237 | + catalogXml.append("<ParentID>" + channel.getParentId() + "</ParentID>\r\n"); | ||
| 238 | + } | ||
| 239 | + | ||
| 240 | + break; | ||
| 241 | + case 216: | ||
| 242 | + if (!ObjectUtils.isEmpty(channel.getParentId())) { | ||
| 243 | + catalogXml.append("<ParentID>" + channel.getParentId() + "</ParentID>\r\n"); | ||
| 244 | + }else { | ||
| 245 | + catalogXml.append("<ParentID></ParentID>\r\n"); | ||
| 246 | + } | ||
| 247 | + if (!ObjectUtils.isEmpty(channel.getBusinessGroupId())) { | ||
| 248 | + catalogXml.append("<BusinessGroupID>" + channel.getBusinessGroupId() + "</BusinessGroupID>\r\n"); | ||
| 249 | + }else { | ||
| 250 | + catalogXml.append("<BusinessGroupID></BusinessGroupID>\r\n"); | ||
| 251 | + } | ||
| 252 | + break; | ||
| 253 | + default: | ||
| 254 | + // 通道项 | ||
| 255 | + if (channel.getManufacture() != null) { | ||
| 256 | + catalogXml.append("<Manufacturer>" + channel.getManufacture() + "</Manufacturer>\r\n"); | ||
| 257 | + }else { | ||
| 258 | + catalogXml.append("<Manufacturer></Manufacturer>\r\n"); | ||
| 259 | + } | ||
| 260 | + if (channel.getSecrecy() != null) { | ||
| 261 | + catalogXml.append("<Secrecy>" + channel.getSecrecy() + "</Secrecy>\r\n"); | ||
| 262 | + }else { | ||
| 263 | + catalogXml.append("<Secrecy></Secrecy>\r\n"); | ||
| 264 | + } | ||
| 265 | + catalogXml.append("<RegisterWay>" + channel.getRegisterWay() + "</RegisterWay>\r\n"); | ||
| 266 | + if (channel.getModel() != null) { | ||
| 267 | + catalogXml.append("<Model>" + channel.getModel() + "</Model>\r\n"); | ||
| 268 | + }else { | ||
| 269 | + catalogXml.append("<Model></Model>\r\n"); | ||
| 270 | + } | ||
| 271 | + if (channel.getOwner() != null) { | ||
| 272 | + catalogXml.append("<Owner>" + channel.getOwner()+ "</Owner>\r\n"); | ||
| 273 | + }else { | ||
| 274 | + catalogXml.append("<Owner></Owner>\r\n"); | ||
| 275 | + } | ||
| 276 | + if (channel.getCivilCode() != null) { | ||
| 277 | + catalogXml.append("<CivilCode>" + channel.getCivilCode() + "</CivilCode>\r\n"); | ||
| 278 | + }else { | ||
| 279 | + catalogXml.append("<CivilCode></CivilCode>\r\n"); | ||
| 280 | + } | ||
| 281 | + if (channel.getAddress() == null) { | ||
| 282 | + catalogXml.append("<Address></Address>\r\n"); | ||
| 283 | + }else { | ||
| 284 | + catalogXml.append("<Address>" + channel.getAddress() + "</Address>\r\n"); | ||
| 285 | + } | ||
| 286 | + if (!ObjectUtils.isEmpty(channel.getParentId())) { | ||
| 287 | + catalogXml.append("<ParentID>" + channel.getParentId() + "</ParentID>\r\n"); | ||
| 288 | + }else { | ||
| 289 | + catalogXml.append("<ParentID></ParentID>\r\n"); | ||
| 290 | + } | ||
| 291 | + if (!ObjectUtils.isEmpty(channel.getBlock())) { | ||
| 292 | + catalogXml.append("<Block>" + channel.getBlock() + "</Block>\r\n"); | ||
| 293 | + }else { | ||
| 294 | + catalogXml.append("<Block></Block>\r\n"); | ||
| 295 | + } | ||
| 296 | + if (!ObjectUtils.isEmpty(channel.getSafetyWay())) { | ||
| 297 | + catalogXml.append("<SafetyWay>" + channel.getSafetyWay() + "</SafetyWay>\r\n"); | ||
| 298 | + }else { | ||
| 299 | + catalogXml.append("<SafetyWay></SafetyWay>\r\n"); | ||
| 300 | + } | ||
| 301 | + if (!ObjectUtils.isEmpty(channel.getCertNum())) { | ||
| 302 | + catalogXml.append("<CertNum>" + channel.getCertNum() + "</CertNum>\r\n"); | ||
| 303 | + }else { | ||
| 304 | + catalogXml.append("<CertNum></CertNum>\r\n"); | ||
| 305 | + } | ||
| 306 | + if (!ObjectUtils.isEmpty(channel.getCertifiable())) { | ||
| 307 | + catalogXml.append("<Certifiable>" + channel.getCertifiable() + "</Certifiable>\r\n"); | ||
| 308 | + }else { | ||
| 309 | + catalogXml.append("<Certifiable></Certifiable>\r\n"); | ||
| 310 | + } | ||
| 311 | + if (!ObjectUtils.isEmpty(channel.getErrCode())) { | ||
| 312 | + catalogXml.append("<ErrCode>" + channel.getErrCode() + "</ErrCode>\r\n"); | ||
| 313 | + }else { | ||
| 314 | + catalogXml.append("<ErrCode></ErrCode>\r\n"); | ||
| 315 | + } | ||
| 316 | + if (!ObjectUtils.isEmpty(channel.getEndTime())) { | ||
| 317 | + catalogXml.append("<EndTime>" + channel.getEndTime() + "</EndTime>\r\n"); | ||
| 318 | + }else { | ||
| 319 | + catalogXml.append("<EndTime></EndTime>\r\n"); | ||
| 320 | + } | ||
| 321 | + if (!ObjectUtils.isEmpty(channel.getSecrecy())) { | ||
| 322 | + catalogXml.append("<Secrecy>" + channel.getSecrecy() + "</Secrecy>\r\n"); | ||
| 323 | + }else { | ||
| 324 | + catalogXml.append("<Secrecy></Secrecy>\r\n"); | ||
| 325 | + } | ||
| 326 | + if (!ObjectUtils.isEmpty(channel.getIpAddress())) { | ||
| 327 | + catalogXml.append("<IPAddress>" + channel.getIpAddress() + "</IPAddress>\r\n"); | ||
| 328 | + }else { | ||
| 329 | + catalogXml.append("<IPAddress></IPAddress>\r\n"); | ||
| 330 | + } | ||
| 331 | + catalogXml.append("<Port>" + channel.getPort() + "</Port>\r\n"); | ||
| 332 | + if (!ObjectUtils.isEmpty(channel.getPassword())) { | ||
| 333 | + catalogXml.append("<Password>" + channel.getPassword() + "</Password>\r\n"); | ||
| 334 | + }else { | ||
| 335 | + catalogXml.append("<Password></Password>\r\n"); | ||
| 336 | + } | ||
| 337 | + if (!ObjectUtils.isEmpty(channel.getPTZType())) { | ||
| 338 | + catalogXml.append("<PTZType>" + channel.getPTZType() + "</PTZType>\r\n"); | ||
| 339 | + }else { | ||
| 340 | + catalogXml.append("<PTZType></PTZType>\r\n"); | ||
| 341 | + } | ||
| 342 | + catalogXml.append("<Status>" + (channel.isStatus() ?"ON":"OFF") + "</Status>\r\n"); | ||
| 343 | + | ||
| 344 | + catalogXml.append("<Longitude>" + | ||
| 345 | + (channel.getLongitudeWgs84() != 0? channel.getLongitudeWgs84():channel.getLongitude()) | ||
| 346 | + + "</Longitude>\r\n"); | ||
| 347 | + catalogXml.append("<Latitude>" + | ||
| 348 | + (channel.getLatitudeWgs84() != 0? channel.getLatitudeWgs84():channel.getLatitude()) | ||
| 349 | + + "</Latitude>\r\n"); | ||
| 350 | + break; | ||
| 261 | 351 | ||
| 262 | } | 352 | } |
| 353 | + catalogXml.append("</Item>\r\n"); | ||
| 263 | } | 354 | } |
| 264 | - catalogXml.append("</Item>\r\n"); | ||
| 265 | } | 355 | } |
| 266 | } | 356 | } |
| 267 | 357 |
src/main/java/com/genersoft/iot/vmp/gb28181/transmit/event/request/impl/InviteRequestProcessor.java
| @@ -188,6 +188,8 @@ public class InviteRequestProcessor extends SIPRequestProcessorParent implements | @@ -188,6 +188,8 @@ public class InviteRequestProcessor extends SIPRequestProcessorParent implements | ||
| 188 | logger.error("[命令发送失败] invite GONE: {}", e.getMessage()); | 188 | logger.error("[命令发送失败] invite GONE: {}", e.getMessage()); |
| 189 | } | 189 | } |
| 190 | return; | 190 | return; |
| 191 | + }else { | ||
| 192 | + // TODO 可能漏回复消息 | ||
| 191 | } | 193 | } |
| 192 | } | 194 | } |
| 193 | } else { | 195 | } else { |
src/main/java/com/genersoft/iot/vmp/gb28181/transmit/event/request/impl/NotifyRequestForCatalogProcessor.java
| 1 | package com.genersoft.iot.vmp.gb28181.transmit.event.request.impl; | 1 | package com.genersoft.iot.vmp.gb28181.transmit.event.request.impl; |
| 2 | 2 | ||
| 3 | +import com.genersoft.iot.vmp.conf.CivilCodeFileConf; | ||
| 3 | import com.genersoft.iot.vmp.conf.DynamicTask; | 4 | import com.genersoft.iot.vmp.conf.DynamicTask; |
| 4 | import com.genersoft.iot.vmp.conf.UserSetting; | 5 | import com.genersoft.iot.vmp.conf.UserSetting; |
| 5 | import com.genersoft.iot.vmp.gb28181.bean.Device; | 6 | import com.genersoft.iot.vmp.gb28181.bean.Device; |
| @@ -20,7 +21,10 @@ import org.springframework.stereotype.Component; | @@ -20,7 +21,10 @@ import org.springframework.stereotype.Component; | ||
| 20 | 21 | ||
| 21 | import javax.sip.RequestEvent; | 22 | import javax.sip.RequestEvent; |
| 22 | import javax.sip.header.FromHeader; | 23 | import javax.sip.header.FromHeader; |
| 23 | -import java.util.*; | 24 | +import java.util.ArrayList; |
| 25 | +import java.util.Iterator; | ||
| 26 | +import java.util.List; | ||
| 27 | +import java.util.Map; | ||
| 24 | import java.util.concurrent.ConcurrentHashMap; | 28 | import java.util.concurrent.ConcurrentHashMap; |
| 25 | import java.util.concurrent.CopyOnWriteArrayList; | 29 | import java.util.concurrent.CopyOnWriteArrayList; |
| 26 | 30 | ||
| @@ -56,6 +60,9 @@ public class NotifyRequestForCatalogProcessor extends SIPRequestProcessorParent | @@ -56,6 +60,9 @@ public class NotifyRequestForCatalogProcessor extends SIPRequestProcessorParent | ||
| 56 | @Autowired | 60 | @Autowired |
| 57 | private DynamicTask dynamicTask; | 61 | private DynamicTask dynamicTask; |
| 58 | 62 | ||
| 63 | + @Autowired | ||
| 64 | + private CivilCodeFileConf civilCodeFileConf; | ||
| 65 | + | ||
| 59 | private final static String talkKey = "notify-request-for-catalog-task"; | 66 | private final static String talkKey = "notify-request-for-catalog-task"; |
| 60 | 67 | ||
| 61 | public void process(RequestEvent evt) { | 68 | public void process(RequestEvent evt) { |
| @@ -96,7 +103,7 @@ public class NotifyRequestForCatalogProcessor extends SIPRequestProcessorParent | @@ -96,7 +103,7 @@ public class NotifyRequestForCatalogProcessor extends SIPRequestProcessorParent | ||
| 96 | }else { | 103 | }else { |
| 97 | event = eventElement.getText().toUpperCase(); | 104 | event = eventElement.getText().toUpperCase(); |
| 98 | } | 105 | } |
| 99 | - DeviceChannel channel = XmlUtil.channelContentHander(itemDevice, device, event); | 106 | + DeviceChannel channel = XmlUtil.channelContentHandler(itemDevice, device, event, civilCodeFileConf); |
| 100 | 107 | ||
| 101 | channel.setDeviceId(device.getDeviceId()); | 108 | channel.setDeviceId(device.getDeviceId()); |
| 102 | logger.info("[收到目录订阅]:{}/{}", device.getDeviceId(), channel.getChannelId()); | 109 | logger.info("[收到目录订阅]:{}/{}", device.getDeviceId(), channel.getChannelId()); |
src/main/java/com/genersoft/iot/vmp/gb28181/transmit/event/request/impl/NotifyRequestProcessor.java
| 1 | package com.genersoft.iot.vmp.gb28181.transmit.event.request.impl; | 1 | package com.genersoft.iot.vmp.gb28181.transmit.event.request.impl; |
| 2 | 2 | ||
| 3 | import com.alibaba.fastjson2.JSONObject; | 3 | import com.alibaba.fastjson2.JSONObject; |
| 4 | +import com.genersoft.iot.vmp.conf.CivilCodeFileConf; | ||
| 4 | import com.genersoft.iot.vmp.conf.SipConfig; | 5 | import com.genersoft.iot.vmp.conf.SipConfig; |
| 5 | import com.genersoft.iot.vmp.conf.UserSetting; | 6 | import com.genersoft.iot.vmp.conf.UserSetting; |
| 6 | import com.genersoft.iot.vmp.gb28181.bean.*; | 7 | import com.genersoft.iot.vmp.gb28181.bean.*; |
| @@ -79,6 +80,9 @@ public class NotifyRequestProcessor extends SIPRequestProcessorParent implements | @@ -79,6 +80,9 @@ public class NotifyRequestProcessor extends SIPRequestProcessorParent implements | ||
| 79 | @Autowired | 80 | @Autowired |
| 80 | private NotifyRequestForCatalogProcessor notifyRequestForCatalogProcessor; | 81 | private NotifyRequestForCatalogProcessor notifyRequestForCatalogProcessor; |
| 81 | 82 | ||
| 83 | + @Autowired | ||
| 84 | + private CivilCodeFileConf civilCodeFileConf; | ||
| 85 | + | ||
| 82 | private ConcurrentLinkedQueue<HandlerCatchData> taskQueue = new ConcurrentLinkedQueue<>(); | 86 | private ConcurrentLinkedQueue<HandlerCatchData> taskQueue = new ConcurrentLinkedQueue<>(); |
| 83 | 87 | ||
| 84 | @Qualifier("taskExecutor") | 88 | @Qualifier("taskExecutor") |
| @@ -408,7 +412,7 @@ public class NotifyRequestProcessor extends SIPRequestProcessorParent implements | @@ -408,7 +412,7 @@ public class NotifyRequestProcessor extends SIPRequestProcessorParent implements | ||
| 408 | }else { | 412 | }else { |
| 409 | event = eventElement.getText().toUpperCase(); | 413 | event = eventElement.getText().toUpperCase(); |
| 410 | } | 414 | } |
| 411 | - DeviceChannel channel = XmlUtil.channelContentHander(itemDevice, device, event); | 415 | + DeviceChannel channel = XmlUtil.channelContentHandler(itemDevice, device, event, civilCodeFileConf); |
| 412 | channel.setDeviceId(device.getDeviceId()); | 416 | channel.setDeviceId(device.getDeviceId()); |
| 413 | logger.info("[收到目录订阅]:{}/{}", device.getDeviceId(), channel.getChannelId()); | 417 | logger.info("[收到目录订阅]:{}/{}", device.getDeviceId(), channel.getChannelId()); |
| 414 | switch (event) { | 418 | switch (event) { |
src/main/java/com/genersoft/iot/vmp/gb28181/transmit/event/request/impl/RegisterRequestProcessor.java
| @@ -164,7 +164,6 @@ public class RegisterRequestProcessor extends SIPRequestProcessorParent implemen | @@ -164,7 +164,6 @@ public class RegisterRequestProcessor extends SIPRequestProcessorParent implemen | ||
| 164 | device.setStreamMode("UDP"); | 164 | device.setStreamMode("UDP"); |
| 165 | device.setCharset("GB2312"); | 165 | device.setCharset("GB2312"); |
| 166 | device.setGeoCoordSys("WGS84"); | 166 | device.setGeoCoordSys("WGS84"); |
| 167 | - device.setTreeType("CivilCode"); | ||
| 168 | device.setDeviceId(deviceId); | 167 | device.setDeviceId(deviceId); |
| 169 | device.setOnLine(false); | 168 | device.setOnLine(false); |
| 170 | } | 169 | } |
src/main/java/com/genersoft/iot/vmp/gb28181/transmit/event/request/impl/message/response/cmd/CatalogResponseMessageHandler.java
| 1 | package com.genersoft.iot.vmp.gb28181.transmit.event.request.impl.message.response.cmd; | 1 | package com.genersoft.iot.vmp.gb28181.transmit.event.request.impl.message.response.cmd; |
| 2 | 2 | ||
| 3 | +import com.genersoft.iot.vmp.conf.CivilCodeFileConf; | ||
| 3 | import com.genersoft.iot.vmp.gb28181.bean.*; | 4 | import com.genersoft.iot.vmp.gb28181.bean.*; |
| 4 | import com.genersoft.iot.vmp.gb28181.session.CatalogDataCatch; | 5 | import com.genersoft.iot.vmp.gb28181.session.CatalogDataCatch; |
| 5 | import com.genersoft.iot.vmp.gb28181.transmit.event.request.SIPRequestProcessorParent; | 6 | import com.genersoft.iot.vmp.gb28181.transmit.event.request.SIPRequestProcessorParent; |
| @@ -53,6 +54,9 @@ public class CatalogResponseMessageHandler extends SIPRequestProcessorParent imp | @@ -53,6 +54,9 @@ public class CatalogResponseMessageHandler extends SIPRequestProcessorParent imp | ||
| 53 | @Autowired | 54 | @Autowired |
| 54 | private ThreadPoolTaskExecutor taskExecutor; | 55 | private ThreadPoolTaskExecutor taskExecutor; |
| 55 | 56 | ||
| 57 | + @Autowired | ||
| 58 | + private CivilCodeFileConf civilCodeFileConf; | ||
| 59 | + | ||
| 56 | @Override | 60 | @Override |
| 57 | public void afterPropertiesSet() throws Exception { | 61 | public void afterPropertiesSet() throws Exception { |
| 58 | responseMessageHandler.addHandler(cmdType, this); | 62 | responseMessageHandler.addHandler(cmdType, this); |
| @@ -100,6 +104,7 @@ public class CatalogResponseMessageHandler extends SIPRequestProcessorParent imp | @@ -100,6 +104,7 @@ public class CatalogResponseMessageHandler extends SIPRequestProcessorParent imp | ||
| 100 | Iterator<Element> deviceListIterator = deviceListElement.elementIterator(); | 104 | Iterator<Element> deviceListIterator = deviceListElement.elementIterator(); |
| 101 | if (deviceListIterator != null) { | 105 | if (deviceListIterator != null) { |
| 102 | List<DeviceChannel> channelList = new ArrayList<>(); | 106 | List<DeviceChannel> channelList = new ArrayList<>(); |
| 107 | + List<String> parentChannelIds = new ArrayList<>(); | ||
| 103 | // 遍历DeviceList | 108 | // 遍历DeviceList |
| 104 | while (deviceListIterator.hasNext()) { | 109 | while (deviceListIterator.hasNext()) { |
| 105 | Element itemDevice = deviceListIterator.next(); | 110 | Element itemDevice = deviceListIterator.next(); |
| @@ -107,7 +112,7 @@ public class CatalogResponseMessageHandler extends SIPRequestProcessorParent imp | @@ -107,7 +112,7 @@ public class CatalogResponseMessageHandler extends SIPRequestProcessorParent imp | ||
| 107 | if (channelDeviceElement == null) { | 112 | if (channelDeviceElement == null) { |
| 108 | continue; | 113 | continue; |
| 109 | } | 114 | } |
| 110 | - DeviceChannel deviceChannel = XmlUtil.channelContentHander(itemDevice, device, null); | 115 | + DeviceChannel deviceChannel = XmlUtil.channelContentHandler(itemDevice, device, null, civilCodeFileConf); |
| 111 | deviceChannel = SipUtils.updateGps(deviceChannel, device.getGeoCoordSys()); | 116 | deviceChannel = SipUtils.updateGps(deviceChannel, device.getGeoCoordSys()); |
| 112 | deviceChannel.setDeviceId(take.getDevice().getDeviceId()); | 117 | deviceChannel.setDeviceId(take.getDevice().getDeviceId()); |
| 113 | 118 |
src/main/java/com/genersoft/iot/vmp/gb28181/utils/XmlUtil.java
| @@ -2,6 +2,8 @@ package com.genersoft.iot.vmp.gb28181.utils; | @@ -2,6 +2,8 @@ package com.genersoft.iot.vmp.gb28181.utils; | ||
| 2 | 2 | ||
| 3 | import com.alibaba.fastjson2.JSONArray; | 3 | import com.alibaba.fastjson2.JSONArray; |
| 4 | import com.alibaba.fastjson2.JSONObject; | 4 | import com.alibaba.fastjson2.JSONObject; |
| 5 | +import com.genersoft.iot.vmp.common.CivilCodePo; | ||
| 6 | +import com.genersoft.iot.vmp.conf.CivilCodeFileConf; | ||
| 5 | import com.genersoft.iot.vmp.gb28181.bean.Device; | 7 | import com.genersoft.iot.vmp.gb28181.bean.Device; |
| 6 | import com.genersoft.iot.vmp.gb28181.bean.DeviceChannel; | 8 | import com.genersoft.iot.vmp.gb28181.bean.DeviceChannel; |
| 7 | import com.genersoft.iot.vmp.gb28181.event.subscribe.catalog.CatalogEvent; | 9 | import com.genersoft.iot.vmp.gb28181.event.subscribe.catalog.CatalogEvent; |
| @@ -192,7 +194,7 @@ public class XmlUtil { | @@ -192,7 +194,7 @@ public class XmlUtil { | ||
| 192 | CivilCode, BusinessGroup,VirtualOrganization,Other | 194 | CivilCode, BusinessGroup,VirtualOrganization,Other |
| 193 | } | 195 | } |
| 194 | 196 | ||
| 195 | - public static DeviceChannel channelContentHander(Element itemDevice, Device device, String event){ | 197 | + public static DeviceChannel channelContentHandler(Element itemDevice, Device device, String event, CivilCodeFileConf civilCodeFileConf){ |
| 196 | DeviceChannel deviceChannel = new DeviceChannel(); | 198 | DeviceChannel deviceChannel = new DeviceChannel(); |
| 197 | deviceChannel.setDeviceId(device.getDeviceId()); | 199 | deviceChannel.setDeviceId(device.getDeviceId()); |
| 198 | Element channdelIdElement = itemDevice.element("DeviceID"); | 200 | Element channdelIdElement = itemDevice.element("DeviceID"); |
| @@ -210,208 +212,353 @@ public class XmlUtil { | @@ -210,208 +212,353 @@ public class XmlUtil { | ||
| 210 | // 除了ADD和update情况下需要识别全部内容, | 212 | // 除了ADD和update情况下需要识别全部内容, |
| 211 | return deviceChannel; | 213 | return deviceChannel; |
| 212 | } | 214 | } |
| 213 | - | ||
| 214 | - ChannelType channelType = ChannelType.Other; | ||
| 215 | - if (channelId.length() <= 8) { | ||
| 216 | - channelType = ChannelType.CivilCode; | ||
| 217 | - deviceChannel.setHasAudio(false); | ||
| 218 | - }else { | ||
| 219 | - if (channelId.length() == 20) { | ||
| 220 | - int code = Integer.parseInt(channelId.substring(10, 13)); | ||
| 221 | - switch (code){ | ||
| 222 | - case 215: | ||
| 223 | - channelType = ChannelType.BusinessGroup; | ||
| 224 | - deviceChannel.setHasAudio(false); | ||
| 225 | - break; | ||
| 226 | - case 216: | ||
| 227 | - channelType = ChannelType.VirtualOrganization; | ||
| 228 | - deviceChannel.setHasAudio(false); | ||
| 229 | - break; | ||
| 230 | - case 136: | ||
| 231 | - case 137: | ||
| 232 | - case 138: | ||
| 233 | - deviceChannel.setHasAudio(true); | ||
| 234 | - break; | ||
| 235 | - default: | ||
| 236 | - deviceChannel.setHasAudio(false); | ||
| 237 | - break; | ||
| 238 | - | ||
| 239 | - } | ||
| 240 | - } | 215 | + Element nameElement = itemDevice.element("Name"); |
| 216 | + if (nameElement != null) { | ||
| 217 | + deviceChannel.setName(nameElement.getText()); | ||
| 241 | } | 218 | } |
| 242 | - | ||
| 243 | - Element channdelNameElement = itemDevice.element("Name"); | ||
| 244 | - String channelName = channdelNameElement != null ? channdelNameElement.getTextTrim() : ""; | ||
| 245 | - deviceChannel.setName(channelName); | ||
| 246 | - | ||
| 247 | - String civilCode = XmlUtil.getText(itemDevice, "CivilCode"); | ||
| 248 | - deviceChannel.setCivilCode(civilCode); | ||
| 249 | - if (channelType == ChannelType.CivilCode && civilCode == null) { | ||
| 250 | - deviceChannel.setParental(1); | ||
| 251 | - // 行政区划如果没有传递具体值,则推测一个 | ||
| 252 | - if (channelId.length() > 2) { | ||
| 253 | - deviceChannel.setCivilCode(channelId.substring(0, channelId.length() - 2)); | 219 | + if(channelId.length() <= 8) { |
| 220 | + deviceChannel.setHasAudio(false); | ||
| 221 | + CivilCodePo parentCode = civilCodeFileConf.getParentCode(channelId); | ||
| 222 | + if (parentCode != null) { | ||
| 223 | + deviceChannel.setParentId(parentCode.getCode()); | ||
| 224 | + deviceChannel.setCivilCode(parentCode.getCode()); | ||
| 225 | + }else { | ||
| 226 | + logger.warn("[xml解析] 无法确定行政区划{}的上级行政区划", channelId); | ||
| 254 | } | 227 | } |
| 255 | - } | ||
| 256 | - if (channelType.equals(ChannelType.CivilCode)) { | ||
| 257 | - // 行政区划其他字段没必要识别了,默认在线即可 | ||
| 258 | deviceChannel.setStatus(true); | 228 | deviceChannel.setStatus(true); |
| 259 | - deviceChannel.setParental(1); | ||
| 260 | - deviceChannel.setCreateTime(DateUtil.getNow()); | ||
| 261 | - deviceChannel.setUpdateTime(DateUtil.getNow()); | ||
| 262 | return deviceChannel; | 229 | return deviceChannel; |
| 263 | - } | ||
| 264 | - /** | ||
| 265 | - * 行政区划展示设备树与业务分组展示设备树是两种不同的模式 | ||
| 266 | - * 行政区划展示设备树 各个目录之间主要靠deviceId做关联,摄像头通过CivilCode指定其属于那个行政区划;都是不超过十位的编号; 结构如下: | ||
| 267 | - * 河北省 | ||
| 268 | - * --> 石家庄市 | ||
| 269 | - * --> 摄像头 | ||
| 270 | - *String parentId = XmlUtil.getText(itemDevice, "ParentID"); | ||
| 271 | - if (parentId != null) { | ||
| 272 | - if (parentId.contains("/")) { | ||
| 273 | - String lastParentId = parentId.substring(parentId.lastIndexOf("/") + 1); | ||
| 274 | - String businessGroup = parentId.substring(0, parentId.indexOf("/")); | ||
| 275 | - deviceChannel.setParentId(lastParentId); | ||
| 276 | - }else { | ||
| 277 | - deviceChannel.setParentId(parentId); | ||
| 278 | - } | ||
| 279 | - } | ||
| 280 | - deviceCh --> 正定县 | ||
| 281 | - * --> 摄像头 | ||
| 282 | - * --> 摄像头 | ||
| 283 | - * | ||
| 284 | - * 业务分组展示设备树是顶级是业务分组,其下的虚拟组织靠BusinessGroupID指定其所属的业务分组;摄像头通过ParentId来指定其所属于的虚拟组织: | ||
| 285 | - * 业务分组 | ||
| 286 | - * --> 虚拟组织 | ||
| 287 | - * --> 摄像头 | ||
| 288 | - * --> 虚拟组织 | ||
| 289 | - * --> 摄像头 | ||
| 290 | - * --> 摄像头 | ||
| 291 | - */ | ||
| 292 | - String parentId = XmlUtil.getText(itemDevice, "ParentID"); | ||
| 293 | - String businessGroupID = XmlUtil.getText(itemDevice, "BusinessGroupID"); | ||
| 294 | - if (parentId != null) { | ||
| 295 | - if (parentId.contains("/")) { | ||
| 296 | - String lastParentId = parentId.substring(parentId.lastIndexOf("/") + 1); | ||
| 297 | - if (businessGroupID == null) { | ||
| 298 | - businessGroupID = parentId.substring(0, parentId.indexOf("/")); | ||
| 299 | - } | ||
| 300 | - deviceChannel.setParentId(lastParentId); | 230 | + }else { |
| 231 | + if(channelId.length() != 20) { | ||
| 232 | + logger.warn("[xml解析] 失败,编号不符合国标28181定义: {}", channelId); | ||
| 233 | + return null; | ||
| 234 | + } | ||
| 235 | + | ||
| 236 | + int code = Integer.parseInt(channelId.substring(10, 13)); | ||
| 237 | + if (code == 136 || code == 137 || code == 138) { | ||
| 238 | + deviceChannel.setHasAudio(true); | ||
| 301 | }else { | 239 | }else { |
| 302 | - deviceChannel.setParentId(parentId); | 240 | + deviceChannel.setHasAudio(false); |
| 303 | } | 241 | } |
| 304 | - // 兼容设备通道信息中自己为自己父节点的情况 | ||
| 305 | - if (deviceChannel.getParentId().equals(deviceChannel.getChannelId())) { | ||
| 306 | - deviceChannel.setParentId(null); | 242 | + // 设备厂商 |
| 243 | + String manufacturer = getText(itemDevice, "Manufacturer"); | ||
| 244 | + // 设备型号 | ||
| 245 | + String model = getText(itemDevice, "Model"); | ||
| 246 | + // 设备归属 | ||
| 247 | + String owner = getText(itemDevice, "Owner"); | ||
| 248 | + // 行政区域 | ||
| 249 | + String civilCode = getText(itemDevice, "CivilCode"); | ||
| 250 | + // 虚拟组织所属的业务分组ID,业务分组根据特定的业务需求制定,一个业务分组包含一组特定的虚拟组织 | ||
| 251 | + String businessGroupID = getText(itemDevice, "BusinessGroupID"); | ||
| 252 | + // 父设备/区域/系统ID | ||
| 253 | + String parentID = getText(itemDevice, "ParentID"); | ||
| 254 | + if (parentID != null && parentID.equalsIgnoreCase("null")) { | ||
| 255 | + parentID = null; | ||
| 307 | } | 256 | } |
| 308 | - } | ||
| 309 | - deviceChannel.setBusinessGroupId(businessGroupID); | ||
| 310 | - if (channelType.equals(ChannelType.BusinessGroup) || channelType.equals(ChannelType.VirtualOrganization)) { | ||
| 311 | - // 业务分组和虚拟组织 其他字段没必要识别了,默认在线即可 | ||
| 312 | - deviceChannel.setStatus(true); | ||
| 313 | - deviceChannel.setParental(1); | ||
| 314 | - deviceChannel.setCreateTime(DateUtil.getNow()); | ||
| 315 | - deviceChannel.setUpdateTime(DateUtil.getNow()); | ||
| 316 | - return deviceChannel; | ||
| 317 | - } | 257 | + // 注册方式(必选)缺省为1;1:符合IETFRFC3261标准的认证注册模式;2:基于口令的双向认证注册模式;3:基于数字证书的双向认证注册模式 |
| 258 | + String registerWay = getText(itemDevice, "RegisterWay"); | ||
| 259 | + // 保密属性(必选)缺省为0;0:不涉密,1:涉密 | ||
| 260 | + String secrecy = getText(itemDevice, "Secrecy"); | ||
| 261 | + // 安装地址 | ||
| 262 | + String address = getText(itemDevice, "Address"); | ||
| 263 | + | ||
| 264 | + switch (code){ | ||
| 265 | + case 200: | ||
| 266 | + // 系统目录 | ||
| 267 | + if (!ObjectUtils.isEmpty(manufacturer)) { | ||
| 268 | + deviceChannel.setManufacture(manufacturer); | ||
| 269 | + } | ||
| 270 | + if (!ObjectUtils.isEmpty(model)) { | ||
| 271 | + deviceChannel.setModel(model); | ||
| 272 | + } | ||
| 273 | + if (!ObjectUtils.isEmpty(owner)) { | ||
| 274 | + deviceChannel.setOwner(owner); | ||
| 275 | + } | ||
| 276 | + if (!ObjectUtils.isEmpty(civilCode)) { | ||
| 277 | + deviceChannel.setCivilCode(civilCode); | ||
| 278 | + deviceChannel.setParentId(civilCode); | ||
| 279 | + }else { | ||
| 280 | + if (!ObjectUtils.isEmpty(parentID)) { | ||
| 281 | + deviceChannel.setParentId(parentID); | ||
| 282 | + } | ||
| 283 | + } | ||
| 284 | + if (!ObjectUtils.isEmpty(address)) { | ||
| 285 | + deviceChannel.setAddress(address); | ||
| 286 | + } | ||
| 287 | + deviceChannel.setStatus(true); | ||
| 288 | + if (!ObjectUtils.isEmpty(registerWay)) { | ||
| 289 | + try { | ||
| 290 | + deviceChannel.setRegisterWay(Integer.parseInt(registerWay)); | ||
| 291 | + }catch (NumberFormatException exception) { | ||
| 292 | + logger.warn("[xml解析] 从通道数据获取registerWay失败: {}", registerWay); | ||
| 293 | + } | ||
| 294 | + } | ||
| 295 | + if (!ObjectUtils.isEmpty(secrecy)) { | ||
| 296 | + deviceChannel.setSecrecy(secrecy); | ||
| 297 | + } | ||
| 298 | + return deviceChannel; | ||
| 299 | + case 215: | ||
| 300 | + // 业务分组 | ||
| 301 | + deviceChannel.setStatus(true); | ||
| 302 | + if (!ObjectUtils.isEmpty(parentID)) { | ||
| 303 | + if (!parentID.trim().equalsIgnoreCase(device.getDeviceId())) { | ||
| 304 | + deviceChannel.setParentId(parentID); | ||
| 305 | + } | ||
| 306 | + }else { | ||
| 307 | + logger.warn("[xml解析] 业务分组数据中缺少关键信息->ParentId"); | ||
| 308 | + if (!ObjectUtils.isEmpty(civilCode)) { | ||
| 309 | + deviceChannel.setCivilCode(civilCode); | ||
| 310 | + } | ||
| 311 | + } | ||
| 312 | + break; | ||
| 313 | + case 216: | ||
| 314 | + // 虚拟组织 | ||
| 315 | + deviceChannel.setStatus(true); | ||
| 316 | + if (!ObjectUtils.isEmpty(businessGroupID)) { | ||
| 317 | + deviceChannel.setBusinessGroupId(businessGroupID); | ||
| 318 | + } | ||
| 318 | 319 | ||
| 319 | - Element statusElement = itemDevice.element("Status"); | ||
| 320 | 320 | ||
| 321 | - if (statusElement != null) { | ||
| 322 | - String status = statusElement.getTextTrim().trim(); | ||
| 323 | - // ONLINE OFFLINE HIKVISION DS-7716N-E4 NVR的兼容性处理 | ||
| 324 | - if (status.equals("ON") || status.equals("On") || status.equals("ONLINE") || status.equals("OK")) { | ||
| 325 | - deviceChannel.setStatus(true); | ||
| 326 | - } | ||
| 327 | - if (status.equals("OFF") || status.equals("Off") || status.equals("OFFLINE")) { | ||
| 328 | - deviceChannel.setStatus(false); | ||
| 329 | - } | ||
| 330 | - }else { | ||
| 331 | - deviceChannel.setStatus(true); | ||
| 332 | - } | ||
| 333 | - // 识别自带的目录标识 | ||
| 334 | - String parental = XmlUtil.getText(itemDevice, "Parental"); | ||
| 335 | - // 由于海康会错误的发送65535作为这里的取值,所以这里除非是0否则认为是1 | ||
| 336 | - if (!ObjectUtils.isEmpty(parental) && parental.length() == 1 && Integer.parseInt(parental) == 0) { | ||
| 337 | - deviceChannel.setParental(0); | ||
| 338 | - }else { | ||
| 339 | - deviceChannel.setParental(1); | ||
| 340 | - } | 321 | + if (!ObjectUtils.isEmpty(parentID)) { |
| 322 | + if (parentID.contains("/")) { | ||
| 323 | + String[] parentIdArray = parentID.split("/"); | ||
| 324 | + parentID = parentIdArray[parentIdArray.length - 1]; | ||
| 325 | + } | ||
| 326 | + deviceChannel.setParentId(parentID); | ||
| 327 | + }else { | ||
| 328 | + if (!ObjectUtils.isEmpty(businessGroupID)) { | ||
| 329 | + deviceChannel.setParentId(businessGroupID); | ||
| 330 | + } | ||
| 331 | + } | ||
| 332 | + break; | ||
| 333 | + default: | ||
| 334 | + // 设备目录 | ||
| 335 | + if (!ObjectUtils.isEmpty(manufacturer)) { | ||
| 336 | + deviceChannel.setManufacture(manufacturer); | ||
| 337 | + } | ||
| 338 | + if (!ObjectUtils.isEmpty(model)) { | ||
| 339 | + deviceChannel.setModel(model); | ||
| 340 | + } | ||
| 341 | + if (!ObjectUtils.isEmpty(owner)) { | ||
| 342 | + deviceChannel.setOwner(owner); | ||
| 343 | + } | ||
| 344 | + if (!ObjectUtils.isEmpty(civilCode)) { | ||
| 345 | + deviceChannel.setCivilCode(civilCode); | ||
| 346 | + } | ||
| 347 | + if (!ObjectUtils.isEmpty(businessGroupID)) { | ||
| 348 | + deviceChannel.setBusinessGroupId(businessGroupID); | ||
| 349 | + } | ||
| 341 | 350 | ||
| 351 | + // 警区 | ||
| 352 | + String block = getText(itemDevice, "Block"); | ||
| 353 | + if (!ObjectUtils.isEmpty(block)) { | ||
| 354 | + deviceChannel.setBlock(block); | ||
| 355 | + } | ||
| 356 | + if (!ObjectUtils.isEmpty(address)) { | ||
| 357 | + deviceChannel.setAddress(address); | ||
| 358 | + } | ||
| 342 | 359 | ||
| 343 | - deviceChannel.setManufacture(XmlUtil.getText(itemDevice, "Manufacturer")); | ||
| 344 | - deviceChannel.setModel(XmlUtil.getText(itemDevice, "Model")); | ||
| 345 | - deviceChannel.setOwner(XmlUtil.getText(itemDevice, "Owner")); | ||
| 346 | - deviceChannel.setCertNum(XmlUtil.getText(itemDevice, "CertNum")); | ||
| 347 | - deviceChannel.setBlock(XmlUtil.getText(itemDevice, "Block")); | ||
| 348 | - deviceChannel.setAddress(XmlUtil.getText(itemDevice, "Address")); | ||
| 349 | - deviceChannel.setPassword(XmlUtil.getText(itemDevice, "Password")); | 360 | + if (!ObjectUtils.isEmpty(secrecy)) { |
| 361 | + deviceChannel.setSecrecy(secrecy); | ||
| 362 | + } | ||
| 350 | 363 | ||
| 351 | - String safetyWay = XmlUtil.getText(itemDevice, "SafetyWay"); | ||
| 352 | - if (ObjectUtils.isEmpty(safetyWay)) { | ||
| 353 | - deviceChannel.setSafetyWay(0); | ||
| 354 | - } else { | ||
| 355 | - deviceChannel.setSafetyWay(Integer.parseInt(safetyWay)); | ||
| 356 | - } | 364 | + // 当为设备时,是否有子设备(必选)1有,0没有 |
| 365 | + String parental = getText(itemDevice, "Parental"); | ||
| 366 | + if (!ObjectUtils.isEmpty(parental)) { | ||
| 367 | + try { | ||
| 368 | + // 由于海康会错误的发送65535作为这里的取值,所以这里除非是0否则认为是1 | ||
| 369 | + if (!ObjectUtils.isEmpty(parental) && parental.length() == 1 && Integer.parseInt(parental) == 0) { | ||
| 370 | + deviceChannel.setParental(0); | ||
| 371 | + }else { | ||
| 372 | + deviceChannel.setParental(1); | ||
| 373 | + } | ||
| 374 | + }catch (NumberFormatException e) { | ||
| 375 | + logger.warn("[xml解析] 从通道数据获取 parental失败: {}", parental); | ||
| 376 | + } | ||
| 377 | + } | ||
| 378 | + // 父设备/区域/系统ID | ||
| 379 | + String realParentId = parentID; | ||
| 380 | + if (!ObjectUtils.isEmpty(parentID)) { | ||
| 381 | + if (parentID.contains("/")) { | ||
| 382 | + String[] parentIdArray = parentID.split("/"); | ||
| 383 | + realParentId = parentIdArray[parentIdArray.length - 1]; | ||
| 384 | + } | ||
| 385 | + deviceChannel.setParentId(realParentId); | ||
| 386 | + }else { | ||
| 387 | + if (!ObjectUtils.isEmpty(businessGroupID)) { | ||
| 388 | + deviceChannel.setParentId(businessGroupID); | ||
| 389 | + }else { | ||
| 390 | + if (!ObjectUtils.isEmpty(civilCode)) { | ||
| 391 | + deviceChannel.setParentId(civilCode); | ||
| 392 | + } | ||
| 393 | + } | ||
| 394 | + } | ||
| 395 | + // 注册方式 | ||
| 396 | + if (!ObjectUtils.isEmpty(registerWay)) { | ||
| 397 | + try { | ||
| 398 | + int registerWayInt = Integer.parseInt(registerWay); | ||
| 399 | + deviceChannel.setRegisterWay(registerWayInt); | ||
| 400 | + }catch (NumberFormatException exception) { | ||
| 401 | + logger.warn("[xml解析] 从通道数据获取registerWay失败: {}", registerWay); | ||
| 402 | + deviceChannel.setRegisterWay(1); | ||
| 403 | + } | ||
| 404 | + }else { | ||
| 405 | + deviceChannel.setRegisterWay(1); | ||
| 406 | + } | ||
| 357 | 407 | ||
| 358 | - String registerWay = XmlUtil.getText(itemDevice, "RegisterWay"); | ||
| 359 | - if (ObjectUtils.isEmpty(registerWay)) { | ||
| 360 | - deviceChannel.setRegisterWay(1); | ||
| 361 | - } else { | ||
| 362 | - deviceChannel.setRegisterWay(Integer.parseInt(registerWay)); | ||
| 363 | - } | 408 | + // 信令安全模式(可选)缺省为0; 0:不采用;2:S/MIME 签名方式;3:S/MIME加密签名同时采用方式;4:数字摘要方式 |
| 409 | + String safetyWay = getText(itemDevice, "SafetyWay"); | ||
| 410 | + if (!ObjectUtils.isEmpty(safetyWay)) { | ||
| 411 | + try { | ||
| 412 | + deviceChannel.setSafetyWay(Integer.parseInt(safetyWay)); | ||
| 413 | + }catch (NumberFormatException e) { | ||
| 414 | + logger.warn("[xml解析] 从通道数据获取 safetyWay失败: {}", safetyWay); | ||
| 415 | + } | ||
| 416 | + } | ||
| 364 | 417 | ||
| 365 | - if (XmlUtil.getText(itemDevice, "Certifiable") == null | ||
| 366 | - || XmlUtil.getText(itemDevice, "Certifiable") == "") { | ||
| 367 | - deviceChannel.setCertifiable(0); | ||
| 368 | - } else { | ||
| 369 | - deviceChannel.setCertifiable(Integer.parseInt(XmlUtil.getText(itemDevice, "Certifiable"))); | ||
| 370 | - } | 418 | + // 证书序列号(有证书的设备必选) |
| 419 | + String certNum = getText(itemDevice, "CertNum"); | ||
| 420 | + if (!ObjectUtils.isEmpty(certNum)) { | ||
| 421 | + deviceChannel.setCertNum(certNum); | ||
| 422 | + } | ||
| 371 | 423 | ||
| 372 | - if (XmlUtil.getText(itemDevice, "ErrCode") == null | ||
| 373 | - || XmlUtil.getText(itemDevice, "ErrCode") == "") { | ||
| 374 | - deviceChannel.setErrCode(0); | ||
| 375 | - } else { | ||
| 376 | - deviceChannel.setErrCode(Integer.parseInt(XmlUtil.getText(itemDevice, "ErrCode"))); | ||
| 377 | - } | 424 | + // 证书有效标识(有证书的设备必选)缺省为0;证书有效标识:0:无效 1:有效 |
| 425 | + String certifiable = getText(itemDevice, "Certifiable"); | ||
| 426 | + if (!ObjectUtils.isEmpty(certifiable)) { | ||
| 427 | + try { | ||
| 428 | + deviceChannel.setCertifiable(Integer.parseInt(certifiable)); | ||
| 429 | + }catch (NumberFormatException e) { | ||
| 430 | + logger.warn("[xml解析] 从通道数据获取 Certifiable失败: {}", certifiable); | ||
| 431 | + } | ||
| 432 | + } | ||
| 378 | 433 | ||
| 379 | - deviceChannel.setEndTime(XmlUtil.getText(itemDevice, "EndTime")); | ||
| 380 | - deviceChannel.setSecrecy(XmlUtil.getText(itemDevice, "Secrecy")); | ||
| 381 | - deviceChannel.setIpAddress(XmlUtil.getText(itemDevice, "IPAddress")); | ||
| 382 | - if (XmlUtil.getText(itemDevice, "Port") == null || XmlUtil.getText(itemDevice, "Port") == "") { | ||
| 383 | - deviceChannel.setPort(0); | ||
| 384 | - } else { | ||
| 385 | - deviceChannel.setPort(Integer.parseInt(XmlUtil.getText(itemDevice, "Port"))); | ||
| 386 | - } | 434 | + // 无效原因码(有证书且证书无效的设备必选) |
| 435 | + String errCode = getText(itemDevice, "ErrCode"); | ||
| 436 | + if (!ObjectUtils.isEmpty(errCode)) { | ||
| 437 | + try { | ||
| 438 | + deviceChannel.setErrCode(Integer.parseInt(errCode)); | ||
| 439 | + }catch (NumberFormatException e) { | ||
| 440 | + logger.warn("[xml解析] 从通道数据获取 ErrCode失败: {}", errCode); | ||
| 441 | + } | ||
| 442 | + } | ||
| 387 | 443 | ||
| 444 | + // 证书终止有效期(有证书的设备必选) | ||
| 445 | + String endTime = getText(itemDevice, "EndTime"); | ||
| 446 | + if (!ObjectUtils.isEmpty(endTime)) { | ||
| 447 | + deviceChannel.setEndTime(endTime); | ||
| 448 | + } | ||
| 388 | 449 | ||
| 389 | - String longitude = XmlUtil.getText(itemDevice, "Longitude"); | ||
| 390 | - if (NumericUtil.isDouble(longitude)) { | ||
| 391 | - deviceChannel.setLongitude(Double.parseDouble(longitude)); | ||
| 392 | - } else { | ||
| 393 | - deviceChannel.setLongitude(0.00); | ||
| 394 | - } | ||
| 395 | - String latitude = XmlUtil.getText(itemDevice, "Latitude"); | ||
| 396 | - if (NumericUtil.isDouble(latitude)) { | ||
| 397 | - deviceChannel.setLatitude(Double.parseDouble(latitude)); | ||
| 398 | - } else { | ||
| 399 | - deviceChannel.setLatitude(0.00); | ||
| 400 | - } | ||
| 401 | 450 | ||
| 402 | - deviceChannel.setGpsTime(DateUtil.getNow()); | 451 | + // 设备/区域/系统IP地址 |
| 452 | + String ipAddress = getText(itemDevice, "IPAddress"); | ||
| 453 | + if (!ObjectUtils.isEmpty(ipAddress)) { | ||
| 454 | + deviceChannel.setIpAddress(ipAddress); | ||
| 455 | + } | ||
| 456 | + | ||
| 457 | + // 设备/区域/系统端口 | ||
| 458 | + String port = getText(itemDevice, "Port"); | ||
| 459 | + if (!ObjectUtils.isEmpty(port)) { | ||
| 460 | + try { | ||
| 461 | + deviceChannel.setPort(Integer.parseInt(port)); | ||
| 462 | + }catch (NumberFormatException e) { | ||
| 463 | + logger.warn("[xml解析] 从通道数据获取 Port失败: {}", port); | ||
| 464 | + } | ||
| 465 | + } | ||
| 466 | + | ||
| 467 | + // 设备口令 | ||
| 468 | + String password = getText(itemDevice, "Password"); | ||
| 469 | + if (!ObjectUtils.isEmpty(password)) { | ||
| 470 | + deviceChannel.setPassword(password); | ||
| 471 | + } | ||
| 472 | + | ||
| 403 | 473 | ||
| 474 | + // 设备状态 | ||
| 475 | + String status = getText(itemDevice, "Status"); | ||
| 476 | + if (status != null) { | ||
| 477 | + // ONLINE OFFLINE HIKVISION DS-7716N-E4 NVR的兼容性处理 | ||
| 478 | + if (status.equals("ON") || status.equals("On") || status.equals("ONLINE") || status.equals("OK")) { | ||
| 479 | + deviceChannel.setStatus(true); | ||
| 480 | + } | ||
| 481 | + if (status.equals("OFF") || status.equals("Off") || status.equals("OFFLINE")) { | ||
| 482 | + deviceChannel.setStatus(false); | ||
| 483 | + } | ||
| 484 | + }else { | ||
| 485 | + deviceChannel.setStatus(true); | ||
| 486 | + } | ||
| 487 | + | ||
| 488 | + // 经度 | ||
| 489 | + String longitude = getText(itemDevice, "Longitude"); | ||
| 490 | + if (NumericUtil.isDouble(longitude)) { | ||
| 491 | + deviceChannel.setLongitude(Double.parseDouble(longitude)); | ||
| 492 | + } else { | ||
| 493 | + deviceChannel.setLongitude(0.00); | ||
| 494 | + } | ||
| 495 | + | ||
| 496 | + // 纬度 | ||
| 497 | + String latitude = getText(itemDevice, "Latitude"); | ||
| 498 | + if (NumericUtil.isDouble(latitude)) { | ||
| 499 | + deviceChannel.setLatitude(Double.parseDouble(latitude)); | ||
| 500 | + } else { | ||
| 501 | + deviceChannel.setLatitude(0.00); | ||
| 502 | + } | ||
| 503 | + | ||
| 504 | + deviceChannel.setGpsTime(DateUtil.getNow()); | ||
| 505 | + | ||
| 506 | + // -摄像机类型扩展,标识摄像机类型:1-球机;2-半球;3-固定枪机;4-遥控枪机。当目录项为摄像机时可选 | ||
| 507 | + String ptzType = getText(itemDevice, "PTZType"); | ||
| 508 | + if (ObjectUtils.isEmpty(ptzType)) { | ||
| 509 | + //兼容INFO中的信息 | ||
| 510 | + Element info = itemDevice.element("Info"); | ||
| 511 | + String ptzTypeFromInfo = XmlUtil.getText(info, "PTZType"); | ||
| 512 | + if(!ObjectUtils.isEmpty(ptzTypeFromInfo)){ | ||
| 513 | + try { | ||
| 514 | + deviceChannel.setPTZType(Integer.parseInt(ptzTypeFromInfo)); | ||
| 515 | + }catch (NumberFormatException e){ | ||
| 516 | + logger.warn("[xml解析] 从通道数据info中获取PTZType失败: {}", ptzTypeFromInfo); | ||
| 517 | + } | ||
| 518 | + } | ||
| 519 | + } else { | ||
| 520 | + try { | ||
| 521 | + deviceChannel.setPTZType(Integer.parseInt(ptzType)); | ||
| 522 | + }catch (NumberFormatException e){ | ||
| 523 | + logger.warn("[xml解析] 从通道数据中获取PTZType失败: {}", ptzType); | ||
| 524 | + } | ||
| 525 | + } | ||
| 404 | 526 | ||
| 405 | - if (XmlUtil.getText(itemDevice, "PTZType") == null || "".equals(XmlUtil.getText(itemDevice, "PTZType"))) { | ||
| 406 | - //兼容INFO中的信息 | ||
| 407 | - Element info = itemDevice.element("Info"); | ||
| 408 | - if(XmlUtil.getText(info, "PTZType") == null || "".equals(XmlUtil.getText(info, "PTZType"))){ | ||
| 409 | - deviceChannel.setPTZType(0); | ||
| 410 | - }else{ | ||
| 411 | - deviceChannel.setPTZType(Integer.parseInt(XmlUtil.getText(info, "PTZType"))); | 527 | + // TODO 摄像机位置类型扩展。 |
| 528 | + // 1-省际检查站、 | ||
| 529 | + // 2-党政机关、 | ||
| 530 | + // 3-车站码头、 | ||
| 531 | + // 4-中心广场、 | ||
| 532 | + // 5-体育场馆、 | ||
| 533 | + // 6-商业中心、 | ||
| 534 | + // 7-宗教场所、 | ||
| 535 | + // 8-校园周边、 | ||
| 536 | + // 9-治安复杂区域、 | ||
| 537 | + // 10-交通干线。 | ||
| 538 | + // String positionType = getText(itemDevice, "PositionType"); | ||
| 539 | + | ||
| 540 | + // TODO 摄像机安装位置室外、室内属性。1-室外、2-室内。 | ||
| 541 | + // String roomType = getText(itemDevice, "RoomType"); | ||
| 542 | + // TODO 摄像机用途属性 | ||
| 543 | + // String useType = getText(itemDevice, "UseType"); | ||
| 544 | + // TODO 摄像机补光属性。1-无补光、2-红外补光、3-白光补光 | ||
| 545 | + // String supplyLightType = getText(itemDevice, "SupplyLightType"); | ||
| 546 | + // TODO 摄像机监视方位属性。1-东、2-西、3-南、4-北、5-东南、6-东北、7-西南、8-西北。 | ||
| 547 | + // String directionType = getText(itemDevice, "DirectionType"); | ||
| 548 | + // TODO 摄像机支持的分辨率,可有多个分辨率值,各个取值间以“/”分隔。分辨率取值参见附录 F中SDPf字段规定 | ||
| 549 | + // String resolution = getText(itemDevice, "Resolution"); | ||
| 550 | + | ||
| 551 | + // TODO 下载倍速范围(可选),各可选参数以“/”分隔,如设备支持1,2,4倍速下载则应写为“1/2/4 | ||
| 552 | + // String downloadSpeed = getText(itemDevice, "DownloadSpeed"); | ||
| 553 | + // TODO 空域编码能力,取值0:不支持;1:1级增强(1个增强层);2:2级增强(2个增强层);3:3级增强(3个增强层) | ||
| 554 | + // String svcSpaceSupportMode = getText(itemDevice, "SVCSpaceSupportMode"); | ||
| 555 | + // TODO 时域编码能力,取值0:不支持;1:1级增强;2:2级增强;3:3级增强 | ||
| 556 | + // String svcTimeSupportMode = getText(itemDevice, "SVCTimeSupportMode"); | ||
| 557 | + | ||
| 558 | + | ||
| 559 | + deviceChannel.setSecrecy(secrecy); | ||
| 560 | + break; | ||
| 412 | } | 561 | } |
| 413 | - } else { | ||
| 414 | - deviceChannel.setPTZType(Integer.parseInt(XmlUtil.getText(itemDevice, "PTZType"))); | ||
| 415 | } | 562 | } |
| 416 | 563 | ||
| 417 | return deviceChannel; | 564 | return deviceChannel; |
src/main/java/com/genersoft/iot/vmp/service/impl/DeviceChannelServiceImpl.java
| @@ -50,8 +50,6 @@ public class DeviceChannelServiceImpl implements IDeviceChannelService { | @@ -50,8 +50,6 @@ public class DeviceChannelServiceImpl implements IDeviceChannelService { | ||
| 50 | device = deviceMapper.getDeviceByDeviceId(deviceChannel.getDeviceId()); | 50 | device = deviceMapper.getDeviceByDeviceId(deviceChannel.getDeviceId()); |
| 51 | } | 51 | } |
| 52 | 52 | ||
| 53 | - | ||
| 54 | - | ||
| 55 | if ("WGS84".equals(device.getGeoCoordSys())) { | 53 | if ("WGS84".equals(device.getGeoCoordSys())) { |
| 56 | deviceChannel.setLongitudeWgs84(deviceChannel.getLongitude()); | 54 | deviceChannel.setLongitudeWgs84(deviceChannel.getLongitude()); |
| 57 | deviceChannel.setLatitudeWgs84(deviceChannel.getLatitude()); | 55 | deviceChannel.setLatitudeWgs84(deviceChannel.getLatitude()); |
| @@ -262,4 +260,6 @@ public class DeviceChannelServiceImpl implements IDeviceChannelService { | @@ -262,4 +260,6 @@ public class DeviceChannelServiceImpl implements IDeviceChannelService { | ||
| 262 | } | 260 | } |
| 263 | } | 261 | } |
| 264 | } | 262 | } |
| 263 | + | ||
| 264 | + | ||
| 265 | } | 265 | } |
src/main/java/com/genersoft/iot/vmp/service/impl/DeviceServiceImpl.java
| @@ -122,9 +122,10 @@ public class DeviceServiceImpl implements IDeviceService { | @@ -122,9 +122,10 @@ public class DeviceServiceImpl implements IDeviceService { | ||
| 122 | } | 122 | } |
| 123 | 123 | ||
| 124 | // 第一次上线 或则设备之前是离线状态--进行通道同步和设备信息查询 | 124 | // 第一次上线 或则设备之前是离线状态--进行通道同步和设备信息查询 |
| 125 | - if (device.getCreateTime() == null) { | 125 | + if (deviceInDb == null) { |
| 126 | device.setOnLine(true); | 126 | device.setOnLine(true); |
| 127 | device.setCreateTime(now); | 127 | device.setCreateTime(now); |
| 128 | + device.setUpdateTime(now); | ||
| 128 | logger.info("[设备上线,首次注册]: {},查询设备信息以及通道信息", device.getDeviceId()); | 129 | logger.info("[设备上线,首次注册]: {},查询设备信息以及通道信息", device.getDeviceId()); |
| 129 | deviceMapper.add(device); | 130 | deviceMapper.add(device); |
| 130 | redisCatchStorage.updateDevice(device); | 131 | redisCatchStorage.updateDevice(device); |
| @@ -389,63 +390,11 @@ public class DeviceServiceImpl implements IDeviceService { | @@ -389,63 +390,11 @@ public class DeviceServiceImpl implements IDeviceService { | ||
| 389 | if (device == null) { | 390 | if (device == null) { |
| 390 | return null; | 391 | return null; |
| 391 | } | 392 | } |
| 392 | - if (parentId == null || parentId.equals(deviceId)) { | ||
| 393 | - // 字根节点开始查询 | ||
| 394 | - List<DeviceChannel> rootNodes = getRootNodes(deviceId, TreeType.CIVIL_CODE.equals(device.getTreeType()), true, !onlyCatalog); | ||
| 395 | - return transportChannelsToTree(rootNodes, ""); | 393 | + if (ObjectUtils.isEmpty(parentId) || parentId.equals(deviceId)) { |
| 394 | + parentId = null; | ||
| 396 | } | 395 | } |
| 397 | - | ||
| 398 | - if (TreeType.CIVIL_CODE.equals(device.getTreeType())) { | ||
| 399 | - if (parentId.length()%2 != 0) { | ||
| 400 | - return null; | ||
| 401 | - } | ||
| 402 | - // 使用行政区划展示树 | ||
| 403 | -// if (parentId.length() > 10) { | ||
| 404 | -// // TODO 可能是行政区划与业务分组混杂的情形 | ||
| 405 | -// return null; | ||
| 406 | -// } | ||
| 407 | - | ||
| 408 | - if (parentId.length() == 10 ) { | ||
| 409 | - if (onlyCatalog) { | ||
| 410 | - return null; | ||
| 411 | - } | ||
| 412 | - // parentId为行业编码, 其下不会再有行政区划 | ||
| 413 | - List<DeviceChannel> channels = deviceChannelMapper.getChannelsByCivilCode(deviceId, parentId); | ||
| 414 | - List<BaseTree<DeviceChannel>> trees = transportChannelsToTree(channels, parentId); | ||
| 415 | - return trees; | ||
| 416 | - } | ||
| 417 | - // 查询其下的行政区划和摄像机 | ||
| 418 | - List<DeviceChannel> channelsForCivilCode = deviceChannelMapper.getChannelsWithCivilCodeAndLength(deviceId, parentId, parentId.length() + 2); | ||
| 419 | - if (!onlyCatalog) { | ||
| 420 | - List<DeviceChannel> channels = deviceChannelMapper.getChannelsByCivilCode(deviceId, parentId); | ||
| 421 | - | ||
| 422 | - for(DeviceChannel channel : channels) { | ||
| 423 | - boolean flag = false; | ||
| 424 | - for(DeviceChannel deviceChannel : channelsForCivilCode) { | ||
| 425 | - if(channel.getChannelId().equals(deviceChannel.getChannelId())) { | ||
| 426 | - flag = true; | ||
| 427 | - } | ||
| 428 | - } | ||
| 429 | - if(!flag) { | ||
| 430 | - channelsForCivilCode.add(channel); | ||
| 431 | - } | ||
| 432 | - } | ||
| 433 | - } | ||
| 434 | - List<BaseTree<DeviceChannel>> trees = transportChannelsToTree(channelsForCivilCode, parentId); | ||
| 435 | - return trees; | ||
| 436 | - | ||
| 437 | - } | ||
| 438 | - // 使用业务分组展示树 | ||
| 439 | - if (TreeType.BUSINESS_GROUP.equals(device.getTreeType())) { | ||
| 440 | - if (parentId.length() < 14 ) { | ||
| 441 | - return null; | ||
| 442 | - } | ||
| 443 | - List<DeviceChannel> deviceChannels = deviceChannelMapper.queryChannels(deviceId, parentId, null, null, null,null); | ||
| 444 | - List<BaseTree<DeviceChannel>> trees = transportChannelsToTree(deviceChannels, parentId); | ||
| 445 | - return trees; | ||
| 446 | - } | ||
| 447 | - | ||
| 448 | - return null; | 396 | + List<DeviceChannel> rootNodes = deviceChannelMapper.getSubChannelsByDeviceId(deviceId, parentId, onlyCatalog); |
| 397 | + return transportChannelsToTree(rootNodes, ""); | ||
| 449 | } | 398 | } |
| 450 | 399 | ||
| 451 | @Override | 400 | @Override |
| @@ -454,42 +403,11 @@ public class DeviceServiceImpl implements IDeviceService { | @@ -454,42 +403,11 @@ public class DeviceServiceImpl implements IDeviceService { | ||
| 454 | if (device == null) { | 403 | if (device == null) { |
| 455 | return null; | 404 | return null; |
| 456 | } | 405 | } |
| 457 | - if (parentId == null || parentId.equals(deviceId)) { | ||
| 458 | - // 字根节点开始查询 | ||
| 459 | - List<DeviceChannel> rootNodes = getRootNodes(deviceId, TreeType.CIVIL_CODE.equals(device.getTreeType()), false, true); | ||
| 460 | - return rootNodes; | ||
| 461 | - } | ||
| 462 | - | ||
| 463 | - if (TreeType.CIVIL_CODE.equals(device.getTreeType())) { | ||
| 464 | - if (parentId.length()%2 != 0) { | ||
| 465 | - return null; | ||
| 466 | - } | ||
| 467 | - // 使用行政区划展示树 | ||
| 468 | - if (parentId.length() > 10) { | ||
| 469 | - // TODO 可能是行政区划与业务分组混杂的情形 | ||
| 470 | - return null; | ||
| 471 | - } | ||
| 472 | - | ||
| 473 | - if (parentId.length() == 10 ) { | ||
| 474 | - // parentId为行业编码, 其下不会再有行政区划 | ||
| 475 | - List<DeviceChannel> channels = deviceChannelMapper.getChannelsByCivilCode(deviceId, parentId); | ||
| 476 | - return channels; | ||
| 477 | - } | ||
| 478 | - // 查询其下的行政区划和摄像机 | ||
| 479 | - List<DeviceChannel> channels = deviceChannelMapper.getChannelsByCivilCode(deviceId, parentId); | ||
| 480 | - return channels; | ||
| 481 | - | ||
| 482 | - } | ||
| 483 | - // 使用业务分组展示树 | ||
| 484 | - if (TreeType.BUSINESS_GROUP.equals(device.getTreeType())) { | ||
| 485 | - if (parentId.length() < 14 ) { | ||
| 486 | - return null; | ||
| 487 | - } | ||
| 488 | - List<DeviceChannel> deviceChannels = deviceChannelMapper.queryChannels(deviceId, parentId, null, null, null,null); | ||
| 489 | - return deviceChannels; | 406 | + if (ObjectUtils.isEmpty(parentId) || parentId.equals(deviceId)) { |
| 407 | + return deviceChannelMapper.getSubChannelsByDeviceId(deviceId, null, false); | ||
| 408 | + }else { | ||
| 409 | + return deviceChannelMapper.getSubChannelsByDeviceId(deviceId, parentId, false); | ||
| 490 | } | 410 | } |
| 491 | - | ||
| 492 | - return null; | ||
| 493 | } | 411 | } |
| 494 | 412 | ||
| 495 | private List<BaseTree<DeviceChannel>> transportChannelsToTree(List<DeviceChannel> channels, String parentId) { | 413 | private List<BaseTree<DeviceChannel>> transportChannelsToTree(List<DeviceChannel> channels, String parentId) { |
| @@ -509,65 +427,26 @@ public class DeviceServiceImpl implements IDeviceService { | @@ -509,65 +427,26 @@ public class DeviceServiceImpl implements IDeviceService { | ||
| 509 | node.setPid(parentId); | 427 | node.setPid(parentId); |
| 510 | node.setBasicData(channel); | 428 | node.setBasicData(channel); |
| 511 | node.setParent(false); | 429 | node.setParent(false); |
| 512 | - if (channel.getChannelId().length() > 8) { | ||
| 513 | - if (channel.getChannelId().length() > 13) { | ||
| 514 | - String gbCodeType = channel.getChannelId().substring(10, 13); | ||
| 515 | - node.setParent(gbCodeType.equals(ChannelIdType.BUSINESS_GROUP) || gbCodeType.equals(ChannelIdType.VIRTUAL_ORGANIZATION) ); | ||
| 516 | - } | ||
| 517 | - }else { | 430 | + if (channel.getChannelId().length() <= 8) { |
| 518 | node.setParent(true); | 431 | node.setParent(true); |
| 519 | - } | ||
| 520 | - treeNotes.add(node); | ||
| 521 | - } | ||
| 522 | - Collections.sort(treeNotes); | ||
| 523 | - return treeNotes; | ||
| 524 | - } | ||
| 525 | - | ||
| 526 | - private List<DeviceChannel> getRootNodes(String deviceId, boolean isCivilCode, boolean haveCatalog, boolean haveChannel) { | ||
| 527 | - if (!haveCatalog && !haveChannel) { | ||
| 528 | - return null; | ||
| 529 | - } | ||
| 530 | - List<DeviceChannel> result = new ArrayList<>(); | ||
| 531 | - if (isCivilCode) { | ||
| 532 | - // 使用行政区划 | ||
| 533 | - Integer length= deviceChannelMapper.getChannelMinLength(deviceId); | ||
| 534 | - if (length == null) { | ||
| 535 | - return null; | ||
| 536 | - } | ||
| 537 | - if (length <= 10) { | ||
| 538 | - if (haveCatalog) { | ||
| 539 | - List<DeviceChannel> provinceNode = deviceChannelMapper.getChannelsWithCivilCodeAndLength(deviceId, null, length); | ||
| 540 | - if (provinceNode != null && provinceNode.size() > 0) { | ||
| 541 | - result.addAll(provinceNode); | ||
| 542 | - } | ||
| 543 | - } | ||
| 544 | - | ||
| 545 | - if (haveChannel) { | ||
| 546 | - // 查询那些civilCode不在通道中的不规范通道,放置在根目录 | ||
| 547 | - List<DeviceChannel> nonstandardNode = deviceChannelMapper.getChannelWithoutCivilCode(deviceId); | ||
| 548 | - if (nonstandardNode != null && nonstandardNode.size() > 0) { | ||
| 549 | - result.addAll(nonstandardNode); | ||
| 550 | - } | ||
| 551 | - } | ||
| 552 | }else { | 432 | }else { |
| 553 | - if (haveChannel) { | ||
| 554 | - List<DeviceChannel> deviceChannels = deviceChannelMapper.queryChannels(deviceId, null, null, null, null,null); | ||
| 555 | - if (deviceChannels != null && deviceChannels.size() > 0) { | ||
| 556 | - result.addAll(deviceChannels); | 433 | + if (channel.getChannelId().length() != 20) { |
| 434 | + node.setParent(channel.getParental() == 1); | ||
| 435 | + }else { | ||
| 436 | + try { | ||
| 437 | + int type = Integer.parseInt(channel.getChannelId().substring(10, 13)); | ||
| 438 | + if (type == 215 || type == 216 || type == 200) { | ||
| 439 | + node.setParent(true); | ||
| 440 | + } | ||
| 441 | + }catch (NumberFormatException e) { | ||
| 442 | + node.setParent(false); | ||
| 557 | } | 443 | } |
| 558 | } | 444 | } |
| 559 | } | 445 | } |
| 560 | - | ||
| 561 | - }else { | ||
| 562 | - // 使用业务分组+虚拟组织 | ||
| 563 | - | ||
| 564 | - // 只获取业务分组 | ||
| 565 | - List<DeviceChannel> deviceChannels = deviceChannelMapper.getBusinessGroups(deviceId, ChannelIdType.BUSINESS_GROUP); | ||
| 566 | - if (deviceChannels != null && deviceChannels.size() > 0) { | ||
| 567 | - result.addAll(deviceChannels); | ||
| 568 | - } | 446 | + treeNotes.add(node); |
| 569 | } | 447 | } |
| 570 | - return result; | 448 | + Collections.sort(treeNotes); |
| 449 | + return treeNotes; | ||
| 571 | } | 450 | } |
| 572 | 451 | ||
| 573 | @Override | 452 | @Override |
| @@ -617,7 +496,6 @@ public class DeviceServiceImpl implements IDeviceService { | @@ -617,7 +496,6 @@ public class DeviceServiceImpl implements IDeviceService { | ||
| 617 | } | 496 | } |
| 618 | deviceInStore.setSdpIp(device.getSdpIp()); | 497 | deviceInStore.setSdpIp(device.getSdpIp()); |
| 619 | deviceInStore.setCharset(device.getCharset()); | 498 | deviceInStore.setCharset(device.getCharset()); |
| 620 | - deviceInStore.setTreeType(device.getTreeType()); | ||
| 621 | 499 | ||
| 622 | // 目录订阅相关的信息 | 500 | // 目录订阅相关的信息 |
| 623 | if (device.getSubscribeCycleForCatalog() > 0) { | 501 | if (device.getSubscribeCycleForCatalog() > 0) { |
| @@ -673,6 +551,9 @@ public class DeviceServiceImpl implements IDeviceService { | @@ -673,6 +551,9 @@ public class DeviceServiceImpl implements IDeviceService { | ||
| 673 | }catch (Exception e) { | 551 | }catch (Exception e) { |
| 674 | dataSourceTransactionManager.rollback(transactionStatus); | 552 | dataSourceTransactionManager.rollback(transactionStatus); |
| 675 | } | 553 | } |
| 554 | + if (result) { | ||
| 555 | + redisCatchStorage.removeDevice(deviceId); | ||
| 556 | + } | ||
| 676 | return result; | 557 | return result; |
| 677 | } | 558 | } |
| 678 | 559 |
src/main/java/com/genersoft/iot/vmp/service/impl/GbStreamServiceImpl.java
| @@ -113,20 +113,15 @@ public class GbStreamServiceImpl implements IGbStreamService { | @@ -113,20 +113,15 @@ public class GbStreamServiceImpl implements IGbStreamService { | ||
| 113 | deviceChannel.setStatus(gbStream.isStatus()); | 113 | deviceChannel.setStatus(gbStream.isStatus()); |
| 114 | 114 | ||
| 115 | deviceChannel.setRegisterWay(1); | 115 | deviceChannel.setRegisterWay(1); |
| 116 | - deviceChannel.setCivilCode(platform.getAdministrativeDivision()); | ||
| 117 | - | ||
| 118 | - if (platform.getTreeType().equals(TreeType.CIVIL_CODE)){ | ||
| 119 | - deviceChannel.setCivilCode(catalogId); | ||
| 120 | - }else if (platform.getTreeType().equals(TreeType.BUSINESS_GROUP)){ | ||
| 121 | - PlatformCatalog catalog = catalogMapper.select(catalogId); | ||
| 122 | - if (catalog == null) { | ||
| 123 | - deviceChannel.setParentId(platform.getDeviceGBId()); | ||
| 124 | - deviceChannel.setBusinessGroupId(null); | ||
| 125 | - }else { | ||
| 126 | - deviceChannel.setParentId(catalog.getId()); | ||
| 127 | - deviceChannel.setBusinessGroupId(catalog.getBusinessGroupId()); | ||
| 128 | - } | ||
| 129 | 116 | ||
| 117 | + PlatformCatalog catalog = catalogMapper.select(catalogId); | ||
| 118 | + if (catalog != null) { | ||
| 119 | + deviceChannel.setCivilCode(catalog.getCivilCode()); | ||
| 120 | + deviceChannel.setParentId(catalog.getParentId()); | ||
| 121 | + deviceChannel.setBusinessGroupId(catalog.getBusinessGroupId()); | ||
| 122 | + }else { | ||
| 123 | + deviceChannel.setCivilCode(platform.getAdministrativeDivision()); | ||
| 124 | + deviceChannel.setParentId(platform.getDeviceGBId()); | ||
| 130 | } | 125 | } |
| 131 | 126 | ||
| 132 | deviceChannel.setModel("live"); | 127 | deviceChannel.setModel("live"); |
| @@ -221,20 +216,14 @@ public class GbStreamServiceImpl implements IGbStreamService { | @@ -221,20 +216,14 @@ public class GbStreamServiceImpl implements IGbStreamService { | ||
| 221 | deviceChannel.setStatus(status != null && status); | 216 | deviceChannel.setStatus(status != null && status); |
| 222 | 217 | ||
| 223 | deviceChannel.setRegisterWay(1); | 218 | deviceChannel.setRegisterWay(1); |
| 224 | - deviceChannel.setCivilCode(platform.getAdministrativeDivision()); | ||
| 225 | - | ||
| 226 | - if (platform.getTreeType().equals(TreeType.CIVIL_CODE)){ | ||
| 227 | - deviceChannel.setCivilCode(catalogId); | ||
| 228 | - }else if (platform.getTreeType().equals(TreeType.BUSINESS_GROUP)){ | ||
| 229 | - PlatformCatalog catalog = catalogMapper.select(catalogId); | ||
| 230 | - if (catalog == null) { | ||
| 231 | - deviceChannel.setParentId(platform.getDeviceGBId()); | ||
| 232 | - deviceChannel.setBusinessGroupId(null); | ||
| 233 | - }else { | ||
| 234 | - deviceChannel.setParentId(catalog.getId()); | ||
| 235 | - deviceChannel.setBusinessGroupId(catalog.getBusinessGroupId()); | ||
| 236 | - } | ||
| 237 | - | 219 | + PlatformCatalog catalog = catalogMapper.select(catalogId); |
| 220 | + if (catalog != null) { | ||
| 221 | + deviceChannel.setCivilCode(catalog.getCivilCode()); | ||
| 222 | + deviceChannel.setParentId(catalog.getParentId()); | ||
| 223 | + deviceChannel.setBusinessGroupId(catalog.getBusinessGroupId()); | ||
| 224 | + }else { | ||
| 225 | + deviceChannel.setCivilCode(platform.getAdministrativeDivision()); | ||
| 226 | + deviceChannel.setParentId(platform.getDeviceGBId()); | ||
| 238 | } | 227 | } |
| 239 | 228 | ||
| 240 | deviceChannel.setModel("live"); | 229 | deviceChannel.setModel("live"); |
src/main/java/com/genersoft/iot/vmp/service/impl/PlatformChannelServiceImpl.java
| @@ -126,22 +126,17 @@ public class PlatformChannelServiceImpl implements IPlatformChannelService { | @@ -126,22 +126,17 @@ public class PlatformChannelServiceImpl implements IPlatformChannelService { | ||
| 126 | List<DeviceChannel> deviceChannelList = new ArrayList<>(); | 126 | List<DeviceChannel> deviceChannelList = new ArrayList<>(); |
| 127 | if (channelReduces.size() > 0){ | 127 | if (channelReduces.size() > 0){ |
| 128 | PlatformCatalog catalog = catalogManager.select(catalogId); | 128 | PlatformCatalog catalog = catalogManager.select(catalogId); |
| 129 | - if (catalog == null && !catalogId.equals(platform.getDeviceGBId())) { | 129 | + if (catalog == null || !catalogId.equals(platform.getDeviceGBId())) { |
| 130 | logger.warn("未查询到目录{}的信息", catalogId); | 130 | logger.warn("未查询到目录{}的信息", catalogId); |
| 131 | return null; | 131 | return null; |
| 132 | } | 132 | } |
| 133 | for (ChannelReduce channelReduce : channelReduces) { | 133 | for (ChannelReduce channelReduce : channelReduces) { |
| 134 | DeviceChannel deviceChannel = deviceChannelMapper.queryChannel(channelReduce.getDeviceId(), channelReduce.getChannelId()); | 134 | DeviceChannel deviceChannel = deviceChannelMapper.queryChannel(channelReduce.getDeviceId(), channelReduce.getChannelId()); |
| 135 | deviceChannel.setParental(0); | 135 | deviceChannel.setParental(0); |
| 136 | + deviceChannel.setCivilCode(catalog.getCivilCode()); | ||
| 137 | + deviceChannel.setParentId(catalog.getParentId()); | ||
| 138 | + deviceChannel.setBusinessGroupId(catalog.getBusinessGroupId()); | ||
| 136 | deviceChannelList.add(deviceChannel); | 139 | deviceChannelList.add(deviceChannel); |
| 137 | - if (platform.getTreeType().equals(TreeType.CIVIL_CODE)){ | ||
| 138 | - deviceChannel.setCivilCode(catalogId); | ||
| 139 | - }else if (platform.getTreeType().equals(TreeType.BUSINESS_GROUP)){ | ||
| 140 | - deviceChannel.setParentId(catalogId); | ||
| 141 | - if (catalog != null) { | ||
| 142 | - deviceChannel.setBusinessGroupId(catalog.getBusinessGroupId()); | ||
| 143 | - } | ||
| 144 | - } | ||
| 145 | } | 140 | } |
| 146 | } | 141 | } |
| 147 | return deviceChannelList; | 142 | return deviceChannelList; |
src/main/java/com/genersoft/iot/vmp/service/impl/PlatformServiceImpl.java
| @@ -35,6 +35,8 @@ import java.util.Map; | @@ -35,6 +35,8 @@ import java.util.Map; | ||
| 35 | public class PlatformServiceImpl implements IPlatformService { | 35 | public class PlatformServiceImpl implements IPlatformService { |
| 36 | 36 | ||
| 37 | private final static String REGISTER_KEY_PREFIX = "platform_register_"; | 37 | private final static String REGISTER_KEY_PREFIX = "platform_register_"; |
| 38 | + | ||
| 39 | + private final static String REGISTER_FAIL_AGAIN_KEY_PREFIX = "platform_register_fail_again_"; | ||
| 38 | private final static String KEEPALIVE_KEY_PREFIX = "platform_keepalive_"; | 40 | private final static String KEEPALIVE_KEY_PREFIX = "platform_keepalive_"; |
| 39 | 41 | ||
| 40 | private final static Logger logger = LoggerFactory.getLogger(PlatformServiceImpl.class); | 42 | private final static Logger logger = LoggerFactory.getLogger(PlatformServiceImpl.class); |
| @@ -132,14 +134,6 @@ public class PlatformServiceImpl implements IPlatformService { | @@ -132,14 +134,6 @@ public class PlatformServiceImpl implements IPlatformService { | ||
| 132 | ParentPlatform parentPlatformOld = platformMapper.getParentPlatById(parentPlatform.getId()); | 134 | ParentPlatform parentPlatformOld = platformMapper.getParentPlatById(parentPlatform.getId()); |
| 133 | ParentPlatformCatch parentPlatformCatchOld = redisCatchStorage.queryPlatformCatchInfo(parentPlatformOld.getServerGBId()); | 135 | ParentPlatformCatch parentPlatformCatchOld = redisCatchStorage.queryPlatformCatchInfo(parentPlatformOld.getServerGBId()); |
| 134 | parentPlatform.setUpdateTime(DateUtil.getNow()); | 136 | parentPlatform.setUpdateTime(DateUtil.getNow()); |
| 135 | - if (!parentPlatformOld.getTreeType().equals(parentPlatform.getTreeType())) { | ||
| 136 | - // 目录结构发生变化,清空之前的关联关系 | ||
| 137 | - logger.info("保存平台{}时发现目录结构变化,清空关联关系", parentPlatform.getDeviceGBId()); | ||
| 138 | - catalogMapper.delByPlatformId(parentPlatformOld.getServerGBId()); | ||
| 139 | - platformChannelMapper.delByPlatformId(parentPlatformOld.getServerGBId()); | ||
| 140 | - platformGbStreamMapper.delByPlatformId(parentPlatformOld.getServerGBId()); | ||
| 141 | - } | ||
| 142 | - | ||
| 143 | 137 | ||
| 144 | // 停止心跳定时 | 138 | // 停止心跳定时 |
| 145 | final String keepaliveTaskKey = KEEPALIVE_KEY_PREFIX + parentPlatformOld.getServerGBId(); | 139 | final String keepaliveTaskKey = KEEPALIVE_KEY_PREFIX + parentPlatformOld.getServerGBId(); |
| @@ -150,12 +144,11 @@ public class PlatformServiceImpl implements IPlatformService { | @@ -150,12 +144,11 @@ public class PlatformServiceImpl implements IPlatformService { | ||
| 150 | // 注销旧的 | 144 | // 注销旧的 |
| 151 | try { | 145 | try { |
| 152 | if (parentPlatformOld.isStatus()) { | 146 | if (parentPlatformOld.isStatus()) { |
| 153 | - logger.info("保存平台{}时发现救平台在线,发送注销命令", parentPlatformOld.getServerGBId()); | 147 | + logger.info("保存平台{}时发现旧平台在线,发送注销命令", parentPlatformOld.getServerGBId()); |
| 154 | commanderForPlatform.unregister(parentPlatformOld, parentPlatformCatchOld.getSipTransactionInfo(), null, eventResult -> { | 148 | commanderForPlatform.unregister(parentPlatformOld, parentPlatformCatchOld.getSipTransactionInfo(), null, eventResult -> { |
| 155 | logger.info("[国标级联] 注销成功, 平台:{}", parentPlatformOld.getServerGBId()); | 149 | logger.info("[国标级联] 注销成功, 平台:{}", parentPlatformOld.getServerGBId()); |
| 156 | }); | 150 | }); |
| 157 | } | 151 | } |
| 158 | - | ||
| 159 | } catch (InvalidArgumentException | ParseException | SipException e) { | 152 | } catch (InvalidArgumentException | ParseException | SipException e) { |
| 160 | logger.error("[命令发送失败] 国标级联 注销: {}", e.getMessage()); | 153 | logger.error("[命令发送失败] 国标级联 注销: {}", e.getMessage()); |
| 161 | } | 154 | } |
| @@ -188,9 +181,6 @@ public class PlatformServiceImpl implements IPlatformService { | @@ -188,9 +181,6 @@ public class PlatformServiceImpl implements IPlatformService { | ||
| 188 | logger.error("[命令发送失败] 国标级联: {}", e.getMessage()); | 181 | logger.error("[命令发送失败] 国标级联: {}", e.getMessage()); |
| 189 | } | 182 | } |
| 190 | } | 183 | } |
| 191 | - // 重新开启定时注册, 使用续订消息 | ||
| 192 | - // 重新开始心跳保活 | ||
| 193 | - | ||
| 194 | 184 | ||
| 195 | return false; | 185 | return false; |
| 196 | } | 186 | } |
| @@ -199,6 +189,9 @@ public class PlatformServiceImpl implements IPlatformService { | @@ -199,6 +189,9 @@ public class PlatformServiceImpl implements IPlatformService { | ||
| 199 | @Override | 189 | @Override |
| 200 | public void online(ParentPlatform parentPlatform, SipTransactionInfo sipTransactionInfo) { | 190 | public void online(ParentPlatform parentPlatform, SipTransactionInfo sipTransactionInfo) { |
| 201 | logger.info("[国标级联]:{}, 平台上线", parentPlatform.getServerGBId()); | 191 | logger.info("[国标级联]:{}, 平台上线", parentPlatform.getServerGBId()); |
| 192 | + final String registerFailAgainTaskKey = REGISTER_FAIL_AGAIN_KEY_PREFIX + parentPlatform.getServerGBId(); | ||
| 193 | + dynamicTask.stop(registerFailAgainTaskKey); | ||
| 194 | + | ||
| 202 | platformMapper.updateParentPlatformStatus(parentPlatform.getServerGBId(), true); | 195 | platformMapper.updateParentPlatformStatus(parentPlatform.getServerGBId(), true); |
| 203 | ParentPlatformCatch parentPlatformCatch = redisCatchStorage.queryPlatformCatchInfo(parentPlatform.getServerGBId()); | 196 | ParentPlatformCatch parentPlatformCatch = redisCatchStorage.queryPlatformCatchInfo(parentPlatform.getServerGBId()); |
| 204 | if (parentPlatformCatch == null) { | 197 | if (parentPlatformCatch == null) { |
| @@ -239,15 +232,9 @@ public class PlatformServiceImpl implements IPlatformService { | @@ -239,15 +232,9 @@ public class PlatformServiceImpl implements IPlatformService { | ||
| 239 | // 此时是第三次心跳超时, 平台离线 | 232 | // 此时是第三次心跳超时, 平台离线 |
| 240 | if (platformCatch.getKeepAliveReply() == 2) { | 233 | if (platformCatch.getKeepAliveReply() == 2) { |
| 241 | // 设置平台离线,并重新注册 | 234 | // 设置平台离线,并重新注册 |
| 242 | - logger.info("[国标级联] {},三次心跳超时后再次发起注册", parentPlatform.getServerGBId()); | ||
| 243 | - try { | ||
| 244 | - commanderForPlatform.register(parentPlatform, eventResult1 -> { | ||
| 245 | - logger.info("[国标级联] {},三次心跳超时后再次发起注册仍然失败,开始定时发起注册,间隔为1分钟", parentPlatform.getServerGBId()); | ||
| 246 | - offline(parentPlatform, false); | ||
| 247 | - }, null); | ||
| 248 | - } catch (InvalidArgumentException | ParseException | SipException e) { | ||
| 249 | - logger.error("[命令发送失败] 国标级联 注册: {}", e.getMessage()); | ||
| 250 | - } | 235 | + logger.info("[国标级联] 三次心跳超时, 平台{}({})离线", parentPlatform.getName(), parentPlatform.getServerGBId()); |
| 236 | + offline(parentPlatform, false); | ||
| 237 | + | ||
| 251 | } | 238 | } |
| 252 | 239 | ||
| 253 | }else { | 240 | }else { |
| @@ -273,21 +260,22 @@ public class PlatformServiceImpl implements IPlatformService { | @@ -273,21 +260,22 @@ public class PlatformServiceImpl implements IPlatformService { | ||
| 273 | 260 | ||
| 274 | private void registerTask(ParentPlatform parentPlatform, SipTransactionInfo sipTransactionInfo){ | 261 | private void registerTask(ParentPlatform parentPlatform, SipTransactionInfo sipTransactionInfo){ |
| 275 | try { | 262 | try { |
| 276 | - // 设置超时重发, 后续从底层支持消息重发 | ||
| 277 | - String key = KEEPALIVE_KEY_PREFIX + parentPlatform.getServerGBId() + "_timeout"; | ||
| 278 | - if (dynamicTask.isAlive(key)) { | ||
| 279 | - return; | 263 | + // 不在同一个会话中续订则每次全新注册 |
| 264 | + if (!userSetting.isRegisterKeepIntDialog()) { | ||
| 265 | + sipTransactionInfo = null; | ||
| 266 | + } | ||
| 267 | + | ||
| 268 | + if (sipTransactionInfo == null) { | ||
| 269 | + logger.info("[国标级联] 平台:{}注册即将到期,开始重新注册", parentPlatform.getServerGBId()); | ||
| 270 | + }else { | ||
| 271 | + logger.info("[国标级联] 平台:{}注册即将到期,开始续订", parentPlatform.getServerGBId()); | ||
| 280 | } | 272 | } |
| 281 | - dynamicTask.startDelay(key, ()->{ | ||
| 282 | - registerTask(parentPlatform, sipTransactionInfo); | ||
| 283 | - }, 1000); | ||
| 284 | - logger.info("[国标级联] 平台:{}注册即将到期,开始续订", parentPlatform.getServerGBId()); | 273 | + |
| 285 | commanderForPlatform.register(parentPlatform, sipTransactionInfo, eventResult -> { | 274 | commanderForPlatform.register(parentPlatform, sipTransactionInfo, eventResult -> { |
| 286 | - dynamicTask.stop(key); | 275 | + logger.info("[国标级联] 平台:{}注册失败,{}:{}", parentPlatform.getServerGBId(), |
| 276 | + eventResult.statusCode, eventResult.msg); | ||
| 287 | offline(parentPlatform, false); | 277 | offline(parentPlatform, false); |
| 288 | - },eventResult -> { | ||
| 289 | - dynamicTask.stop(key); | ||
| 290 | - }); | 278 | + }, null); |
| 291 | } catch (InvalidArgumentException | ParseException | SipException e) { | 279 | } catch (InvalidArgumentException | ParseException | SipException e) { |
| 292 | logger.error("[命令发送失败] 国标级联定时注册: {}", e.getMessage()); | 280 | logger.error("[命令发送失败] 国标级联定时注册: {}", e.getMessage()); |
| 293 | } | 281 | } |
| @@ -308,24 +296,35 @@ public class PlatformServiceImpl implements IPlatformService { | @@ -308,24 +296,35 @@ public class PlatformServiceImpl implements IPlatformService { | ||
| 308 | // 停止所有推流 | 296 | // 停止所有推流 |
| 309 | logger.info("[平台离线] {}, 停止所有推流", parentPlatform.getServerGBId()); | 297 | logger.info("[平台离线] {}, 停止所有推流", parentPlatform.getServerGBId()); |
| 310 | stopAllPush(parentPlatform.getServerGBId()); | 298 | stopAllPush(parentPlatform.getServerGBId()); |
| 311 | - if (stopRegister) { | ||
| 312 | - // 清除注册定时 | ||
| 313 | - logger.info("[平台离线] {}, 停止定时注册任务", parentPlatform.getServerGBId()); | ||
| 314 | - final String registerTaskKey = REGISTER_KEY_PREFIX + parentPlatform.getServerGBId(); | ||
| 315 | - if (dynamicTask.contains(registerTaskKey)) { | ||
| 316 | - dynamicTask.stop(registerTaskKey); | ||
| 317 | - } | 299 | + |
| 300 | + // 清除注册定时 | ||
| 301 | + logger.info("[平台离线] {}, 停止定时注册任务", parentPlatform.getServerGBId()); | ||
| 302 | + final String registerTaskKey = REGISTER_KEY_PREFIX + parentPlatform.getServerGBId(); | ||
| 303 | + if (dynamicTask.contains(registerTaskKey)) { | ||
| 304 | + dynamicTask.stop(registerTaskKey); | ||
| 318 | } | 305 | } |
| 319 | // 清除心跳定时 | 306 | // 清除心跳定时 |
| 320 | logger.info("[平台离线] {}, 停止定时发送心跳任务", parentPlatform.getServerGBId()); | 307 | logger.info("[平台离线] {}, 停止定时发送心跳任务", parentPlatform.getServerGBId()); |
| 321 | final String keepaliveTaskKey = KEEPALIVE_KEY_PREFIX + parentPlatform.getServerGBId(); | 308 | final String keepaliveTaskKey = KEEPALIVE_KEY_PREFIX + parentPlatform.getServerGBId(); |
| 322 | if (dynamicTask.contains(keepaliveTaskKey)) { | 309 | if (dynamicTask.contains(keepaliveTaskKey)) { |
| 323 | - // 添加心跳任务 | 310 | + // 清除心跳任务 |
| 324 | dynamicTask.stop(keepaliveTaskKey); | 311 | dynamicTask.stop(keepaliveTaskKey); |
| 325 | } | 312 | } |
| 326 | // 停止目录订阅回复 | 313 | // 停止目录订阅回复 |
| 327 | logger.info("[平台离线] {}, 停止订阅回复", parentPlatform.getServerGBId()); | 314 | logger.info("[平台离线] {}, 停止订阅回复", parentPlatform.getServerGBId()); |
| 328 | subscribeHolder.removeAllSubscribe(parentPlatform.getServerGBId()); | 315 | subscribeHolder.removeAllSubscribe(parentPlatform.getServerGBId()); |
| 316 | + // 发起定时自动重新注册 | ||
| 317 | + if (!stopRegister) { | ||
| 318 | + // 设置为60秒自动尝试重新注册 | ||
| 319 | + final String registerFailAgainTaskKey = REGISTER_FAIL_AGAIN_KEY_PREFIX + parentPlatform.getServerGBId(); | ||
| 320 | + ParentPlatform platform = platformMapper.getParentPlatById(parentPlatform.getId()); | ||
| 321 | + if (platform.isEnable()) { | ||
| 322 | + dynamicTask.startCron(registerFailAgainTaskKey, | ||
| 323 | + ()-> registerTask(platform, null), | ||
| 324 | + userSetting.getRegisterAgainAfterTime() * 1000); | ||
| 325 | + } | ||
| 326 | + | ||
| 327 | + } | ||
| 329 | } | 328 | } |
| 330 | 329 | ||
| 331 | private void stopAllPush(String platformId) { | 330 | private void stopAllPush(String platformId) { |
src/main/java/com/genersoft/iot/vmp/storager/dao/DeviceChannelMapper.java
| @@ -451,10 +451,18 @@ public interface DeviceChannelMapper { | @@ -451,10 +451,18 @@ public interface DeviceChannelMapper { | ||
| 451 | @Select("select count(1) from wvp_device_channel") | 451 | @Select("select count(1) from wvp_device_channel") |
| 452 | int getAllChannelCount(); | 452 | int getAllChannelCount(); |
| 453 | 453 | ||
| 454 | - | ||
| 455 | - /*=================设备主子码流逻辑START==============*/ | 454 | + // 设备主子码流逻辑START |
| 456 | @Update(value = {"UPDATE wvp_device_channel SET stream_id=null WHERE device_id=#{deviceId}"}) | 455 | @Update(value = {"UPDATE wvp_device_channel SET stream_id=null WHERE device_id=#{deviceId}"}) |
| 457 | void clearPlay(String deviceId); | 456 | void clearPlay(String deviceId); |
| 458 | - /*=================设备主子码流逻辑END==============*/ | 457 | + // 设备主子码流逻辑END |
| 458 | + @Select(value = {" <script>" + | ||
| 459 | + "select * " + | ||
| 460 | + "from device_channel " + | ||
| 461 | + "where device_id=#{deviceId}" + | ||
| 462 | + " <if test='parentId != null '> and parent_id = #{parentId} </if>" + | ||
| 463 | + " <if test='parentId == null '> and parent_id is null </if>" + | ||
| 464 | + " <if test='onlyCatalog == true '> and parental = 1 </if>" + | ||
| 465 | + " </script>"}) | ||
| 466 | + List<DeviceChannel> getSubChannelsByDeviceId(String deviceId, String parentId, boolean onlyCatalog); | ||
| 459 | 467 | ||
| 460 | } | 468 | } |
src/main/java/com/genersoft/iot/vmp/storager/dao/DeviceMapper.java
| @@ -40,7 +40,6 @@ public interface DeviceMapper { | @@ -40,7 +40,6 @@ public interface DeviceMapper { | ||
| 40 | "ssrc_check," + | 40 | "ssrc_check," + |
| 41 | "as_message_channel," + | 41 | "as_message_channel," + |
| 42 | "geo_coord_sys," + | 42 | "geo_coord_sys," + |
| 43 | - "tree_type," + | ||
| 44 | "on_line," + | 43 | "on_line," + |
| 45 | "media_server_id," + | 44 | "media_server_id," + |
| 46 | "switch_primary_sub_stream," + | 45 | "switch_primary_sub_stream," + |
| @@ -75,7 +74,6 @@ public interface DeviceMapper { | @@ -75,7 +74,6 @@ public interface DeviceMapper { | ||
| 75 | "ssrc_check,"+ | 74 | "ssrc_check,"+ |
| 76 | "as_message_channel,"+ | 75 | "as_message_channel,"+ |
| 77 | "geo_coord_sys,"+ | 76 | "geo_coord_sys,"+ |
| 78 | - "tree_type,"+ | ||
| 79 | "on_line"+ | 77 | "on_line"+ |
| 80 | ") VALUES (" + | 78 | ") VALUES (" + |
| 81 | "#{deviceId}," + | 79 | "#{deviceId}," + |
| @@ -104,7 +102,6 @@ public interface DeviceMapper { | @@ -104,7 +102,6 @@ public interface DeviceMapper { | ||
| 104 | "#{ssrcCheck}," + | 102 | "#{ssrcCheck}," + |
| 105 | "#{asMessageChannel}," + | 103 | "#{asMessageChannel}," + |
| 106 | "#{geoCoordSys}," + | 104 | "#{geoCoordSys}," + |
| 107 | - "#{treeType}," + | ||
| 108 | "#{onLine}" + | 105 | "#{onLine}" + |
| 109 | ")") | 106 | ")") |
| 110 | int add(Device device); | 107 | int add(Device device); |
| @@ -159,7 +156,6 @@ public interface DeviceMapper { | @@ -159,7 +156,6 @@ public interface DeviceMapper { | ||
| 159 | "ssrc_check,"+ | 156 | "ssrc_check,"+ |
| 160 | "as_message_channel,"+ | 157 | "as_message_channel,"+ |
| 161 | "geo_coord_sys,"+ | 158 | "geo_coord_sys,"+ |
| 162 | - "tree_type,"+ | ||
| 163 | "on_line,"+ | 159 | "on_line,"+ |
| 164 | "media_server_id,"+ | 160 | "media_server_id,"+ |
| 165 | "switch_primary_sub_stream switchPrimarySubStream,"+ | 161 | "switch_primary_sub_stream switchPrimarySubStream,"+ |
| @@ -201,7 +197,6 @@ public interface DeviceMapper { | @@ -201,7 +197,6 @@ public interface DeviceMapper { | ||
| 201 | "ssrc_check,"+ | 197 | "ssrc_check,"+ |
| 202 | "as_message_channel,"+ | 198 | "as_message_channel,"+ |
| 203 | "geo_coord_sys,"+ | 199 | "geo_coord_sys,"+ |
| 204 | - "tree_type,"+ | ||
| 205 | "on_line"+ | 200 | "on_line"+ |
| 206 | " FROM wvp_device WHERE on_line = true") | 201 | " FROM wvp_device WHERE on_line = true") |
| 207 | List<Device> getOnlineDevices(); | 202 | List<Device> getOnlineDevices(); |
| @@ -232,7 +227,6 @@ public interface DeviceMapper { | @@ -232,7 +227,6 @@ public interface DeviceMapper { | ||
| 232 | "ssrc_check,"+ | 227 | "ssrc_check,"+ |
| 233 | "as_message_channel,"+ | 228 | "as_message_channel,"+ |
| 234 | "geo_coord_sys,"+ | 229 | "geo_coord_sys,"+ |
| 235 | - "tree_type,"+ | ||
| 236 | "on_line"+ | 230 | "on_line"+ |
| 237 | " FROM wvp_device WHERE ip = #{host} AND port=#{port}") | 231 | " FROM wvp_device WHERE ip = #{host} AND port=#{port}") |
| 238 | Device getDeviceByHostAndPort(String host, int port); | 232 | Device getDeviceByHostAndPort(String host, int port); |
| @@ -254,7 +248,6 @@ public interface DeviceMapper { | @@ -254,7 +248,6 @@ public interface DeviceMapper { | ||
| 254 | "<if test=\"ssrcCheck != null\">, ssrc_check=#{ssrcCheck}</if>" + | 248 | "<if test=\"ssrcCheck != null\">, ssrc_check=#{ssrcCheck}</if>" + |
| 255 | "<if test=\"asMessageChannel != null\">, as_message_channel=#{asMessageChannel}</if>" + | 249 | "<if test=\"asMessageChannel != null\">, as_message_channel=#{asMessageChannel}</if>" + |
| 256 | "<if test=\"geoCoordSys != null\">, geo_coord_sys=#{geoCoordSys}</if>" + | 250 | "<if test=\"geoCoordSys != null\">, geo_coord_sys=#{geoCoordSys}</if>" + |
| 257 | - "<if test=\"treeType != null\">, tree_type=#{treeType}</if>" + | ||
| 258 | "<if test=\"switchPrimarySubStream != null\">, switch_primary_sub_stream=#{switchPrimarySubStream}</if>" + | 251 | "<if test=\"switchPrimarySubStream != null\">, switch_primary_sub_stream=#{switchPrimarySubStream}</if>" + |
| 259 | "<if test=\"mediaServerId != null\">, media_server_id=#{mediaServerId}</if>" + | 252 | "<if test=\"mediaServerId != null\">, media_server_id=#{mediaServerId}</if>" + |
| 260 | "WHERE device_id=#{deviceId}"+ | 253 | "WHERE device_id=#{deviceId}"+ |
| @@ -272,7 +265,6 @@ public interface DeviceMapper { | @@ -272,7 +265,6 @@ public interface DeviceMapper { | ||
| 272 | "ssrc_check,"+ | 265 | "ssrc_check,"+ |
| 273 | "as_message_channel,"+ | 266 | "as_message_channel,"+ |
| 274 | "geo_coord_sys,"+ | 267 | "geo_coord_sys,"+ |
| 275 | - "tree_type,"+ | ||
| 276 | "on_line,"+ | 268 | "on_line,"+ |
| 277 | "media_server_id,"+ | 269 | "media_server_id,"+ |
| 278 | "switch_primary_sub_stream"+ | 270 | "switch_primary_sub_stream"+ |
| @@ -287,7 +279,6 @@ public interface DeviceMapper { | @@ -287,7 +279,6 @@ public interface DeviceMapper { | ||
| 287 | "#{ssrcCheck}," + | 279 | "#{ssrcCheck}," + |
| 288 | "#{asMessageChannel}," + | 280 | "#{asMessageChannel}," + |
| 289 | "#{geoCoordSys}," + | 281 | "#{geoCoordSys}," + |
| 290 | - "#{treeType}," + | ||
| 291 | "#{onLine}," + | 282 | "#{onLine}," + |
| 292 | "#{mediaServerId}," + | 283 | "#{mediaServerId}," + |
| 293 | "#{switchPrimarySubStream}" + | 284 | "#{switchPrimarySubStream}" + |
src/main/java/com/genersoft/iot/vmp/storager/dao/ParentPlatformMapper.java
| @@ -16,10 +16,10 @@ public interface ParentPlatformMapper { | @@ -16,10 +16,10 @@ public interface ParentPlatformMapper { | ||
| 16 | 16 | ||
| 17 | @Insert("INSERT INTO wvp_platform (enable, name, server_gb_id, server_gb_domain, server_ip, server_port,device_gb_id,device_ip,"+ | 17 | @Insert("INSERT INTO wvp_platform (enable, name, server_gb_id, server_gb_domain, server_ip, server_port,device_gb_id,device_ip,"+ |
| 18 | "device_port,username,password,expires,keep_timeout,transport,character_set,ptz,rtcp,as_message_channel,"+ | 18 | "device_port,username,password,expires,keep_timeout,transport,character_set,ptz,rtcp,as_message_channel,"+ |
| 19 | - "status,start_offline_push,catalog_id,administrative_division,catalog_group,create_time,update_time,tree_type) " + | 19 | + "status,start_offline_push,catalog_id,administrative_division,catalog_group,create_time,update_time) " + |
| 20 | " VALUES (#{enable}, #{name}, #{serverGBId}, #{serverGBDomain}, #{serverIP}, #{serverPort}, #{deviceGBId}, #{deviceIp}, " + | 20 | " VALUES (#{enable}, #{name}, #{serverGBId}, #{serverGBDomain}, #{serverIP}, #{serverPort}, #{deviceGBId}, #{deviceIp}, " + |
| 21 | " #{devicePort}, #{username}, #{password}, #{expires}, #{keepTimeout}, #{transport}, #{characterSet}, #{ptz}, #{rtcp}, #{asMessageChannel}, " + | 21 | " #{devicePort}, #{username}, #{password}, #{expires}, #{keepTimeout}, #{transport}, #{characterSet}, #{ptz}, #{rtcp}, #{asMessageChannel}, " + |
| 22 | - " #{status}, #{startOfflinePush}, #{catalogId}, #{administrativeDivision}, #{catalogGroup}, #{createTime}, #{updateTime}, #{treeType})") | 22 | + " #{status}, #{startOfflinePush}, #{catalogId}, #{administrativeDivision}, #{catalogGroup}, #{createTime}, #{updateTime})") |
| 23 | int addParentPlatform(ParentPlatform parentPlatform); | 23 | int addParentPlatform(ParentPlatform parentPlatform); |
| 24 | 24 | ||
| 25 | @Update("UPDATE wvp_platform " + | 25 | @Update("UPDATE wvp_platform " + |
| @@ -47,7 +47,6 @@ public interface ParentPlatformMapper { | @@ -47,7 +47,6 @@ public interface ParentPlatformMapper { | ||
| 47 | "administrative_division=#{administrativeDivision}, " + | 47 | "administrative_division=#{administrativeDivision}, " + |
| 48 | "create_time=#{createTime}, " + | 48 | "create_time=#{createTime}, " + |
| 49 | "update_time=#{updateTime}, " + | 49 | "update_time=#{updateTime}, " + |
| 50 | - "tree_type=#{treeType}, " + | ||
| 51 | "catalog_id=#{catalogId} " + | 50 | "catalog_id=#{catalogId} " + |
| 52 | "WHERE id=#{id}") | 51 | "WHERE id=#{id}") |
| 53 | int updateParentPlatform(ParentPlatform parentPlatform); | 52 | int updateParentPlatform(ParentPlatform parentPlatform); |
src/main/java/com/genersoft/iot/vmp/storager/impl/VideoManagerStorageImpl.java
| @@ -128,51 +128,56 @@ public class VideoManagerStorageImpl implements IVideoManagerStorage { | @@ -128,51 +128,56 @@ public class VideoManagerStorageImpl implements IVideoManagerStorage { | ||
| 128 | List<DeviceChannel> addChannels = new ArrayList<>(); | 128 | List<DeviceChannel> addChannels = new ArrayList<>(); |
| 129 | StringBuilder stringBuilder = new StringBuilder(); | 129 | StringBuilder stringBuilder = new StringBuilder(); |
| 130 | Map<String, Integer> subContMap = new HashMap<>(); | 130 | Map<String, Integer> subContMap = new HashMap<>(); |
| 131 | - if (deviceChannelList.size() > 0) { | ||
| 132 | - // 数据去重 | ||
| 133 | - Set<String> gbIdSet = new HashSet<>(); | ||
| 134 | - for (DeviceChannel deviceChannel : deviceChannelList) { | ||
| 135 | - if (!gbIdSet.contains(deviceChannel.getChannelId())) { | ||
| 136 | - gbIdSet.add(deviceChannel.getChannelId()); | ||
| 137 | - deviceChannel.setUpdateTime(DateUtil.getNow()); | ||
| 138 | - if (allChannelMap.containsKey(deviceChannel.getChannelId())) { | ||
| 139 | - deviceChannel.setStreamId(allChannelMap.get(deviceChannel.getChannelId()).getStreamId()); | ||
| 140 | - deviceChannel.setHasAudio(allChannelMap.get(deviceChannel.getChannelId()).isHasAudio()); | ||
| 141 | - if (allChannelMap.get(deviceChannel.getChannelId()).isStatus() !=deviceChannel.isStatus()){ | ||
| 142 | - List<String> strings = platformChannelMapper.queryParentPlatformByChannelId(deviceChannel.getChannelId()); | ||
| 143 | - if (!CollectionUtils.isEmpty(strings)){ | ||
| 144 | - strings.forEach(platformId->{ | ||
| 145 | - eventPublisher.catalogEventPublish(platformId, deviceChannel, deviceChannel.isStatus()?CatalogEvent.ON:CatalogEvent.OFF); | ||
| 146 | - }); | ||
| 147 | - } | ||
| 148 | - } | ||
| 149 | - updateChannels.add(deviceChannel); | ||
| 150 | - }else { | ||
| 151 | - deviceChannel.setCreateTime(DateUtil.getNow()); | ||
| 152 | - addChannels.add(deviceChannel); | ||
| 153 | - } | ||
| 154 | - channels.add(deviceChannel); | ||
| 155 | - if (!ObjectUtils.isEmpty(deviceChannel.getParentId())) { | ||
| 156 | - if (subContMap.get(deviceChannel.getParentId()) == null) { | ||
| 157 | - subContMap.put(deviceChannel.getParentId(), 1); | ||
| 158 | - }else { | ||
| 159 | - Integer count = subContMap.get(deviceChannel.getParentId()); | ||
| 160 | - subContMap.put(deviceChannel.getParentId(), count++); | ||
| 161 | - } | 131 | + |
| 132 | + // 数据去重 | ||
| 133 | + Set<String> gbIdSet = new HashSet<>(); | ||
| 134 | + for (DeviceChannel deviceChannel : deviceChannelList) { | ||
| 135 | + if (gbIdSet.contains(deviceChannel.getChannelId())) { | ||
| 136 | + stringBuilder.append(deviceChannel.getChannelId()).append(","); | ||
| 137 | + continue; | ||
| 138 | + } | ||
| 139 | + gbIdSet.add(deviceChannel.getChannelId()); | ||
| 140 | + if (allChannelMap.containsKey(deviceChannel.getChannelId())) { | ||
| 141 | + deviceChannel.setStreamId(allChannelMap.get(deviceChannel.getChannelId()).getStreamId()); | ||
| 142 | + deviceChannel.setHasAudio(allChannelMap.get(deviceChannel.getChannelId()).isHasAudio()); | ||
| 143 | + if (allChannelMap.get(deviceChannel.getChannelId()).isStatus() !=deviceChannel.isStatus()){ | ||
| 144 | + List<String> strings = platformChannelMapper.queryParentPlatformByChannelId(deviceChannel.getChannelId()); | ||
| 145 | + if (!CollectionUtils.isEmpty(strings)){ | ||
| 146 | + strings.forEach(platformId->{ | ||
| 147 | + eventPublisher.catalogEventPublish(platformId, deviceChannel, deviceChannel.isStatus()?CatalogEvent.ON:CatalogEvent.OFF); | ||
| 148 | + }); | ||
| 162 | } | 149 | } |
| 150 | + | ||
| 151 | + } | ||
| 152 | + deviceChannel.setUpdateTime(DateUtil.getNow()); | ||
| 153 | + updateChannels.add(deviceChannel); | ||
| 154 | + }else { | ||
| 155 | + deviceChannel.setCreateTime(DateUtil.getNow()); | ||
| 156 | + deviceChannel.setUpdateTime(DateUtil.getNow()); | ||
| 157 | + addChannels.add(deviceChannel); | ||
| 158 | + } | ||
| 159 | + channels.add(deviceChannel); | ||
| 160 | + if (!ObjectUtils.isEmpty(deviceChannel.getParentId())) { | ||
| 161 | + if (subContMap.get(deviceChannel.getParentId()) == null) { | ||
| 162 | + subContMap.put(deviceChannel.getParentId(), 1); | ||
| 163 | }else { | 163 | }else { |
| 164 | - stringBuilder.append(deviceChannel.getChannelId()).append(","); | 164 | + Integer count = subContMap.get(deviceChannel.getParentId()); |
| 165 | + subContMap.put(deviceChannel.getParentId(), count++); | ||
| 165 | } | 166 | } |
| 166 | } | 167 | } |
| 167 | - if (channels.size() > 0) { | ||
| 168 | - for (DeviceChannel channel : channels) { | ||
| 169 | - if (subContMap.get(channel.getChannelId()) != null){ | ||
| 170 | - channel.setSubCount(subContMap.get(channel.getChannelId())); | 168 | + } |
| 169 | + if (channels.size() > 0) { | ||
| 170 | + for (DeviceChannel channel : channels) { | ||
| 171 | + if (subContMap.get(channel.getChannelId()) != null){ | ||
| 172 | + Integer count = subContMap.get(channel.getChannelId()); | ||
| 173 | + if (count > 0) { | ||
| 174 | + channel.setSubCount(count); | ||
| 175 | + channel.setParental(1); | ||
| 171 | } | 176 | } |
| 172 | } | 177 | } |
| 173 | } | 178 | } |
| 174 | - | ||
| 175 | } | 179 | } |
| 180 | + | ||
| 176 | if (stringBuilder.length() > 0) { | 181 | if (stringBuilder.length() > 0) { |
| 177 | logger.info("[目录查询]收到的数据存在重复: {}" , stringBuilder); | 182 | logger.info("[目录查询]收到的数据存在重复: {}" , stringBuilder); |
| 178 | } | 183 | } |
| @@ -795,25 +800,49 @@ public class VideoManagerStorageImpl implements IVideoManagerStorage { | @@ -795,25 +800,49 @@ public class VideoManagerStorageImpl implements IVideoManagerStorage { | ||
| 795 | if (platform == null) { | 800 | if (platform == null) { |
| 796 | return 0; | 801 | return 0; |
| 797 | } | 802 | } |
| 798 | - if (platform.getTreeType().equals(TreeType.BUSINESS_GROUP)) { | ||
| 799 | - if (platform.getDeviceGBId().equals(platformCatalog.getParentId())) { | ||
| 800 | - // 第一层节点 | ||
| 801 | - platformCatalog.setBusinessGroupId(platformCatalog.getId()); | ||
| 802 | - platformCatalog.setParentId(platform.getDeviceGBId()); | ||
| 803 | - }else { | ||
| 804 | - // 获取顶层的 | ||
| 805 | - PlatformCatalog topCatalog = getTopCatalog(platformCatalog.getParentId(), platform.getDeviceGBId()); | ||
| 806 | - platformCatalog.setBusinessGroupId(topCatalog.getId()); | 803 | + if (platformCatalog.getId().length() <= 8) { |
| 804 | + platformCatalog.setCivilCode(platformCatalog.getParentId()); | ||
| 805 | + }else { | ||
| 806 | + if (platformCatalog.getId().length() != 20) { | ||
| 807 | + return 0; | ||
| 807 | } | 808 | } |
| 808 | - } | ||
| 809 | - if (platform.getTreeType().equals(TreeType.CIVIL_CODE)) { | ||
| 810 | - platformCatalog.setCivilCode(platformCatalog.getId()); | ||
| 811 | - if (platformCatalog.getPlatformId().equals(platformCatalog.getParentId())) { | ||
| 812 | - // 第一层节点 | ||
| 813 | - platformCatalog.setParentId(platform.getDeviceGBId()); | 809 | + if (platformCatalog.getParentId() != null) { |
| 810 | + switch (Integer.parseInt(platformCatalog.getId().substring(10, 13))){ | ||
| 811 | + case 200: | ||
| 812 | + case 215: | ||
| 813 | + if (platformCatalog.getParentId().length() <= 8) { | ||
| 814 | + platformCatalog.setCivilCode(platformCatalog.getParentId()); | ||
| 815 | + }else { | ||
| 816 | + PlatformCatalog catalog = catalogMapper.select(platformCatalog.getParentId()); | ||
| 817 | + if (catalog != null) { | ||
| 818 | + platformCatalog.setCivilCode(catalog.getCivilCode()); | ||
| 819 | + } | ||
| 820 | + } | ||
| 821 | + break; | ||
| 822 | + case 216: | ||
| 823 | + if (platformCatalog.getParentId().length() <= 8) { | ||
| 824 | + platformCatalog.setCivilCode(platformCatalog.getParentId()); | ||
| 825 | + }else { | ||
| 826 | + PlatformCatalog catalog = catalogMapper.select(platformCatalog.getParentId()); | ||
| 827 | + if (catalog == null) { | ||
| 828 | + logger.warn("[添加目录] 无法获取目录{}的CivilCode和BusinessGroupId", platformCatalog.getPlatformId()); | ||
| 829 | + break; | ||
| 830 | + } | ||
| 831 | + platformCatalog.setCivilCode(catalog.getCivilCode()); | ||
| 832 | + if (Integer.parseInt(platformCatalog.getParentId().substring(10, 13)) == 215) { | ||
| 833 | + platformCatalog.setBusinessGroupId(platformCatalog.getParentId()); | ||
| 834 | + }else { | ||
| 835 | + if (Integer.parseInt(platformCatalog.getParentId().substring(10, 13)) == 216) { | ||
| 836 | + platformCatalog.setBusinessGroupId(catalog.getBusinessGroupId()); | ||
| 837 | + } | ||
| 838 | + } | ||
| 839 | + } | ||
| 840 | + break; | ||
| 841 | + default: | ||
| 842 | + break; | ||
| 843 | + } | ||
| 814 | } | 844 | } |
| 815 | } | 845 | } |
| 816 | - | ||
| 817 | int result = catalogMapper.add(platformCatalog); | 846 | int result = catalogMapper.add(platformCatalog); |
| 818 | if (result > 0) { | 847 | if (result > 0) { |
| 819 | DeviceChannel deviceChannel = getDeviceChannelByCatalog(platformCatalog); | 848 | DeviceChannel deviceChannel = getDeviceChannelByCatalog(platformCatalog); |
| @@ -937,19 +966,14 @@ public class VideoManagerStorageImpl implements IVideoManagerStorage { | @@ -937,19 +966,14 @@ public class VideoManagerStorageImpl implements IVideoManagerStorage { | ||
| 937 | DeviceChannel deviceChannel = new DeviceChannel(); | 966 | DeviceChannel deviceChannel = new DeviceChannel(); |
| 938 | deviceChannel.setChannelId(catalog.getId()); | 967 | deviceChannel.setChannelId(catalog.getId()); |
| 939 | deviceChannel.setName(catalog.getName()); | 968 | deviceChannel.setName(catalog.getName()); |
| 940 | - deviceChannel.setLongitude(0.0); | ||
| 941 | - deviceChannel.setLatitude(0.0); | ||
| 942 | deviceChannel.setDeviceId(platform.getDeviceGBId()); | 969 | deviceChannel.setDeviceId(platform.getDeviceGBId()); |
| 943 | deviceChannel.setManufacture("wvp-pro"); | 970 | deviceChannel.setManufacture("wvp-pro"); |
| 944 | deviceChannel.setStatus(true); | 971 | deviceChannel.setStatus(true); |
| 945 | deviceChannel.setParental(1); | 972 | deviceChannel.setParental(1); |
| 946 | 973 | ||
| 947 | deviceChannel.setRegisterWay(1); | 974 | deviceChannel.setRegisterWay(1); |
| 948 | - // 行政区划应该是Domain的前八位 | ||
| 949 | - if (platform.getTreeType().equals(TreeType.BUSINESS_GROUP)) { | ||
| 950 | - deviceChannel.setParentId(catalog.getParentId()); | ||
| 951 | - deviceChannel.setBusinessGroupId(catalog.getBusinessGroupId()); | ||
| 952 | - } | 975 | + deviceChannel.setParentId(catalog.getParentId()); |
| 976 | + deviceChannel.setBusinessGroupId(catalog.getBusinessGroupId()); | ||
| 953 | 977 | ||
| 954 | deviceChannel.setModel("live"); | 978 | deviceChannel.setModel("live"); |
| 955 | deviceChannel.setOwner("wvp-pro"); | 979 | deviceChannel.setOwner("wvp-pro"); |
src/main/java/com/genersoft/iot/vmp/vmanager/gb28181/platform/PlatformController.java
| @@ -403,8 +403,12 @@ public class PlatformController { | @@ -403,8 +403,12 @@ public class PlatformController { | ||
| 403 | if (platform == null) { | 403 | if (platform == null) { |
| 404 | throw new ControllerException(ErrorCode.ERROR100.getCode(), "平台未找到"); | 404 | throw new ControllerException(ErrorCode.ERROR100.getCode(), "平台未找到"); |
| 405 | } | 405 | } |
| 406 | - if (platformId.equals(parentId)) { | ||
| 407 | - parentId = platform.getDeviceGBId(); | 406 | +// if (platformId.equals(parentId)) { |
| 407 | +// parentId = platform.getDeviceGBId(); | ||
| 408 | +// } | ||
| 409 | + | ||
| 410 | + if (platformId.equals(platform.getDeviceGBId())) { | ||
| 411 | + parentId = null; | ||
| 408 | } | 412 | } |
| 409 | 413 | ||
| 410 | return storager.getChildrenCatalogByPlatform(platformId, parentId); | 414 | return storager.getChildrenCatalogByPlatform(platformId, parentId); |
src/main/resources/all-application.yml
| @@ -202,6 +202,10 @@ user-settings: | @@ -202,6 +202,10 @@ user-settings: | ||
| 202 | device-status-notify: false | 202 | device-status-notify: false |
| 203 | # 上级平台点播时不使用上级平台指定的ssrc,使用自定义的ssrc,参考国标文档-点播外域设备媒体流SSRC处理方式 | 203 | # 上级平台点播时不使用上级平台指定的ssrc,使用自定义的ssrc,参考国标文档-点播外域设备媒体流SSRC处理方式 |
| 204 | use-custom-ssrc-for-parent-invite: true | 204 | use-custom-ssrc-for-parent-invite: true |
| 205 | + # 国标级联离线后多久重试一次注册 | ||
| 206 | + register-again-after-time: 60 | ||
| 207 | + # 国标续订方式,true为续订,每次注册在同一个会话里,false为重新注册,每次使用新的会话 | ||
| 208 | + register-keep-int-dialog: false | ||
| 205 | # 跨域配置,配置你访问前端页面的地址即可, 可以配置多个 | 209 | # 跨域配置,配置你访问前端页面的地址即可, 可以配置多个 |
| 206 | allowed-origins: | 210 | allowed-origins: |
| 207 | - http://localhost:8008 | 211 | - http://localhost:8008 |
src/main/resources/civilCode.csv
0 → 100644
| 1 | +编号,名称,上级 | ||
| 2 | +11,北京市, | ||
| 3 | +110101,东城区,11 | ||
| 4 | +110102,西城区,11 | ||
| 5 | +110105,朝阳区,11 | ||
| 6 | +110106,丰台区,11 | ||
| 7 | +110107,石景山区,11 | ||
| 8 | +110108,海淀区,11 | ||
| 9 | +110109,门头沟区,11 | ||
| 10 | +110111,房山区,11 | ||
| 11 | +110112,通州区,11 | ||
| 12 | +110113,顺义区,11 | ||
| 13 | +110114,昌平区,11 | ||
| 14 | +110115,大兴区,11 | ||
| 15 | +110116,怀柔区,11 | ||
| 16 | +110117,平谷区,11 | ||
| 17 | +110118,密云区,11 | ||
| 18 | +110119,延庆区,11 | ||
| 19 | +12,天津市, | ||
| 20 | +120101,和平区,12 | ||
| 21 | +120102,河东区,12 | ||
| 22 | +120103,河西区,12 | ||
| 23 | +120104,南开区,12 | ||
| 24 | +120105,河北区,12 | ||
| 25 | +120106,红桥区,12 | ||
| 26 | +120110,东丽区,12 | ||
| 27 | +120111,西青区,12 | ||
| 28 | +120112,津南区,12 | ||
| 29 | +120113,北辰区,12 | ||
| 30 | +120114,武清区,12 | ||
| 31 | +120115,宝坻区,12 | ||
| 32 | +120116,滨海新区,12 | ||
| 33 | +120117,宁河区,12 | ||
| 34 | +120118,静海区,12 | ||
| 35 | +120119,蓟州区,12 | ||
| 36 | +13,河北省, | ||
| 37 | +1301,石家庄市,13 | ||
| 38 | +130102,长安区,1301 | ||
| 39 | +130104,桥西区,1301 | ||
| 40 | +130105,新华区,1301 | ||
| 41 | +130107,井陉矿区,1301 | ||
| 42 | +130108,裕华区,1301 | ||
| 43 | +130109,藁城区,1301 | ||
| 44 | +130110,鹿泉区,1301 | ||
| 45 | +130111,栾城区,1301 | ||
| 46 | +130121,井陉县,1301 | ||
| 47 | +130123,正定县,1301 | ||
| 48 | +130125,行唐县,1301 | ||
| 49 | +130126,灵寿县,1301 | ||
| 50 | +130127,高邑县,1301 | ||
| 51 | +130128,深泽县,1301 | ||
| 52 | +130129,赞皇县,1301 | ||
| 53 | +130130,无极县,1301 | ||
| 54 | +130131,平山县,1301 | ||
| 55 | +130132,元氏县,1301 | ||
| 56 | +130133,赵县,1301 | ||
| 57 | +130181,辛集市,1301 | ||
| 58 | +130183,晋州市,1301 | ||
| 59 | +130184,新乐市,1301 | ||
| 60 | +1302,唐山市,13 | ||
| 61 | +130202,路南区,1302 | ||
| 62 | +130203,路北区,1302 | ||
| 63 | +130204,古冶区,1302 | ||
| 64 | +130205,开平区,1302 | ||
| 65 | +130207,丰南区,1302 | ||
| 66 | +130208,丰润区,1302 | ||
| 67 | +130209,曹妃甸区,1302 | ||
| 68 | +130224,滦南县,1302 | ||
| 69 | +130225,乐亭县,1302 | ||
| 70 | +130227,迁西县,1302 | ||
| 71 | +130229,玉田县,1302 | ||
| 72 | +130281,遵化市,1302 | ||
| 73 | +130283,迁安市,1302 | ||
| 74 | +130284,滦州市,1302 | ||
| 75 | +1303,秦皇岛市,13 | ||
| 76 | +130302,海港区,1303 | ||
| 77 | +130303,山海关区,1303 | ||
| 78 | +130304,北戴河区,1303 | ||
| 79 | +130306,抚宁区,1303 | ||
| 80 | +130321,青龙满族自治县,1303 | ||
| 81 | +130322,昌黎县,1303 | ||
| 82 | +130324,卢龙县,1303 | ||
| 83 | +1304,邯郸市,13 | ||
| 84 | +130402,邯山区,1304 | ||
| 85 | +130403,丛台区,1304 | ||
| 86 | +130404,复兴区,1304 | ||
| 87 | +130406,峰峰矿区,1304 | ||
| 88 | +130407,肥乡区,1304 | ||
| 89 | +130408,永年区,1304 | ||
| 90 | +130423,临漳县,1304 | ||
| 91 | +130424,成安县,1304 | ||
| 92 | +130425,大名县,1304 | ||
| 93 | +130426,涉县,1304 | ||
| 94 | +130427,磁县,1304 | ||
| 95 | +130430,邱县,1304 | ||
| 96 | +130431,鸡泽县,1304 | ||
| 97 | +130432,广平县,1304 | ||
| 98 | +130433,馆陶县,1304 | ||
| 99 | +130434,魏县,1304 | ||
| 100 | +130435,曲周县,1304 | ||
| 101 | +130481,武安市,1304 | ||
| 102 | +1305,邢台市,13 | ||
| 103 | +130502,桥东区,1305 | ||
| 104 | +130503,桥西区,1305 | ||
| 105 | +130521,邢台县,1305 | ||
| 106 | +130522,临城县,1305 | ||
| 107 | +130523,内丘县,1305 | ||
| 108 | +130524,柏乡县,1305 | ||
| 109 | +130525,隆尧县,1305 | ||
| 110 | +130526,任县,1305 | ||
| 111 | +130527,南和县,1305 | ||
| 112 | +130528,宁晋县,1305 | ||
| 113 | +130529,巨鹿县,1305 | ||
| 114 | +130530,新河县,1305 | ||
| 115 | +130531,广宗县,1305 | ||
| 116 | +130532,平乡县,1305 | ||
| 117 | +130533,威县,1305 | ||
| 118 | +130534,清河县,1305 | ||
| 119 | +130535,临西县,1305 | ||
| 120 | +130581,南宫市,1305 | ||
| 121 | +130582,沙河市,1305 | ||
| 122 | +1306,保定市,13 | ||
| 123 | +130602,竞秀区,1306 | ||
| 124 | +130606,莲池区,1306 | ||
| 125 | +130607,满城区,1306 | ||
| 126 | +130608,清苑区,1306 | ||
| 127 | +130609,徐水区,1306 | ||
| 128 | +130623,涞水县,1306 | ||
| 129 | +130624,阜平县,1306 | ||
| 130 | +130626,定兴县,1306 | ||
| 131 | +130627,唐县,1306 | ||
| 132 | +130628,高阳县,1306 | ||
| 133 | +130629,容城县,1306 | ||
| 134 | +130630,涞源县,1306 | ||
| 135 | +130631,望都县,1306 | ||
| 136 | +130632,安新县,1306 | ||
| 137 | +130633,易县,1306 | ||
| 138 | +130634,曲阳县,1306 | ||
| 139 | +130635,蠡县,1306 | ||
| 140 | +130636,顺平县,1306 | ||
| 141 | +130637,博野县,1306 | ||
| 142 | +130638,雄县,1306 | ||
| 143 | +130681,涿州市,1306 | ||
| 144 | +130682,定州市,1306 | ||
| 145 | +130683,安国市,1306 | ||
| 146 | +130684,高碑店市,1306 | ||
| 147 | +1307,张家口市,13 | ||
| 148 | +130702,桥东区,1307 | ||
| 149 | +130703,桥西区,1307 | ||
| 150 | +130705,宣化区,1307 | ||
| 151 | +130706,下花园区,1307 | ||
| 152 | +130708,万全区,1307 | ||
| 153 | +130709,崇礼区,1307 | ||
| 154 | +130722,张北县,1307 | ||
| 155 | +130723,康保县,1307 | ||
| 156 | +130724,沽源县,1307 | ||
| 157 | +130725,尚义县,1307 | ||
| 158 | +130726,蔚县,1307 | ||
| 159 | +130727,阳原县,1307 | ||
| 160 | +130728,怀安县,1307 | ||
| 161 | +130730,怀来县,1307 | ||
| 162 | +130731,涿鹿县,1307 | ||
| 163 | +130732,赤城县,1307 | ||
| 164 | +1308,承德市,13 | ||
| 165 | +130802,双桥区,1308 | ||
| 166 | +130803,双滦区,1308 | ||
| 167 | +130804,鹰手营子矿区,1308 | ||
| 168 | +130821,承德县,1308 | ||
| 169 | +130822,兴隆县,1308 | ||
| 170 | +130824,滦平县,1308 | ||
| 171 | +130825,隆化县,1308 | ||
| 172 | +130826,丰宁满族自治县,1308 | ||
| 173 | +130827,宽城满族自治县,1308 | ||
| 174 | +130828,围场满族蒙古族自治县,1308 | ||
| 175 | +130881,平泉市,1308 | ||
| 176 | +1309,沧州市,13 | ||
| 177 | +130902,新华区,1309 | ||
| 178 | +130903,运河区,1309 | ||
| 179 | +130921,沧县,1309 | ||
| 180 | +130922,青县,1309 | ||
| 181 | +130923,东光县,1309 | ||
| 182 | +130924,海兴县,1309 | ||
| 183 | +130925,盐山县,1309 | ||
| 184 | +130926,肃宁县,1309 | ||
| 185 | +130927,南皮县,1309 | ||
| 186 | +130928,吴桥县,1309 | ||
| 187 | +130929,献县,1309 | ||
| 188 | +130930,孟村回族自治县,1309 | ||
| 189 | +130981,泊头市,1309 | ||
| 190 | +130982,任丘市,1309 | ||
| 191 | +130983,黄骅市,1309 | ||
| 192 | +130984,河间市,1309 | ||
| 193 | +1310,廊坊市,13 | ||
| 194 | +131002,安次区,1310 | ||
| 195 | +131003,广阳区,1310 | ||
| 196 | +131022,固安县,1310 | ||
| 197 | +131023,永清县,1310 | ||
| 198 | +131024,香河县,1310 | ||
| 199 | +131025,大城县,1310 | ||
| 200 | +131026,文安县,1310 | ||
| 201 | +131028,大厂回族自治县,1310 | ||
| 202 | +131081,霸州市,1310 | ||
| 203 | +131082,三河市,1310 | ||
| 204 | +1311,衡水市,13 | ||
| 205 | +131102,桃城区,1311 | ||
| 206 | +131103,冀州区,1311 | ||
| 207 | +131121,枣强县,1311 | ||
| 208 | +131122,武邑县,1311 | ||
| 209 | +131123,武强县,1311 | ||
| 210 | +131124,饶阳县,1311 | ||
| 211 | +131125,安平县,1311 | ||
| 212 | +131126,故城县,1311 | ||
| 213 | +131127,景县,1311 | ||
| 214 | +131128,阜城县,1311 | ||
| 215 | +131182,深州市,1311 | ||
| 216 | +14,山西省, | ||
| 217 | +1401,太原市,14 | ||
| 218 | +140105,小店区,1401 | ||
| 219 | +140106,迎泽区,1401 | ||
| 220 | +140107,杏花岭区,1401 | ||
| 221 | +140108,尖草坪区,1401 | ||
| 222 | +140109,万柏林区,1401 | ||
| 223 | +140110,晋源区,1401 | ||
| 224 | +140121,清徐县,1401 | ||
| 225 | +140122,阳曲县,1401 | ||
| 226 | +140123,娄烦县,1401 | ||
| 227 | +140181,古交市,1401 | ||
| 228 | +1402,大同市,14 | ||
| 229 | +140212,新荣区,1402 | ||
| 230 | +140213,平城区,1402 | ||
| 231 | +140214,云冈区,1402 | ||
| 232 | +140215,云州区,1402 | ||
| 233 | +140221,阳高县,1402 | ||
| 234 | +140222,天镇县,1402 | ||
| 235 | +140223,广灵县,1402 | ||
| 236 | +140224,灵丘县,1402 | ||
| 237 | +140225,浑源县,1402 | ||
| 238 | +140226,左云县,1402 | ||
| 239 | +1403,阳泉市,14 | ||
| 240 | +140302,城区,1403 | ||
| 241 | +140303,矿区,1403 | ||
| 242 | +140311,郊区,1403 | ||
| 243 | +140321,平定县,1403 | ||
| 244 | +140322,盂县,1403 | ||
| 245 | +1404,长治市,14 | ||
| 246 | +140403,潞州区,1404 | ||
| 247 | +140404,上党区,1404 | ||
| 248 | +140405,屯留区,1404 | ||
| 249 | +140406,潞城区,1404 | ||
| 250 | +140423,襄垣县,1404 | ||
| 251 | +140425,平顺县,1404 | ||
| 252 | +140426,黎城县,1404 | ||
| 253 | +140427,壶关县,1404 | ||
| 254 | +140428,长子县,1404 | ||
| 255 | +140429,武乡县,1404 | ||
| 256 | +140430,沁县,1404 | ||
| 257 | +140431,沁源县,1404 | ||
| 258 | +1405,晋城市,14 | ||
| 259 | +140502,城区,1405 | ||
| 260 | +140521,沁水县,1405 | ||
| 261 | +140522,阳城县,1405 | ||
| 262 | +140524,陵川县,1405 | ||
| 263 | +140525,泽州县,1405 | ||
| 264 | +140581,高平市,1405 | ||
| 265 | +1406,朔州市,14 | ||
| 266 | +140602,朔城区,1406 | ||
| 267 | +140603,平鲁区,1406 | ||
| 268 | +140621,山阴县,1406 | ||
| 269 | +140622,应县,1406 | ||
| 270 | +140623,右玉县,1406 | ||
| 271 | +140681,怀仁市,1406 | ||
| 272 | +1407,晋中市,14 | ||
| 273 | +140702,榆次区,1407 | ||
| 274 | +140721,榆社县,1407 | ||
| 275 | +140722,左权县,1407 | ||
| 276 | +140723,和顺县,1407 | ||
| 277 | +140724,昔阳县,1407 | ||
| 278 | +140725,寿阳县,1407 | ||
| 279 | +140726,太谷县,1407 | ||
| 280 | +140727,祁县,1407 | ||
| 281 | +140728,平遥县,1407 | ||
| 282 | +140729,灵石县,1407 | ||
| 283 | +140781,介休市,1407 | ||
| 284 | +1408,运城市,14 | ||
| 285 | +140802,盐湖区,1408 | ||
| 286 | +140821,临猗县,1408 | ||
| 287 | +140822,万荣县,1408 | ||
| 288 | +140823,闻喜县,1408 | ||
| 289 | +140824,稷山县,1408 | ||
| 290 | +140825,新绛县,1408 | ||
| 291 | +140826,绛县,1408 | ||
| 292 | +140827,垣曲县,1408 | ||
| 293 | +140828,夏县,1408 | ||
| 294 | +140829,平陆县,1408 | ||
| 295 | +140830,芮城县,1408 | ||
| 296 | +140881,永济市,1408 | ||
| 297 | +140882,河津市,1408 | ||
| 298 | +1409,忻州市,14 | ||
| 299 | +140902,忻府区,1409 | ||
| 300 | +140921,定襄县,1409 | ||
| 301 | +140922,五台县,1409 | ||
| 302 | +140923,代县,1409 | ||
| 303 | +140924,繁峙县,1409 | ||
| 304 | +140925,宁武县,1409 | ||
| 305 | +140926,静乐县,1409 | ||
| 306 | +140927,神池县,1409 | ||
| 307 | +140928,五寨县,1409 | ||
| 308 | +140929,岢岚县,1409 | ||
| 309 | +140930,河曲县,1409 | ||
| 310 | +140931,保德县,1409 | ||
| 311 | +140932,偏关县,1409 | ||
| 312 | +140981,原平市,1409 | ||
| 313 | +1410,临汾市,14 | ||
| 314 | +141002,尧都区,1410 | ||
| 315 | +141021,曲沃县,1410 | ||
| 316 | +141022,翼城县,1410 | ||
| 317 | +141023,襄汾县,1410 | ||
| 318 | +141024,洪洞县,1410 | ||
| 319 | +141025,古县,1410 | ||
| 320 | +141026,安泽县,1410 | ||
| 321 | +141027,浮山县,1410 | ||
| 322 | +141028,吉县,1410 | ||
| 323 | +141029,乡宁县,1410 | ||
| 324 | +141030,大宁县,1410 | ||
| 325 | +141031,隰县,1410 | ||
| 326 | +141032,永和县,1410 | ||
| 327 | +141033,蒲县,1410 | ||
| 328 | +141034,汾西县,1410 | ||
| 329 | +141081,侯马市,1410 | ||
| 330 | +141082,霍州市,1410 | ||
| 331 | +1411,吕梁市,14 | ||
| 332 | +141102,离石区,1411 | ||
| 333 | +141121,文水县,1411 | ||
| 334 | +141122,交城县,1411 | ||
| 335 | +141123,兴县,1411 | ||
| 336 | +141124,临县,1411 | ||
| 337 | +141125,柳林县,1411 | ||
| 338 | +141126,石楼县,1411 | ||
| 339 | +141127,岚县,1411 | ||
| 340 | +141128,方山县,1411 | ||
| 341 | +141129,中阳县,1411 | ||
| 342 | +141130,交口县,1411 | ||
| 343 | +141181,孝义市,1411 | ||
| 344 | +141182,汾阳市,1411 | ||
| 345 | +15,内蒙古自治区, | ||
| 346 | +1501,呼和浩特市,15 | ||
| 347 | +150102,新城区,1501 | ||
| 348 | +150103,回民区,1501 | ||
| 349 | +150104,玉泉区,1501 | ||
| 350 | +150105,赛罕区,1501 | ||
| 351 | +150121,土默特左旗,1501 | ||
| 352 | +150122,托克托县,1501 | ||
| 353 | +150123,和林格尔县,1501 | ||
| 354 | +150124,清水河县,1501 | ||
| 355 | +150125,武川县,1501 | ||
| 356 | +1502,包头市,15 | ||
| 357 | +150202,东河区,1502 | ||
| 358 | +150203,昆都仑区,1502 | ||
| 359 | +150204,青山区,1502 | ||
| 360 | +150205,石拐区,1502 | ||
| 361 | +150206,白云鄂博矿区,1502 | ||
| 362 | +150207,九原区,1502 | ||
| 363 | +150221,土默特右旗,1502 | ||
| 364 | +150222,固阳县,1502 | ||
| 365 | +150223,达尔罕茂明安联合旗,1502 | ||
| 366 | +1503,乌海市,15 | ||
| 367 | +150302,海勃湾区,1503 | ||
| 368 | +150303,海南区,1503 | ||
| 369 | +150304,乌达区,1503 | ||
| 370 | +1504,赤峰市,15 | ||
| 371 | +150402,红山区,1504 | ||
| 372 | +150403,元宝山区,1504 | ||
| 373 | +150404,松山区,1504 | ||
| 374 | +150421,阿鲁科尔沁旗,1504 | ||
| 375 | +150422,巴林左旗,1504 | ||
| 376 | +150423,巴林右旗,1504 | ||
| 377 | +150424,林西县,1504 | ||
| 378 | +150425,克什克腾旗,1504 | ||
| 379 | +150426,翁牛特旗,1504 | ||
| 380 | +150428,喀喇沁旗,1504 | ||
| 381 | +150429,宁城县,1504 | ||
| 382 | +150430,敖汉旗,1504 | ||
| 383 | +1505,通辽市,15 | ||
| 384 | +150502,科尔沁区,1505 | ||
| 385 | +150521,科尔沁左翼中旗,1505 | ||
| 386 | +150522,科尔沁左翼后旗,1505 | ||
| 387 | +150523,开鲁县,1505 | ||
| 388 | +150524,库伦旗,1505 | ||
| 389 | +150525,奈曼旗,1505 | ||
| 390 | +150526,扎鲁特旗,1505 | ||
| 391 | +150581,霍林郭勒市,1505 | ||
| 392 | +1506,鄂尔多斯市,15 | ||
| 393 | +150602,东胜区,1506 | ||
| 394 | +150603,康巴什区,1506 | ||
| 395 | +150621,达拉特旗,1506 | ||
| 396 | +150622,准格尔旗,1506 | ||
| 397 | +150623,鄂托克前旗,1506 | ||
| 398 | +150624,鄂托克旗,1506 | ||
| 399 | +150625,杭锦旗,1506 | ||
| 400 | +150626,乌审旗,1506 | ||
| 401 | +150627,伊金霍洛旗,1506 | ||
| 402 | +1507,呼伦贝尔市,15 | ||
| 403 | +150702,海拉尔区,1507 | ||
| 404 | +150703,扎赉诺尔区,1507 | ||
| 405 | +150721,阿荣旗,1507 | ||
| 406 | +150722,莫力达瓦达斡尔族自治旗,1507 | ||
| 407 | +150723,鄂伦春自治旗,1507 | ||
| 408 | +150724,鄂温克族自治旗,1507 | ||
| 409 | +150725,陈巴尔虎旗,1507 | ||
| 410 | +150726,新巴尔虎左旗,1507 | ||
| 411 | +150727,新巴尔虎右旗,1507 | ||
| 412 | +150781,满洲里市,1507 | ||
| 413 | +150782,牙克石市,1507 | ||
| 414 | +150783,扎兰屯市,1507 | ||
| 415 | +150784,额尔古纳市,1507 | ||
| 416 | +150785,根河市,1507 | ||
| 417 | +1508,巴彦淖尔市,15 | ||
| 418 | +150802,临河区,1508 | ||
| 419 | +150821,五原县,1508 | ||
| 420 | +150822,磴口县,1508 | ||
| 421 | +150823,乌拉特前旗,1508 | ||
| 422 | +150824,乌拉特中旗,1508 | ||
| 423 | +150825,乌拉特后旗,1508 | ||
| 424 | +150826,杭锦后旗,1508 | ||
| 425 | +1509,乌兰察布市,15 | ||
| 426 | +150902,集宁区,1509 | ||
| 427 | +150921,卓资县,1509 | ||
| 428 | +150922,化德县,1509 | ||
| 429 | +150923,商都县,1509 | ||
| 430 | +150924,兴和县,1509 | ||
| 431 | +150925,凉城县,1509 | ||
| 432 | +150926,察哈尔右翼前旗,1509 | ||
| 433 | +150927,察哈尔右翼中旗,1509 | ||
| 434 | +150928,察哈尔右翼后旗,1509 | ||
| 435 | +150929,四子王旗,1509 | ||
| 436 | +150981,丰镇市,1509 | ||
| 437 | +1522,兴安盟,15 | ||
| 438 | +152201,乌兰浩特市,1522 | ||
| 439 | +152202,阿尔山市,1522 | ||
| 440 | +152221,科尔沁右翼前旗,1522 | ||
| 441 | +152222,科尔沁右翼中旗,1522 | ||
| 442 | +152223,扎赉特旗,1522 | ||
| 443 | +152224,突泉县,1522 | ||
| 444 | +1525,锡林郭勒盟,15 | ||
| 445 | +152501,二连浩特市,1525 | ||
| 446 | +152502,锡林浩特市,1525 | ||
| 447 | +152522,阿巴嘎旗,1525 | ||
| 448 | +152523,苏尼特左旗,1525 | ||
| 449 | +152524,苏尼特右旗,1525 | ||
| 450 | +152525,东乌珠穆沁旗,1525 | ||
| 451 | +152526,西乌珠穆沁旗,1525 | ||
| 452 | +152527,太仆寺旗,1525 | ||
| 453 | +152528,镶黄旗,1525 | ||
| 454 | +152529,正镶白旗,1525 | ||
| 455 | +152530,正蓝旗,1525 | ||
| 456 | +152531,多伦县,1525 | ||
| 457 | +1529,阿拉善盟,15 | ||
| 458 | +152921,阿拉善左旗,1529 | ||
| 459 | +152922,阿拉善右旗,1529 | ||
| 460 | +152923,额济纳旗,1529 | ||
| 461 | +21,辽宁省, | ||
| 462 | +2101,沈阳市,21 | ||
| 463 | +210102,和平区,2101 | ||
| 464 | +210103,沈河区,2101 | ||
| 465 | +210104,大东区,2101 | ||
| 466 | +210105,皇姑区,2101 | ||
| 467 | +210106,铁西区,2101 | ||
| 468 | +210111,苏家屯区,2101 | ||
| 469 | +210112,浑南区,2101 | ||
| 470 | +210113,沈北新区,2101 | ||
| 471 | +210114,于洪区,2101 | ||
| 472 | +210115,辽中区,2101 | ||
| 473 | +210123,康平县,2101 | ||
| 474 | +210124,法库县,2101 | ||
| 475 | +210181,新民市,2101 | ||
| 476 | +2102,大连市,21 | ||
| 477 | +210202,中山区,2102 | ||
| 478 | +210203,西岗区,2102 | ||
| 479 | +210204,沙河口区,2102 | ||
| 480 | +210211,甘井子区,2102 | ||
| 481 | +210212,旅顺口区,2102 | ||
| 482 | +210213,金州区,2102 | ||
| 483 | +210214,普兰店区,2102 | ||
| 484 | +210224,长海县,2102 | ||
| 485 | +210281,瓦房店市,2102 | ||
| 486 | +210283,庄河市,2102 | ||
| 487 | +2103,鞍山市,21 | ||
| 488 | +210302,铁东区,2103 | ||
| 489 | +210303,铁西区,2103 | ||
| 490 | +210304,立山区,2103 | ||
| 491 | +210311,千山区,2103 | ||
| 492 | +210321,台安县,2103 | ||
| 493 | +210323,岫岩满族自治县,2103 | ||
| 494 | +210381,海城市,2103 | ||
| 495 | +2104,抚顺市,21 | ||
| 496 | +210402,新抚区,2104 | ||
| 497 | +210403,东洲区,2104 | ||
| 498 | +210404,望花区,2104 | ||
| 499 | +210411,顺城区,2104 | ||
| 500 | +210421,抚顺县,2104 | ||
| 501 | +210422,新宾满族自治县,2104 | ||
| 502 | +210423,清原满族自治县,2104 | ||
| 503 | +2105,本溪市,21 | ||
| 504 | +210502,平山区,2105 | ||
| 505 | +210503,溪湖区,2105 | ||
| 506 | +210504,明山区,2105 | ||
| 507 | +210505,南芬区,2105 | ||
| 508 | +210521,本溪满族自治县,2105 | ||
| 509 | +210522,桓仁满族自治县,2105 | ||
| 510 | +2106,丹东市,21 | ||
| 511 | +210602,元宝区,2106 | ||
| 512 | +210603,振兴区,2106 | ||
| 513 | +210604,振安区,2106 | ||
| 514 | +210624,宽甸满族自治县,2106 | ||
| 515 | +210681,东港市,2106 | ||
| 516 | +210682,凤城市,2106 | ||
| 517 | +2107,锦州市,21 | ||
| 518 | +210702,古塔区,2107 | ||
| 519 | +210703,凌河区,2107 | ||
| 520 | +210711,太和区,2107 | ||
| 521 | +210726,黑山县,2107 | ||
| 522 | +210727,义县,2107 | ||
| 523 | +210781,凌海市,2107 | ||
| 524 | +210782,北镇市,2107 | ||
| 525 | +2108,营口市,21 | ||
| 526 | +210802,站前区,2108 | ||
| 527 | +210803,西市区,2108 | ||
| 528 | +210804,鲅鱼圈区,2108 | ||
| 529 | +210811,老边区,2108 | ||
| 530 | +210881,盖州市,2108 | ||
| 531 | +210882,大石桥市,2108 | ||
| 532 | +2109,阜新市,21 | ||
| 533 | +210902,海州区,2109 | ||
| 534 | +210903,新邱区,2109 | ||
| 535 | +210904,太平区,2109 | ||
| 536 | +210905,清河门区,2109 | ||
| 537 | +210911,细河区,2109 | ||
| 538 | +210921,阜新蒙古族自治县,2109 | ||
| 539 | +210922,彰武县,2109 | ||
| 540 | +2110,辽阳市,21 | ||
| 541 | +211002,白塔区,2110 | ||
| 542 | +211003,文圣区,2110 | ||
| 543 | +211004,宏伟区,2110 | ||
| 544 | +211005,弓长岭区,2110 | ||
| 545 | +211011,太子河区,2110 | ||
| 546 | +211021,辽阳县,2110 | ||
| 547 | +211081,灯塔市,2110 | ||
| 548 | +2111,盘锦市,21 | ||
| 549 | +211102,双台子区,2111 | ||
| 550 | +211103,兴隆台区,2111 | ||
| 551 | +211104,大洼区,2111 | ||
| 552 | +211122,盘山县,2111 | ||
| 553 | +2112,铁岭市,21 | ||
| 554 | +211202,银州区,2112 | ||
| 555 | +211204,清河区,2112 | ||
| 556 | +211221,铁岭县,2112 | ||
| 557 | +211223,西丰县,2112 | ||
| 558 | +211224,昌图县,2112 | ||
| 559 | +211281,调兵山市,2112 | ||
| 560 | +211282,开原市,2112 | ||
| 561 | +2113,朝阳市,21 | ||
| 562 | +211302,双塔区,2113 | ||
| 563 | +211303,龙城区,2113 | ||
| 564 | +211321,朝阳县,2113 | ||
| 565 | +211322,建平县,2113 | ||
| 566 | +211324,喀喇沁左翼蒙古族自治县,2113 | ||
| 567 | +211381,北票市,2113 | ||
| 568 | +211382,凌源市,2113 | ||
| 569 | +2114,葫芦岛市,21 | ||
| 570 | +211402,连山区,2114 | ||
| 571 | +211403,龙港区,2114 | ||
| 572 | +211404,南票区,2114 | ||
| 573 | +211421,绥中县,2114 | ||
| 574 | +211422,建昌县,2114 | ||
| 575 | +211481,兴城市,2114 | ||
| 576 | +22,吉林省, | ||
| 577 | +2201,长春市,22 | ||
| 578 | +220102,南关区,2201 | ||
| 579 | +220103,宽城区,2201 | ||
| 580 | +220104,朝阳区,2201 | ||
| 581 | +220105,二道区,2201 | ||
| 582 | +220106,绿园区,2201 | ||
| 583 | +220112,双阳区,2201 | ||
| 584 | +220113,九台区,2201 | ||
| 585 | +220122,农安县,2201 | ||
| 586 | +220182,榆树市,2201 | ||
| 587 | +220183,德惠市,2201 | ||
| 588 | +2202,吉林市,22 | ||
| 589 | +220202,昌邑区,2202 | ||
| 590 | +220203,龙潭区,2202 | ||
| 591 | +220204,船营区,2202 | ||
| 592 | +220211,丰满区,2202 | ||
| 593 | +220221,永吉县,2202 | ||
| 594 | +220281,蛟河市,2202 | ||
| 595 | +220282,桦甸市,2202 | ||
| 596 | +220283,舒兰市,2202 | ||
| 597 | +220284,磐石市,2202 | ||
| 598 | +2203,四平市,22 | ||
| 599 | +220302,铁西区,2203 | ||
| 600 | +220303,铁东区,2203 | ||
| 601 | +220322,梨树县,2203 | ||
| 602 | +220323,伊通满族自治县,2203 | ||
| 603 | +220381,公主岭市,2203 | ||
| 604 | +220382,双辽市,2203 | ||
| 605 | +2204,辽源市,22 | ||
| 606 | +220402,龙山区,2204 | ||
| 607 | +220403,西安区,2204 | ||
| 608 | +220421,东丰县,2204 | ||
| 609 | +220422,东辽县,2204 | ||
| 610 | +2205,通化市,22 | ||
| 611 | +220502,东昌区,2205 | ||
| 612 | +220503,二道江区,2205 | ||
| 613 | +220521,通化县,2205 | ||
| 614 | +220523,辉南县,2205 | ||
| 615 | +220524,柳河县,2205 | ||
| 616 | +220581,梅河口市,2205 | ||
| 617 | +220582,集安市,2205 | ||
| 618 | +2206,白山市,22 | ||
| 619 | +220602,浑江区,2206 | ||
| 620 | +220605,江源区,2206 | ||
| 621 | +220621,抚松县,2206 | ||
| 622 | +220622,靖宇县,2206 | ||
| 623 | +220623,长白朝鲜族自治县,2206 | ||
| 624 | +220681,临江市,2206 | ||
| 625 | +2207,松原市,22 | ||
| 626 | +220702,宁江区,2207 | ||
| 627 | +220721,前郭尔罗斯蒙古族自治县,2207 | ||
| 628 | +220722,长岭县,2207 | ||
| 629 | +220723,乾安县,2207 | ||
| 630 | +220781,扶余市,2207 | ||
| 631 | +2208,白城市,22 | ||
| 632 | +220802,洮北区,2208 | ||
| 633 | +220821,镇赉县,2208 | ||
| 634 | +220822,通榆县,2208 | ||
| 635 | +220881,洮南市,2208 | ||
| 636 | +220882,大安市,2208 | ||
| 637 | +2224,延边朝鲜族自治州,22 | ||
| 638 | +222401,延吉市,2224 | ||
| 639 | +222402,图们市,2224 | ||
| 640 | +222403,敦化市,2224 | ||
| 641 | +222404,珲春市,2224 | ||
| 642 | +222405,龙井市,2224 | ||
| 643 | +222406,和龙市,2224 | ||
| 644 | +222424,汪清县,2224 | ||
| 645 | +222426,安图县,2224 | ||
| 646 | +23,黑龙江省, | ||
| 647 | +2301,哈尔滨市,23 | ||
| 648 | +230102,道里区,2301 | ||
| 649 | +230103,南岗区,2301 | ||
| 650 | +230104,道外区,2301 | ||
| 651 | +230108,平房区,2301 | ||
| 652 | +230109,松北区,2301 | ||
| 653 | +230110,香坊区,2301 | ||
| 654 | +230111,呼兰区,2301 | ||
| 655 | +230112,阿城区,2301 | ||
| 656 | +230113,双城区,2301 | ||
| 657 | +230123,依兰县,2301 | ||
| 658 | +230124,方正县,2301 | ||
| 659 | +230125,宾县,2301 | ||
| 660 | +230126,巴彦县,2301 | ||
| 661 | +230127,木兰县,2301 | ||
| 662 | +230128,通河县,2301 | ||
| 663 | +230129,延寿县,2301 | ||
| 664 | +230183,尚志市,2301 | ||
| 665 | +230184,五常市,2301 | ||
| 666 | +2302,齐齐哈尔市,23 | ||
| 667 | +230202,龙沙区,2302 | ||
| 668 | +230203,建华区,2302 | ||
| 669 | +230204,铁锋区,2302 | ||
| 670 | +230205,昂昂溪区,2302 | ||
| 671 | +230206,富拉尔基区,2302 | ||
| 672 | +230207,碾子山区,2302 | ||
| 673 | +230208,梅里斯达斡尔族区,2302 | ||
| 674 | +230221,龙江县,2302 | ||
| 675 | +230223,依安县,2302 | ||
| 676 | +230224,泰来县,2302 | ||
| 677 | +230225,甘南县,2302 | ||
| 678 | +230227,富裕县,2302 | ||
| 679 | +230229,克山县,2302 | ||
| 680 | +230230,克东县,2302 | ||
| 681 | +230231,拜泉县,2302 | ||
| 682 | +230281,讷河市,2302 | ||
| 683 | +2303,鸡西市,23 | ||
| 684 | +230302,鸡冠区,2303 | ||
| 685 | +230303,恒山区,2303 | ||
| 686 | +230304,滴道区,2303 | ||
| 687 | +230305,梨树区,2303 | ||
| 688 | +230306,城子河区,2303 | ||
| 689 | +230307,麻山区,2303 | ||
| 690 | +230321,鸡东县,2303 | ||
| 691 | +230381,虎林市,2303 | ||
| 692 | +230382,密山市,2303 | ||
| 693 | +2304,鹤岗市,23 | ||
| 694 | +230402,向阳区,2304 | ||
| 695 | +230403,工农区,2304 | ||
| 696 | +230404,南山区,2304 | ||
| 697 | +230405,兴安区,2304 | ||
| 698 | +230406,东山区,2304 | ||
| 699 | +230407,兴山区,2304 | ||
| 700 | +230421,萝北县,2304 | ||
| 701 | +230422,绥滨县,2304 | ||
| 702 | +2305,双鸭山市,23 | ||
| 703 | +230502,尖山区,2305 | ||
| 704 | +230503,岭东区,2305 | ||
| 705 | +230505,四方台区,2305 | ||
| 706 | +230506,宝山区,2305 | ||
| 707 | +230521,集贤县,2305 | ||
| 708 | +230522,友谊县,2305 | ||
| 709 | +230523,宝清县,2305 | ||
| 710 | +230524,饶河县,2305 | ||
| 711 | +2306,大庆市,23 | ||
| 712 | +230602,萨尔图区,2306 | ||
| 713 | +230603,龙凤区,2306 | ||
| 714 | +230604,让胡路区,2306 | ||
| 715 | +230605,红岗区,2306 | ||
| 716 | +230606,大同区,2306 | ||
| 717 | +230621,肇州县,2306 | ||
| 718 | +230622,肇源县,2306 | ||
| 719 | +230623,林甸县,2306 | ||
| 720 | +230624,杜尔伯特蒙古族自治县,2306 | ||
| 721 | +2307,伊春市,23 | ||
| 722 | +230702,伊春区,2307 | ||
| 723 | +230703,南岔区,2307 | ||
| 724 | +230704,友好区,2307 | ||
| 725 | +230705,西林区,2307 | ||
| 726 | +230706,翠峦区,2307 | ||
| 727 | +230707,新青区,2307 | ||
| 728 | +230708,美溪区,2307 | ||
| 729 | +230709,金山屯区,2307 | ||
| 730 | +230710,五营区,2307 | ||
| 731 | +230711,乌马河区,2307 | ||
| 732 | +230712,汤旺河区,2307 | ||
| 733 | +230713,带岭区,2307 | ||
| 734 | +230714,乌伊岭区,2307 | ||
| 735 | +230715,红星区,2307 | ||
| 736 | +230716,上甘岭区,2307 | ||
| 737 | +230722,嘉荫县,2307 | ||
| 738 | +230781,铁力市,2307 | ||
| 739 | +2308,佳木斯市,23 | ||
| 740 | +230803,向阳区,2308 | ||
| 741 | +230804,前进区,2308 | ||
| 742 | +230805,东风区,2308 | ||
| 743 | +230811,郊区,2308 | ||
| 744 | +230822,桦南县,2308 | ||
| 745 | +230826,桦川县,2308 | ||
| 746 | +230828,汤原县,2308 | ||
| 747 | +230881,同江市,2308 | ||
| 748 | +230882,富锦市,2308 | ||
| 749 | +230883,抚远市,2308 | ||
| 750 | +2309,七台河市,23 | ||
| 751 | +230902,新兴区,2309 | ||
| 752 | +230903,桃山区,2309 | ||
| 753 | +230904,茄子河区,2309 | ||
| 754 | +230921,勃利县,2309 | ||
| 755 | +2310,牡丹江市,23 | ||
| 756 | +231002,东安区,2310 | ||
| 757 | +231003,阳明区,2310 | ||
| 758 | +231004,爱民区,2310 | ||
| 759 | +231005,西安区,2310 | ||
| 760 | +231025,林口县,2310 | ||
| 761 | +231081,绥芬河市,2310 | ||
| 762 | +231083,海林市,2310 | ||
| 763 | +231084,宁安市,2310 | ||
| 764 | +231085,穆棱市,2310 | ||
| 765 | +231086,东宁市,2310 | ||
| 766 | +2311,黑河市,23 | ||
| 767 | +231102,爱辉区,2311 | ||
| 768 | +231121,嫩江县,2311 | ||
| 769 | +231123,逊克县,2311 | ||
| 770 | +231124,孙吴县,2311 | ||
| 771 | +231181,北安市,2311 | ||
| 772 | +231182,五大连池市,2311 | ||
| 773 | +2312,绥化市,23 | ||
| 774 | +231202,北林区,2312 | ||
| 775 | +231221,望奎县,2312 | ||
| 776 | +231222,兰西县,2312 | ||
| 777 | +231223,青冈县,2312 | ||
| 778 | +231224,庆安县,2312 | ||
| 779 | +231225,明水县,2312 | ||
| 780 | +231226,绥棱县,2312 | ||
| 781 | +231281,安达市,2312 | ||
| 782 | +231282,肇东市,2312 | ||
| 783 | +231283,海伦市,2312 | ||
| 784 | +2327,大兴安岭地区,23 | ||
| 785 | +232701,漠河市,2327 | ||
| 786 | +232721,呼玛县,2327 | ||
| 787 | +232722,塔河县,2327 | ||
| 788 | +31,上海市, | ||
| 789 | +310101,黄浦区,31 | ||
| 790 | +310104,徐汇区,31 | ||
| 791 | +310105,长宁区,31 | ||
| 792 | +310106,静安区,31 | ||
| 793 | +310107,普陀区,31 | ||
| 794 | +310109,虹口区,31 | ||
| 795 | +310110,杨浦区,31 | ||
| 796 | +310112,闵行区,31 | ||
| 797 | +310113,宝山区,31 | ||
| 798 | +310114,嘉定区,31 | ||
| 799 | +310115,浦东新区,31 | ||
| 800 | +310116,金山区,31 | ||
| 801 | +310117,松江区,31 | ||
| 802 | +310118,青浦区,31 | ||
| 803 | +310120,奉贤区,31 | ||
| 804 | +310151,崇明区,31 | ||
| 805 | +32,江苏省, | ||
| 806 | +3201,南京市,32 | ||
| 807 | +320102,玄武区,3201 | ||
| 808 | +320104,秦淮区,3201 | ||
| 809 | +320105,建邺区,3201 | ||
| 810 | +320106,鼓楼区,3201 | ||
| 811 | +320111,浦口区,3201 | ||
| 812 | +320113,栖霞区,3201 | ||
| 813 | +320114,雨花台区,3201 | ||
| 814 | +320115,江宁区,3201 | ||
| 815 | +320116,六合区,3201 | ||
| 816 | +320117,溧水区,3201 | ||
| 817 | +320118,高淳区,3201 | ||
| 818 | +3202,无锡市,32 | ||
| 819 | +320205,锡山区,3202 | ||
| 820 | +320206,惠山区,3202 | ||
| 821 | +320211,滨湖区,3202 | ||
| 822 | +320213,梁溪区,3202 | ||
| 823 | +320214,新吴区,3202 | ||
| 824 | +320281,江阴市,3202 | ||
| 825 | +320282,宜兴市,3202 | ||
| 826 | +3203,徐州市,32 | ||
| 827 | +320302,鼓楼区,3203 | ||
| 828 | +320303,云龙区,3203 | ||
| 829 | +320305,贾汪区,3203 | ||
| 830 | +320311,泉山区,3203 | ||
| 831 | +320312,铜山区,3203 | ||
| 832 | +320321,丰县,3203 | ||
| 833 | +320322,沛县,3203 | ||
| 834 | +320324,睢宁县,3203 | ||
| 835 | +320381,新沂市,3203 | ||
| 836 | +320382,邳州市,3203 | ||
| 837 | +3204,常州市,32 | ||
| 838 | +320402,天宁区,3204 | ||
| 839 | +320404,钟楼区,3204 | ||
| 840 | +320411,新北区,3204 | ||
| 841 | +320412,武进区,3204 | ||
| 842 | +320413,金坛区,3204 | ||
| 843 | +320481,溧阳市,3204 | ||
| 844 | +3205,苏州市,32 | ||
| 845 | +320505,虎丘区,3205 | ||
| 846 | +320506,吴中区,3205 | ||
| 847 | +320507,相城区,3205 | ||
| 848 | +320508,姑苏区,3205 | ||
| 849 | +320509,吴江区,3205 | ||
| 850 | +320581,常熟市,3205 | ||
| 851 | +320582,张家港市,3205 | ||
| 852 | +320583,昆山市,3205 | ||
| 853 | +320585,太仓市,3205 | ||
| 854 | +3206,南通市,32 | ||
| 855 | +320602,崇川区,3206 | ||
| 856 | +320611,港闸区,3206 | ||
| 857 | +320612,通州区,3206 | ||
| 858 | +320623,如东县,3206 | ||
| 859 | +320681,启东市,3206 | ||
| 860 | +320682,如皋市,3206 | ||
| 861 | +320684,海门市,3206 | ||
| 862 | +320685,海安市,3206 | ||
| 863 | +3207,连云港市,32 | ||
| 864 | +320703,连云区,3207 | ||
| 865 | +320706,海州区,3207 | ||
| 866 | +320707,赣榆区,3207 | ||
| 867 | +320722,东海县,3207 | ||
| 868 | +320723,灌云县,3207 | ||
| 869 | +320724,灌南县,3207 | ||
| 870 | +3208,淮安市,32 | ||
| 871 | +320803,淮安区,3208 | ||
| 872 | +320804,淮阴区,3208 | ||
| 873 | +320812,清江浦区,3208 | ||
| 874 | +320813,洪泽区,3208 | ||
| 875 | +320826,涟水县,3208 | ||
| 876 | +320830,盱眙县,3208 | ||
| 877 | +320831,金湖县,3208 | ||
| 878 | +3209,盐城市,32 | ||
| 879 | +320902,亭湖区,3209 | ||
| 880 | +320903,盐都区,3209 | ||
| 881 | +320904,大丰区,3209 | ||
| 882 | +320921,响水县,3209 | ||
| 883 | +320922,滨海县,3209 | ||
| 884 | +320923,阜宁县,3209 | ||
| 885 | +320924,射阳县,3209 | ||
| 886 | +320925,建湖县,3209 | ||
| 887 | +320981,东台市,3209 | ||
| 888 | +3210,扬州市,32 | ||
| 889 | +321002,广陵区,3210 | ||
| 890 | +321003,邗江区,3210 | ||
| 891 | +321012,江都区,3210 | ||
| 892 | +321023,宝应县,3210 | ||
| 893 | +321081,仪征市,3210 | ||
| 894 | +321084,高邮市,3210 | ||
| 895 | +3211,镇江市,32 | ||
| 896 | +321102,京口区,3211 | ||
| 897 | +321111,润州区,3211 | ||
| 898 | +321112,丹徒区,3211 | ||
| 899 | +321181,丹阳市,3211 | ||
| 900 | +321182,扬中市,3211 | ||
| 901 | +321183,句容市,3211 | ||
| 902 | +3212,泰州市,32 | ||
| 903 | +321202,海陵区,3212 | ||
| 904 | +321203,高港区,3212 | ||
| 905 | +321204,姜堰区,3212 | ||
| 906 | +321281,兴化市,3212 | ||
| 907 | +321282,靖江市,3212 | ||
| 908 | +321283,泰兴市,3212 | ||
| 909 | +3213,宿迁市,32 | ||
| 910 | +321302,宿城区,3213 | ||
| 911 | +321311,宿豫区,3213 | ||
| 912 | +321322,沭阳县,3213 | ||
| 913 | +321323,泗阳县,3213 | ||
| 914 | +321324,泗洪县,3213 | ||
| 915 | +33,浙江省, | ||
| 916 | +3301,杭州市,33 | ||
| 917 | +330102,上城区,3301 | ||
| 918 | +330103,下城区,3301 | ||
| 919 | +330104,江干区,3301 | ||
| 920 | +330105,拱墅区,3301 | ||
| 921 | +330106,西湖区,3301 | ||
| 922 | +330108,滨江区,3301 | ||
| 923 | +330109,萧山区,3301 | ||
| 924 | +330110,余杭区,3301 | ||
| 925 | +330111,富阳区,3301 | ||
| 926 | +330112,临安区,3301 | ||
| 927 | +330122,桐庐县,3301 | ||
| 928 | +330127,淳安县,3301 | ||
| 929 | +330182,建德市,3301 | ||
| 930 | +3302,宁波市,33 | ||
| 931 | +330203,海曙区,3302 | ||
| 932 | +330205,江北区,3302 | ||
| 933 | +330206,北仑区,3302 | ||
| 934 | +330211,镇海区,3302 | ||
| 935 | +330212,鄞州区,3302 | ||
| 936 | +330213,奉化区,3302 | ||
| 937 | +330225,象山县,3302 | ||
| 938 | +330226,宁海县,3302 | ||
| 939 | +330281,余姚市,3302 | ||
| 940 | +330282,慈溪市,3302 | ||
| 941 | +3303,温州市,33 | ||
| 942 | +330302,鹿城区,3303 | ||
| 943 | +330303,龙湾区,3303 | ||
| 944 | +330304,瓯海区,3303 | ||
| 945 | +330305,洞头区,3303 | ||
| 946 | +330324,永嘉县,3303 | ||
| 947 | +330326,平阳县,3303 | ||
| 948 | +330327,苍南县,3303 | ||
| 949 | +330328,文成县,3303 | ||
| 950 | +330329,泰顺县,3303 | ||
| 951 | +330381,瑞安市,3303 | ||
| 952 | +330382,乐清市,3303 | ||
| 953 | +3304,嘉兴市,33 | ||
| 954 | +330402,南湖区,3304 | ||
| 955 | +330411,秀洲区,3304 | ||
| 956 | +330421,嘉善县,3304 | ||
| 957 | +330424,海盐县,3304 | ||
| 958 | +330481,海宁市,3304 | ||
| 959 | +330482,平湖市,3304 | ||
| 960 | +330483,桐乡市,3304 | ||
| 961 | +3305,湖州市,33 | ||
| 962 | +330502,吴兴区,3305 | ||
| 963 | +330503,南浔区,3305 | ||
| 964 | +330521,德清县,3305 | ||
| 965 | +330522,长兴县,3305 | ||
| 966 | +330523,安吉县,3305 | ||
| 967 | +3306,绍兴市,33 | ||
| 968 | +330602,越城区,3306 | ||
| 969 | +330603,柯桥区,3306 | ||
| 970 | +330604,上虞区,3306 | ||
| 971 | +330624,新昌县,3306 | ||
| 972 | +330681,诸暨市,3306 | ||
| 973 | +330683,嵊州市,3306 | ||
| 974 | +3307,金华市,33 | ||
| 975 | +330702,婺城区,3307 | ||
| 976 | +330703,金东区,3307 | ||
| 977 | +330723,武义县,3307 | ||
| 978 | +330726,浦江县,3307 | ||
| 979 | +330727,磐安县,3307 | ||
| 980 | +330781,兰溪市,3307 | ||
| 981 | +330782,义乌市,3307 | ||
| 982 | +330783,东阳市,3307 | ||
| 983 | +330784,永康市,3307 | ||
| 984 | +3308,衢州市,33 | ||
| 985 | +330802,柯城区,3308 | ||
| 986 | +330803,衢江区,3308 | ||
| 987 | +330822,常山县,3308 | ||
| 988 | +330824,开化县,3308 | ||
| 989 | +330825,龙游县,3308 | ||
| 990 | +330881,江山市,3308 | ||
| 991 | +3309,舟山市,33 | ||
| 992 | +330902,定海区,3309 | ||
| 993 | +330903,普陀区,3309 | ||
| 994 | +330921,岱山县,3309 | ||
| 995 | +330922,嵊泗县,3309 | ||
| 996 | +3310,台州市,33 | ||
| 997 | +331002,椒江区,3310 | ||
| 998 | +331003,黄岩区,3310 | ||
| 999 | +331004,路桥区,3310 | ||
| 1000 | +331022,三门县,3310 | ||
| 1001 | +331023,天台县,3310 | ||
| 1002 | +331024,仙居县,3310 | ||
| 1003 | +331081,温岭市,3310 | ||
| 1004 | +331082,临海市,3310 | ||
| 1005 | +331083,玉环市,3310 | ||
| 1006 | +3311,丽水市,33 | ||
| 1007 | +331102,莲都区,3311 | ||
| 1008 | +331121,青田县,3311 | ||
| 1009 | +331122,缙云县,3311 | ||
| 1010 | +331123,遂昌县,3311 | ||
| 1011 | +331124,松阳县,3311 | ||
| 1012 | +331125,云和县,3311 | ||
| 1013 | +331126,庆元县,3311 | ||
| 1014 | +331127,景宁畲族自治县,3311 | ||
| 1015 | +331181,龙泉市,3311 | ||
| 1016 | +34,安徽省, | ||
| 1017 | +3401,合肥市,34 | ||
| 1018 | +340102,瑶海区,3401 | ||
| 1019 | +340103,庐阳区,3401 | ||
| 1020 | +340104,蜀山区,3401 | ||
| 1021 | +340111,包河区,3401 | ||
| 1022 | +340121,长丰县,3401 | ||
| 1023 | +340122,肥东县,3401 | ||
| 1024 | +340123,肥西县,3401 | ||
| 1025 | +340124,庐江县,3401 | ||
| 1026 | +340181,巢湖市,3401 | ||
| 1027 | +3402,芜湖市,34 | ||
| 1028 | +340202,镜湖区,3402 | ||
| 1029 | +340203,弋江区,3402 | ||
| 1030 | +340207,鸠江区,3402 | ||
| 1031 | +340208,三山区,3402 | ||
| 1032 | +340221,芜湖县,3402 | ||
| 1033 | +340222,繁昌县,3402 | ||
| 1034 | +340223,南陵县,3402 | ||
| 1035 | +340225,无为县,3402 | ||
| 1036 | +3403,蚌埠市,34 | ||
| 1037 | +340302,龙子湖区,3403 | ||
| 1038 | +340303,蚌山区,3403 | ||
| 1039 | +340304,禹会区,3403 | ||
| 1040 | +340311,淮上区,3403 | ||
| 1041 | +340321,怀远县,3403 | ||
| 1042 | +340322,五河县,3403 | ||
| 1043 | +340323,固镇县,3403 | ||
| 1044 | +3404,淮南市,34 | ||
| 1045 | +340402,大通区,3404 | ||
| 1046 | +340403,田家庵区,3404 | ||
| 1047 | +340404,谢家集区,3404 | ||
| 1048 | +340405,八公山区,3404 | ||
| 1049 | +340406,潘集区,3404 | ||
| 1050 | +340421,凤台县,3404 | ||
| 1051 | +340422,寿县,3404 | ||
| 1052 | +3405,马鞍山市,34 | ||
| 1053 | +340503,花山区,3405 | ||
| 1054 | +340504,雨山区,3405 | ||
| 1055 | +340506,博望区,3405 | ||
| 1056 | +340521,当涂县,3405 | ||
| 1057 | +340522,含山县,3405 | ||
| 1058 | +340523,和县,3405 | ||
| 1059 | +3406,淮北市,34 | ||
| 1060 | +340602,杜集区,3406 | ||
| 1061 | +340603,相山区,3406 | ||
| 1062 | +340604,烈山区,3406 | ||
| 1063 | +340621,濉溪县,3406 | ||
| 1064 | +3407,铜陵市,34 | ||
| 1065 | +340705,铜官区,3407 | ||
| 1066 | +340706,义安区,3407 | ||
| 1067 | +340711,郊区,3407 | ||
| 1068 | +340722,枞阳县,3407 | ||
| 1069 | +3408,安庆市,34 | ||
| 1070 | +340802,迎江区,3408 | ||
| 1071 | +340803,大观区,3408 | ||
| 1072 | +340811,宜秀区,3408 | ||
| 1073 | +340822,怀宁县,3408 | ||
| 1074 | +340825,太湖县,3408 | ||
| 1075 | +340826,宿松县,3408 | ||
| 1076 | +340827,望江县,3408 | ||
| 1077 | +340828,岳西县,3408 | ||
| 1078 | +340881,桐城市,3408 | ||
| 1079 | +340882,潜山市,3408 | ||
| 1080 | +3410,黄山市,34 | ||
| 1081 | +341002,屯溪区,3410 | ||
| 1082 | +341003,黄山区,3410 | ||
| 1083 | +341004,徽州区,3410 | ||
| 1084 | +341021,歙县,3410 | ||
| 1085 | +341022,休宁县,3410 | ||
| 1086 | +341023,黟县,3410 | ||
| 1087 | +341024,祁门县,3410 | ||
| 1088 | +3411,滁州市,34 | ||
| 1089 | +341102,琅琊区,3411 | ||
| 1090 | +341103,南谯区,3411 | ||
| 1091 | +341122,来安县,3411 | ||
| 1092 | +341124,全椒县,3411 | ||
| 1093 | +341125,定远县,3411 | ||
| 1094 | +341126,凤阳县,3411 | ||
| 1095 | +341181,天长市,3411 | ||
| 1096 | +341182,明光市,3411 | ||
| 1097 | +3412,阜阳市,34 | ||
| 1098 | +341202,颍州区,3412 | ||
| 1099 | +341203,颍东区,3412 | ||
| 1100 | +341204,颍泉区,3412 | ||
| 1101 | +341221,临泉县,3412 | ||
| 1102 | +341222,太和县,3412 | ||
| 1103 | +341225,阜南县,3412 | ||
| 1104 | +341226,颍上县,3412 | ||
| 1105 | +341282,界首市,3412 | ||
| 1106 | +3413,宿州市,34 | ||
| 1107 | +341302,埇桥区,3413 | ||
| 1108 | +341321,砀山县,3413 | ||
| 1109 | +341322,萧县,3413 | ||
| 1110 | +341323,灵璧县,3413 | ||
| 1111 | +341324,泗县,3413 | ||
| 1112 | +3415,六安市,34 | ||
| 1113 | +341502,金安区,3415 | ||
| 1114 | +341503,裕安区,3415 | ||
| 1115 | +341504,叶集区,3415 | ||
| 1116 | +341522,霍邱县,3415 | ||
| 1117 | +341523,舒城县,3415 | ||
| 1118 | +341524,金寨县,3415 | ||
| 1119 | +341525,霍山县,3415 | ||
| 1120 | +3416,亳州市,34 | ||
| 1121 | +341602,谯城区,3416 | ||
| 1122 | +341621,涡阳县,3416 | ||
| 1123 | +341622,蒙城县,3416 | ||
| 1124 | +341623,利辛县,3416 | ||
| 1125 | +3417,池州市,34 | ||
| 1126 | +341702,贵池区,3417 | ||
| 1127 | +341721,东至县,3417 | ||
| 1128 | +341722,石台县,3417 | ||
| 1129 | +341723,青阳县,3417 | ||
| 1130 | +3418,宣城市,34 | ||
| 1131 | +341802,宣州区,3418 | ||
| 1132 | +341821,郎溪县,3418 | ||
| 1133 | +341822,广德县,3418 | ||
| 1134 | +341823,泾县,3418 | ||
| 1135 | +341824,绩溪县,3418 | ||
| 1136 | +341825,旌德县,3418 | ||
| 1137 | +341881,宁国市,3418 | ||
| 1138 | +35,福建省, | ||
| 1139 | +3501,福州市,35 | ||
| 1140 | +350102,鼓楼区,3501 | ||
| 1141 | +350103,台江区,3501 | ||
| 1142 | +350104,仓山区,3501 | ||
| 1143 | +350105,马尾区,3501 | ||
| 1144 | +350111,晋安区,3501 | ||
| 1145 | +350112,长乐区,3501 | ||
| 1146 | +350121,闽侯县,3501 | ||
| 1147 | +350122,连江县,3501 | ||
| 1148 | +350123,罗源县,3501 | ||
| 1149 | +350124,闽清县,3501 | ||
| 1150 | +350125,永泰县,3501 | ||
| 1151 | +350128,平潭县,3501 | ||
| 1152 | +350181,福清市,3501 | ||
| 1153 | +3502,厦门市,35 | ||
| 1154 | +350203,思明区,3502 | ||
| 1155 | +350205,海沧区,3502 | ||
| 1156 | +350206,湖里区,3502 | ||
| 1157 | +350211,集美区,3502 | ||
| 1158 | +350212,同安区,3502 | ||
| 1159 | +350213,翔安区,3502 | ||
| 1160 | +3503,莆田市,35 | ||
| 1161 | +350302,城厢区,3503 | ||
| 1162 | +350303,涵江区,3503 | ||
| 1163 | +350304,荔城区,3503 | ||
| 1164 | +350305,秀屿区,3503 | ||
| 1165 | +350322,仙游县,3503 | ||
| 1166 | +3504,三明市,35 | ||
| 1167 | +350402,梅列区,3504 | ||
| 1168 | +350403,三元区,3504 | ||
| 1169 | +350421,明溪县,3504 | ||
| 1170 | +350423,清流县,3504 | ||
| 1171 | +350424,宁化县,3504 | ||
| 1172 | +350425,大田县,3504 | ||
| 1173 | +350426,尤溪县,3504 | ||
| 1174 | +350427,沙县,3504 | ||
| 1175 | +350428,将乐县,3504 | ||
| 1176 | +350429,泰宁县,3504 | ||
| 1177 | +350430,建宁县,3504 | ||
| 1178 | +350481,永安市,3504 | ||
| 1179 | +3505,泉州市,35 | ||
| 1180 | +350502,鲤城区,3505 | ||
| 1181 | +350503,丰泽区,3505 | ||
| 1182 | +350504,洛江区,3505 | ||
| 1183 | +350505,泉港区,3505 | ||
| 1184 | +350521,惠安县,3505 | ||
| 1185 | +350524,安溪县,3505 | ||
| 1186 | +350525,永春县,3505 | ||
| 1187 | +350526,德化县,3505 | ||
| 1188 | +350527,金门县,3505 | ||
| 1189 | +350581,石狮市,3505 | ||
| 1190 | +350582,晋江市,3505 | ||
| 1191 | +350583,南安市,3505 | ||
| 1192 | +3506,漳州市,35 | ||
| 1193 | +350602,芗城区,3506 | ||
| 1194 | +350603,龙文区,3506 | ||
| 1195 | +350622,云霄县,3506 | ||
| 1196 | +350623,漳浦县,3506 | ||
| 1197 | +350624,诏安县,3506 | ||
| 1198 | +350625,长泰县,3506 | ||
| 1199 | +350626,东山县,3506 | ||
| 1200 | +350627,南靖县,3506 | ||
| 1201 | +350628,平和县,3506 | ||
| 1202 | +350629,华安县,3506 | ||
| 1203 | +350681,龙海市,3506 | ||
| 1204 | +3507,南平市,35 | ||
| 1205 | +350702,延平区,3507 | ||
| 1206 | +350703,建阳区,3507 | ||
| 1207 | +350721,顺昌县,3507 | ||
| 1208 | +350722,浦城县,3507 | ||
| 1209 | +350723,光泽县,3507 | ||
| 1210 | +350724,松溪县,3507 | ||
| 1211 | +350725,政和县,3507 | ||
| 1212 | +350781,邵武市,3507 | ||
| 1213 | +350782,武夷山市,3507 | ||
| 1214 | +350783,建瓯市,3507 | ||
| 1215 | +3508,龙岩市,35 | ||
| 1216 | +350802,新罗区,3508 | ||
| 1217 | +350803,永定区,3508 | ||
| 1218 | +350821,长汀县,3508 | ||
| 1219 | +350823,上杭县,3508 | ||
| 1220 | +350824,武平县,3508 | ||
| 1221 | +350825,连城县,3508 | ||
| 1222 | +350881,漳平市,3508 | ||
| 1223 | +3509,宁德市,35 | ||
| 1224 | +350902,蕉城区,3509 | ||
| 1225 | +350921,霞浦县,3509 | ||
| 1226 | +350922,古田县,3509 | ||
| 1227 | +350923,屏南县,3509 | ||
| 1228 | +350924,寿宁县,3509 | ||
| 1229 | +350925,周宁县,3509 | ||
| 1230 | +350926,柘荣县,3509 | ||
| 1231 | +350981,福安市,3509 | ||
| 1232 | +350982,福鼎市,3509 | ||
| 1233 | +36,江西省, | ||
| 1234 | +3601,南昌市,36 | ||
| 1235 | +360102,东湖区,3601 | ||
| 1236 | +360103,西湖区,3601 | ||
| 1237 | +360104,青云谱区,3601 | ||
| 1238 | +360105,湾里区,3601 | ||
| 1239 | +360111,青山湖区,3601 | ||
| 1240 | +360112,新建区,3601 | ||
| 1241 | +360121,南昌县,3601 | ||
| 1242 | +360123,安义县,3601 | ||
| 1243 | +360124,进贤县,3601 | ||
| 1244 | +3602,景德镇市,36 | ||
| 1245 | +360202,昌江区,3602 | ||
| 1246 | +360203,珠山区,3602 | ||
| 1247 | +360222,浮梁县,3602 | ||
| 1248 | +360281,乐平市,3602 | ||
| 1249 | +3603,萍乡市,36 | ||
| 1250 | +360302,安源区,3603 | ||
| 1251 | +360313,湘东区,3603 | ||
| 1252 | +360321,莲花县,3603 | ||
| 1253 | +360322,上栗县,3603 | ||
| 1254 | +360323,芦溪县,3603 | ||
| 1255 | +3604,九江市,36 | ||
| 1256 | +360402,濂溪区,3604 | ||
| 1257 | +360403,浔阳区,3604 | ||
| 1258 | +360404,柴桑区,3604 | ||
| 1259 | +360423,武宁县,3604 | ||
| 1260 | +360424,修水县,3604 | ||
| 1261 | +360425,永修县,3604 | ||
| 1262 | +360426,德安县,3604 | ||
| 1263 | +360428,都昌县,3604 | ||
| 1264 | +360429,湖口县,3604 | ||
| 1265 | +360430,彭泽县,3604 | ||
| 1266 | +360481,瑞昌市,3604 | ||
| 1267 | +360482,共青城市,3604 | ||
| 1268 | +360483,庐山市,3604 | ||
| 1269 | +3605,新余市,36 | ||
| 1270 | +360502,渝水区,3605 | ||
| 1271 | +360521,分宜县,3605 | ||
| 1272 | +3606,鹰潭市,36 | ||
| 1273 | +360602,月湖区,3606 | ||
| 1274 | +360603,余江区,3606 | ||
| 1275 | +360681,贵溪市,3606 | ||
| 1276 | +3607,赣州市,36 | ||
| 1277 | +360702,章贡区,3607 | ||
| 1278 | +360703,南康区,3607 | ||
| 1279 | +360704,赣县区,3607 | ||
| 1280 | +360722,信丰县,3607 | ||
| 1281 | +360723,大余县,3607 | ||
| 1282 | +360724,上犹县,3607 | ||
| 1283 | +360725,崇义县,3607 | ||
| 1284 | +360726,安远县,3607 | ||
| 1285 | +360727,龙南县,3607 | ||
| 1286 | +360728,定南县,3607 | ||
| 1287 | +360729,全南县,3607 | ||
| 1288 | +360730,宁都县,3607 | ||
| 1289 | +360731,于都县,3607 | ||
| 1290 | +360732,兴国县,3607 | ||
| 1291 | +360733,会昌县,3607 | ||
| 1292 | +360734,寻乌县,3607 | ||
| 1293 | +360735,石城县,3607 | ||
| 1294 | +360781,瑞金市,3607 | ||
| 1295 | +3608,吉安市,36 | ||
| 1296 | +360802,吉州区,3608 | ||
| 1297 | +360803,青原区,3608 | ||
| 1298 | +360821,吉安县,3608 | ||
| 1299 | +360822,吉水县,3608 | ||
| 1300 | +360823,峡江县,3608 | ||
| 1301 | +360824,新干县,3608 | ||
| 1302 | +360825,永丰县,3608 | ||
| 1303 | +360826,泰和县,3608 | ||
| 1304 | +360827,遂川县,3608 | ||
| 1305 | +360828,万安县,3608 | ||
| 1306 | +360829,安福县,3608 | ||
| 1307 | +360830,永新县,3608 | ||
| 1308 | +360881,井冈山市,3608 | ||
| 1309 | +3609,宜春市,36 | ||
| 1310 | +360902,袁州区,3609 | ||
| 1311 | +360921,奉新县,3609 | ||
| 1312 | +360922,万载县,3609 | ||
| 1313 | +360923,上高县,3609 | ||
| 1314 | +360924,宜丰县,3609 | ||
| 1315 | +360925,靖安县,3609 | ||
| 1316 | +360926,铜鼓县,3609 | ||
| 1317 | +360981,丰城市,3609 | ||
| 1318 | +360982,樟树市,3609 | ||
| 1319 | +360983,高安市,3609 | ||
| 1320 | +3610,抚州市,36 | ||
| 1321 | +361002,临川区,3610 | ||
| 1322 | +361003,东乡区,3610 | ||
| 1323 | +361021,南城县,3610 | ||
| 1324 | +361022,黎川县,3610 | ||
| 1325 | +361023,南丰县,3610 | ||
| 1326 | +361024,崇仁县,3610 | ||
| 1327 | +361025,乐安县,3610 | ||
| 1328 | +361026,宜黄县,3610 | ||
| 1329 | +361027,金溪县,3610 | ||
| 1330 | +361028,资溪县,3610 | ||
| 1331 | +361030,广昌县,3610 | ||
| 1332 | +3611,上饶市,36 | ||
| 1333 | +361102,信州区,3611 | ||
| 1334 | +361103,广丰区,3611 | ||
| 1335 | +361121,上饶县,3611 | ||
| 1336 | +361123,玉山县,3611 | ||
| 1337 | +361124,铅山县,3611 | ||
| 1338 | +361125,横峰县,3611 | ||
| 1339 | +361126,弋阳县,3611 | ||
| 1340 | +361127,余干县,3611 | ||
| 1341 | +361128,鄱阳县,3611 | ||
| 1342 | +361129,万年县,3611 | ||
| 1343 | +361130,婺源县,3611 | ||
| 1344 | +361181,德兴市,3611 | ||
| 1345 | +37,山东省, | ||
| 1346 | +3701,济南市,37 | ||
| 1347 | +370102,历下区,3701 | ||
| 1348 | +370103,市中区,3701 | ||
| 1349 | +370104,槐荫区,3701 | ||
| 1350 | +370105,天桥区,3701 | ||
| 1351 | +370112,历城区,3701 | ||
| 1352 | +370113,长清区,3701 | ||
| 1353 | +370114,章丘区,3701 | ||
| 1354 | +370115,济阳区,3701 | ||
| 1355 | +370124,平阴县,3701 | ||
| 1356 | +370126,商河县,3701 | ||
| 1357 | +3702,青岛市,37 | ||
| 1358 | +370202,市南区,3702 | ||
| 1359 | +370203,市北区,3702 | ||
| 1360 | +370211,黄岛区,3702 | ||
| 1361 | +370212,崂山区,3702 | ||
| 1362 | +370213,李沧区,3702 | ||
| 1363 | +370214,城阳区,3702 | ||
| 1364 | +370215,即墨区,3702 | ||
| 1365 | +370281,胶州市,3702 | ||
| 1366 | +370283,平度市,3702 | ||
| 1367 | +370285,莱西市,3702 | ||
| 1368 | +3703,淄博市,37 | ||
| 1369 | +370302,淄川区,3703 | ||
| 1370 | +370303,张店区,3703 | ||
| 1371 | +370304,博山区,3703 | ||
| 1372 | +370305,临淄区,3703 | ||
| 1373 | +370306,周村区,3703 | ||
| 1374 | +370321,桓台县,3703 | ||
| 1375 | +370322,高青县,3703 | ||
| 1376 | +370323,沂源县,3703 | ||
| 1377 | +3704,枣庄市,37 | ||
| 1378 | +370402,市中区,3704 | ||
| 1379 | +370403,薛城区,3704 | ||
| 1380 | +370404,峄城区,3704 | ||
| 1381 | +370405,台儿庄区,3704 | ||
| 1382 | +370406,山亭区,3704 | ||
| 1383 | +370481,滕州市,3704 | ||
| 1384 | +3705,东营市,37 | ||
| 1385 | +370502,东营区,3705 | ||
| 1386 | +370503,河口区,3705 | ||
| 1387 | +370505,垦利区,3705 | ||
| 1388 | +370522,利津县,3705 | ||
| 1389 | +370523,广饶县,3705 | ||
| 1390 | +3706,烟台市,37 | ||
| 1391 | +370602,芝罘区,3706 | ||
| 1392 | +370611,福山区,3706 | ||
| 1393 | +370612,牟平区,3706 | ||
| 1394 | +370613,莱山区,3706 | ||
| 1395 | +370634,长岛县,3706 | ||
| 1396 | +370681,龙口市,3706 | ||
| 1397 | +370682,莱阳市,3706 | ||
| 1398 | +370683,莱州市,3706 | ||
| 1399 | +370684,蓬莱市,3706 | ||
| 1400 | +370685,招远市,3706 | ||
| 1401 | +370686,栖霞市,3706 | ||
| 1402 | +370687,海阳市,3706 | ||
| 1403 | +3707,潍坊市,37 | ||
| 1404 | +370702,潍城区,3707 | ||
| 1405 | +370703,寒亭区,3707 | ||
| 1406 | +370704,坊子区,3707 | ||
| 1407 | +370705,奎文区,3707 | ||
| 1408 | +370724,临朐县,3707 | ||
| 1409 | +370725,昌乐县,3707 | ||
| 1410 | +370781,青州市,3707 | ||
| 1411 | +370782,诸城市,3707 | ||
| 1412 | +370783,寿光市,3707 | ||
| 1413 | +370784,安丘市,3707 | ||
| 1414 | +370785,高密市,3707 | ||
| 1415 | +370786,昌邑市,3707 | ||
| 1416 | +3708,济宁市,37 | ||
| 1417 | +370811,任城区,3708 | ||
| 1418 | +370812,兖州区,3708 | ||
| 1419 | +370826,微山县,3708 | ||
| 1420 | +370827,鱼台县,3708 | ||
| 1421 | +370828,金乡县,3708 | ||
| 1422 | +370829,嘉祥县,3708 | ||
| 1423 | +370830,汶上县,3708 | ||
| 1424 | +370831,泗水县,3708 | ||
| 1425 | +370832,梁山县,3708 | ||
| 1426 | +370881,曲阜市,3708 | ||
| 1427 | +370883,邹城市,3708 | ||
| 1428 | +3709,泰安市,37 | ||
| 1429 | +370902,泰山区,3709 | ||
| 1430 | +370911,岱岳区,3709 | ||
| 1431 | +370921,宁阳县,3709 | ||
| 1432 | +370923,东平县,3709 | ||
| 1433 | +370982,新泰市,3709 | ||
| 1434 | +370983,肥城市,3709 | ||
| 1435 | +3710,威海市,37 | ||
| 1436 | +371002,环翠区,3710 | ||
| 1437 | +371003,文登区,3710 | ||
| 1438 | +371082,荣成市,3710 | ||
| 1439 | +371083,乳山市,3710 | ||
| 1440 | +3711,日照市,37 | ||
| 1441 | +371102,东港区,3711 | ||
| 1442 | +371103,岚山区,3711 | ||
| 1443 | +371121,五莲县,3711 | ||
| 1444 | +371122,莒县,3711 | ||
| 1445 | +3712,莱芜市,37 | ||
| 1446 | +371202,莱城区,3712 | ||
| 1447 | +371203,钢城区,3712 | ||
| 1448 | +3713,临沂市,37 | ||
| 1449 | +371302,兰山区,3713 | ||
| 1450 | +371311,罗庄区,3713 | ||
| 1451 | +371312,河东区,3713 | ||
| 1452 | +371321,沂南县,3713 | ||
| 1453 | +371322,郯城县,3713 | ||
| 1454 | +371323,沂水县,3713 | ||
| 1455 | +371324,兰陵县,3713 | ||
| 1456 | +371325,费县,3713 | ||
| 1457 | +371326,平邑县,3713 | ||
| 1458 | +371327,莒南县,3713 | ||
| 1459 | +371328,蒙阴县,3713 | ||
| 1460 | +371329,临沭县,3713 | ||
| 1461 | +3714,德州市,37 | ||
| 1462 | +371402,德城区,3714 | ||
| 1463 | +371403,陵城区,3714 | ||
| 1464 | +371422,宁津县,3714 | ||
| 1465 | +371423,庆云县,3714 | ||
| 1466 | +371424,临邑县,3714 | ||
| 1467 | +371425,齐河县,3714 | ||
| 1468 | +371426,平原县,3714 | ||
| 1469 | +371427,夏津县,3714 | ||
| 1470 | +371428,武城县,3714 | ||
| 1471 | +371481,乐陵市,3714 | ||
| 1472 | +371482,禹城市,3714 | ||
| 1473 | +3715,聊城市,37 | ||
| 1474 | +371502,东昌府区,3715 | ||
| 1475 | +371521,阳谷县,3715 | ||
| 1476 | +371522,莘县,3715 | ||
| 1477 | +371523,茌平县,3715 | ||
| 1478 | +371524,东阿县,3715 | ||
| 1479 | +371525,冠县,3715 | ||
| 1480 | +371526,高唐县,3715 | ||
| 1481 | +371581,临清市,3715 | ||
| 1482 | +3716,滨州市,37 | ||
| 1483 | +371602,滨城区,3716 | ||
| 1484 | +371603,沾化区,3716 | ||
| 1485 | +371621,惠民县,3716 | ||
| 1486 | +371622,阳信县,3716 | ||
| 1487 | +371623,无棣县,3716 | ||
| 1488 | +371625,博兴县,3716 | ||
| 1489 | +371681,邹平市,3716 | ||
| 1490 | +3717,菏泽市,37 | ||
| 1491 | +371702,牡丹区,3717 | ||
| 1492 | +371703,定陶区,3717 | ||
| 1493 | +371721,曹县,3717 | ||
| 1494 | +371722,单县,3717 | ||
| 1495 | +371723,成武县,3717 | ||
| 1496 | +371724,巨野县,3717 | ||
| 1497 | +371725,郓城县,3717 | ||
| 1498 | +371726,鄄城县,3717 | ||
| 1499 | +371728,东明县,3717 | ||
| 1500 | +41,河南省, | ||
| 1501 | +4101,郑州市,41 | ||
| 1502 | +410102,中原区,4101 | ||
| 1503 | +410103,二七区,4101 | ||
| 1504 | +410104,管城回族区,4101 | ||
| 1505 | +410105,金水区,4101 | ||
| 1506 | +410106,上街区,4101 | ||
| 1507 | +410108,惠济区,4101 | ||
| 1508 | +410122,中牟县,4101 | ||
| 1509 | +410181,巩义市,4101 | ||
| 1510 | +410182,荥阳市,4101 | ||
| 1511 | +410183,新密市,4101 | ||
| 1512 | +410184,新郑市,4101 | ||
| 1513 | +410185,登封市,4101 | ||
| 1514 | +4102,开封市,41 | ||
| 1515 | +410202,龙亭区,4102 | ||
| 1516 | +410203,顺河回族区,4102 | ||
| 1517 | +410204,鼓楼区,4102 | ||
| 1518 | +410205,禹王台区,4102 | ||
| 1519 | +410212,祥符区,4102 | ||
| 1520 | +410221,杞县,4102 | ||
| 1521 | +410222,通许县,4102 | ||
| 1522 | +410223,尉氏县,4102 | ||
| 1523 | +410225,兰考县,4102 | ||
| 1524 | +4103,洛阳市,41 | ||
| 1525 | +410302,老城区,4103 | ||
| 1526 | +410303,西工区,4103 | ||
| 1527 | +410304,瀍河回族区,4103 | ||
| 1528 | +410305,涧西区,4103 | ||
| 1529 | +410306,吉利区,4103 | ||
| 1530 | +410311,洛龙区,4103 | ||
| 1531 | +410322,孟津县,4103 | ||
| 1532 | +410323,新安县,4103 | ||
| 1533 | +410324,栾川县,4103 | ||
| 1534 | +410325,嵩县,4103 | ||
| 1535 | +410326,汝阳县,4103 | ||
| 1536 | +410327,宜阳县,4103 | ||
| 1537 | +410328,洛宁县,4103 | ||
| 1538 | +410329,伊川县,4103 | ||
| 1539 | +410381,偃师市,4103 | ||
| 1540 | +4104,平顶山市,41 | ||
| 1541 | +410402,新华区,4104 | ||
| 1542 | +410403,卫东区,4104 | ||
| 1543 | +410404,石龙区,4104 | ||
| 1544 | +410411,湛河区,4104 | ||
| 1545 | +410421,宝丰县,4104 | ||
| 1546 | +410422,叶县,4104 | ||
| 1547 | +410423,鲁山县,4104 | ||
| 1548 | +410425,郏县,4104 | ||
| 1549 | +410481,舞钢市,4104 | ||
| 1550 | +410482,汝州市,4104 | ||
| 1551 | +4105,安阳市,41 | ||
| 1552 | +410502,文峰区,4105 | ||
| 1553 | +410503,北关区,4105 | ||
| 1554 | +410505,殷都区,4105 | ||
| 1555 | +410506,龙安区,4105 | ||
| 1556 | +410522,安阳县,4105 | ||
| 1557 | +410523,汤阴县,4105 | ||
| 1558 | +410526,滑县,4105 | ||
| 1559 | +410527,内黄县,4105 | ||
| 1560 | +410581,林州市,4105 | ||
| 1561 | +4106,鹤壁市,41 | ||
| 1562 | +410602,鹤山区,4106 | ||
| 1563 | +410603,山城区,4106 | ||
| 1564 | +410611,淇滨区,4106 | ||
| 1565 | +410621,浚县,4106 | ||
| 1566 | +410622,淇县,4106 | ||
| 1567 | +4107,新乡市,41 | ||
| 1568 | +410702,红旗区,4107 | ||
| 1569 | +410703,卫滨区,4107 | ||
| 1570 | +410704,凤泉区,4107 | ||
| 1571 | +410711,牧野区,4107 | ||
| 1572 | +410721,新乡县,4107 | ||
| 1573 | +410724,获嘉县,4107 | ||
| 1574 | +410725,原阳县,4107 | ||
| 1575 | +410726,延津县,4107 | ||
| 1576 | +410727,封丘县,4107 | ||
| 1577 | +410728,长垣县,4107 | ||
| 1578 | +410781,卫辉市,4107 | ||
| 1579 | +410782,辉县市,4107 | ||
| 1580 | +4108,焦作市,41 | ||
| 1581 | +410802,解放区,4108 | ||
| 1582 | +410803,中站区,4108 | ||
| 1583 | +410804,马村区,4108 | ||
| 1584 | +410811,山阳区,4108 | ||
| 1585 | +410821,修武县,4108 | ||
| 1586 | +410822,博爱县,4108 | ||
| 1587 | +410823,武陟县,4108 | ||
| 1588 | +410825,温县,4108 | ||
| 1589 | +410882,沁阳市,4108 | ||
| 1590 | +410883,孟州市,4108 | ||
| 1591 | +4109,濮阳市,41 | ||
| 1592 | +410902,华龙区,4109 | ||
| 1593 | +410922,清丰县,4109 | ||
| 1594 | +410923,南乐县,4109 | ||
| 1595 | +410926,范县,4109 | ||
| 1596 | +410927,台前县,4109 | ||
| 1597 | +410928,濮阳县,4109 | ||
| 1598 | +4110,许昌市,41 | ||
| 1599 | +411002,魏都区,4110 | ||
| 1600 | +411003,建安区,4110 | ||
| 1601 | +411024,鄢陵县,4110 | ||
| 1602 | +411025,襄城县,4110 | ||
| 1603 | +411081,禹州市,4110 | ||
| 1604 | +411082,长葛市,4110 | ||
| 1605 | +4111,漯河市,41 | ||
| 1606 | +411102,源汇区,4111 | ||
| 1607 | +411103,郾城区,4111 | ||
| 1608 | +411104,召陵区,4111 | ||
| 1609 | +411121,舞阳县,4111 | ||
| 1610 | +411122,临颍县,4111 | ||
| 1611 | +4112,三门峡市,41 | ||
| 1612 | +411202,湖滨区,4112 | ||
| 1613 | +411203,陕州区,4112 | ||
| 1614 | +411221,渑池县,4112 | ||
| 1615 | +411224,卢氏县,4112 | ||
| 1616 | +411281,义马市,4112 | ||
| 1617 | +411282,灵宝市,4112 | ||
| 1618 | +4113,南阳市,41 | ||
| 1619 | +411302,宛城区,4113 | ||
| 1620 | +411303,卧龙区,4113 | ||
| 1621 | +411321,南召县,4113 | ||
| 1622 | +411322,方城县,4113 | ||
| 1623 | +411323,西峡县,4113 | ||
| 1624 | +411324,镇平县,4113 | ||
| 1625 | +411325,内乡县,4113 | ||
| 1626 | +411326,淅川县,4113 | ||
| 1627 | +411327,社旗县,4113 | ||
| 1628 | +411328,唐河县,4113 | ||
| 1629 | +411329,新野县,4113 | ||
| 1630 | +411330,桐柏县,4113 | ||
| 1631 | +411381,邓州市,4113 | ||
| 1632 | +4114,商丘市,41 | ||
| 1633 | +411402,梁园区,4114 | ||
| 1634 | +411403,睢阳区,4114 | ||
| 1635 | +411421,民权县,4114 | ||
| 1636 | +411422,睢县,4114 | ||
| 1637 | +411423,宁陵县,4114 | ||
| 1638 | +411424,柘城县,4114 | ||
| 1639 | +411425,虞城县,4114 | ||
| 1640 | +411426,夏邑县,4114 | ||
| 1641 | +411481,永城市,4114 | ||
| 1642 | +4115,信阳市,41 | ||
| 1643 | +411502,浉河区,4115 | ||
| 1644 | +411503,平桥区,4115 | ||
| 1645 | +411521,罗山县,4115 | ||
| 1646 | +411522,光山县,4115 | ||
| 1647 | +411523,新县,4115 | ||
| 1648 | +411524,商城县,4115 | ||
| 1649 | +411525,固始县,4115 | ||
| 1650 | +411526,潢川县,4115 | ||
| 1651 | +411527,淮滨县,4115 | ||
| 1652 | +411528,息县,4115 | ||
| 1653 | +4116,周口市,41 | ||
| 1654 | +411602,川汇区,4116 | ||
| 1655 | +411621,扶沟县,4116 | ||
| 1656 | +411622,西华县,4116 | ||
| 1657 | +411623,商水县,4116 | ||
| 1658 | +411624,沈丘县,4116 | ||
| 1659 | +411625,郸城县,4116 | ||
| 1660 | +411626,淮阳县,4116 | ||
| 1661 | +411627,太康县,4116 | ||
| 1662 | +411628,鹿邑县,4116 | ||
| 1663 | +411681,项城市,4116 | ||
| 1664 | +4117,驻马店市,41 | ||
| 1665 | +411702,驿城区,4117 | ||
| 1666 | +411721,西平县,4117 | ||
| 1667 | +411722,上蔡县,4117 | ||
| 1668 | +411723,平舆县,4117 | ||
| 1669 | +411724,正阳县,4117 | ||
| 1670 | +411725,确山县,4117 | ||
| 1671 | +411726,泌阳县,4117 | ||
| 1672 | +411727,汝南县,4117 | ||
| 1673 | +411728,遂平县,4117 | ||
| 1674 | +411729,新蔡县,4117 | ||
| 1675 | +419001,济源市,41 | ||
| 1676 | +42,湖北省, | ||
| 1677 | +4201,武汉市,42 | ||
| 1678 | +420102,江岸区,4201 | ||
| 1679 | +420103,江汉区,4201 | ||
| 1680 | +420104,硚口区,4201 | ||
| 1681 | +420105,汉阳区,4201 | ||
| 1682 | +420106,武昌区,4201 | ||
| 1683 | +420107,青山区,4201 | ||
| 1684 | +420111,洪山区,4201 | ||
| 1685 | +420112,东西湖区,4201 | ||
| 1686 | +420113,汉南区,4201 | ||
| 1687 | +420114,蔡甸区,4201 | ||
| 1688 | +420115,江夏区,4201 | ||
| 1689 | +420116,黄陂区,4201 | ||
| 1690 | +420117,新洲区,4201 | ||
| 1691 | +4202,黄石市,42 | ||
| 1692 | +420202,黄石港区,4202 | ||
| 1693 | +420203,西塞山区,4202 | ||
| 1694 | +420204,下陆区,4202 | ||
| 1695 | +420205,铁山区,4202 | ||
| 1696 | +420222,阳新县,4202 | ||
| 1697 | +420281,大冶市,4202 | ||
| 1698 | +4203,十堰市,42 | ||
| 1699 | +420302,茅箭区,4203 | ||
| 1700 | +420303,张湾区,4203 | ||
| 1701 | +420304,郧阳区,4203 | ||
| 1702 | +420322,郧西县,4203 | ||
| 1703 | +420323,竹山县,4203 | ||
| 1704 | +420324,竹溪县,4203 | ||
| 1705 | +420325,房县,4203 | ||
| 1706 | +420381,丹江口市,4203 | ||
| 1707 | +4205,宜昌市,42 | ||
| 1708 | +420502,西陵区,4205 | ||
| 1709 | +420503,伍家岗区,4205 | ||
| 1710 | +420504,点军区,4205 | ||
| 1711 | +420505,猇亭区,4205 | ||
| 1712 | +420506,夷陵区,4205 | ||
| 1713 | +420525,远安县,4205 | ||
| 1714 | +420526,兴山县,4205 | ||
| 1715 | +420527,秭归县,4205 | ||
| 1716 | +420528,长阳土家族自治县,4205 | ||
| 1717 | +420529,五峰土家族自治县,4205 | ||
| 1718 | +420581,宜都市,4205 | ||
| 1719 | +420582,当阳市,4205 | ||
| 1720 | +420583,枝江市,4205 | ||
| 1721 | +4206,襄阳市,42 | ||
| 1722 | +420602,襄城区,4206 | ||
| 1723 | +420606,樊城区,4206 | ||
| 1724 | +420607,襄州区,4206 | ||
| 1725 | +420624,南漳县,4206 | ||
| 1726 | +420625,谷城县,4206 | ||
| 1727 | +420626,保康县,4206 | ||
| 1728 | +420682,老河口市,4206 | ||
| 1729 | +420683,枣阳市,4206 | ||
| 1730 | +420684,宜城市,4206 | ||
| 1731 | +4207,鄂州市,42 | ||
| 1732 | +420702,梁子湖区,4207 | ||
| 1733 | +420703,华容区,4207 | ||
| 1734 | +420704,鄂城区,4207 | ||
| 1735 | +4208,荆门市,42 | ||
| 1736 | +420802,东宝区,4208 | ||
| 1737 | +420804,掇刀区,4208 | ||
| 1738 | +420822,沙洋县,4208 | ||
| 1739 | +420881,钟祥市,4208 | ||
| 1740 | +420882,京山市,4208 | ||
| 1741 | +4209,孝感市,42 | ||
| 1742 | +420902,孝南区,4209 | ||
| 1743 | +420921,孝昌县,4209 | ||
| 1744 | +420922,大悟县,4209 | ||
| 1745 | +420923,云梦县,4209 | ||
| 1746 | +420981,应城市,4209 | ||
| 1747 | +420982,安陆市,4209 | ||
| 1748 | +420984,汉川市,4209 | ||
| 1749 | +4210,荆州市,42 | ||
| 1750 | +421002,沙市区,4210 | ||
| 1751 | +421003,荆州区,4210 | ||
| 1752 | +421022,公安县,4210 | ||
| 1753 | +421023,监利县,4210 | ||
| 1754 | +421024,江陵县,4210 | ||
| 1755 | +421081,石首市,4210 | ||
| 1756 | +421083,洪湖市,4210 | ||
| 1757 | +421087,松滋市,4210 | ||
| 1758 | +4211,黄冈市,42 | ||
| 1759 | +421102,黄州区,4211 | ||
| 1760 | +421121,团风县,4211 | ||
| 1761 | +421122,红安县,4211 | ||
| 1762 | +421123,罗田县,4211 | ||
| 1763 | +421124,英山县,4211 | ||
| 1764 | +421125,浠水县,4211 | ||
| 1765 | +421126,蕲春县,4211 | ||
| 1766 | +421127,黄梅县,4211 | ||
| 1767 | +421181,麻城市,4211 | ||
| 1768 | +421182,武穴市,4211 | ||
| 1769 | +4212,咸宁市,42 | ||
| 1770 | +421202,咸安区,4212 | ||
| 1771 | +421221,嘉鱼县,4212 | ||
| 1772 | +421222,通城县,4212 | ||
| 1773 | +421223,崇阳县,4212 | ||
| 1774 | +421224,通山县,4212 | ||
| 1775 | +421281,赤壁市,4212 | ||
| 1776 | +4213,随州市,42 | ||
| 1777 | +421303,曾都区,4213 | ||
| 1778 | +421321,随县,4213 | ||
| 1779 | +421381,广水市,4213 | ||
| 1780 | +4228,恩施土家族苗族自治州,42 | ||
| 1781 | +422801,恩施市,4228 | ||
| 1782 | +422802,利川市,4228 | ||
| 1783 | +422822,建始县,4228 | ||
| 1784 | +422823,巴东县,4228 | ||
| 1785 | +422825,宣恩县,4228 | ||
| 1786 | +422826,咸丰县,4228 | ||
| 1787 | +422827,来凤县,4228 | ||
| 1788 | +422828,鹤峰县,4228 | ||
| 1789 | +429004,仙桃市,42 | ||
| 1790 | +429005,潜江市,42 | ||
| 1791 | +429006,天门市,42 | ||
| 1792 | +429021,神农架林区,42 | ||
| 1793 | +43,湖南省, | ||
| 1794 | +4301,长沙市,43 | ||
| 1795 | +430102,芙蓉区,4301 | ||
| 1796 | +430103,天心区,4301 | ||
| 1797 | +430104,岳麓区,4301 | ||
| 1798 | +430105,开福区,4301 | ||
| 1799 | +430111,雨花区,4301 | ||
| 1800 | +430112,望城区,4301 | ||
| 1801 | +430121,长沙县,4301 | ||
| 1802 | +430181,浏阳市,4301 | ||
| 1803 | +430182,宁乡市,4301 | ||
| 1804 | +4302,株洲市,43 | ||
| 1805 | +430202,荷塘区,4302 | ||
| 1806 | +430203,芦淞区,4302 | ||
| 1807 | +430204,石峰区,4302 | ||
| 1808 | +430211,天元区,4302 | ||
| 1809 | +430212,渌口区,4302 | ||
| 1810 | +430223,攸县,4302 | ||
| 1811 | +430224,茶陵县,4302 | ||
| 1812 | +430225,炎陵县,4302 | ||
| 1813 | +430281,醴陵市,4302 | ||
| 1814 | +4303,湘潭市,43 | ||
| 1815 | +430302,雨湖区,4303 | ||
| 1816 | +430304,岳塘区,4303 | ||
| 1817 | +430321,湘潭县,4303 | ||
| 1818 | +430381,湘乡市,4303 | ||
| 1819 | +430382,韶山市,4303 | ||
| 1820 | +4304,衡阳市,43 | ||
| 1821 | +430405,珠晖区,4304 | ||
| 1822 | +430406,雁峰区,4304 | ||
| 1823 | +430407,石鼓区,4304 | ||
| 1824 | +430408,蒸湘区,4304 | ||
| 1825 | +430412,南岳区,4304 | ||
| 1826 | +430421,衡阳县,4304 | ||
| 1827 | +430422,衡南县,4304 | ||
| 1828 | +430423,衡山县,4304 | ||
| 1829 | +430424,衡东县,4304 | ||
| 1830 | +430426,祁东县,4304 | ||
| 1831 | +430481,耒阳市,4304 | ||
| 1832 | +430482,常宁市,4304 | ||
| 1833 | +4305,邵阳市,43 | ||
| 1834 | +430502,双清区,4305 | ||
| 1835 | +430503,大祥区,4305 | ||
| 1836 | +430511,北塔区,4305 | ||
| 1837 | +430521,邵东县,4305 | ||
| 1838 | +430522,新邵县,4305 | ||
| 1839 | +430523,邵阳县,4305 | ||
| 1840 | +430524,隆回县,4305 | ||
| 1841 | +430525,洞口县,4305 | ||
| 1842 | +430527,绥宁县,4305 | ||
| 1843 | +430528,新宁县,4305 | ||
| 1844 | +430529,城步苗族自治县,4305 | ||
| 1845 | +430581,武冈市,4305 | ||
| 1846 | +4306,岳阳市,43 | ||
| 1847 | +430602,岳阳楼区,4306 | ||
| 1848 | +430603,云溪区,4306 | ||
| 1849 | +430611,君山区,4306 | ||
| 1850 | +430621,岳阳县,4306 | ||
| 1851 | +430623,华容县,4306 | ||
| 1852 | +430624,湘阴县,4306 | ||
| 1853 | +430626,平江县,4306 | ||
| 1854 | +430681,汨罗市,4306 | ||
| 1855 | +430682,临湘市,4306 | ||
| 1856 | +4307,常德市,43 | ||
| 1857 | +430702,武陵区,4307 | ||
| 1858 | +430703,鼎城区,4307 | ||
| 1859 | +430721,安乡县,4307 | ||
| 1860 | +430722,汉寿县,4307 | ||
| 1861 | +430723,澧县,4307 | ||
| 1862 | +430724,临澧县,4307 | ||
| 1863 | +430725,桃源县,4307 | ||
| 1864 | +430726,石门县,4307 | ||
| 1865 | +430781,津市市,4307 | ||
| 1866 | +4308,张家界市,43 | ||
| 1867 | +430802,永定区,4308 | ||
| 1868 | +430811,武陵源区,4308 | ||
| 1869 | +430821,慈利县,4308 | ||
| 1870 | +430822,桑植县,4308 | ||
| 1871 | +4309,益阳市,43 | ||
| 1872 | +430902,资阳区,4309 | ||
| 1873 | +430903,赫山区,4309 | ||
| 1874 | +430921,南县,4309 | ||
| 1875 | +430922,桃江县,4309 | ||
| 1876 | +430923,安化县,4309 | ||
| 1877 | +430981,沅江市,4309 | ||
| 1878 | +4310,郴州市,43 | ||
| 1879 | +431002,北湖区,4310 | ||
| 1880 | +431003,苏仙区,4310 | ||
| 1881 | +431021,桂阳县,4310 | ||
| 1882 | +431022,宜章县,4310 | ||
| 1883 | +431023,永兴县,4310 | ||
| 1884 | +431024,嘉禾县,4310 | ||
| 1885 | +431025,临武县,4310 | ||
| 1886 | +431026,汝城县,4310 | ||
| 1887 | +431027,桂东县,4310 | ||
| 1888 | +431028,安仁县,4310 | ||
| 1889 | +431081,资兴市,4310 | ||
| 1890 | +4311,永州市,43 | ||
| 1891 | +431102,零陵区,4311 | ||
| 1892 | +431103,冷水滩区,4311 | ||
| 1893 | +431121,祁阳县,4311 | ||
| 1894 | +431122,东安县,4311 | ||
| 1895 | +431123,双牌县,4311 | ||
| 1896 | +431124,道县,4311 | ||
| 1897 | +431125,江永县,4311 | ||
| 1898 | +431126,宁远县,4311 | ||
| 1899 | +431127,蓝山县,4311 | ||
| 1900 | +431128,新田县,4311 | ||
| 1901 | +431129,江华瑶族自治县,4311 | ||
| 1902 | +4312,怀化市,43 | ||
| 1903 | +431202,鹤城区,4312 | ||
| 1904 | +431221,中方县,4312 | ||
| 1905 | +431222,沅陵县,4312 | ||
| 1906 | +431223,辰溪县,4312 | ||
| 1907 | +431224,溆浦县,4312 | ||
| 1908 | +431225,会同县,4312 | ||
| 1909 | +431226,麻阳苗族自治县,4312 | ||
| 1910 | +431227,新晃侗族自治县,4312 | ||
| 1911 | +431228,芷江侗族自治县,4312 | ||
| 1912 | +431229,靖州苗族侗族自治县,4312 | ||
| 1913 | +431230,通道侗族自治县,4312 | ||
| 1914 | +431281,洪江市,4312 | ||
| 1915 | +4313,娄底市,43 | ||
| 1916 | +431302,娄星区,4313 | ||
| 1917 | +431321,双峰县,4313 | ||
| 1918 | +431322,新化县,4313 | ||
| 1919 | +431381,冷水江市,4313 | ||
| 1920 | +431382,涟源市,4313 | ||
| 1921 | +4331,湘西土家族苗族自治州,43 | ||
| 1922 | +433101,吉首市,4331 | ||
| 1923 | +433122,泸溪县,4331 | ||
| 1924 | +433123,凤凰县,4331 | ||
| 1925 | +433124,花垣县,4331 | ||
| 1926 | +433125,保靖县,4331 | ||
| 1927 | +433126,古丈县,4331 | ||
| 1928 | +433127,永顺县,4331 | ||
| 1929 | +433130,龙山县,4331 | ||
| 1930 | +44,广东省, | ||
| 1931 | +4401,广州市,44 | ||
| 1932 | +440103,荔湾区,4401 | ||
| 1933 | +440104,越秀区,4401 | ||
| 1934 | +440105,海珠区,4401 | ||
| 1935 | +440106,天河区,4401 | ||
| 1936 | +440111,白云区,4401 | ||
| 1937 | +440112,黄埔区,4401 | ||
| 1938 | +440113,番禺区,4401 | ||
| 1939 | +440114,花都区,4401 | ||
| 1940 | +440115,南沙区,4401 | ||
| 1941 | +440117,从化区,4401 | ||
| 1942 | +440118,增城区,4401 | ||
| 1943 | +4402,韶关市,44 | ||
| 1944 | +440203,武江区,4402 | ||
| 1945 | +440204,浈江区,4402 | ||
| 1946 | +440205,曲江区,4402 | ||
| 1947 | +440222,始兴县,4402 | ||
| 1948 | +440224,仁化县,4402 | ||
| 1949 | +440229,翁源县,4402 | ||
| 1950 | +440232,乳源瑶族自治县,4402 | ||
| 1951 | +440233,新丰县,4402 | ||
| 1952 | +440281,乐昌市,4402 | ||
| 1953 | +440282,南雄市,4402 | ||
| 1954 | +4403,深圳市,44 | ||
| 1955 | +440303,罗湖区,4403 | ||
| 1956 | +440304,福田区,4403 | ||
| 1957 | +440305,南山区,4403 | ||
| 1958 | +440306,宝安区,4403 | ||
| 1959 | +440307,龙岗区,4403 | ||
| 1960 | +440308,盐田区,4403 | ||
| 1961 | +440309,龙华区,4403 | ||
| 1962 | +440310,坪山区,4403 | ||
| 1963 | +440311,光明区,4403 | ||
| 1964 | +4404,珠海市,44 | ||
| 1965 | +440402,香洲区,4404 | ||
| 1966 | +440403,斗门区,4404 | ||
| 1967 | +440404,金湾区,4404 | ||
| 1968 | +4405,汕头市,44 | ||
| 1969 | +440507,龙湖区,4405 | ||
| 1970 | +440511,金平区,4405 | ||
| 1971 | +440512,濠江区,4405 | ||
| 1972 | +440513,潮阳区,4405 | ||
| 1973 | +440514,潮南区,4405 | ||
| 1974 | +440515,澄海区,4405 | ||
| 1975 | +440523,南澳县,4405 | ||
| 1976 | +4406,佛山市,44 | ||
| 1977 | +440604,禅城区,4406 | ||
| 1978 | +440605,南海区,4406 | ||
| 1979 | +440606,顺德区,4406 | ||
| 1980 | +440607,三水区,4406 | ||
| 1981 | +440608,高明区,4406 | ||
| 1982 | +4407,江门市,44 | ||
| 1983 | +440703,蓬江区,4407 | ||
| 1984 | +440704,江海区,4407 | ||
| 1985 | +440705,新会区,4407 | ||
| 1986 | +440781,台山市,4407 | ||
| 1987 | +440783,开平市,4407 | ||
| 1988 | +440784,鹤山市,4407 | ||
| 1989 | +440785,恩平市,4407 | ||
| 1990 | +4408,湛江市,44 | ||
| 1991 | +440802,赤坎区,4408 | ||
| 1992 | +440803,霞山区,4408 | ||
| 1993 | +440804,坡头区,4408 | ||
| 1994 | +440811,麻章区,4408 | ||
| 1995 | +440823,遂溪县,4408 | ||
| 1996 | +440825,徐闻县,4408 | ||
| 1997 | +440881,廉江市,4408 | ||
| 1998 | +440882,雷州市,4408 | ||
| 1999 | +440883,吴川市,4408 | ||
| 2000 | +4409,茂名市,44 | ||
| 2001 | +440902,茂南区,4409 | ||
| 2002 | +440904,电白区,4409 | ||
| 2003 | +440981,高州市,4409 | ||
| 2004 | +440982,化州市,4409 | ||
| 2005 | +440983,信宜市,4409 | ||
| 2006 | +4412,肇庆市,44 | ||
| 2007 | +441202,端州区,4412 | ||
| 2008 | +441203,鼎湖区,4412 | ||
| 2009 | +441204,高要区,4412 | ||
| 2010 | +441223,广宁县,4412 | ||
| 2011 | +441224,怀集县,4412 | ||
| 2012 | +441225,封开县,4412 | ||
| 2013 | +441226,德庆县,4412 | ||
| 2014 | +441284,四会市,4412 | ||
| 2015 | +4413,惠州市,44 | ||
| 2016 | +441302,惠城区,4413 | ||
| 2017 | +441303,惠阳区,4413 | ||
| 2018 | +441322,博罗县,4413 | ||
| 2019 | +441323,惠东县,4413 | ||
| 2020 | +441324,龙门县,4413 | ||
| 2021 | +4414,梅州市,44 | ||
| 2022 | +441402,梅江区,4414 | ||
| 2023 | +441403,梅县区,4414 | ||
| 2024 | +441422,大埔县,4414 | ||
| 2025 | +441423,丰顺县,4414 | ||
| 2026 | +441424,五华县,4414 | ||
| 2027 | +441426,平远县,4414 | ||
| 2028 | +441427,蕉岭县,4414 | ||
| 2029 | +441481,兴宁市,4414 | ||
| 2030 | +4415,汕尾市,44 | ||
| 2031 | +441502,城区,4415 | ||
| 2032 | +441521,海丰县,4415 | ||
| 2033 | +441523,陆河县,4415 | ||
| 2034 | +441581,陆丰市,4415 | ||
| 2035 | +4416,河源市,44 | ||
| 2036 | +441602,源城区,4416 | ||
| 2037 | +441621,紫金县,4416 | ||
| 2038 | +441622,龙川县,4416 | ||
| 2039 | +441623,连平县,4416 | ||
| 2040 | +441624,和平县,4416 | ||
| 2041 | +441625,东源县,4416 | ||
| 2042 | +4417,阳江市,44 | ||
| 2043 | +441702,江城区,4417 | ||
| 2044 | +441704,阳东区,4417 | ||
| 2045 | +441721,阳西县,4417 | ||
| 2046 | +441781,阳春市,4417 | ||
| 2047 | +4418,清远市,44 | ||
| 2048 | +441802,清城区,4418 | ||
| 2049 | +441803,清新区,4418 | ||
| 2050 | +441821,佛冈县,4418 | ||
| 2051 | +441823,阳山县,4418 | ||
| 2052 | +441825,连山壮族瑶族自治县,4418 | ||
| 2053 | +441826,连南瑶族自治县,4418 | ||
| 2054 | +441881,英德市,4418 | ||
| 2055 | +441882,连州市,4418 | ||
| 2056 | +4419,东莞市,44 | ||
| 2057 | +4420,中山市,44 | ||
| 2058 | +4451,潮州市,44 | ||
| 2059 | +445102,湘桥区,4451 | ||
| 2060 | +445103,潮安区,4451 | ||
| 2061 | +445122,饶平县,4451 | ||
| 2062 | +4452,揭阳市,44 | ||
| 2063 | +445202,榕城区,4452 | ||
| 2064 | +445203,揭东区,4452 | ||
| 2065 | +445222,揭西县,4452 | ||
| 2066 | +445224,惠来县,4452 | ||
| 2067 | +445281,普宁市,4452 | ||
| 2068 | +4453,云浮市,44 | ||
| 2069 | +445302,云城区,4453 | ||
| 2070 | +445303,云安区,4453 | ||
| 2071 | +445321,新兴县,4453 | ||
| 2072 | +445322,郁南县,4453 | ||
| 2073 | +445381,罗定市,4453 | ||
| 2074 | +45,广西壮族自治区, | ||
| 2075 | +4501,南宁市,45 | ||
| 2076 | +450102,兴宁区,4501 | ||
| 2077 | +450103,青秀区,4501 | ||
| 2078 | +450105,江南区,4501 | ||
| 2079 | +450107,西乡塘区,4501 | ||
| 2080 | +450108,良庆区,4501 | ||
| 2081 | +450109,邕宁区,4501 | ||
| 2082 | +450110,武鸣区,4501 | ||
| 2083 | +450123,隆安县,4501 | ||
| 2084 | +450124,马山县,4501 | ||
| 2085 | +450125,上林县,4501 | ||
| 2086 | +450126,宾阳县,4501 | ||
| 2087 | +450127,横县,4501 | ||
| 2088 | +4502,柳州市,45 | ||
| 2089 | +450202,城中区,4502 | ||
| 2090 | +450203,鱼峰区,4502 | ||
| 2091 | +450204,柳南区,4502 | ||
| 2092 | +450205,柳北区,4502 | ||
| 2093 | +450206,柳江区,4502 | ||
| 2094 | +450222,柳城县,4502 | ||
| 2095 | +450223,鹿寨县,4502 | ||
| 2096 | +450224,融安县,4502 | ||
| 2097 | +450225,融水苗族自治县,4502 | ||
| 2098 | +450226,三江侗族自治县,4502 | ||
| 2099 | +4503,桂林市,45 | ||
| 2100 | +450302,秀峰区,4503 | ||
| 2101 | +450303,叠彩区,4503 | ||
| 2102 | +450304,象山区,4503 | ||
| 2103 | +450305,七星区,4503 | ||
| 2104 | +450311,雁山区,4503 | ||
| 2105 | +450312,临桂区,4503 | ||
| 2106 | +450321,阳朔县,4503 | ||
| 2107 | +450323,灵川县,4503 | ||
| 2108 | +450324,全州县,4503 | ||
| 2109 | +450325,兴安县,4503 | ||
| 2110 | +450326,永福县,4503 | ||
| 2111 | +450327,灌阳县,4503 | ||
| 2112 | +450328,龙胜各族自治县,4503 | ||
| 2113 | +450329,资源县,4503 | ||
| 2114 | +450330,平乐县,4503 | ||
| 2115 | +450332,恭城瑶族自治县,4503 | ||
| 2116 | +450381,荔浦市,4503 | ||
| 2117 | +4504,梧州市,45 | ||
| 2118 | +450403,万秀区,4504 | ||
| 2119 | +450405,长洲区,4504 | ||
| 2120 | +450406,龙圩区,4504 | ||
| 2121 | +450421,苍梧县,4504 | ||
| 2122 | +450422,藤县,4504 | ||
| 2123 | +450423,蒙山县,4504 | ||
| 2124 | +450481,岑溪市,4504 | ||
| 2125 | +4505,北海市,45 | ||
| 2126 | +450502,海城区,4505 | ||
| 2127 | +450503,银海区,4505 | ||
| 2128 | +450512,铁山港区,4505 | ||
| 2129 | +450521,合浦县,4505 | ||
| 2130 | +4506,防城港市,45 | ||
| 2131 | +450602,港口区,4506 | ||
| 2132 | +450603,防城区,4506 | ||
| 2133 | +450621,上思县,4506 | ||
| 2134 | +450681,东兴市,4506 | ||
| 2135 | +4507,钦州市,45 | ||
| 2136 | +450702,钦南区,4507 | ||
| 2137 | +450703,钦北区,4507 | ||
| 2138 | +450721,灵山县,4507 | ||
| 2139 | +450722,浦北县,4507 | ||
| 2140 | +4508,贵港市,45 | ||
| 2141 | +450802,港北区,4508 | ||
| 2142 | +450803,港南区,4508 | ||
| 2143 | +450804,覃塘区,4508 | ||
| 2144 | +450821,平南县,4508 | ||
| 2145 | +450881,桂平市,4508 | ||
| 2146 | +4509,玉林市,45 | ||
| 2147 | +450902,玉州区,4509 | ||
| 2148 | +450903,福绵区,4509 | ||
| 2149 | +450921,容县,4509 | ||
| 2150 | +450922,陆川县,4509 | ||
| 2151 | +450923,博白县,4509 | ||
| 2152 | +450924,兴业县,4509 | ||
| 2153 | +450981,北流市,4509 | ||
| 2154 | +4510,百色市,45 | ||
| 2155 | +451002,右江区,4510 | ||
| 2156 | +451021,田阳县,4510 | ||
| 2157 | +451022,田东县,4510 | ||
| 2158 | +451023,平果县,4510 | ||
| 2159 | +451024,德保县,4510 | ||
| 2160 | +451026,那坡县,4510 | ||
| 2161 | +451027,凌云县,4510 | ||
| 2162 | +451028,乐业县,4510 | ||
| 2163 | +451029,田林县,4510 | ||
| 2164 | +451030,西林县,4510 | ||
| 2165 | +451031,隆林各族自治县,4510 | ||
| 2166 | +451081,靖西市,4510 | ||
| 2167 | +4511,贺州市,45 | ||
| 2168 | +451102,八步区,4511 | ||
| 2169 | +451103,平桂区,4511 | ||
| 2170 | +451121,昭平县,4511 | ||
| 2171 | +451122,钟山县,4511 | ||
| 2172 | +451123,富川瑶族自治县,4511 | ||
| 2173 | +4512,河池市,45 | ||
| 2174 | +451202,金城江区,4512 | ||
| 2175 | +451203,宜州区,4512 | ||
| 2176 | +451221,南丹县,4512 | ||
| 2177 | +451222,天峨县,4512 | ||
| 2178 | +451223,凤山县,4512 | ||
| 2179 | +451224,东兰县,4512 | ||
| 2180 | +451225,罗城仫佬族自治县,4512 | ||
| 2181 | +451226,环江毛南族自治县,4512 | ||
| 2182 | +451227,巴马瑶族自治县,4512 | ||
| 2183 | +451228,都安瑶族自治县,4512 | ||
| 2184 | +451229,大化瑶族自治县,4512 | ||
| 2185 | +4513,来宾市,45 | ||
| 2186 | +451302,兴宾区,4513 | ||
| 2187 | +451321,忻城县,4513 | ||
| 2188 | +451322,象州县,4513 | ||
| 2189 | +451323,武宣县,4513 | ||
| 2190 | +451324,金秀瑶族自治县,4513 | ||
| 2191 | +451381,合山市,4513 | ||
| 2192 | +4514,崇左市,45 | ||
| 2193 | +451402,江州区,4514 | ||
| 2194 | +451421,扶绥县,4514 | ||
| 2195 | +451422,宁明县,4514 | ||
| 2196 | +451423,龙州县,4514 | ||
| 2197 | +451424,大新县,4514 | ||
| 2198 | +451425,天等县,4514 | ||
| 2199 | +451481,凭祥市,4514 | ||
| 2200 | +46,海南省, | ||
| 2201 | +4601,海口市,46 | ||
| 2202 | +460105,秀英区,4601 | ||
| 2203 | +460106,龙华区,4601 | ||
| 2204 | +460107,琼山区,4601 | ||
| 2205 | +460108,美兰区,4601 | ||
| 2206 | +4602,三亚市,46 | ||
| 2207 | +460202,海棠区,4602 | ||
| 2208 | +460203,吉阳区,4602 | ||
| 2209 | +460204,天涯区,4602 | ||
| 2210 | +460205,崖州区,4602 | ||
| 2211 | +4603,三沙市,46 | ||
| 2212 | +4604,儋州市,46 | ||
| 2213 | +469001,五指山市,46 | ||
| 2214 | +469002,琼海市,46 | ||
| 2215 | +469005,文昌市,46 | ||
| 2216 | +469006,万宁市,46 | ||
| 2217 | +469007,东方市,46 | ||
| 2218 | +469021,定安县,46 | ||
| 2219 | +469022,屯昌县,46 | ||
| 2220 | +469023,澄迈县,46 | ||
| 2221 | +469024,临高县,46 | ||
| 2222 | +469025,白沙黎族自治县,46 | ||
| 2223 | +469026,昌江黎族自治县,46 | ||
| 2224 | +469027,乐东黎族自治县,46 | ||
| 2225 | +469028,陵水黎族自治县,46 | ||
| 2226 | +469029,保亭黎族苗族自治县,46 | ||
| 2227 | +469030,琼中黎族苗族自治县,46 | ||
| 2228 | +50,重庆市, | ||
| 2229 | +500101,万州区,50 | ||
| 2230 | +500102,涪陵区,50 | ||
| 2231 | +500103,渝中区,50 | ||
| 2232 | +500104,大渡口区,50 | ||
| 2233 | +500105,江北区,50 | ||
| 2234 | +500106,沙坪坝区,50 | ||
| 2235 | +500107,九龙坡区,50 | ||
| 2236 | +500108,南岸区,50 | ||
| 2237 | +500109,北碚区,50 | ||
| 2238 | +500110,綦江区,50 | ||
| 2239 | +500111,大足区,50 | ||
| 2240 | +500112,渝北区,50 | ||
| 2241 | +500113,巴南区,50 | ||
| 2242 | +500114,黔江区,50 | ||
| 2243 | +500115,长寿区,50 | ||
| 2244 | +500116,江津区,50 | ||
| 2245 | +500117,合川区,50 | ||
| 2246 | +500118,永川区,50 | ||
| 2247 | +500119,南川区,50 | ||
| 2248 | +500120,璧山区,50 | ||
| 2249 | +500151,铜梁区,50 | ||
| 2250 | +500152,潼南区,50 | ||
| 2251 | +500153,荣昌区,50 | ||
| 2252 | +500154,开州区,50 | ||
| 2253 | +500155,梁平区,50 | ||
| 2254 | +500156,武隆区,50 | ||
| 2255 | +500229,城口县,50 | ||
| 2256 | +500230,丰都县,50 | ||
| 2257 | +500231,垫江县,50 | ||
| 2258 | +500233,忠县,50 | ||
| 2259 | +500235,云阳县,50 | ||
| 2260 | +500236,奉节县,50 | ||
| 2261 | +500237,巫山县,50 | ||
| 2262 | +500238,巫溪县,50 | ||
| 2263 | +500240,石柱土家族自治县,50 | ||
| 2264 | +500241,秀山土家族苗族自治县,50 | ||
| 2265 | +500242,酉阳土家族苗族自治县,50 | ||
| 2266 | +500243,彭水苗族土家族自治县,50 | ||
| 2267 | +51,四川省, | ||
| 2268 | +5101,成都市,51 | ||
| 2269 | +510104,锦江区,5101 | ||
| 2270 | +510105,青羊区,5101 | ||
| 2271 | +510106,金牛区,5101 | ||
| 2272 | +510107,武侯区,5101 | ||
| 2273 | +510108,成华区,5101 | ||
| 2274 | +510112,龙泉驿区,5101 | ||
| 2275 | +510113,青白江区,5101 | ||
| 2276 | +510114,新都区,5101 | ||
| 2277 | +510115,温江区,5101 | ||
| 2278 | +510116,双流区,5101 | ||
| 2279 | +510117,郫都区,5101 | ||
| 2280 | +510121,金堂县,5101 | ||
| 2281 | +510129,大邑县,5101 | ||
| 2282 | +510131,蒲江县,5101 | ||
| 2283 | +510132,新津县,5101 | ||
| 2284 | +510181,都江堰市,5101 | ||
| 2285 | +510182,彭州市,5101 | ||
| 2286 | +510183,邛崃市,5101 | ||
| 2287 | +510184,崇州市,5101 | ||
| 2288 | +510185,简阳市,5101 | ||
| 2289 | +5103,自贡市,51 | ||
| 2290 | +510302,自流井区,5103 | ||
| 2291 | +510303,贡井区,5103 | ||
| 2292 | +510304,大安区,5103 | ||
| 2293 | +510311,沿滩区,5103 | ||
| 2294 | +510321,荣县,5103 | ||
| 2295 | +510322,富顺县,5103 | ||
| 2296 | +5104,攀枝花市,51 | ||
| 2297 | +510402,东区,5104 | ||
| 2298 | +510403,西区,5104 | ||
| 2299 | +510411,仁和区,5104 | ||
| 2300 | +510421,米易县,5104 | ||
| 2301 | +510422,盐边县,5104 | ||
| 2302 | +5105,泸州市,51 | ||
| 2303 | +510502,江阳区,5105 | ||
| 2304 | +510503,纳溪区,5105 | ||
| 2305 | +510504,龙马潭区,5105 | ||
| 2306 | +510521,泸县,5105 | ||
| 2307 | +510522,合江县,5105 | ||
| 2308 | +510524,叙永县,5105 | ||
| 2309 | +510525,古蔺县,5105 | ||
| 2310 | +5106,德阳市,51 | ||
| 2311 | +510603,旌阳区,5106 | ||
| 2312 | +510604,罗江区,5106 | ||
| 2313 | +510623,中江县,5106 | ||
| 2314 | +510681,广汉市,5106 | ||
| 2315 | +510682,什邡市,5106 | ||
| 2316 | +510683,绵竹市,5106 | ||
| 2317 | +5107,绵阳市,51 | ||
| 2318 | +510703,涪城区,5107 | ||
| 2319 | +510704,游仙区,5107 | ||
| 2320 | +510705,安州区,5107 | ||
| 2321 | +510722,三台县,5107 | ||
| 2322 | +510723,盐亭县,5107 | ||
| 2323 | +510725,梓潼县,5107 | ||
| 2324 | +510726,北川羌族自治县,5107 | ||
| 2325 | +510727,平武县,5107 | ||
| 2326 | +510781,江油市,5107 | ||
| 2327 | +5108,广元市,51 | ||
| 2328 | +510802,利州区,5108 | ||
| 2329 | +510811,昭化区,5108 | ||
| 2330 | +510812,朝天区,5108 | ||
| 2331 | +510821,旺苍县,5108 | ||
| 2332 | +510822,青川县,5108 | ||
| 2333 | +510823,剑阁县,5108 | ||
| 2334 | +510824,苍溪县,5108 | ||
| 2335 | +5109,遂宁市,51 | ||
| 2336 | +510903,船山区,5109 | ||
| 2337 | +510904,安居区,5109 | ||
| 2338 | +510921,蓬溪县,5109 | ||
| 2339 | +510922,射洪县,5109 | ||
| 2340 | +510923,大英县,5109 | ||
| 2341 | +5110,内江市,51 | ||
| 2342 | +511002,市中区,5110 | ||
| 2343 | +511011,东兴区,5110 | ||
| 2344 | +511024,威远县,5110 | ||
| 2345 | +511025,资中县,5110 | ||
| 2346 | +511083,隆昌市,5110 | ||
| 2347 | +5111,乐山市,51 | ||
| 2348 | +511102,市中区,5111 | ||
| 2349 | +511111,沙湾区,5111 | ||
| 2350 | +511112,五通桥区,5111 | ||
| 2351 | +511113,金口河区,5111 | ||
| 2352 | +511123,犍为县,5111 | ||
| 2353 | +511124,井研县,5111 | ||
| 2354 | +511126,夹江县,5111 | ||
| 2355 | +511129,沐川县,5111 | ||
| 2356 | +511132,峨边彝族自治县,5111 | ||
| 2357 | +511133,马边彝族自治县,5111 | ||
| 2358 | +511181,峨眉山市,5111 | ||
| 2359 | +5113,南充市,51 | ||
| 2360 | +511302,顺庆区,5113 | ||
| 2361 | +511303,高坪区,5113 | ||
| 2362 | +511304,嘉陵区,5113 | ||
| 2363 | +511321,南部县,5113 | ||
| 2364 | +511322,营山县,5113 | ||
| 2365 | +511323,蓬安县,5113 | ||
| 2366 | +511324,仪陇县,5113 | ||
| 2367 | +511325,西充县,5113 | ||
| 2368 | +511381,阆中市,5113 | ||
| 2369 | +5114,眉山市,51 | ||
| 2370 | +511402,东坡区,5114 | ||
| 2371 | +511403,彭山区,5114 | ||
| 2372 | +511421,仁寿县,5114 | ||
| 2373 | +511423,洪雅县,5114 | ||
| 2374 | +511424,丹棱县,5114 | ||
| 2375 | +511425,青神县,5114 | ||
| 2376 | +5115,宜宾市,51 | ||
| 2377 | +511502,翠屏区,5115 | ||
| 2378 | +511503,南溪区,5115 | ||
| 2379 | +511504,叙州区,5115 | ||
| 2380 | +511523,江安县,5115 | ||
| 2381 | +511524,长宁县,5115 | ||
| 2382 | +511525,高县,5115 | ||
| 2383 | +511526,珙县,5115 | ||
| 2384 | +511527,筠连县,5115 | ||
| 2385 | +511528,兴文县,5115 | ||
| 2386 | +511529,屏山县,5115 | ||
| 2387 | +5116,广安市,51 | ||
| 2388 | +511602,广安区,5116 | ||
| 2389 | +511603,前锋区,5116 | ||
| 2390 | +511621,岳池县,5116 | ||
| 2391 | +511622,武胜县,5116 | ||
| 2392 | +511623,邻水县,5116 | ||
| 2393 | +511681,华蓥市,5116 | ||
| 2394 | +5117,达州市,51 | ||
| 2395 | +511702,通川区,5117 | ||
| 2396 | +511703,达川区,5117 | ||
| 2397 | +511722,宣汉县,5117 | ||
| 2398 | +511723,开江县,5117 | ||
| 2399 | +511724,大竹县,5117 | ||
| 2400 | +511725,渠县,5117 | ||
| 2401 | +511781,万源市,5117 | ||
| 2402 | +5118,雅安市,51 | ||
| 2403 | +511802,雨城区,5118 | ||
| 2404 | +511803,名山区,5118 | ||
| 2405 | +511822,荥经县,5118 | ||
| 2406 | +511823,汉源县,5118 | ||
| 2407 | +511824,石棉县,5118 | ||
| 2408 | +511825,天全县,5118 | ||
| 2409 | +511826,芦山县,5118 | ||
| 2410 | +511827,宝兴县,5118 | ||
| 2411 | +5119,巴中市,51 | ||
| 2412 | +511902,巴州区,5119 | ||
| 2413 | +511903,恩阳区,5119 | ||
| 2414 | +511921,通江县,5119 | ||
| 2415 | +511922,南江县,5119 | ||
| 2416 | +511923,平昌县,5119 | ||
| 2417 | +5120,资阳市,51 | ||
| 2418 | +512002,雁江区,5120 | ||
| 2419 | +512021,安岳县,5120 | ||
| 2420 | +512022,乐至县,5120 | ||
| 2421 | +5132,阿坝藏族羌族自治州,51 | ||
| 2422 | +513201,马尔康市,5132 | ||
| 2423 | +513221,汶川县,5132 | ||
| 2424 | +513222,理县,5132 | ||
| 2425 | +513223,茂县,5132 | ||
| 2426 | +513224,松潘县,5132 | ||
| 2427 | +513225,九寨沟县,5132 | ||
| 2428 | +513226,金川县,5132 | ||
| 2429 | +513227,小金县,5132 | ||
| 2430 | +513228,黑水县,5132 | ||
| 2431 | +513230,壤塘县,5132 | ||
| 2432 | +513231,阿坝县,5132 | ||
| 2433 | +513232,若尔盖县,5132 | ||
| 2434 | +513233,红原县,5132 | ||
| 2435 | +5133,甘孜藏族自治州,51 | ||
| 2436 | +513301,康定市,5133 | ||
| 2437 | +513322,泸定县,5133 | ||
| 2438 | +513323,丹巴县,5133 | ||
| 2439 | +513324,九龙县,5133 | ||
| 2440 | +513325,雅江县,5133 | ||
| 2441 | +513326,道孚县,5133 | ||
| 2442 | +513327,炉霍县,5133 | ||
| 2443 | +513328,甘孜县,5133 | ||
| 2444 | +513329,新龙县,5133 | ||
| 2445 | +513330,德格县,5133 | ||
| 2446 | +513331,白玉县,5133 | ||
| 2447 | +513332,石渠县,5133 | ||
| 2448 | +513333,色达县,5133 | ||
| 2449 | +513334,理塘县,5133 | ||
| 2450 | +513335,巴塘县,5133 | ||
| 2451 | +513336,乡城县,5133 | ||
| 2452 | +513337,稻城县,5133 | ||
| 2453 | +513338,得荣县,5133 | ||
| 2454 | +5134,凉山彝族自治州,51 | ||
| 2455 | +513401,西昌市,5134 | ||
| 2456 | +513422,木里藏族自治县,5134 | ||
| 2457 | +513423,盐源县,5134 | ||
| 2458 | +513424,德昌县,5134 | ||
| 2459 | +513425,会理县,5134 | ||
| 2460 | +513426,会东县,5134 | ||
| 2461 | +513427,宁南县,5134 | ||
| 2462 | +513428,普格县,5134 | ||
| 2463 | +513429,布拖县,5134 | ||
| 2464 | +513430,金阳县,5134 | ||
| 2465 | +513431,昭觉县,5134 | ||
| 2466 | +513432,喜德县,5134 | ||
| 2467 | +513433,冕宁县,5134 | ||
| 2468 | +513434,越西县,5134 | ||
| 2469 | +513435,甘洛县,5134 | ||
| 2470 | +513436,美姑县,5134 | ||
| 2471 | +513437,雷波县,5134 | ||
| 2472 | +52,贵州省, | ||
| 2473 | +5201,贵阳市,52 | ||
| 2474 | +520102,南明区,5201 | ||
| 2475 | +520103,云岩区,5201 | ||
| 2476 | +520111,花溪区,5201 | ||
| 2477 | +520112,乌当区,5201 | ||
| 2478 | +520113,白云区,5201 | ||
| 2479 | +520115,观山湖区,5201 | ||
| 2480 | +520121,开阳县,5201 | ||
| 2481 | +520122,息烽县,5201 | ||
| 2482 | +520123,修文县,5201 | ||
| 2483 | +520181,清镇市,5201 | ||
| 2484 | +5202,六盘水市,52 | ||
| 2485 | +520201,钟山区,5202 | ||
| 2486 | +520203,六枝特区,5202 | ||
| 2487 | +520221,水城县,5202 | ||
| 2488 | +520281,盘州市,5202 | ||
| 2489 | +5203,遵义市,52 | ||
| 2490 | +520302,红花岗区,5203 | ||
| 2491 | +520303,汇川区,5203 | ||
| 2492 | +520304,播州区,5203 | ||
| 2493 | +520322,桐梓县,5203 | ||
| 2494 | +520323,绥阳县,5203 | ||
| 2495 | +520324,正安县,5203 | ||
| 2496 | +520325,道真仡佬族苗族自治县,5203 | ||
| 2497 | +520326,务川仡佬族苗族自治县,5203 | ||
| 2498 | +520327,凤冈县,5203 | ||
| 2499 | +520328,湄潭县,5203 | ||
| 2500 | +520329,余庆县,5203 | ||
| 2501 | +520330,习水县,5203 | ||
| 2502 | +520381,赤水市,5203 | ||
| 2503 | +520382,仁怀市,5203 | ||
| 2504 | +5204,安顺市,52 | ||
| 2505 | +520402,西秀区,5204 | ||
| 2506 | +520403,平坝区,5204 | ||
| 2507 | +520422,普定县,5204 | ||
| 2508 | +520423,镇宁布依族苗族自治县,5204 | ||
| 2509 | +520424,关岭布依族苗族自治县,5204 | ||
| 2510 | +520425,紫云苗族布依族自治县,5204 | ||
| 2511 | +5205,毕节市,52 | ||
| 2512 | +520502,七星关区,5205 | ||
| 2513 | +520521,大方县,5205 | ||
| 2514 | +520522,黔西县,5205 | ||
| 2515 | +520523,金沙县,5205 | ||
| 2516 | +520524,织金县,5205 | ||
| 2517 | +520525,纳雍县,5205 | ||
| 2518 | +520526,威宁彝族回族苗族自治县,5205 | ||
| 2519 | +520527,赫章县,5205 | ||
| 2520 | +5206,铜仁市,52 | ||
| 2521 | +520602,碧江区,5206 | ||
| 2522 | +520603,万山区,5206 | ||
| 2523 | +520621,江口县,5206 | ||
| 2524 | +520622,玉屏侗族自治县,5206 | ||
| 2525 | +520623,石阡县,5206 | ||
| 2526 | +520624,思南县,5206 | ||
| 2527 | +520625,印江土家族苗族自治县,5206 | ||
| 2528 | +520626,德江县,5206 | ||
| 2529 | +520627,沿河土家族自治县,5206 | ||
| 2530 | +520628,松桃苗族自治县,5206 | ||
| 2531 | +5223,黔西南布依族苗族自治州,52 | ||
| 2532 | +522301,兴义市,5223 | ||
| 2533 | +522302,兴仁市,5223 | ||
| 2534 | +522323,普安县,5223 | ||
| 2535 | +522324,晴隆县,5223 | ||
| 2536 | +522325,贞丰县,5223 | ||
| 2537 | +522326,望谟县,5223 | ||
| 2538 | +522327,册亨县,5223 | ||
| 2539 | +522328,安龙县,5223 | ||
| 2540 | +5226,黔东南苗族侗族自治州,52 | ||
| 2541 | +522601,凯里市,5226 | ||
| 2542 | +522622,黄平县,5226 | ||
| 2543 | +522623,施秉县,5226 | ||
| 2544 | +522624,三穗县,5226 | ||
| 2545 | +522625,镇远县,5226 | ||
| 2546 | +522626,岑巩县,5226 | ||
| 2547 | +522627,天柱县,5226 | ||
| 2548 | +522628,锦屏县,5226 | ||
| 2549 | +522629,剑河县,5226 | ||
| 2550 | +522630,台江县,5226 | ||
| 2551 | +522631,黎平县,5226 | ||
| 2552 | +522632,榕江县,5226 | ||
| 2553 | +522633,从江县,5226 | ||
| 2554 | +522634,雷山县,5226 | ||
| 2555 | +522635,麻江县,5226 | ||
| 2556 | +522636,丹寨县,5226 | ||
| 2557 | +5227,黔南布依族苗族自治州,52 | ||
| 2558 | +522701,都匀市,5227 | ||
| 2559 | +522702,福泉市,5227 | ||
| 2560 | +522722,荔波县,5227 | ||
| 2561 | +522723,贵定县,5227 | ||
| 2562 | +522725,瓮安县,5227 | ||
| 2563 | +522726,独山县,5227 | ||
| 2564 | +522727,平塘县,5227 | ||
| 2565 | +522728,罗甸县,5227 | ||
| 2566 | +522729,长顺县,5227 | ||
| 2567 | +522730,龙里县,5227 | ||
| 2568 | +522731,惠水县,5227 | ||
| 2569 | +522732,三都水族自治县,5227 | ||
| 2570 | +53,云南省, | ||
| 2571 | +5301,昆明市,53 | ||
| 2572 | +530102,五华区,5301 | ||
| 2573 | +530103,盘龙区,5301 | ||
| 2574 | +530111,官渡区,5301 | ||
| 2575 | +530112,西山区,5301 | ||
| 2576 | +530113,东川区,5301 | ||
| 2577 | +530114,呈贡区,5301 | ||
| 2578 | +530115,晋宁区,5301 | ||
| 2579 | +530124,富民县,5301 | ||
| 2580 | +530125,宜良县,5301 | ||
| 2581 | +530126,石林彝族自治县,5301 | ||
| 2582 | +530127,嵩明县,5301 | ||
| 2583 | +530128,禄劝彝族苗族自治县,5301 | ||
| 2584 | +530129,寻甸回族彝族自治县,5301 | ||
| 2585 | +530181,安宁市,5301 | ||
| 2586 | +5303,曲靖市,53 | ||
| 2587 | +530302,麒麟区,5303 | ||
| 2588 | +530303,沾益区,5303 | ||
| 2589 | +530304,马龙区,5303 | ||
| 2590 | +530322,陆良县,5303 | ||
| 2591 | +530323,师宗县,5303 | ||
| 2592 | +530324,罗平县,5303 | ||
| 2593 | +530325,富源县,5303 | ||
| 2594 | +530326,会泽县,5303 | ||
| 2595 | +530381,宣威市,5303 | ||
| 2596 | +5304,玉溪市,53 | ||
| 2597 | +530402,红塔区,5304 | ||
| 2598 | +530403,江川区,5304 | ||
| 2599 | +530422,澄江县,5304 | ||
| 2600 | +530423,通海县,5304 | ||
| 2601 | +530424,华宁县,5304 | ||
| 2602 | +530425,易门县,5304 | ||
| 2603 | +530426,峨山彝族自治县,5304 | ||
| 2604 | +530427,新平彝族傣族自治县,5304 | ||
| 2605 | +530428,元江哈尼族彝族傣族自治县,5304 | ||
| 2606 | +5305,保山市,53 | ||
| 2607 | +530502,隆阳区,5305 | ||
| 2608 | +530521,施甸县,5305 | ||
| 2609 | +530523,龙陵县,5305 | ||
| 2610 | +530524,昌宁县,5305 | ||
| 2611 | +530581,腾冲市,5305 | ||
| 2612 | +5306,昭通市,53 | ||
| 2613 | +530602,昭阳区,5306 | ||
| 2614 | +530621,鲁甸县,5306 | ||
| 2615 | +530622,巧家县,5306 | ||
| 2616 | +530623,盐津县,5306 | ||
| 2617 | +530624,大关县,5306 | ||
| 2618 | +530625,永善县,5306 | ||
| 2619 | +530626,绥江县,5306 | ||
| 2620 | +530627,镇雄县,5306 | ||
| 2621 | +530628,彝良县,5306 | ||
| 2622 | +530629,威信县,5306 | ||
| 2623 | +530681,水富市,5306 | ||
| 2624 | +5307,丽江市,53 | ||
| 2625 | +530702,古城区,5307 | ||
| 2626 | +530721,玉龙纳西族自治县,5307 | ||
| 2627 | +530722,永胜县,5307 | ||
| 2628 | +530723,华坪县,5307 | ||
| 2629 | +530724,宁蒗彝族自治县,5307 | ||
| 2630 | +5308,普洱市,53 | ||
| 2631 | +530802,思茅区,5308 | ||
| 2632 | +530821,宁洱哈尼族彝族自治县,5308 | ||
| 2633 | +530822,墨江哈尼族自治县,5308 | ||
| 2634 | +530823,景东彝族自治县,5308 | ||
| 2635 | +530824,景谷傣族彝族自治县,5308 | ||
| 2636 | +530825,镇沅彝族哈尼族拉祜族自治县,5308 | ||
| 2637 | +530826,江城哈尼族彝族自治县,5308 | ||
| 2638 | +530827,孟连傣族拉祜族佤族自治县,5308 | ||
| 2639 | +530828,澜沧拉祜族自治县,5308 | ||
| 2640 | +530829,西盟佤族自治县,5308 | ||
| 2641 | +5309,临沧市,53 | ||
| 2642 | +530902,临翔区,5309 | ||
| 2643 | +530921,凤庆县,5309 | ||
| 2644 | +530922,云县,5309 | ||
| 2645 | +530923,永德县,5309 | ||
| 2646 | +530924,镇康县,5309 | ||
| 2647 | +530925,双江拉祜族佤族布朗族傣族自治县,5309 | ||
| 2648 | +530926,耿马傣族佤族自治县,5309 | ||
| 2649 | +530927,沧源佤族自治县,5309 | ||
| 2650 | +5323,楚雄彝族自治州,53 | ||
| 2651 | +532301,楚雄市,5323 | ||
| 2652 | +532322,双柏县,5323 | ||
| 2653 | +532323,牟定县,5323 | ||
| 2654 | +532324,南华县,5323 | ||
| 2655 | +532325,姚安县,5323 | ||
| 2656 | +532326,大姚县,5323 | ||
| 2657 | +532327,永仁县,5323 | ||
| 2658 | +532328,元谋县,5323 | ||
| 2659 | +532329,武定县,5323 | ||
| 2660 | +532331,禄丰县,5323 | ||
| 2661 | +5325,红河哈尼族彝族自治州,53 | ||
| 2662 | +532501,个旧市,5325 | ||
| 2663 | +532502,开远市,5325 | ||
| 2664 | +532503,蒙自市,5325 | ||
| 2665 | +532504,弥勒市,5325 | ||
| 2666 | +532523,屏边苗族自治县,5325 | ||
| 2667 | +532524,建水县,5325 | ||
| 2668 | +532525,石屏县,5325 | ||
| 2669 | +532527,泸西县,5325 | ||
| 2670 | +532528,元阳县,5325 | ||
| 2671 | +532529,红河县,5325 | ||
| 2672 | +532530,金平苗族瑶族傣族自治县,5325 | ||
| 2673 | +532531,绿春县,5325 | ||
| 2674 | +532532,河口瑶族自治县,5325 | ||
| 2675 | +5326,文山壮族苗族自治州,53 | ||
| 2676 | +532601,文山市,5326 | ||
| 2677 | +532622,砚山县,5326 | ||
| 2678 | +532623,西畴县,5326 | ||
| 2679 | +532624,麻栗坡县,5326 | ||
| 2680 | +532625,马关县,5326 | ||
| 2681 | +532626,丘北县,5326 | ||
| 2682 | +532627,广南县,5326 | ||
| 2683 | +532628,富宁县,5326 | ||
| 2684 | +5328,西双版纳傣族自治州,53 | ||
| 2685 | +532801,景洪市,5328 | ||
| 2686 | +532822,勐海县,5328 | ||
| 2687 | +532823,勐腊县,5328 | ||
| 2688 | +5329,大理白族自治州,53 | ||
| 2689 | +532901,大理市,5329 | ||
| 2690 | +532922,漾濞彝族自治县,5329 | ||
| 2691 | +532923,祥云县,5329 | ||
| 2692 | +532924,宾川县,5329 | ||
| 2693 | +532925,弥渡县,5329 | ||
| 2694 | +532926,南涧彝族自治县,5329 | ||
| 2695 | +532927,巍山彝族回族自治县,5329 | ||
| 2696 | +532928,永平县,5329 | ||
| 2697 | +532929,云龙县,5329 | ||
| 2698 | +532930,洱源县,5329 | ||
| 2699 | +532931,剑川县,5329 | ||
| 2700 | +532932,鹤庆县,5329 | ||
| 2701 | +5331,德宏傣族景颇族自治州,53 | ||
| 2702 | +533102,瑞丽市,5331 | ||
| 2703 | +533103,芒市,5331 | ||
| 2704 | +533122,梁河县,5331 | ||
| 2705 | +533123,盈江县,5331 | ||
| 2706 | +533124,陇川县,5331 | ||
| 2707 | +5333,怒江傈僳族自治州,53 | ||
| 2708 | +533301,泸水市,5333 | ||
| 2709 | +533323,福贡县,5333 | ||
| 2710 | +533324,贡山独龙族怒族自治县,5333 | ||
| 2711 | +533325,兰坪白族普米族自治县,5333 | ||
| 2712 | +5334,迪庆藏族自治州,53 | ||
| 2713 | +533401,香格里拉市,5334 | ||
| 2714 | +533422,德钦县,5334 | ||
| 2715 | +533423,维西傈僳族自治县,5334 | ||
| 2716 | +54,西藏自治区, | ||
| 2717 | +5401,拉萨市,54 | ||
| 2718 | +540102,城关区,5401 | ||
| 2719 | +540103,堆龙德庆区,5401 | ||
| 2720 | +540104,达孜区,5401 | ||
| 2721 | +540121,林周县,5401 | ||
| 2722 | +540122,当雄县,5401 | ||
| 2723 | +540123,尼木县,5401 | ||
| 2724 | +540124,曲水县,5401 | ||
| 2725 | +540127,墨竹工卡县,5401 | ||
| 2726 | +5402,日喀则市,54 | ||
| 2727 | +540202,桑珠孜区,5402 | ||
| 2728 | +540221,南木林县,5402 | ||
| 2729 | +540222,江孜县,5402 | ||
| 2730 | +540223,定日县,5402 | ||
| 2731 | +540224,萨迦县,5402 | ||
| 2732 | +540225,拉孜县,5402 | ||
| 2733 | +540226,昂仁县,5402 | ||
| 2734 | +540227,谢通门县,5402 | ||
| 2735 | +540228,白朗县,5402 | ||
| 2736 | +540229,仁布县,5402 | ||
| 2737 | +540230,康马县,5402 | ||
| 2738 | +540231,定结县,5402 | ||
| 2739 | +540232,仲巴县,5402 | ||
| 2740 | +540233,亚东县,5402 | ||
| 2741 | +540234,吉隆县,5402 | ||
| 2742 | +540235,聂拉木县,5402 | ||
| 2743 | +540236,萨嘎县,5402 | ||
| 2744 | +540237,岗巴县,5402 | ||
| 2745 | +5403,昌都市,54 | ||
| 2746 | +540302,卡若区,5403 | ||
| 2747 | +540321,江达县,5403 | ||
| 2748 | +540322,贡觉县,5403 | ||
| 2749 | +540323,类乌齐县,5403 | ||
| 2750 | +540324,丁青县,5403 | ||
| 2751 | +540325,察雅县,5403 | ||
| 2752 | +540326,八宿县,5403 | ||
| 2753 | +540327,左贡县,5403 | ||
| 2754 | +540328,芒康县,5403 | ||
| 2755 | +540329,洛隆县,5403 | ||
| 2756 | +540330,边坝县,5403 | ||
| 2757 | +5404,林芝市,54 | ||
| 2758 | +540402,巴宜区,5404 | ||
| 2759 | +540421,工布江达县,5404 | ||
| 2760 | +540422,米林县,5404 | ||
| 2761 | +540423,墨脱县,5404 | ||
| 2762 | +540424,波密县,5404 | ||
| 2763 | +540425,察隅县,5404 | ||
| 2764 | +540426,朗县,5404 | ||
| 2765 | +5405,山南市,54 | ||
| 2766 | +540502,乃东区,5405 | ||
| 2767 | +540521,扎囊县,5405 | ||
| 2768 | +540522,贡嘎县,5405 | ||
| 2769 | +540523,桑日县,5405 | ||
| 2770 | +540524,琼结县,5405 | ||
| 2771 | +540525,曲松县,5405 | ||
| 2772 | +540526,措美县,5405 | ||
| 2773 | +540527,洛扎县,5405 | ||
| 2774 | +540528,加查县,5405 | ||
| 2775 | +540529,隆子县,5405 | ||
| 2776 | +540530,错那县,5405 | ||
| 2777 | +540531,浪卡子县,5405 | ||
| 2778 | +5406,那曲市,54 | ||
| 2779 | +540602,色尼区,5406 | ||
| 2780 | +540621,嘉黎县,5406 | ||
| 2781 | +540622,比如县,5406 | ||
| 2782 | +540623,聂荣县,5406 | ||
| 2783 | +540624,安多县,5406 | ||
| 2784 | +540625,申扎县,5406 | ||
| 2785 | +540626,索县,5406 | ||
| 2786 | +540627,班戈县,5406 | ||
| 2787 | +540628,巴青县,5406 | ||
| 2788 | +540629,尼玛县,5406 | ||
| 2789 | +540630,双湖县,5406 | ||
| 2790 | +5425,阿里地区,54 | ||
| 2791 | +542521,普兰县,5425 | ||
| 2792 | +542522,札达县,5425 | ||
| 2793 | +542523,噶尔县,5425 | ||
| 2794 | +542524,日土县,5425 | ||
| 2795 | +542525,革吉县,5425 | ||
| 2796 | +542526,改则县,5425 | ||
| 2797 | +542527,措勤县,5425 | ||
| 2798 | +61,陕西省, | ||
| 2799 | +6101,西安市,61 | ||
| 2800 | +610102,新城区,6101 | ||
| 2801 | +610103,碑林区,6101 | ||
| 2802 | +610104,莲湖区,6101 | ||
| 2803 | +610111,灞桥区,6101 | ||
| 2804 | +610112,未央区,6101 | ||
| 2805 | +610113,雁塔区,6101 | ||
| 2806 | +610114,阎良区,6101 | ||
| 2807 | +610115,临潼区,6101 | ||
| 2808 | +610116,长安区,6101 | ||
| 2809 | +610117,高陵区,6101 | ||
| 2810 | +610118,鄠邑区,6101 | ||
| 2811 | +610122,蓝田县,6101 | ||
| 2812 | +610124,周至县,6101 | ||
| 2813 | +6102,铜川市,61 | ||
| 2814 | +610202,王益区,6102 | ||
| 2815 | +610203,印台区,6102 | ||
| 2816 | +610204,耀州区,6102 | ||
| 2817 | +610222,宜君县,6102 | ||
| 2818 | +6103,宝鸡市,61 | ||
| 2819 | +610302,渭滨区,6103 | ||
| 2820 | +610303,金台区,6103 | ||
| 2821 | +610304,陈仓区,6103 | ||
| 2822 | +610322,凤翔县,6103 | ||
| 2823 | +610323,岐山县,6103 | ||
| 2824 | +610324,扶风县,6103 | ||
| 2825 | +610326,眉县,6103 | ||
| 2826 | +610327,陇县,6103 | ||
| 2827 | +610328,千阳县,6103 | ||
| 2828 | +610329,麟游县,6103 | ||
| 2829 | +610330,凤县,6103 | ||
| 2830 | +610331,太白县,6103 | ||
| 2831 | +6104,咸阳市,61 | ||
| 2832 | +610402,秦都区,6104 | ||
| 2833 | +610403,杨陵区,6104 | ||
| 2834 | +610404,渭城区,6104 | ||
| 2835 | +610422,三原县,6104 | ||
| 2836 | +610423,泾阳县,6104 | ||
| 2837 | +610424,乾县,6104 | ||
| 2838 | +610425,礼泉县,6104 | ||
| 2839 | +610426,永寿县,6104 | ||
| 2840 | +610428,长武县,6104 | ||
| 2841 | +610429,旬邑县,6104 | ||
| 2842 | +610430,淳化县,6104 | ||
| 2843 | +610431,武功县,6104 | ||
| 2844 | +610481,兴平市,6104 | ||
| 2845 | +610482,彬州市,6104 | ||
| 2846 | +6105,渭南市,61 | ||
| 2847 | +610502,临渭区,6105 | ||
| 2848 | +610503,华州区,6105 | ||
| 2849 | +610522,潼关县,6105 | ||
| 2850 | +610523,大荔县,6105 | ||
| 2851 | +610524,合阳县,6105 | ||
| 2852 | +610525,澄城县,6105 | ||
| 2853 | +610526,蒲城县,6105 | ||
| 2854 | +610527,白水县,6105 | ||
| 2855 | +610528,富平县,6105 | ||
| 2856 | +610581,韩城市,6105 | ||
| 2857 | +610582,华阴市,6105 | ||
| 2858 | +6106,延安市,61 | ||
| 2859 | +610602,宝塔区,6106 | ||
| 2860 | +610603,安塞区,6106 | ||
| 2861 | +610621,延长县,6106 | ||
| 2862 | +610622,延川县,6106 | ||
| 2863 | +610623,子长县,6106 | ||
| 2864 | +610625,志丹县,6106 | ||
| 2865 | +610626,吴起县,6106 | ||
| 2866 | +610627,甘泉县,6106 | ||
| 2867 | +610628,富县,6106 | ||
| 2868 | +610629,洛川县,6106 | ||
| 2869 | +610630,宜川县,6106 | ||
| 2870 | +610631,黄龙县,6106 | ||
| 2871 | +610632,黄陵县,6106 | ||
| 2872 | +6107,汉中市,61 | ||
| 2873 | +610702,汉台区,6107 | ||
| 2874 | +610703,南郑区,6107 | ||
| 2875 | +610722,城固县,6107 | ||
| 2876 | +610723,洋县,6107 | ||
| 2877 | +610724,西乡县,6107 | ||
| 2878 | +610725,勉县,6107 | ||
| 2879 | +610726,宁强县,6107 | ||
| 2880 | +610727,略阳县,6107 | ||
| 2881 | +610728,镇巴县,6107 | ||
| 2882 | +610729,留坝县,6107 | ||
| 2883 | +610730,佛坪县,6107 | ||
| 2884 | +6108,榆林市,61 | ||
| 2885 | +610802,榆阳区,6108 | ||
| 2886 | +610803,横山区,6108 | ||
| 2887 | +610822,府谷县,6108 | ||
| 2888 | +610824,靖边县,6108 | ||
| 2889 | +610825,定边县,6108 | ||
| 2890 | +610826,绥德县,6108 | ||
| 2891 | +610827,米脂县,6108 | ||
| 2892 | +610828,佳县,6108 | ||
| 2893 | +610829,吴堡县,6108 | ||
| 2894 | +610830,清涧县,6108 | ||
| 2895 | +610831,子洲县,6108 | ||
| 2896 | +610881,神木市,6108 | ||
| 2897 | +6109,安康市,61 | ||
| 2898 | +610902,汉滨区,6109 | ||
| 2899 | +610921,汉阴县,6109 | ||
| 2900 | +610922,石泉县,6109 | ||
| 2901 | +610923,宁陕县,6109 | ||
| 2902 | +610924,紫阳县,6109 | ||
| 2903 | +610925,岚皋县,6109 | ||
| 2904 | +610926,平利县,6109 | ||
| 2905 | +610927,镇坪县,6109 | ||
| 2906 | +610928,旬阳县,6109 | ||
| 2907 | +610929,白河县,6109 | ||
| 2908 | +6110,商洛市,61 | ||
| 2909 | +611002,商州区,6110 | ||
| 2910 | +611021,洛南县,6110 | ||
| 2911 | +611022,丹凤县,6110 | ||
| 2912 | +611023,商南县,6110 | ||
| 2913 | +611024,山阳县,6110 | ||
| 2914 | +611025,镇安县,6110 | ||
| 2915 | +611026,柞水县,6110 | ||
| 2916 | +62,甘肃省, | ||
| 2917 | +6201,兰州市,62 | ||
| 2918 | +620102,城关区,6201 | ||
| 2919 | +620103,七里河区,6201 | ||
| 2920 | +620104,西固区,6201 | ||
| 2921 | +620105,安宁区,6201 | ||
| 2922 | +620111,红古区,6201 | ||
| 2923 | +620121,永登县,6201 | ||
| 2924 | +620122,皋兰县,6201 | ||
| 2925 | +620123,榆中县,6201 | ||
| 2926 | +6202,嘉峪关市,62 | ||
| 2927 | +6203,金昌市,62 | ||
| 2928 | +620302,金川区,6203 | ||
| 2929 | +620321,永昌县,6203 | ||
| 2930 | +6204,白银市,62 | ||
| 2931 | +620402,白银区,6204 | ||
| 2932 | +620403,平川区,6204 | ||
| 2933 | +620421,靖远县,6204 | ||
| 2934 | +620422,会宁县,6204 | ||
| 2935 | +620423,景泰县,6204 | ||
| 2936 | +6205,天水市,62 | ||
| 2937 | +620502,秦州区,6205 | ||
| 2938 | +620503,麦积区,6205 | ||
| 2939 | +620521,清水县,6205 | ||
| 2940 | +620522,秦安县,6205 | ||
| 2941 | +620523,甘谷县,6205 | ||
| 2942 | +620524,武山县,6205 | ||
| 2943 | +620525,张家川回族自治县,6205 | ||
| 2944 | +6206,武威市,62 | ||
| 2945 | +620602,凉州区,6206 | ||
| 2946 | +620621,民勤县,6206 | ||
| 2947 | +620622,古浪县,6206 | ||
| 2948 | +620623,天祝藏族自治县,6206 | ||
| 2949 | +6207,张掖市,62 | ||
| 2950 | +620702,甘州区,6207 | ||
| 2951 | +620721,肃南裕固族自治县,6207 | ||
| 2952 | +620722,民乐县,6207 | ||
| 2953 | +620723,临泽县,6207 | ||
| 2954 | +620724,高台县,6207 | ||
| 2955 | +620725,山丹县,6207 | ||
| 2956 | +6208,平凉市,62 | ||
| 2957 | +620802,崆峒区,6208 | ||
| 2958 | +620821,泾川县,6208 | ||
| 2959 | +620822,灵台县,6208 | ||
| 2960 | +620823,崇信县,6208 | ||
| 2961 | +620825,庄浪县,6208 | ||
| 2962 | +620826,静宁县,6208 | ||
| 2963 | +620881,华亭市,6208 | ||
| 2964 | +6209,酒泉市,62 | ||
| 2965 | +620902,肃州区,6209 | ||
| 2966 | +620921,金塔县,6209 | ||
| 2967 | +620922,瓜州县,6209 | ||
| 2968 | +620923,肃北蒙古族自治县,6209 | ||
| 2969 | +620924,阿克塞哈萨克族自治县,6209 | ||
| 2970 | +620981,玉门市,6209 | ||
| 2971 | +620982,敦煌市,6209 | ||
| 2972 | +6210,庆阳市,62 | ||
| 2973 | +621002,西峰区,6210 | ||
| 2974 | +621021,庆城县,6210 | ||
| 2975 | +621022,环县,6210 | ||
| 2976 | +621023,华池县,6210 | ||
| 2977 | +621024,合水县,6210 | ||
| 2978 | +621025,正宁县,6210 | ||
| 2979 | +621026,宁县,6210 | ||
| 2980 | +621027,镇原县,6210 | ||
| 2981 | +6211,定西市,62 | ||
| 2982 | +621102,安定区,6211 | ||
| 2983 | +621121,通渭县,6211 | ||
| 2984 | +621122,陇西县,6211 | ||
| 2985 | +621123,渭源县,6211 | ||
| 2986 | +621124,临洮县,6211 | ||
| 2987 | +621125,漳县,6211 | ||
| 2988 | +621126,岷县,6211 | ||
| 2989 | +6212,陇南市,62 | ||
| 2990 | +621202,武都区,6212 | ||
| 2991 | +621221,成县,6212 | ||
| 2992 | +621222,文县,6212 | ||
| 2993 | +621223,宕昌县,6212 | ||
| 2994 | +621224,康县,6212 | ||
| 2995 | +621225,西和县,6212 | ||
| 2996 | +621226,礼县,6212 | ||
| 2997 | +621227,徽县,6212 | ||
| 2998 | +621228,两当县,6212 | ||
| 2999 | +6229,临夏回族自治州,62 | ||
| 3000 | +622901,临夏市,6229 | ||
| 3001 | +622921,临夏县,6229 | ||
| 3002 | +622922,康乐县,6229 | ||
| 3003 | +622923,永靖县,6229 | ||
| 3004 | +622924,广河县,6229 | ||
| 3005 | +622925,和政县,6229 | ||
| 3006 | +622926,东乡族自治县,6229 | ||
| 3007 | +622927,积石山保安族东乡族撒拉族自治县,6229 | ||
| 3008 | +6230,甘南藏族自治州,62 | ||
| 3009 | +623001,合作市,6230 | ||
| 3010 | +623021,临潭县,6230 | ||
| 3011 | +623022,卓尼县,6230 | ||
| 3012 | +623023,舟曲县,6230 | ||
| 3013 | +623024,迭部县,6230 | ||
| 3014 | +623025,玛曲县,6230 | ||
| 3015 | +623026,碌曲县,6230 | ||
| 3016 | +623027,夏河县,6230 | ||
| 3017 | +63,青海省, | ||
| 3018 | +6301,西宁市,63 | ||
| 3019 | +630102,城东区,6301 | ||
| 3020 | +630103,城中区,6301 | ||
| 3021 | +630104,城西区,6301 | ||
| 3022 | +630105,城北区,6301 | ||
| 3023 | +630121,大通回族土族自治县,6301 | ||
| 3024 | +630122,湟中县,6301 | ||
| 3025 | +630123,湟源县,6301 | ||
| 3026 | +6302,海东市,63 | ||
| 3027 | +630202,乐都区,6302 | ||
| 3028 | +630203,平安区,6302 | ||
| 3029 | +630222,民和回族土族自治县,6302 | ||
| 3030 | +630223,互助土族自治县,6302 | ||
| 3031 | +630224,化隆回族自治县,6302 | ||
| 3032 | +630225,循化撒拉族自治县,6302 | ||
| 3033 | +6322,海北藏族自治州,63 | ||
| 3034 | +632221,门源回族自治县,6322 | ||
| 3035 | +632222,祁连县,6322 | ||
| 3036 | +632223,海晏县,6322 | ||
| 3037 | +632224,刚察县,6322 | ||
| 3038 | +6323,黄南藏族自治州,63 | ||
| 3039 | +632321,同仁县,6323 | ||
| 3040 | +632322,尖扎县,6323 | ||
| 3041 | +632323,泽库县,6323 | ||
| 3042 | +632324,河南蒙古族自治县,6323 | ||
| 3043 | +6325,海南藏族自治州,63 | ||
| 3044 | +632521,共和县,6325 | ||
| 3045 | +632522,同德县,6325 | ||
| 3046 | +632523,贵德县,6325 | ||
| 3047 | +632524,兴海县,6325 | ||
| 3048 | +632525,贵南县,6325 | ||
| 3049 | +6326,果洛藏族自治州,63 | ||
| 3050 | +632621,玛沁县,6326 | ||
| 3051 | +632622,班玛县,6326 | ||
| 3052 | +632623,甘德县,6326 | ||
| 3053 | +632624,达日县,6326 | ||
| 3054 | +632625,久治县,6326 | ||
| 3055 | +632626,玛多县,6326 | ||
| 3056 | +6327,玉树藏族自治州,63 | ||
| 3057 | +632701,玉树市,6327 | ||
| 3058 | +632722,杂多县,6327 | ||
| 3059 | +632723,称多县,6327 | ||
| 3060 | +632724,治多县,6327 | ||
| 3061 | +632725,囊谦县,6327 | ||
| 3062 | +632726,曲麻莱县,6327 | ||
| 3063 | +6328,海西蒙古族藏族自治州,63 | ||
| 3064 | +632801,格尔木市,6328 | ||
| 3065 | +632802,德令哈市,6328 | ||
| 3066 | +632803,茫崖市,6328 | ||
| 3067 | +632821,乌兰县,6328 | ||
| 3068 | +632822,都兰县,6328 | ||
| 3069 | +632823,天峻县,6328 | ||
| 3070 | +64,宁夏回族自治区, | ||
| 3071 | +6401,银川市,64 | ||
| 3072 | +640104,兴庆区,6401 | ||
| 3073 | +640105,西夏区,6401 | ||
| 3074 | +640106,金凤区,6401 | ||
| 3075 | +640121,永宁县,6401 | ||
| 3076 | +640122,贺兰县,6401 | ||
| 3077 | +640181,灵武市,6401 | ||
| 3078 | +6402,石嘴山市,64 | ||
| 3079 | +640202,大武口区,6402 | ||
| 3080 | +640205,惠农区,6402 | ||
| 3081 | +640221,平罗县,6402 | ||
| 3082 | +6403,吴忠市,64 | ||
| 3083 | +640302,利通区,6403 | ||
| 3084 | +640303,红寺堡区,6403 | ||
| 3085 | +640323,盐池县,6403 | ||
| 3086 | +640324,同心县,6403 | ||
| 3087 | +640381,青铜峡市,6403 | ||
| 3088 | +6404,固原市,64 | ||
| 3089 | +640402,原州区,6404 | ||
| 3090 | +640422,西吉县,6404 | ||
| 3091 | +640423,隆德县,6404 | ||
| 3092 | +640424,泾源县,6404 | ||
| 3093 | +640425,彭阳县,6404 | ||
| 3094 | +6405,中卫市,64 | ||
| 3095 | +640502,沙坡头区,6405 | ||
| 3096 | +640521,中宁县,6405 | ||
| 3097 | +640522,海原县,6405 | ||
| 3098 | +65,新疆维吾尔自治区, | ||
| 3099 | +6501,乌鲁木齐市,65 | ||
| 3100 | +650102,天山区,6501 | ||
| 3101 | +650103,沙依巴克区,6501 | ||
| 3102 | +650104,新市区,6501 | ||
| 3103 | +650105,水磨沟区,6501 | ||
| 3104 | +650106,头屯河区,6501 | ||
| 3105 | +650107,达坂城区,6501 | ||
| 3106 | +650109,米东区,6501 | ||
| 3107 | +650121,乌鲁木齐县,6501 | ||
| 3108 | +6502,克拉玛依市,65 | ||
| 3109 | +650202,独山子区,6502 | ||
| 3110 | +650203,克拉玛依区,6502 | ||
| 3111 | +650204,白碱滩区,6502 | ||
| 3112 | +650205,乌尔禾区,6502 | ||
| 3113 | +6504,吐鲁番市,65 | ||
| 3114 | +650402,高昌区,6504 | ||
| 3115 | +650421,鄯善县,6504 | ||
| 3116 | +650422,托克逊县,6504 | ||
| 3117 | +6505,哈密市,65 | ||
| 3118 | +650502,伊州区,6505 | ||
| 3119 | +650521,巴里坤哈萨克自治县,6505 | ||
| 3120 | +650522,伊吾县,6505 | ||
| 3121 | +6523,昌吉回族自治州,65 | ||
| 3122 | +652301,昌吉市,6523 | ||
| 3123 | +652302,阜康市,6523 | ||
| 3124 | +652323,呼图壁县,6523 | ||
| 3125 | +652324,玛纳斯县,6523 | ||
| 3126 | +652325,奇台县,6523 | ||
| 3127 | +652327,吉木萨尔县,6523 | ||
| 3128 | +652328,木垒哈萨克自治县,6523 | ||
| 3129 | +6527,博尔塔拉蒙古自治州,65 | ||
| 3130 | +652701,博乐市,6527 | ||
| 3131 | +652702,阿拉山口市,6527 | ||
| 3132 | +652722,精河县,6527 | ||
| 3133 | +652723,温泉县,6527 | ||
| 3134 | +6528,巴音郭楞蒙古自治州,65 | ||
| 3135 | +652801,库尔勒市,6528 | ||
| 3136 | +652822,轮台县,6528 | ||
| 3137 | +652823,尉犁县,6528 | ||
| 3138 | +652824,若羌县,6528 | ||
| 3139 | +652825,且末县,6528 | ||
| 3140 | +652826,焉耆回族自治县,6528 | ||
| 3141 | +652827,和静县,6528 | ||
| 3142 | +652828,和硕县,6528 | ||
| 3143 | +652829,博湖县,6528 | ||
| 3144 | +6529,阿克苏地区,65 | ||
| 3145 | +652901,阿克苏市,6529 | ||
| 3146 | +652922,温宿县,6529 | ||
| 3147 | +652923,库车县,6529 | ||
| 3148 | +652924,沙雅县,6529 | ||
| 3149 | +652925,新和县,6529 | ||
| 3150 | +652926,拜城县,6529 | ||
| 3151 | +652927,乌什县,6529 | ||
| 3152 | +652928,阿瓦提县,6529 | ||
| 3153 | +652929,柯坪县,6529 | ||
| 3154 | +6530,克孜勒苏柯尔克孜自治州,65 | ||
| 3155 | +653001,阿图什市,6530 | ||
| 3156 | +653022,阿克陶县,6530 | ||
| 3157 | +653023,阿合奇县,6530 | ||
| 3158 | +653024,乌恰县,6530 | ||
| 3159 | +6531,喀什地区,65 | ||
| 3160 | +653101,喀什市,6531 | ||
| 3161 | +653121,疏附县,6531 | ||
| 3162 | +653122,疏勒县,6531 | ||
| 3163 | +653123,英吉沙县,6531 | ||
| 3164 | +653124,泽普县,6531 | ||
| 3165 | +653125,莎车县,6531 | ||
| 3166 | +653126,叶城县,6531 | ||
| 3167 | +653127,麦盖提县,6531 | ||
| 3168 | +653128,岳普湖县,6531 | ||
| 3169 | +653129,伽师县,6531 | ||
| 3170 | +653130,巴楚县,6531 | ||
| 3171 | +653131,塔什库尔干塔吉克自治县,6531 | ||
| 3172 | +6532,和田地区,65 | ||
| 3173 | +653201,和田市,6532 | ||
| 3174 | +653221,和田县,6532 | ||
| 3175 | +653222,墨玉县,6532 | ||
| 3176 | +653223,皮山县,6532 | ||
| 3177 | +653224,洛浦县,6532 | ||
| 3178 | +653225,策勒县,6532 | ||
| 3179 | +653226,于田县,6532 | ||
| 3180 | +653227,民丰县,6532 | ||
| 3181 | +6540,伊犁哈萨克自治州,65 | ||
| 3182 | +654002,伊宁市,6540 | ||
| 3183 | +654003,奎屯市,6540 | ||
| 3184 | +654004,霍尔果斯市,6540 | ||
| 3185 | +654021,伊宁县,6540 | ||
| 3186 | +654022,察布查尔锡伯自治县,6540 | ||
| 3187 | +654023,霍城县,6540 | ||
| 3188 | +654024,巩留县,6540 | ||
| 3189 | +654025,新源县,6540 | ||
| 3190 | +654026,昭苏县,6540 | ||
| 3191 | +654027,特克斯县,6540 | ||
| 3192 | +654028,尼勒克县,6540 | ||
| 3193 | +6542,塔城地区,65 | ||
| 3194 | +654201,塔城市,6542 | ||
| 3195 | +654202,乌苏市,6542 | ||
| 3196 | +654221,额敏县,6542 | ||
| 3197 | +654223,沙湾县,6542 | ||
| 3198 | +654224,托里县,6542 | ||
| 3199 | +654225,裕民县,6542 | ||
| 3200 | +654226,和布克赛尔蒙古自治县,6542 | ||
| 3201 | +6543,阿勒泰地区,65 | ||
| 3202 | +654301,阿勒泰市,6543 | ||
| 3203 | +654321,布尔津县,6543 | ||
| 3204 | +654322,富蕴县,6543 | ||
| 3205 | +654323,福海县,6543 | ||
| 3206 | +654324,哈巴河县,6543 | ||
| 3207 | +654325,青河县,6543 | ||
| 3208 | +654326,吉木乃县,6543 | ||
| 3209 | +659001,石河子市,65 | ||
| 3210 | +659002,阿拉尔市,65 | ||
| 3211 | +659003,图木舒克市,65 | ||
| 3212 | +659004,五家渠市,65 | ||
| 3213 | +659005,北屯市,65 | ||
| 3214 | +659006,铁门关市,65 | ||
| 3215 | +659007,双河市,65 | ||
| 3216 | +659008,可克达拉市,65 | ||
| 3217 | +659009,昆玉市,65 | ||
| 3218 | +71,台湾省, | ||
| 3219 | +81,香港特别行政区, | ||
| 3220 | +82,澳门特别行政区, | ||
| 0 | \ No newline at end of file | 3221 | \ No newline at end of file |
web_src/src/components/ParentPlatformList.vue
| @@ -144,7 +144,7 @@ export default { | @@ -144,7 +144,7 @@ export default { | ||
| 144 | }, | 144 | }, |
| 145 | chooseChannel: function(platform) { | 145 | chooseChannel: function(platform) { |
| 146 | console.log("platform.name: " + platform.name) | 146 | console.log("platform.name: " + platform.name) |
| 147 | - this.$refs.chooseChannelDialog.openDialog(platform.serverGBId,platform.deviceGBId, platform.name, platform.catalogId, platform.treeType, this.initData) | 147 | + this.$refs.chooseChannelDialog.openDialog(platform.serverGBId,platform.deviceGBId, platform.name, platform.catalogId, this.initData) |
| 148 | }, | 148 | }, |
| 149 | initData: function() { | 149 | initData: function() { |
| 150 | this.getPlatformList(); | 150 | this.getPlatformList(); |
web_src/src/components/dialog/catalogEdit.vue
| @@ -46,12 +46,11 @@ | @@ -46,12 +46,11 @@ | ||
| 46 | export default { | 46 | export default { |
| 47 | name: "catalogEdit", | 47 | name: "catalogEdit", |
| 48 | computed: {}, | 48 | computed: {}, |
| 49 | - props: ['platformId'], | 49 | + props: ['platformId', 'platformDeviceId'], |
| 50 | created() {}, | 50 | created() {}, |
| 51 | data() { | 51 | data() { |
| 52 | let checkId = (rule, value, callback) => { | 52 | let checkId = (rule, value, callback) => { |
| 53 | console.log("checkId") | 53 | console.log("checkId") |
| 54 | - console.log(this.treeType) | ||
| 55 | console.log(rule) | 54 | console.log(rule) |
| 56 | console.log(value) | 55 | console.log(value) |
| 57 | console.log(value.length) | 56 | console.log(value.length) |
| @@ -59,21 +58,34 @@ export default { | @@ -59,21 +58,34 @@ export default { | ||
| 59 | if (!value) { | 58 | if (!value) { |
| 60 | return callback(new Error('编号不能为空')); | 59 | return callback(new Error('编号不能为空')); |
| 61 | } | 60 | } |
| 62 | - if (this.treeType === "BusinessGroup" && value.length !== 20) { | ||
| 63 | - return callback(new Error('编号必须由20位数字组成')); | ||
| 64 | - } | ||
| 65 | - if (this.treeType === "CivilCode" && value.length <= 8 && value.length%2 !== 0) { | ||
| 66 | - return callback(new Error('行政区划必须是八位以下的偶数个数字组成')); | ||
| 67 | - } | ||
| 68 | - if (this.treeType === "BusinessGroup") { | 61 | + if (value.trim().length <= 8) { |
| 62 | + if (value.trim().length%2 !== 0) { | ||
| 63 | + return callback(new Error('行政区划编号必须为2/4/6/8位')); | ||
| 64 | + } | ||
| 65 | + if (this.form.parentId !== this.platformDeviceId && this.form.parentId.length >= value.trim().length) { | ||
| 66 | + return callback(new Error('行政区划编号长度应该每次两位递增')); | ||
| 67 | + } | ||
| 68 | + }else { | ||
| 69 | + if (value.trim().length !== 20) { | ||
| 70 | + return callback(new Error('编号必须为2/4/6/8位的行政区划或20位的虚拟组织/业务分组')); | ||
| 71 | + } | ||
| 69 | let catalogType = value.substring(10, 13); | 72 | let catalogType = value.substring(10, 13); |
| 70 | console.log(catalogType) | 73 | console.log(catalogType) |
| 71 | - // 216 为虚拟组织 215 为业务分组;目录第一级必须为业务分组, 业务分组下为虚拟组织,虚拟组织下可以有其他虚拟组织 | ||
| 72 | - if (this.level === 1 && catalogType !== "215") { | ||
| 73 | - return callback(new Error('业务分组模式下第一层目录的编号11到13位必须为215')); | 74 | + if (catalogType !== "215" && catalogType !== "216") { |
| 75 | + return callback(new Error('编号错误,业务分组11-13位为215,虚拟组织11-13位为216')); | ||
| 74 | } | 76 | } |
| 75 | - if (this.level > 1 && catalogType !== "216") { | ||
| 76 | - return callback(new Error('业务分组模式下第一层以下目录的编号11到13位必须为216')); | 77 | + if (catalogType === "216") { |
| 78 | + | ||
| 79 | + if (this.form.parentId !== this.platformDeviceId){ | ||
| 80 | + if (this.form.parentId.length <= 8) { | ||
| 81 | + return callback(new Error('编号错误,建立虚拟组织前必须先建立业务分组(11-13位为215)')); | ||
| 82 | + } | ||
| 83 | + } | ||
| 84 | + } | ||
| 85 | + if (catalogType === "215") { | ||
| 86 | + if (this.form.parentId.length === "215") { | ||
| 87 | + return callback(new Error('编号错误,业务分组下只能建立虚拟组织(11-13位为216)')); | ||
| 88 | + } | ||
| 77 | } | 89 | } |
| 78 | } | 90 | } |
| 79 | callback(); | 91 | callback(); |
| @@ -83,7 +95,6 @@ export default { | @@ -83,7 +95,6 @@ export default { | ||
| 83 | showDialog: false, | 95 | showDialog: false, |
| 84 | isLoging: false, | 96 | isLoging: false, |
| 85 | isEdit: false, | 97 | isEdit: false, |
| 86 | - treeType: null, | ||
| 87 | level: 0, | 98 | level: 0, |
| 88 | form: { | 99 | form: { |
| 89 | id: null, | 100 | id: null, |
| @@ -98,7 +109,7 @@ export default { | @@ -98,7 +109,7 @@ export default { | ||
| 98 | }; | 109 | }; |
| 99 | }, | 110 | }, |
| 100 | methods: { | 111 | methods: { |
| 101 | - openDialog: function (isEdit, id, name, parentId, treeType, level, callback) { | 112 | + openDialog: function (isEdit, id, name, parentId, level, callback) { |
| 102 | console.log("parentId: " + parentId) | 113 | console.log("parentId: " + parentId) |
| 103 | console.log(this.form) | 114 | console.log(this.form) |
| 104 | this.isEdit = isEdit; | 115 | this.isEdit = isEdit; |
| @@ -108,7 +119,6 @@ export default { | @@ -108,7 +119,6 @@ export default { | ||
| 108 | this.form.parentId = parentId; | 119 | this.form.parentId = parentId; |
| 109 | this.showDialog = true; | 120 | this.showDialog = true; |
| 110 | this.submitCallback = callback; | 121 | this.submitCallback = callback; |
| 111 | - this.treeType = treeType; | ||
| 112 | this.level = level; | 122 | this.level = level; |
| 113 | }, | 123 | }, |
| 114 | onSubmit: function () { | 124 | onSubmit: function () { |
web_src/src/components/dialog/chooseChannel.vue
| @@ -8,7 +8,7 @@ | @@ -8,7 +8,7 @@ | ||
| 8 | <el-tab-pane label="目录结构" name="catalog"> | 8 | <el-tab-pane label="目录结构" name="catalog"> |
| 9 | <el-container> | 9 | <el-container> |
| 10 | <el-main v-bind:style="{backgroundColor: '#FFF', maxHeight: winHeight + 'px'}"> | 10 | <el-main v-bind:style="{backgroundColor: '#FFF', maxHeight: winHeight + 'px'}"> |
| 11 | - <chooseChannelForCatalog ref="chooseChannelForCatalog" :platformId=platformId :platformDeviceId=platformDeviceId :platformName=platformName :defaultCatalogId=defaultCatalogId :catalogIdChange="catalogIdChange" :treeType=treeType ></chooseChannelForCatalog> | 11 | + <chooseChannelForCatalog ref="chooseChannelForCatalog" :platformId=platformId :platformDeviceId=platformDeviceId :platformName=platformName :defaultCatalogId=defaultCatalogId :catalogIdChange="catalogIdChange" ></chooseChannelForCatalog> |
| 12 | </el-main> | 12 | </el-main> |
| 13 | </el-container> | 13 | </el-container> |
| 14 | </el-tab-pane> | 14 | </el-tab-pane> |
| @@ -67,14 +67,13 @@ export default { | @@ -67,14 +67,13 @@ export default { | ||
| 67 | platformName: "", | 67 | platformName: "", |
| 68 | defaultCatalogId: "", | 68 | defaultCatalogId: "", |
| 69 | showDialog: false, | 69 | showDialog: false, |
| 70 | - treeType: null, | ||
| 71 | chooseData: {}, | 70 | chooseData: {}, |
| 72 | winHeight: window.innerHeight - 250, | 71 | winHeight: window.innerHeight - 250, |
| 73 | 72 | ||
| 74 | }; | 73 | }; |
| 75 | }, | 74 | }, |
| 76 | methods: { | 75 | methods: { |
| 77 | - openDialog(platformId, platformDeviceId, platformName, defaultCatalogId, treeType, closeCallback) { | 76 | + openDialog(platformId, platformDeviceId, platformName, defaultCatalogId, closeCallback) { |
| 78 | console.log("defaultCatalogId: " + defaultCatalogId) | 77 | console.log("defaultCatalogId: " + defaultCatalogId) |
| 79 | this.platformId = platformId | 78 | this.platformId = platformId |
| 80 | this.platformDeviceId = platformDeviceId | 79 | this.platformDeviceId = platformDeviceId |
| @@ -82,7 +81,6 @@ export default { | @@ -82,7 +81,6 @@ export default { | ||
| 82 | this.defaultCatalogId = defaultCatalogId | 81 | this.defaultCatalogId = defaultCatalogId |
| 83 | this.showDialog = true | 82 | this.showDialog = true |
| 84 | this.closeCallback = closeCallback | 83 | this.closeCallback = closeCallback |
| 85 | - this.treeType = treeType | ||
| 86 | }, | 84 | }, |
| 87 | tabClick (tab, event){ | 85 | tabClick (tab, event){ |
| 88 | 86 |
web_src/src/components/dialog/chooseChannelForCatalog.vue
| @@ -28,7 +28,7 @@ | @@ -28,7 +28,7 @@ | ||
| 28 | </span> | 28 | </span> |
| 29 | </el-tree> | 29 | </el-tree> |
| 30 | </div> | 30 | </div> |
| 31 | - <catalogEdit ref="catalogEdit" :platformId="platformId"></catalogEdit> | 31 | + <catalogEdit ref="catalogEdit" :platformId="platformId" :platformDeviceId="platformDeviceId"></catalogEdit> |
| 32 | </div> | 32 | </div> |
| 33 | </template> | 33 | </template> |
| 34 | 34 | ||
| @@ -38,7 +38,7 @@ | @@ -38,7 +38,7 @@ | ||
| 38 | import catalogEdit from './catalogEdit.vue' | 38 | import catalogEdit from './catalogEdit.vue' |
| 39 | export default { | 39 | export default { |
| 40 | name: 'chooseChannelForCatalog', | 40 | name: 'chooseChannelForCatalog', |
| 41 | - props: ['platformId', 'platformDeviceId', 'platformName', 'defaultCatalogId', 'catalogIdChange', 'treeType'], | 41 | + props: ['platformId', 'platformDeviceId', 'platformName', 'defaultCatalogId', 'catalogIdChange'], |
| 42 | created() { | 42 | created() { |
| 43 | this.chooseId = this.defaultCatalogId; | 43 | this.chooseId = this.defaultCatalogId; |
| 44 | this.defaultCatalogIdSign = this.defaultCatalogId; | 44 | this.defaultCatalogIdSign = this.defaultCatalogId; |
| @@ -101,9 +101,10 @@ export default { | @@ -101,9 +101,10 @@ export default { | ||
| 101 | }, | 101 | }, |
| 102 | addCatalog: function (parentId, node){ | 102 | addCatalog: function (parentId, node){ |
| 103 | let that = this; | 103 | let that = this; |
| 104 | - console.log(this.treeType) | 104 | + console.log(this.platformId) |
| 105 | + console.log(parentId) | ||
| 105 | // 打开添加弹窗 | 106 | // 打开添加弹窗 |
| 106 | - that.$refs.catalogEdit.openDialog(false, null, null, parentId, this.treeType, node.level, ()=>{ | 107 | + that.$refs.catalogEdit.openDialog(false, null, null, parentId, node.level, ()=>{ |
| 107 | node.loaded = false | 108 | node.loaded = false |
| 108 | node.expand(); | 109 | node.expand(); |
| 109 | }); | 110 | }); |
web_src/src/components/dialog/deviceEdit.vue
| @@ -49,12 +49,6 @@ | @@ -49,12 +49,6 @@ | ||
| 49 | <el-option key="GCJ02" label="GCJ02" value="GCJ02"></el-option> | 49 | <el-option key="GCJ02" label="GCJ02" value="GCJ02"></el-option> |
| 50 | </el-select> | 50 | </el-select> |
| 51 | </el-form-item> | 51 | </el-form-item> |
| 52 | - <el-form-item label="目录结构" prop="treeType" > | ||
| 53 | - <el-select v-model="form.treeType" style="float: left; width: 100%" > | ||
| 54 | - <el-option key="WGS84" label="行政区划" value="CivilCode"></el-option> | ||
| 55 | - <el-option key="GCJ02" label="业务分组" value="BusinessGroup"></el-option> | ||
| 56 | - </el-select> | ||
| 57 | - </el-form-item> | ||
| 58 | <el-form-item v-if="this.isEdit" label="目录订阅" title="0为取消订阅" prop="subscribeCycleForCatalog" > | 52 | <el-form-item v-if="this.isEdit" label="目录订阅" title="0为取消订阅" prop="subscribeCycleForCatalog" > |
| 59 | <el-input v-model="form.subscribeCycleForCatalog" clearable ></el-input> | 53 | <el-input v-model="form.subscribeCycleForCatalog" clearable ></el-input> |
| 60 | </el-form-item> | 54 | </el-form-item> |
web_src/src/components/dialog/platformEdit.vue
| @@ -78,12 +78,6 @@ | @@ -78,12 +78,6 @@ | ||
| 78 | <el-option label="8" value="8"></el-option> | 78 | <el-option label="8" value="8"></el-option> |
| 79 | </el-select> | 79 | </el-select> |
| 80 | </el-form-item> | 80 | </el-form-item> |
| 81 | - <el-form-item label="目录结构" prop="treeType" > | ||
| 82 | - <el-select v-model="platform.treeType" style="width: 100%" @change="treeTypeChange"> | ||
| 83 | - <el-option key="WGS84" label="行政区划" value="CivilCode"></el-option> | ||
| 84 | - <el-option key="GCJ02" label="业务分组" value="BusinessGroup"></el-option> | ||
| 85 | - </el-select> | ||
| 86 | - </el-form-item> | ||
| 87 | <el-form-item label="字符集" prop="characterSet"> | 81 | <el-form-item label="字符集" prop="characterSet"> |
| 88 | <el-select | 82 | <el-select |
| 89 | v-model="platform.characterSet" | 83 | v-model="platform.characterSet" |
| @@ -164,7 +158,6 @@ export default { | @@ -164,7 +158,6 @@ export default { | ||
| 164 | startOfflinePush: false, | 158 | startOfflinePush: false, |
| 165 | catalogGroup: 1, | 159 | catalogGroup: 1, |
| 166 | administrativeDivision: null, | 160 | administrativeDivision: null, |
| 167 | - treeType: "BusinessGroup", | ||
| 168 | }, | 161 | }, |
| 169 | rules: { | 162 | rules: { |
| 170 | name: [{ required: true, message: "请输入平台名称", trigger: "blur" }], | 163 | name: [{ required: true, message: "请输入平台名称", trigger: "blur" }], |
| @@ -203,7 +196,6 @@ export default { | @@ -203,7 +196,6 @@ export default { | ||
| 203 | that.platform.devicePort = res.data.data.devicePort; | 196 | that.platform.devicePort = res.data.data.devicePort; |
| 204 | that.platform.username = res.data.data.username; | 197 | that.platform.username = res.data.data.username; |
| 205 | that.platform.password = res.data.data.password; | 198 | that.platform.password = res.data.data.password; |
| 206 | - that.platform.treeType = "BusinessGroup"; | ||
| 207 | that.platform.administrativeDivision = res.data.data.username.substr(0, 6); | 199 | that.platform.administrativeDivision = res.data.data.username.substr(0, 6); |
| 208 | } | 200 | } |
| 209 | 201 | ||
| @@ -234,7 +226,6 @@ export default { | @@ -234,7 +226,6 @@ export default { | ||
| 234 | this.platform.startOfflinePush = platform.startOfflinePush; | 226 | this.platform.startOfflinePush = platform.startOfflinePush; |
| 235 | this.platform.catalogGroup = platform.catalogGroup; | 227 | this.platform.catalogGroup = platform.catalogGroup; |
| 236 | this.platform.administrativeDivision = platform.administrativeDivision; | 228 | this.platform.administrativeDivision = platform.administrativeDivision; |
| 237 | - this.platform.treeType = platform.treeType; | ||
| 238 | this.onSubmit_text = "保存"; | 229 | this.onSubmit_text = "保存"; |
| 239 | this.saveUrl = "/api/platform/save"; | 230 | this.saveUrl = "/api/platform/save"; |
| 240 | } | 231 | } |
| @@ -252,7 +243,6 @@ export default { | @@ -252,7 +243,6 @@ export default { | ||
| 252 | if (this.platform.administrativeDivision == null) { | 243 | if (this.platform.administrativeDivision == null) { |
| 253 | this.platform.administrativeDivision = this.platform.deviceGBId.substr(0, 6); | 244 | this.platform.administrativeDivision = this.platform.deviceGBId.substr(0, 6); |
| 254 | } | 245 | } |
| 255 | - | ||
| 256 | }, | 246 | }, |
| 257 | onSubmit: function () { | 247 | onSubmit: function () { |
| 258 | this.saveForm() | 248 | this.saveForm() |
| @@ -309,7 +299,6 @@ export default { | @@ -309,7 +299,6 @@ export default { | ||
| 309 | keepTimeout: 60, | 299 | keepTimeout: 60, |
| 310 | transport: "UDP", | 300 | transport: "UDP", |
| 311 | characterSet: "GB2312", | 301 | characterSet: "GB2312", |
| 312 | - treeType: "BusinessGroup", | ||
| 313 | startOfflinePush: false, | 302 | startOfflinePush: false, |
| 314 | catalogGroup: 1, | 303 | catalogGroup: 1, |
| 315 | } | 304 | } |
| @@ -344,13 +333,6 @@ export default { | @@ -344,13 +333,6 @@ export default { | ||
| 344 | }); | 333 | }); |
| 345 | } | 334 | } |
| 346 | }, | 335 | }, |
| 347 | - treeTypeChange: function (){ | ||
| 348 | - this.$message({ | ||
| 349 | - showClose: true, | ||
| 350 | - message: "修改目录结构会导致关联目录与通道数据被清空,保存后生效", | ||
| 351 | - type: "warning", | ||
| 352 | - }); | ||
| 353 | - } | ||
| 354 | }, | 336 | }, |
| 355 | }; | 337 | }; |
| 356 | </script> | 338 | </script> |