@riil-frontend/component-topology 7.0.8 → 8.0.0-a.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (42) hide show
  1. package/build/index.js +1 -1
  2. package/es/components/BatchAttrMetric/setting.js +0 -2
  3. package/es/core/common/icons/basicIcons.js +57 -0
  4. package/es/core/common/icons/icon.js +4 -6
  5. package/es/core/components/ResourceViewAttributeSetting/Setting.js +5 -11
  6. package/es/core/components/ResourceViewAttributeSetting/nodeCiTypeAttrUtil.js +121 -0
  7. package/es/core/components/TopoView/GraphViewPanel.js +1 -2
  8. package/es/core/components/TopoView/topoView.js +3 -1
  9. package/es/core/hooks/useTopoEdit.js +35 -127
  10. package/es/core/models/AttributeMetricDisplay.js +4 -4
  11. package/es/core/models/TopoApp.js +1 -1
  12. package/es/core/models/tagstips/ElementTagTipConfig.js +17 -9
  13. package/es/core/models/utils/linkUtils.js +30 -36
  14. package/es/core/store/models/topoBizMod.js +1 -11
  15. package/es/core/store/models/topoConfig.js +6 -7
  16. package/es/core/store/models/topoMod.js +74 -50
  17. package/es/networkTopo/getTopoData.js +72 -64
  18. package/es/networkTopo/models/TopoCenter.js +14 -94
  19. package/es/networkTopo/services/topo/basic.js +26 -8
  20. package/es/networkTopo/utils/resourcePermissionUtil.js +2 -2
  21. package/es/utils/topoData.js +4 -169
  22. package/lib/components/BatchAttrMetric/setting.js +0 -4
  23. package/lib/core/common/icons/basicIcons.js +62 -0
  24. package/lib/core/common/icons/icon.js +5 -7
  25. package/lib/core/components/ResourceViewAttributeSetting/Setting.js +6 -11
  26. package/lib/core/components/ResourceViewAttributeSetting/nodeCiTypeAttrUtil.js +127 -0
  27. package/lib/core/components/TopoView/GraphViewPanel.js +1 -2
  28. package/lib/core/components/TopoView/topoView.js +4 -1
  29. package/lib/core/hooks/useTopoEdit.js +35 -129
  30. package/lib/core/models/AttributeMetricDisplay.js +4 -4
  31. package/lib/core/models/TopoApp.js +1 -1
  32. package/lib/core/models/tagstips/ElementTagTipConfig.js +17 -9
  33. package/lib/core/models/utils/linkUtils.js +27 -33
  34. package/lib/core/store/models/topoBizMod.js +1 -11
  35. package/lib/core/store/models/topoConfig.js +5 -6
  36. package/lib/core/store/models/topoMod.js +71 -48
  37. package/lib/networkTopo/getTopoData.js +73 -65
  38. package/lib/networkTopo/models/TopoCenter.js +14 -94
  39. package/lib/networkTopo/services/topo/basic.js +26 -8
  40. package/lib/networkTopo/utils/resourcePermissionUtil.js +2 -2
  41. package/lib/utils/topoData.js +6 -172
  42. package/package.json +2 -2
@@ -94,29 +94,26 @@ var getInterfaceObject = /*#__PURE__*/function () {
94
94
  exports.getInterfaceObject = getInterfaceObject;
95
95
 
96
96
  function mergeLinksData(links, linkCis, nodes, interfaceCis, interfaceDoc) {
97
- var linkCiMap = (0, _keyBy["default"])(linkCis, "id");
97
+ var linkCiMap = (0, _keyBy["default"])(links, 'id');
98
98
  return links.map(function (link) {
99
99
  var _interfaceCis$find, _interfaceCis$find2;
100
100
 
101
101
  var linkCi = linkCiMap[link.id];
102
102
  var attributes = (0, _extends2["default"])({}, linkCi === null || linkCi === void 0 ? void 0 : linkCi.attributes);
103
103
  var sourceNode = nodes.find(function (node) {
104
- return node.id === attributes["network_link.source_device_id"];
104
+ return node.id === attributes['network_link.source_device_id'];
105
105
  });
106
106
  var targetNode = nodes.find(function (node) {
107
- return node.id === attributes["network_link.destination_device_id"];
107
+ return node.id === attributes['network_link.destination_device_id'];
108
108
  }); // 翻译
109
109
 
110
110
  return (0, _extends2["default"])({}, link, {
111
- id: linkCi.id,
112
- ciType: linkCi === null || linkCi === void 0 ? void 0 : linkCi.typeCode,
113
- name: linkCi === null || linkCi === void 0 ? void 0 : linkCi.attributes.name,
114
111
  attributes: (0, _extends2["default"])({}, attributes, {
115
112
  // 源/目的设备
116
- "network_link.source_device_id_object": {
113
+ 'network_link.source_device_id_object': {
117
114
  displayName: sourceNode === null || sourceNode === void 0 ? void 0 : sourceNode.name
118
115
  },
119
- "network_link.destination_device_id_object": {
116
+ 'network_link.destination_device_id_object': {
120
117
  displayName: targetNode === null || targetNode === void 0 ? void 0 : targetNode.name
121
118
  },
122
119
  // 源/目的接口类型
@@ -126,12 +123,12 @@ function mergeLinksData(links, linkCis, nodes, interfaceCis, interfaceDoc) {
126
123
  source_id_object: {
127
124
  displayName: (_interfaceCis$find = interfaceCis.find(function (node) {
128
125
  return node.id === attributes.source_id;
129
- })) === null || _interfaceCis$find === void 0 ? void 0 : _interfaceCis$find.attributes["display_name"]
126
+ })) === null || _interfaceCis$find === void 0 ? void 0 : _interfaceCis$find.attributes['display_name']
130
127
  },
131
128
  destination_id_object: {
132
129
  displayName: (_interfaceCis$find2 = interfaceCis.find(function (node) {
133
130
  return node.id === attributes.destination_id;
134
- })) === null || _interfaceCis$find2 === void 0 ? void 0 : _interfaceCis$find2.attributes["display_name"]
131
+ })) === null || _interfaceCis$find2 === void 0 ? void 0 : _interfaceCis$find2.attributes['display_name']
135
132
  }
136
133
  })
137
134
  });
@@ -157,36 +154,33 @@ function _getLinksDetail() {
157
154
  return _context2.abrupt("return", []);
158
155
 
159
156
  case 2:
160
- _context2.next = 4;
161
- return _topo["default"].relation.batchQueryRelation(links.map(function (link) {
162
- return link.id;
163
- }));
164
-
165
- case 4:
166
- linkCis = _context2.sent;
157
+ // const linkCis = await topoService.relation.batchQueryRelation(
158
+ // links.map((link) => link.id)
159
+ // );
160
+ linkCis = links;
167
161
  interfaceIds = [];
168
162
  interfaceTypes = [];
169
- linkCis.map(function (item) {
163
+ linkCis.forEach(function (item) {
170
164
  interfaceIds.push(item.attributes.source_id);
171
165
  interfaceIds.push(item.attributes.destination_id);
172
166
  interfaceTypes.push(item.attributes.source_type);
173
167
  interfaceTypes.push(item.attributes.destination_type);
174
168
  });
175
- _context2.next = 10;
169
+ _context2.next = 8;
176
170
  return (0, _services.queryCisByIds)(interfaceIds);
177
171
 
178
- case 10:
172
+ case 8:
179
173
  interfaceCis = _context2.sent;
180
- _context2.next = 13;
174
+ _context2.next = 11;
181
175
  return getInterfaceObject(interfaceTypes.filter(function (item) {
182
176
  return item !== 'ip';
183
177
  }));
184
178
 
185
- case 13:
179
+ case 11:
186
180
  interfaceDoc = _context2.sent;
187
181
  return _context2.abrupt("return", mergeLinksData(links, linkCis, nodes, interfaceCis, interfaceDoc));
188
182
 
189
- case 15:
183
+ case 13:
190
184
  case "end":
191
185
  return _context2.stop();
192
186
  }
@@ -216,10 +210,10 @@ var compatibleWith = function compatibleWith(value) {
216
210
  exports.compatibleWith = compatibleWith;
217
211
  var plurals = {
218
212
  0: [],
219
- 1: ["phy"],
220
- 2: ["phy"],
221
- 3: ["agg"],
222
- 4: ["phy", "agg"]
213
+ 1: ['phy'],
214
+ 2: ['phy'],
215
+ 3: ['agg'],
216
+ 4: ['phy', 'agg']
223
217
  };
224
218
  exports.plurals = plurals;
225
219
 
@@ -236,25 +230,25 @@ var showLinkByConfig = function showLinkByConfig(props) {
236
230
  var dm = gv.getDataModel();
237
231
  var edges = (0, _htElementUtils.getEdges)(dm); // console.log("edges", edges);
238
232
 
239
- var showPhy = types.indexOf("phy") >= 0;
240
- var showAgg = types.indexOf("agg") >= 0; // console.log("edges----types",showType, types,showPhy, showAgg);
233
+ var showPhy = types.indexOf('phy') >= 0;
234
+ var showAgg = types.indexOf('agg') >= 0; // console.log("edges----types",showType, types,showPhy, showAgg);
241
235
 
242
236
  if (Array.isArray(edges) && edges.length > 0) {
243
237
  edges.map(function (edge) {
244
238
  if (showType === 1 || showType === true) {
245
239
  // 单链路全部显示
246
240
  // console.log("单链路全部显示", edge);
247
- edge.s("2d.visible", true);
241
+ edge.s('2d.visible', true);
248
242
  } else {
249
243
  var _d$attributes, _d$attributes2;
250
244
 
251
245
  var d = topo.dataModel.getDataById(edge.getTag()); // 判断是否聚合链路
252
246
 
253
- if ((d === null || d === void 0 ? void 0 : (_d$attributes = d.attributes) === null || _d$attributes === void 0 ? void 0 : _d$attributes.destination_type) === "network.agg_interface" && (d === null || d === void 0 ? void 0 : (_d$attributes2 = d.attributes) === null || _d$attributes2 === void 0 ? void 0 : _d$attributes2.source_type) === "network.agg_interface") {
254
- edge.s("2d.visible", showAgg);
247
+ if ((d === null || d === void 0 ? void 0 : (_d$attributes = d.attributes) === null || _d$attributes === void 0 ? void 0 : _d$attributes.destination_type) === 'network.agg_interface' && (d === null || d === void 0 ? void 0 : (_d$attributes2 = d.attributes) === null || _d$attributes2 === void 0 ? void 0 : _d$attributes2.source_type) === 'network.agg_interface') {
248
+ edge.s('2d.visible', showAgg);
255
249
  } else {
256
250
  // console.log("edge", edge, d, showAgg);
257
- edge.s("2d.visible", showPhy);
251
+ edge.s('2d.visible', showPhy);
258
252
  }
259
253
  }
260
254
  });
@@ -23,7 +23,6 @@ function _default(engine) {
23
23
  metricDoc: {},
24
24
  attrDoc: {},
25
25
  allCiSet: {},
26
- ciSetDoc: {},
27
26
  pollingSwitch: false,
28
27
 
29
28
  /**
@@ -44,7 +43,6 @@ function _default(engine) {
44
43
  var _this = this;
45
44
 
46
45
  return (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee() {
47
- var ciDoc, newCiDoc;
48
46
  return _regenerator["default"].wrap(function _callee$(_context) {
49
47
  while (1) {
50
48
  switch (_context.prev = _context.next) {
@@ -53,17 +51,9 @@ function _default(engine) {
53
51
  resAndMetrics: conditions
54
52
  });
55
53
 
56
- ciDoc = conditions.ciDoc;
57
- newCiDoc = (0, _extends2["default"])({}, ciDoc); // rlog.debug('topoBizMod.combBatchCiInfo getBatchCiInfo', conditions);
58
-
59
- _this.update({
60
- ciSetDoc: newCiDoc,
61
- pollingSwitch: true
62
- });
63
-
64
54
  return _context.abrupt("return", {});
65
55
 
66
- case 5:
56
+ case 2:
67
57
  case "end":
68
58
  return _context.stop();
69
59
  }
@@ -330,7 +330,7 @@ function _default(topoApp) {
330
330
  var _this4 = this;
331
331
 
332
332
  return (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee4() {
333
- var topoId, resources, groups, exportLinkIdList, viewConditions, groupInfo, data, _yield$Promise$all, ciTypeMap, _combTopoData, topoData, resAndMetrics, topoDataTrans;
333
+ var topoId, resources, groups, exportLinkIdList, viewConditions, groupInfo, data, _yield$Promise$all, dataWithLinkDetail, _combTopoData, topoData, resAndMetrics, topoDataTrans;
334
334
 
335
335
  return _regenerator["default"].wrap(function _callee4$(_context4) {
336
336
  while (1) {
@@ -357,20 +357,19 @@ function _default(topoApp) {
357
357
  case 8:
358
358
  data = _context4.sent;
359
359
  _context4.next = 11;
360
- return Promise.all([topoApp.ciTyeCache.getCiTypeMap((0, _topoData.getCiTypes)(data)), dispatch.customIcon.loadCustomIcons()]);
360
+ return Promise.all([(0, _getTopoData.addLinkData)(data), topoApp.ciTyeCache.getCiTypeMap((0, _topoData.getCiTypes)(data)), dispatch.customIcon.loadCustomIcons()]);
361
361
 
362
362
  case 11:
363
363
  _yield$Promise$all = _context4.sent;
364
- ciTypeMap = _yield$Promise$all[0];
364
+ dataWithLinkDetail = _yield$Promise$all[0];
365
365
  _combTopoData = (0, _topoData.combTopoData)({
366
366
  engine: topoApp,
367
367
  data: data,
368
368
  linkTo: null,
369
- globalConfig: state.topoMod.globalConfig,
370
- ciTypeMap: ciTypeMap
369
+ globalConfig: state.topoMod.globalConfig
371
370
  }), topoData = _combTopoData.topoData, resAndMetrics = _combTopoData.resAndMetrics;
372
371
  dispatch.topoMod.update({
373
- data: data
372
+ data: dataWithLinkDetail
374
373
  });
375
374
  topoDataTrans = (0, _utils2.transformTopoElements)(topoData);
376
375
 
@@ -23,12 +23,14 @@ var _tree = require("../../../utils/tree");
23
23
 
24
24
  var _topoPermissionUtil = _interopRequireDefault(require("../../../utils/topoPermissionUtil"));
25
25
 
26
+ var _getTopoData = require("../../../networkTopo/getTopoData");
27
+
26
28
  // const clone = (data) => JSON.parse(JSON.stringify(data));
27
29
  function _default(topoApp) {
28
30
  return {
29
31
  state: {
30
32
  loading: true,
31
- viewState: "view",
33
+ viewState: 'view',
32
34
  // view, create, 2种模式
33
35
  graphLoaded: false,
34
36
  graphLoaded2: false,
@@ -37,7 +39,7 @@ function _default(topoApp) {
37
39
  initParams: {},
38
40
  topoLoadError: false,
39
41
  id: undefined,
40
- topoId: "",
42
+ topoId: '',
41
43
  type: undefined,
42
44
  // 拓扑类型
43
45
  currentTopo: undefined,
@@ -81,8 +83,8 @@ function _default(topoApp) {
81
83
 
82
84
  topoModState = rootState.topoMod; // 处理URL参数
83
85
 
84
- type = params.type || "view";
85
- id = params.id || topoModState.topoId || "";
86
+ type = params.type || 'view';
87
+ id = params.id || topoModState.topoId || '';
86
88
 
87
89
  _rlog["default"].debug("topoMod.init \u521D\u59CB\u5316(" + id + ")...", {
88
90
  params: params,
@@ -116,7 +118,7 @@ function _default(topoApp) {
116
118
  loading: false
117
119
  });
118
120
 
119
- _rlog["default"].debug("topoMod.initTopoCenter 初始化完成", {
121
+ _rlog["default"].debug('topoMod.initTopoCenter 初始化完成', {
120
122
  rootState: rootState
121
123
  });
122
124
 
@@ -161,7 +163,7 @@ function _default(topoApp) {
161
163
  switch (_context2.prev = _context2.next) {
162
164
  case 0:
163
165
  id = playload.id, data = playload.data, linkTo = playload.linkTo;
164
- viewState = playload.mode || playload.viewState || "view";
166
+ viewState = playload.mode || playload.viewState || 'view';
165
167
  topoId = id || data.config.id;
166
168
 
167
169
  _this2.update({
@@ -181,7 +183,7 @@ function _default(topoApp) {
181
183
  });
182
184
 
183
185
  case 6:
184
- if (viewState === "edit") {
186
+ if (viewState === 'edit') {
185
187
  // TODO 待优化进入编辑模式方式
186
188
  _this2.enterEditMode();
187
189
  }
@@ -208,7 +210,7 @@ function _default(topoApp) {
208
210
  this.update({
209
211
  graphLoaded: false,
210
212
  graphLoaded2: false,
211
- topoId: "",
213
+ topoId: '',
212
214
  topoData: null,
213
215
  currentTopo: undefined,
214
216
  data: null,
@@ -218,7 +220,7 @@ function _default(topoApp) {
218
220
  },
219
221
  switchToViewMode: function switchToViewMode(playload, rootState) {
220
222
  this.update({
221
- viewState: "view"
223
+ viewState: 'view'
222
224
  });
223
225
  },
224
226
  enterEditMode: function enterEditMode(playload, rootState) {
@@ -242,7 +244,7 @@ function _default(topoApp) {
242
244
  if (!topoId) {
243
245
  // 查找第一个
244
246
  treeData = rootState.topoTreeMod.treeData;
245
- (0, _tree.loopTreeByKey)(treeData, "type", 1, function (item, index, arr) {
247
+ (0, _tree.loopTreeByKey)(treeData, 'type', 1, function (item, index, arr) {
246
248
  if (!topoId) {
247
249
  topoId = item.id;
248
250
  }
@@ -319,7 +321,7 @@ function _default(topoApp) {
319
321
  return (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee6() {
320
322
  var _result$config;
321
323
 
322
- var startTime, topoId, data, linkToData, refresh, clear, linkTo, startState, permission, result, graphConfig, topoConfig, _yield$Promise$all, ciTypeMap, customIcons, xxx, extraConfig, _combTopoData, topoData, resAndMetrics, endTime;
324
+ var startTime, topoId, data, linkToData, refresh, clear, linkTo, startState, permission, result, graphConfig, topoConfig, _yield$Promise$all, ciTypeMap, customIcons, xxx, extraConfig, _combTopoData, topoData, resAndMetrics, _yield$Promise$all2, newData, endTime;
323
325
 
324
326
  return _regenerator["default"].wrap(function _callee6$(_context6) {
325
327
  while (1) {
@@ -352,25 +354,28 @@ function _default(topoApp) {
352
354
 
353
355
  _this5.update(startState);
354
356
 
357
+ dispatch.topoBizMod.update({
358
+ pollingSwitch: false
359
+ });
355
360
  topoApp.options.onLoadStart(); // TODO 待移到拓扑中心
356
361
 
357
- permission = "write";
362
+ permission = 'write';
358
363
 
359
364
  if (!topoApp.options.usePermission) {
360
- _context6.next = 18;
365
+ _context6.next = 19;
361
366
  break;
362
367
  }
363
368
 
364
- _context6.next = 13;
369
+ _context6.next = 14;
365
370
  return _this5.getTopoPermission({
366
371
  id: topoId
367
372
  });
368
373
 
369
- case 13:
374
+ case 14:
370
375
  permission = _context6.sent;
371
376
 
372
377
  if (_topoPermissionUtil["default"].isReadable(permission)) {
373
- _context6.next = 18;
378
+ _context6.next = 19;
374
379
  break;
375
380
  }
376
381
 
@@ -385,23 +390,23 @@ function _default(topoApp) {
385
390
  topoApp.options.onLoad();
386
391
  return _context6.abrupt("return");
387
392
 
388
- case 18:
393
+ case 19:
389
394
  if (!data) {
390
- _context6.next = 29;
395
+ _context6.next = 30;
391
396
  break;
392
397
  }
393
398
 
394
399
  graphConfig = {};
395
400
 
396
401
  if (!topoId) {
397
- _context6.next = 26;
402
+ _context6.next = 27;
398
403
  break;
399
404
  }
400
405
 
401
- _context6.next = 23;
406
+ _context6.next = 24;
402
407
  return _topo["default"].getTopoData(topoId);
403
408
 
404
- case 23:
409
+ case 24:
405
410
  topoConfig = _context6.sent;
406
411
  if (!topoConfig) _rlog["default"].error("\u672A\u67E5\u8BE2\u5230\u62D3\u6251id " + topoId + " \u7684\u6570\u636E\uFF0C\u8BF7\u68C0\u67E5");
407
412
  graphConfig = {
@@ -410,21 +415,21 @@ function _default(topoApp) {
410
415
  serialize: topoConfig === null || topoConfig === void 0 ? void 0 : topoConfig.serialize
411
416
  };
412
417
 
413
- case 26:
418
+ case 27:
414
419
  result = (0, _extends2["default"])({}, data, graphConfig);
415
- _context6.next = 32;
420
+ _context6.next = 33;
416
421
  break;
417
422
 
418
- case 29:
419
- _context6.next = 31;
423
+ case 30:
424
+ _context6.next = 32;
420
425
  return topoApp.options.loadData(topoId, topoApp.serverApi);
421
426
 
422
- case 31:
427
+ case 32:
423
428
  result = _context6.sent;
424
429
 
425
- case 32:
430
+ case 33:
426
431
  if (result) {
427
- _context6.next = 36;
432
+ _context6.next = 37;
428
433
  break;
429
434
  }
430
435
 
@@ -439,23 +444,21 @@ function _default(topoApp) {
439
444
  topoApp.options.onLoad();
440
445
  return _context6.abrupt("return");
441
446
 
442
- case 36:
447
+ case 37:
443
448
  result = (0, _topoData.parseTopoData)(result);
444
449
 
445
- _rlog["default"].debug("topoMod.initTopoData 查询数据完成", topoId, linkTo, result);
450
+ _rlog["default"].debug('topoMod.initTopoData 查询数据完成', topoId, linkTo, result);
446
451
 
447
- _context6.next = 40;
448
- return Promise.all([topoApp.ciTyeCache.getCiTypeMap((0, _topoData.getCiTypes)(result)), dispatch.customIcon.loadCustomIcons(), topoApp.elementTagTipConfig.init(result) // 暂停新配置开发
452
+ _context6.next = 41;
453
+ return Promise.all([// topoApp.ciTyeCache.getCiTypeMap(getCiTypes(result)),
454
+ dispatch.customIcon.loadCustomIcons() // topoApp.elementTagTipConfig.init(result), // 暂停新配置开发
449
455
  ]);
450
456
 
451
- case 40:
457
+ case 41:
452
458
  _yield$Promise$all = _context6.sent;
453
459
  ciTypeMap = _yield$Promise$all[0];
454
460
  customIcons = _yield$Promise$all[1];
455
461
  xxx = _yield$Promise$all[2];
456
-
457
- _rlog["default"].debug("topoMod.initTopoData Ci属性指标元数据", ciTypeMap);
458
-
459
462
  extraConfig = result.global.extraConfig;
460
463
  _context6.next = 48;
461
464
  return dispatch.displayConfig.setConfig((0, _extends2["default"])({}, extraConfig, {
@@ -468,13 +471,11 @@ function _default(topoApp) {
468
471
  engine: topoApp,
469
472
  data: result,
470
473
  linkTo: linkTo,
471
- globalConfig: extraConfig,
472
- ciTypeMap: ciTypeMap,
473
- permission: permission
474
+ globalConfig: extraConfig
474
475
  }), topoData = _combTopoData.topoData, resAndMetrics = _combTopoData.resAndMetrics; // rlog.debug("topoMod.initTopoData combTopoData", { topoData, resAndMetrics, });
475
476
 
476
- _this5.update({
477
- loading: false,
477
+ _context6.next = 51;
478
+ return _this5.update({
478
479
  currentTopo: topoData.config,
479
480
  data: result,
480
481
  globalConfig: extraConfig,
@@ -483,18 +484,40 @@ function _default(topoApp) {
483
484
  resAndMetrics: resAndMetrics
484
485
  });
485
486
 
487
+ case 51:
486
488
  dispatch.topoBizMod.combBatchCiInfo(resAndMetrics);
487
489
  dispatch.background.init(extraConfig); // TODO 优化打开拓扑图显示告警速度:打开拓扑图立即请求告警
488
490
 
489
- topoApp.alarm.open();
491
+ topoApp.alarm.open(); // 加载标注悬浮框数据
492
+
493
+ _context6.next = 56;
494
+ return Promise.all([(0, _getTopoData.addLinkData)(result), topoApp.ciTyeCache.getCiTypeMap((0, _topoData.getCiTypes)(result)), topoApp.elementTagTipConfig.init(result) // 暂停新配置开发
495
+ ]);
496
+
497
+ case 56:
498
+ _yield$Promise$all2 = _context6.sent;
499
+ newData = _yield$Promise$all2[0];
500
+ _context6.next = 60;
501
+ return _this5.update({
502
+ data: newData
503
+ });
504
+
505
+ case 60:
506
+ dispatch.topoBizMod.update({
507
+ pollingSwitch: true
508
+ });
490
509
  topoApp.onTopoDataLoaded(topoData);
491
510
  endTime = (0, _moment["default"])();
492
511
 
493
- _rlog["default"].info("topoMod.initTopoData 初始化拓扑图数据完成. 耗时: ", endTime.diff(startTime, "seconds", true));
512
+ _rlog["default"].info('topoMod.initTopoData 初始化拓扑图数据完成. 耗时: ', endTime.diff(startTime, 'seconds', true));
494
513
 
495
514
  topoApp.options.onLoad();
496
515
 
497
- case 57:
516
+ _this5.update({
517
+ loading: false
518
+ });
519
+
520
+ case 66:
498
521
  case "end":
499
522
  return _context6.stop();
500
523
  }
@@ -550,13 +573,13 @@ function _default(topoApp) {
550
573
  }
551
574
 
552
575
  if (conditions.id === state.topoMod.topoId) {
553
- if (conditions.type === "delete") {
576
+ if (conditions.type === 'delete') {
554
577
  _this7.update({
555
578
  topoId: conditions.defId
556
579
  });
557
580
  }
558
581
 
559
- if (conditions.type === "rename") {
582
+ if (conditions.type === 'rename') {
560
583
  td = (0, _extends2["default"])({}, state.topoMod.topoData, {
561
584
  config: (0, _extends2["default"])({}, state.topoMod.topoData.config, {
562
585
  name: conditions.name
@@ -600,10 +623,10 @@ function _default(topoApp) {
600
623
  switch (_context10.prev = _context10.next) {
601
624
  case 0:
602
625
  if (conditions === void 0) {
603
- conditions = "";
626
+ conditions = '';
604
627
  }
605
628
 
606
- _rlog["default"].debug("updateDelId", conditions);
629
+ _rlog["default"].debug('updateDelId', conditions);
607
630
 
608
631
  case 2:
609
632
  case "end":