diff --git a/src/jmapNew/utils/parser.js b/src/jmapNew/utils/parser.js index 71a0067f4..e75dc26ed 100644 --- a/src/jmapNew/utils/parser.js +++ b/src/jmapNew/utils/parser.js @@ -49,7 +49,7 @@ export function parser(data, skinCode, showConfig) { zrUtil.each(data.sectionList || [], elem => { if (elem.type == '02' || elem.type == '03') { - mapDevice[elem.code].parentName = mapDevice[mapDevice[elem.code].parentCode].name; + mapDevice[elem.code].parentName = mapDevice[elem.parentCode] ? mapDevice[elem.parentCode].name : ''; } }, this);