@riil-frontend/component-topology 3.5.0-a.9 → 3.5.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.
- package/build/1.js +1 -1
- package/build/index.css +1 -1
- package/build/index.js +12 -12
- package/es/components/index.module.scss +3 -114
- package/es/core/components/AlarmListPanel/index.js +7 -12
- package/es/core/components/DisplaySettingDrawer/DisplaySetting.js +8 -5
- package/es/core/components/DisplaySettingDrawer/NodeTag.js +10 -5
- package/es/core/components/DisplaySettingDrawer/NodeTip.js +10 -5
- package/es/core/components/DisplaySettingDrawer/hooks/useDisplaySetting.js +3 -21
- package/es/core/components/TopoView/topoView.js +1 -0
- package/es/core/editor/components/settings/propertyViews/edge/CommonEdgePropertyView.js +7 -140
- package/es/core/editor/components/settings/propertyViews/edge/EdgePropertyView.js +1 -1
- package/es/core/editor/components/settings/propertyViews/node/Setting/Setting.js +1 -1
- package/es/core/editor/components/settings/propertyViews/node/data/Data.js +18 -17
- package/es/core/editor/components/titlebar/TopoEditorTitleBar.js +62 -18
- package/es/core/models/Alarm.js +206 -120
- package/es/core/models/DataModel.js +15 -1
- package/es/core/models/TopoApp.js +4 -6
- package/es/core/models/cache/CiTyeCache.js +4 -0
- package/es/core/models/utils/linkUtils.js +87 -42
- package/es/core/services/index.js +28 -0
- package/es/core/utils/saveSerialize.js +34 -0
- package/es/core/viewer/components/plugins/ResourceDetail/ResourceDetail.js +0 -37
- package/es/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/BaseInfo.js +31 -28
- package/es/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/ResourceOverview.js +44 -43
- package/es/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/ResourceOverviewMetric.js +39 -26
- package/es/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/hooks/useCiData.js +0 -0
- package/es/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/hooks/useMetricModels.js +143 -0
- package/es/core/viewer/components/plugins/ResourceDetail/getCiDisplayMetricModels.js +37 -0
- package/es/core/viewer/components/titlebar/BasicTools.js +11 -1
- package/es/core/viewer/components/titlebar/widgets/AlarmListShowButton.js +21 -13
- package/es/hooks/useGraphAlarmDisplay.js +3 -4
- package/es/hooks/useManageStatus.js +1 -1
- package/es/hooks/useTopoEdit.js +200 -144
- package/es/hooks/useTopoEventListener.js +13 -6
- package/es/index.js +3 -2
- package/es/models/topoConfig.js +0 -1
- package/es/models/topoMod.js +15 -10
- package/es/topoCenter/components/Topo404.js +3 -1
- package/es/topoCenter/components/TopoNoPermission.js +3 -1
- package/es/topoCenter/components/TopoView.js +77 -32
- package/es/topoCenter/components/Topology.js +2 -0
- package/es/topoCenter/components/editor/propertyViews/edge/EdgePropertyView.js +10 -0
- package/es/topoCenter/components/editor/propertyViews/edge/LinkPropertyView/Data/index.js +5 -20
- package/es/topoCenter/components/editor/propertyViews/edge/LinkPropertyView/LinkPropertyView.js +12 -6
- package/es/topoCenter/components/editor/propertyViews/edge/addLinkDrawer/AddLinkDrawer.js +84 -43
- package/es/topoCenter/components/editor/propertyViews/edge/addLinkDrawer/components/editLinkInfo.js +60 -34
- package/es/topoCenter/components/editor/propertyViews/edge/addLinkDrawer/index.module.scss +9 -0
- package/es/topoCenter/components/editor/propertyViews/edge/addLinkDrawer/server.js +62 -19
- package/es/topoCenter/components/editor/propertyViews/edge/link/BindExitLinkSelect.js +157 -0
- package/es/topoCenter/components/editor/propertyViews/edge/link/LinkInfoPreview.js +1 -2
- package/es/topoCenter/hooks/editor/useDeleteEdges.js +2 -3
- package/es/topoCenter/utils/resourcePermissionUtil.js +18 -12
- package/es/utils/topoData.js +15 -13
- package/lib/components/index.module.scss +3 -114
- package/lib/core/components/AlarmListPanel/index.js +7 -12
- package/lib/core/components/DisplaySettingDrawer/DisplaySetting.js +9 -5
- package/lib/core/components/DisplaySettingDrawer/NodeTag.js +11 -5
- package/lib/core/components/DisplaySettingDrawer/NodeTip.js +12 -5
- package/lib/core/components/DisplaySettingDrawer/hooks/useDisplaySetting.js +3 -21
- package/lib/core/components/TopoView/topoView.js +1 -0
- package/lib/core/editor/components/settings/propertyViews/edge/CommonEdgePropertyView.js +7 -151
- package/lib/core/editor/components/settings/propertyViews/edge/EdgePropertyView.js +2 -2
- package/lib/core/editor/components/settings/propertyViews/node/Setting/Setting.js +1 -1
- package/lib/core/editor/components/settings/propertyViews/node/data/Data.js +17 -16
- package/lib/core/editor/components/titlebar/TopoEditorTitleBar.js +66 -20
- package/lib/core/models/Alarm.js +206 -121
- package/lib/core/models/DataModel.js +15 -1
- package/lib/core/models/TopoApp.js +4 -6
- package/lib/core/models/cache/CiTyeCache.js +4 -0
- package/lib/core/models/utils/linkUtils.js +92 -43
- package/lib/core/services/index.js +29 -0
- package/lib/core/utils/saveSerialize.js +43 -0
- package/lib/core/viewer/components/plugins/ResourceDetail/ResourceDetail.js +0 -37
- package/lib/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/BaseInfo.js +29 -26
- package/lib/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/ResourceOverview.js +45 -43
- package/lib/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/ResourceOverviewMetric.js +38 -24
- package/lib/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/hooks/useCiData.js +1 -0
- package/lib/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/hooks/useMetricModels.js +155 -0
- package/lib/core/viewer/components/plugins/ResourceDetail/getCiDisplayMetricModels.js +47 -0
- package/lib/core/viewer/components/titlebar/BasicTools.js +11 -1
- package/lib/core/viewer/components/titlebar/widgets/AlarmListShowButton.js +22 -15
- package/lib/hooks/useGraphAlarmDisplay.js +3 -5
- package/lib/hooks/useManageStatus.js +1 -1
- package/lib/hooks/useTopoEdit.js +197 -141
- package/lib/hooks/useTopoEventListener.js +13 -6
- package/lib/index.js +5 -0
- package/lib/models/topoConfig.js +0 -1
- package/lib/models/topoMod.js +15 -10
- package/lib/topoCenter/components/Topo404.js +4 -1
- package/lib/topoCenter/components/TopoNoPermission.js +4 -1
- package/lib/topoCenter/components/TopoView.js +78 -33
- package/lib/topoCenter/components/Topology.js +3 -0
- package/lib/topoCenter/components/editor/propertyViews/edge/EdgePropertyView.js +22 -0
- package/lib/topoCenter/components/editor/propertyViews/edge/LinkPropertyView/Data/index.js +5 -21
- package/lib/topoCenter/components/editor/propertyViews/edge/LinkPropertyView/LinkPropertyView.js +13 -8
- package/lib/topoCenter/components/editor/propertyViews/edge/addLinkDrawer/AddLinkDrawer.js +87 -42
- package/lib/topoCenter/components/editor/propertyViews/edge/addLinkDrawer/components/editLinkInfo.js +61 -37
- package/lib/topoCenter/components/editor/propertyViews/edge/addLinkDrawer/index.module.scss +9 -0
- package/lib/topoCenter/components/editor/propertyViews/edge/addLinkDrawer/server.js +62 -18
- package/lib/topoCenter/components/editor/propertyViews/edge/link/BindExitLinkSelect.js +183 -0
- package/lib/topoCenter/components/editor/propertyViews/edge/link/LinkInfoPreview.js +1 -2
- package/lib/topoCenter/hooks/editor/useDeleteEdges.js +2 -3
- package/lib/topoCenter/utils/resourcePermissionUtil.js +20 -12
- package/lib/utils/topoData.js +15 -13
- package/package.json +5 -5
package/es/hooks/useTopoEdit.js
CHANGED
|
@@ -3,9 +3,9 @@ import _extends from "@babel/runtime/helpers/extends";
|
|
|
3
3
|
import _Dialog from "@alifd/next/es/dialog";
|
|
4
4
|
import _asyncToGenerator from "@babel/runtime/helpers/asyncToGenerator";
|
|
5
5
|
import _regeneratorRuntime from "@babel/runtime/regenerator";
|
|
6
|
-
import { useCallback, useEffect, useMemo, useState } from
|
|
7
|
-
import rlog from
|
|
8
|
-
import { TopoEvent } from
|
|
6
|
+
import { useCallback, useEffect, useMemo, useState } from "react";
|
|
7
|
+
import rlog from "@riil-frontend/component-topology-utils/es/rlog";
|
|
8
|
+
import { TopoEvent } from "@riil-frontend/component-topology-graph";
|
|
9
9
|
import { filterElementsByNodeId } from "../utils/format";
|
|
10
10
|
import { TPL_BLANK, TPL_TREE } from "../utils/template";
|
|
11
11
|
import topoPermissonUtil from "../utils/topoPermissionUtil";
|
|
@@ -35,15 +35,15 @@ var useTopoEdit = function useTopoEdit(params) {
|
|
|
35
35
|
resourceConfig: resourceConfig
|
|
36
36
|
});
|
|
37
37
|
|
|
38
|
-
var _store$useModel = store.useModel(
|
|
38
|
+
var _store$useModel = store.useModel("topoEdit"),
|
|
39
39
|
topoEditState = _store$useModel[0],
|
|
40
40
|
topoEditDispatchers = _store$useModel[1];
|
|
41
41
|
|
|
42
|
-
var _store$useModel2 = store.useModel(
|
|
42
|
+
var _store$useModel2 = store.useModel("topoConfig"),
|
|
43
43
|
editState = _store$useModel2[0],
|
|
44
44
|
editDispatchers = _store$useModel2[1];
|
|
45
45
|
|
|
46
|
-
var _store$useModel3 = store.useModel(
|
|
46
|
+
var _store$useModel3 = store.useModel("topoMod"),
|
|
47
47
|
topoState = _store$useModel3[0],
|
|
48
48
|
topoDispatchers = _store$useModel3[1];
|
|
49
49
|
|
|
@@ -90,7 +90,7 @@ var useTopoEdit = function useTopoEdit(params) {
|
|
|
90
90
|
|
|
91
91
|
|
|
92
92
|
var addResourceToView = function addResourceToView() {
|
|
93
|
-
rlog.debug(
|
|
93
|
+
rlog.debug("addResourceToView", resourceConfig.getViewResources());
|
|
94
94
|
setComboResData(resourceConfig.getViewResources());
|
|
95
95
|
setShowComboResDrawer(true);
|
|
96
96
|
};
|
|
@@ -100,7 +100,7 @@ var useTopoEdit = function useTopoEdit(params) {
|
|
|
100
100
|
direction = _ref2.direction;
|
|
101
101
|
// 从拓扑图获取分层和资源配置
|
|
102
102
|
var config = resourceConfig.getConfigFromHt(topo.getDataModel());
|
|
103
|
-
rlog.info(
|
|
103
|
+
rlog.info("onLayerAdd", {
|
|
104
104
|
config: config
|
|
105
105
|
}); // 如果非分层拓扑且有分层,切换到分层模板,设置方向
|
|
106
106
|
|
|
@@ -118,7 +118,7 @@ var useTopoEdit = function useTopoEdit(params) {
|
|
|
118
118
|
emitEvent(TopoEvent.EVENT_TRIGGER_DELETE, layerElement); // 获取资源配置
|
|
119
119
|
|
|
120
120
|
var config = resourceConfig.getConfigFromHt(topo.getDataModel());
|
|
121
|
-
rlog.info(
|
|
121
|
+
rlog.info("deleteLayer", {
|
|
122
122
|
config: config
|
|
123
123
|
}); // 如果没有分层,将拓扑类型切换为空白模板
|
|
124
124
|
|
|
@@ -142,13 +142,13 @@ var useTopoEdit = function useTopoEdit(params) {
|
|
|
142
142
|
|
|
143
143
|
|
|
144
144
|
_Dialog.confirm({
|
|
145
|
-
title:
|
|
146
|
-
content:
|
|
145
|
+
title: "删除",
|
|
146
|
+
content: "若执行相关操作,此分层包含的内容也会一同被删除,确定删除吗?",
|
|
147
147
|
okProps: {
|
|
148
|
-
children:
|
|
148
|
+
children: "确定"
|
|
149
149
|
},
|
|
150
150
|
messageProps: {
|
|
151
|
-
type:
|
|
151
|
+
type: "warning"
|
|
152
152
|
},
|
|
153
153
|
onOk: function () {
|
|
154
154
|
var _onOk = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee2() {
|
|
@@ -200,13 +200,13 @@ var useTopoEdit = function useTopoEdit(params) {
|
|
|
200
200
|
|
|
201
201
|
|
|
202
202
|
_Dialog.confirm({
|
|
203
|
-
title:
|
|
204
|
-
content:
|
|
203
|
+
title: "删除",
|
|
204
|
+
content: "若执行相关操作,此区域包含的内容也会一同被删除,确定删除吗?",
|
|
205
205
|
okProps: {
|
|
206
|
-
children:
|
|
206
|
+
children: "确定"
|
|
207
207
|
},
|
|
208
208
|
messageProps: {
|
|
209
|
-
type:
|
|
209
|
+
type: "warning"
|
|
210
210
|
},
|
|
211
211
|
onOk: function () {
|
|
212
212
|
var _onOk2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee3() {
|
|
@@ -281,7 +281,7 @@ var useTopoEdit = function useTopoEdit(params) {
|
|
|
281
281
|
|
|
282
282
|
return newGroup;
|
|
283
283
|
});
|
|
284
|
-
rlog.info(
|
|
284
|
+
rlog.info("删除容器内的单个资源", {
|
|
285
285
|
groups: groups,
|
|
286
286
|
node: node,
|
|
287
287
|
newGroups: newGroups
|
|
@@ -298,17 +298,62 @@ var useTopoEdit = function useTopoEdit(params) {
|
|
|
298
298
|
var nodeDeleteable = params.nodeDeleteable || ((_topo$options$editor = topo.options.editor) === null || _topo$options$editor === void 0 ? void 0 : _topo$options$editor.nodeDeleteable);
|
|
299
299
|
|
|
300
300
|
if (nodeDeleteable === undefined || nodeDeleteable(data)) {
|
|
301
|
-
if (typeof onNodeDelete ===
|
|
301
|
+
if (typeof onNodeDelete === "function") {
|
|
302
302
|
onNodeDelete(data);
|
|
303
303
|
} else {
|
|
304
304
|
deleteNode(data);
|
|
305
305
|
}
|
|
306
306
|
}
|
|
307
|
-
};
|
|
307
|
+
}; // 删除关联在节点上的出口链路
|
|
308
|
+
|
|
309
|
+
|
|
310
|
+
var deleteExLink = /*#__PURE__*/function () {
|
|
311
|
+
var _ref3 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee4(node) {
|
|
312
|
+
var _node$getEdges$toArra, _node$getEdges;
|
|
313
|
+
|
|
314
|
+
var config, edges, exportLinkIdList;
|
|
315
|
+
return _regeneratorRuntime.wrap(function _callee4$(_context4) {
|
|
316
|
+
while (1) {
|
|
317
|
+
switch (_context4.prev = _context4.next) {
|
|
318
|
+
case 0:
|
|
319
|
+
config = resourceConfig.getConfig(); // console.log("删除关联在节点上的出口链路- node, config", node, config);
|
|
320
|
+
|
|
321
|
+
edges = (_node$getEdges$toArra = (_node$getEdges = node.getEdges()) === null || _node$getEdges === void 0 ? void 0 : _node$getEdges.toArray()) !== null && _node$getEdges$toArra !== void 0 ? _node$getEdges$toArra : []; // const exLink = [];
|
|
322
|
+
|
|
323
|
+
if (!(edges.length > 0)) {
|
|
324
|
+
_context4.next = 9;
|
|
325
|
+
break;
|
|
326
|
+
}
|
|
327
|
+
|
|
328
|
+
exportLinkIdList = [].concat(config.exportLinkIdList);
|
|
329
|
+
console.log("删除关联在节点上的出口链路- edge", edges);
|
|
330
|
+
edges.map(function (edge) {
|
|
331
|
+
if (edge.a("connect_type") === "exit" && exportLinkIdList.indexOf(edge.getTag() >= 0)) {
|
|
332
|
+
// exLink.push(edge);
|
|
333
|
+
topo.getGraphView().dm().remove(edge);
|
|
334
|
+
exportLinkIdList.splice(config.exportLinkIdList.indexOf(edge.getTag()), 1);
|
|
335
|
+
}
|
|
336
|
+
});
|
|
337
|
+
config.exportLinkIdList = exportLinkIdList;
|
|
338
|
+
_context4.next = 9;
|
|
339
|
+
return resourceConfig.updateConfig(config);
|
|
340
|
+
|
|
341
|
+
case 9:
|
|
342
|
+
case "end":
|
|
343
|
+
return _context4.stop();
|
|
344
|
+
}
|
|
345
|
+
}
|
|
346
|
+
}, _callee4);
|
|
347
|
+
}));
|
|
348
|
+
|
|
349
|
+
return function deleteExLink(_x) {
|
|
350
|
+
return _ref3.apply(this, arguments);
|
|
351
|
+
};
|
|
352
|
+
}();
|
|
308
353
|
|
|
309
354
|
var onDeleteElement = function onDeleteElement(data) {
|
|
310
355
|
var dtype = data.dtype;
|
|
311
|
-
rlog.info(
|
|
356
|
+
rlog.info("onDeleteElement", data);
|
|
312
357
|
|
|
313
358
|
if (isLayer(data)) {
|
|
314
359
|
handleDeleteLayer(data);
|
|
@@ -332,18 +377,18 @@ var useTopoEdit = function useTopoEdit(params) {
|
|
|
332
377
|
}
|
|
333
378
|
|
|
334
379
|
switch (dtype) {
|
|
335
|
-
case
|
|
380
|
+
case "link":
|
|
336
381
|
if (onLineDelete) {
|
|
337
382
|
onLineDelete(data);
|
|
338
383
|
}
|
|
339
384
|
|
|
340
385
|
break;
|
|
341
386
|
|
|
342
|
-
case
|
|
387
|
+
case "device":
|
|
343
388
|
handleDeleteNode(data);
|
|
344
389
|
break;
|
|
345
390
|
|
|
346
|
-
case
|
|
391
|
+
case "container":
|
|
347
392
|
deleteGroup(data);
|
|
348
393
|
break;
|
|
349
394
|
|
|
@@ -357,39 +402,39 @@ var useTopoEdit = function useTopoEdit(params) {
|
|
|
357
402
|
*/
|
|
358
403
|
|
|
359
404
|
|
|
360
|
-
function bindGroupResources(
|
|
405
|
+
function bindGroupResources(_x2, _x3) {
|
|
361
406
|
return _bindGroupResources.apply(this, arguments);
|
|
362
407
|
}
|
|
363
408
|
|
|
364
409
|
function _bindGroupResources() {
|
|
365
|
-
_bindGroupResources = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
410
|
+
_bindGroupResources = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee9(group, resources) {
|
|
366
411
|
var id, tag, _yield$editDispatcher2, elements, nodeElements, existedLinkIds, newLinkElements, updateElements;
|
|
367
412
|
|
|
368
|
-
return _regeneratorRuntime.wrap(function
|
|
413
|
+
return _regeneratorRuntime.wrap(function _callee9$(_context9) {
|
|
369
414
|
while (1) {
|
|
370
|
-
switch (
|
|
415
|
+
switch (_context9.prev = _context9.next) {
|
|
371
416
|
case 0:
|
|
372
417
|
id = group.id, tag = group.tag;
|
|
373
|
-
rlog.debug(
|
|
374
|
-
|
|
418
|
+
rlog.debug("bindGroupResources--id, tag", id, tag);
|
|
419
|
+
_context9.next = 4;
|
|
375
420
|
return resourceConfig.updateGroupResources(group, resources);
|
|
376
421
|
|
|
377
422
|
case 4:
|
|
378
|
-
|
|
423
|
+
_context9.next = 6;
|
|
379
424
|
return editDispatchers.fetchDataByConfig();
|
|
380
425
|
|
|
381
426
|
case 6:
|
|
382
|
-
_yield$editDispatcher2 =
|
|
427
|
+
_yield$editDispatcher2 = _context9.sent;
|
|
383
428
|
elements = _yield$editDispatcher2.elements;
|
|
384
429
|
nodeElements = elements.filter(function (element) {
|
|
385
430
|
var type = element.type,
|
|
386
431
|
groupId = element.groupId,
|
|
387
432
|
groupTag = element.groupTag;
|
|
388
|
-
return type ===
|
|
433
|
+
return type === "node" && (groupId === id || groupTag === tag);
|
|
389
434
|
});
|
|
390
435
|
existedLinkIds = resourceConfig.getAllEdgeResourceIds();
|
|
391
436
|
newLinkElements = elements.filter(function (element) {
|
|
392
|
-
return (element.type ===
|
|
437
|
+
return (element.type === "link" || element.type === "linkGroup") && existedLinkIds.indexOf(element.id) === -1;
|
|
393
438
|
});
|
|
394
439
|
updateElements = [].concat(nodeElements, newLinkElements);
|
|
395
440
|
|
|
@@ -403,15 +448,15 @@ var useTopoEdit = function useTopoEdit(params) {
|
|
|
403
448
|
|
|
404
449
|
case 13:
|
|
405
450
|
case "end":
|
|
406
|
-
return
|
|
451
|
+
return _context9.stop();
|
|
407
452
|
}
|
|
408
453
|
}
|
|
409
|
-
},
|
|
454
|
+
}, _callee9);
|
|
410
455
|
}));
|
|
411
456
|
return _bindGroupResources.apply(this, arguments);
|
|
412
457
|
}
|
|
413
458
|
|
|
414
|
-
function addGroupResources(
|
|
459
|
+
function addGroupResources(_x4, _x5) {
|
|
415
460
|
return _addGroupResources.apply(this, arguments);
|
|
416
461
|
}
|
|
417
462
|
/**
|
|
@@ -420,11 +465,11 @@ var useTopoEdit = function useTopoEdit(params) {
|
|
|
420
465
|
|
|
421
466
|
|
|
422
467
|
function _addGroupResources() {
|
|
423
|
-
_addGroupResources = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
468
|
+
_addGroupResources = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee10(group, newResourceIds) {
|
|
424
469
|
var groupConfig, resources, groupData;
|
|
425
|
-
return _regeneratorRuntime.wrap(function
|
|
470
|
+
return _regeneratorRuntime.wrap(function _callee10$(_context10) {
|
|
426
471
|
while (1) {
|
|
427
|
-
switch (
|
|
472
|
+
switch (_context10.prev = _context10.next) {
|
|
428
473
|
case 0:
|
|
429
474
|
groupConfig = resourceConfig.getGroupConfigByElement(group);
|
|
430
475
|
resources = {
|
|
@@ -432,22 +477,22 @@ var useTopoEdit = function useTopoEdit(params) {
|
|
|
432
477
|
};
|
|
433
478
|
groupData = {
|
|
434
479
|
id: group.getTag(),
|
|
435
|
-
tag: group.a(
|
|
480
|
+
tag: group.a("tag")
|
|
436
481
|
};
|
|
437
|
-
|
|
482
|
+
_context10.next = 5;
|
|
438
483
|
return bindGroupResources(groupData, resources, newResourceIds);
|
|
439
484
|
|
|
440
485
|
case 5:
|
|
441
486
|
case "end":
|
|
442
|
-
return
|
|
487
|
+
return _context10.stop();
|
|
443
488
|
}
|
|
444
489
|
}
|
|
445
|
-
},
|
|
490
|
+
}, _callee10);
|
|
446
491
|
}));
|
|
447
492
|
return _addGroupResources.apply(this, arguments);
|
|
448
493
|
}
|
|
449
494
|
|
|
450
|
-
function bindViewResources(
|
|
495
|
+
function bindViewResources(_x6) {
|
|
451
496
|
return _bindViewResources.apply(this, arguments);
|
|
452
497
|
}
|
|
453
498
|
/**
|
|
@@ -459,24 +504,25 @@ var useTopoEdit = function useTopoEdit(params) {
|
|
|
459
504
|
|
|
460
505
|
|
|
461
506
|
function _bindViewResources() {
|
|
462
|
-
_bindViewResources = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
507
|
+
_bindViewResources = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee11(data) {
|
|
463
508
|
var config, _yield$editDispatcher3, elements;
|
|
464
509
|
|
|
465
|
-
return _regeneratorRuntime.wrap(function
|
|
510
|
+
return _regeneratorRuntime.wrap(function _callee11$(_context11) {
|
|
466
511
|
while (1) {
|
|
467
|
-
switch (
|
|
512
|
+
switch (_context11.prev = _context11.next) {
|
|
468
513
|
case 0:
|
|
514
|
+
console.log("关联视图的资源", data);
|
|
469
515
|
config = resourceConfig.getConfig();
|
|
470
516
|
config.resources = data;
|
|
471
|
-
|
|
517
|
+
_context11.next = 5;
|
|
472
518
|
return resourceConfig.updateConfig(config);
|
|
473
519
|
|
|
474
|
-
case
|
|
475
|
-
|
|
520
|
+
case 5:
|
|
521
|
+
_context11.next = 7;
|
|
476
522
|
return editDispatchers.fetchDataByConfig();
|
|
477
523
|
|
|
478
|
-
case
|
|
479
|
-
_yield$editDispatcher3 =
|
|
524
|
+
case 7:
|
|
525
|
+
_yield$editDispatcher3 = _context11.sent;
|
|
480
526
|
elements = _yield$editDispatcher3.topoDataTrans;
|
|
481
527
|
saveBind(TopoEvent.DATA_TYPE_RESOURCE_COMBO, elements); // 临时放这里,仅拓扑中心有
|
|
482
528
|
|
|
@@ -484,37 +530,37 @@ var useTopoEdit = function useTopoEdit(params) {
|
|
|
484
530
|
topo.linkDynamicStyleExecutor.execute();
|
|
485
531
|
}
|
|
486
532
|
|
|
487
|
-
case
|
|
533
|
+
case 11:
|
|
488
534
|
case "end":
|
|
489
|
-
return
|
|
535
|
+
return _context11.stop();
|
|
490
536
|
}
|
|
491
537
|
}
|
|
492
|
-
},
|
|
538
|
+
}, _callee11);
|
|
493
539
|
}));
|
|
494
540
|
return _bindViewResources.apply(this, arguments);
|
|
495
541
|
}
|
|
496
542
|
|
|
497
|
-
function addLayerResources(
|
|
543
|
+
function addLayerResources(_x7, _x8) {
|
|
498
544
|
return _addLayerResources.apply(this, arguments);
|
|
499
545
|
}
|
|
500
546
|
|
|
501
547
|
function _addLayerResources() {
|
|
502
|
-
_addLayerResources = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
548
|
+
_addLayerResources = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee12(group, newResourceIds) {
|
|
503
549
|
var _yield$editDispatcher4, topoData, data;
|
|
504
550
|
|
|
505
|
-
return _regeneratorRuntime.wrap(function
|
|
551
|
+
return _regeneratorRuntime.wrap(function _callee12$(_context12) {
|
|
506
552
|
while (1) {
|
|
507
|
-
switch (
|
|
553
|
+
switch (_context12.prev = _context12.next) {
|
|
508
554
|
case 0:
|
|
509
|
-
|
|
555
|
+
_context12.next = 2;
|
|
510
556
|
return resourceConfig.addLayerStaticResources(group, newResourceIds);
|
|
511
557
|
|
|
512
558
|
case 2:
|
|
513
|
-
|
|
559
|
+
_context12.next = 4;
|
|
514
560
|
return editDispatchers.fetchDataByConfig();
|
|
515
561
|
|
|
516
562
|
case 4:
|
|
517
|
-
_yield$editDispatcher4 =
|
|
563
|
+
_yield$editDispatcher4 = _context12.sent;
|
|
518
564
|
topoData = _yield$editDispatcher4.topoData;
|
|
519
565
|
// 过滤出新增的资源和链路
|
|
520
566
|
data = {
|
|
@@ -526,7 +572,7 @@ var useTopoEdit = function useTopoEdit(params) {
|
|
|
526
572
|
})
|
|
527
573
|
}; // 添加到分层
|
|
528
574
|
|
|
529
|
-
|
|
575
|
+
_context12.next = 9;
|
|
530
576
|
return topo.addElements(data);
|
|
531
577
|
|
|
532
578
|
case 9:
|
|
@@ -537,35 +583,35 @@ var useTopoEdit = function useTopoEdit(params) {
|
|
|
537
583
|
|
|
538
584
|
case 10:
|
|
539
585
|
case "end":
|
|
540
|
-
return
|
|
586
|
+
return _context12.stop();
|
|
541
587
|
}
|
|
542
588
|
}
|
|
543
|
-
},
|
|
589
|
+
}, _callee12);
|
|
544
590
|
}));
|
|
545
591
|
return _addLayerResources.apply(this, arguments);
|
|
546
592
|
}
|
|
547
593
|
|
|
548
|
-
function addResourceToFirstLayer(
|
|
594
|
+
function addResourceToFirstLayer(_x9) {
|
|
549
595
|
return _addResourceToFirstLayer.apply(this, arguments);
|
|
550
596
|
}
|
|
551
597
|
|
|
552
598
|
function _addResourceToFirstLayer() {
|
|
553
|
-
_addResourceToFirstLayer = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
599
|
+
_addResourceToFirstLayer = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee13(data) {
|
|
554
600
|
var group;
|
|
555
|
-
return _regeneratorRuntime.wrap(function
|
|
601
|
+
return _regeneratorRuntime.wrap(function _callee13$(_context13) {
|
|
556
602
|
while (1) {
|
|
557
|
-
switch (
|
|
603
|
+
switch (_context13.prev = _context13.next) {
|
|
558
604
|
case 0:
|
|
559
605
|
group = resourceConfig.getGroups()[0];
|
|
560
|
-
|
|
606
|
+
_context13.next = 3;
|
|
561
607
|
return addLayerResources(group, data);
|
|
562
608
|
|
|
563
609
|
case 3:
|
|
564
610
|
case "end":
|
|
565
|
-
return
|
|
611
|
+
return _context13.stop();
|
|
566
612
|
}
|
|
567
613
|
}
|
|
568
|
-
},
|
|
614
|
+
}, _callee13);
|
|
569
615
|
}));
|
|
570
616
|
return _addResourceToFirstLayer.apply(this, arguments);
|
|
571
617
|
}
|
|
@@ -574,7 +620,7 @@ var useTopoEdit = function useTopoEdit(params) {
|
|
|
574
620
|
var type;
|
|
575
621
|
|
|
576
622
|
if (isLayerTopo) {
|
|
577
|
-
type =
|
|
623
|
+
type = "addToFirstLayer";
|
|
578
624
|
}
|
|
579
625
|
|
|
580
626
|
return type;
|
|
@@ -587,119 +633,119 @@ var useTopoEdit = function useTopoEdit(params) {
|
|
|
587
633
|
|
|
588
634
|
|
|
589
635
|
function getAddResourceDrawerMode() {
|
|
590
|
-
return getAddResourceType() ===
|
|
636
|
+
return getAddResourceType() === "addToFirstLayer" ? "new" : "all";
|
|
591
637
|
}
|
|
592
638
|
|
|
593
639
|
var onSaveComboRes = /*#__PURE__*/function () {
|
|
594
|
-
var
|
|
595
|
-
return _regeneratorRuntime.wrap(function
|
|
640
|
+
var _ref4 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee5(data) {
|
|
641
|
+
return _regeneratorRuntime.wrap(function _callee5$(_context5) {
|
|
596
642
|
while (1) {
|
|
597
|
-
switch (
|
|
643
|
+
switch (_context5.prev = _context5.next) {
|
|
598
644
|
case 0:
|
|
599
|
-
rlog.debug(
|
|
645
|
+
rlog.debug("关联资源-----onSaveComboRes", data);
|
|
600
646
|
|
|
601
|
-
if (!(getAddResourceType() ===
|
|
602
|
-
|
|
647
|
+
if (!(getAddResourceType() === "addToFirstLayer")) {
|
|
648
|
+
_context5.next = 6;
|
|
603
649
|
break;
|
|
604
650
|
}
|
|
605
651
|
|
|
606
|
-
|
|
652
|
+
_context5.next = 4;
|
|
607
653
|
return addResourceToFirstLayer(data);
|
|
608
654
|
|
|
609
655
|
case 4:
|
|
610
|
-
|
|
656
|
+
_context5.next = 8;
|
|
611
657
|
break;
|
|
612
658
|
|
|
613
659
|
case 6:
|
|
614
|
-
|
|
660
|
+
_context5.next = 8;
|
|
615
661
|
return bindViewResources(data);
|
|
616
662
|
|
|
617
663
|
case 8:
|
|
618
664
|
case "end":
|
|
619
|
-
return
|
|
665
|
+
return _context5.stop();
|
|
620
666
|
}
|
|
621
667
|
}
|
|
622
|
-
},
|
|
668
|
+
}, _callee5);
|
|
623
669
|
}));
|
|
624
670
|
|
|
625
|
-
return function onSaveComboRes(
|
|
626
|
-
return
|
|
671
|
+
return function onSaveComboRes(_x10) {
|
|
672
|
+
return _ref4.apply(this, arguments);
|
|
627
673
|
};
|
|
628
674
|
}();
|
|
629
675
|
|
|
630
|
-
function checkSavePermission(
|
|
676
|
+
function checkSavePermission(_x11) {
|
|
631
677
|
return _checkSavePermission.apply(this, arguments);
|
|
632
678
|
}
|
|
633
679
|
|
|
634
680
|
function _checkSavePermission() {
|
|
635
|
-
_checkSavePermission = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
681
|
+
_checkSavePermission = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee14(id) {
|
|
636
682
|
var permission;
|
|
637
|
-
return _regeneratorRuntime.wrap(function
|
|
683
|
+
return _regeneratorRuntime.wrap(function _callee14$(_context14) {
|
|
638
684
|
while (1) {
|
|
639
|
-
switch (
|
|
685
|
+
switch (_context14.prev = _context14.next) {
|
|
640
686
|
case 0:
|
|
641
|
-
|
|
687
|
+
_context14.next = 2;
|
|
642
688
|
return topoDispatchers.getTopoPermission({
|
|
643
689
|
id: id,
|
|
644
690
|
update: false
|
|
645
691
|
});
|
|
646
692
|
|
|
647
693
|
case 2:
|
|
648
|
-
permission =
|
|
694
|
+
permission = _context14.sent;
|
|
649
695
|
|
|
650
696
|
if (!topoPermissonUtil.isEditable(permission)) {
|
|
651
|
-
|
|
697
|
+
_context14.next = 5;
|
|
652
698
|
break;
|
|
653
699
|
}
|
|
654
700
|
|
|
655
|
-
return
|
|
701
|
+
return _context14.abrupt("return", true);
|
|
656
702
|
|
|
657
703
|
case 5:
|
|
658
704
|
_Dialog.alert({
|
|
659
|
-
title:
|
|
660
|
-
content:
|
|
705
|
+
title: "没有权限进行此操作",
|
|
706
|
+
content: "您的权限发生了变化,请联系相关管理员。",
|
|
661
707
|
okProps: {
|
|
662
|
-
children:
|
|
708
|
+
children: "确定"
|
|
663
709
|
},
|
|
664
710
|
onOk: function onOk() {}
|
|
665
711
|
});
|
|
666
712
|
|
|
667
|
-
return
|
|
713
|
+
return _context14.abrupt("return", false);
|
|
668
714
|
|
|
669
715
|
case 7:
|
|
670
716
|
case "end":
|
|
671
|
-
return
|
|
717
|
+
return _context14.stop();
|
|
672
718
|
}
|
|
673
719
|
}
|
|
674
|
-
},
|
|
720
|
+
}, _callee14);
|
|
675
721
|
}));
|
|
676
722
|
return _checkSavePermission.apply(this, arguments);
|
|
677
723
|
}
|
|
678
724
|
|
|
679
725
|
var onSaveTopo = /*#__PURE__*/function () {
|
|
680
|
-
var
|
|
726
|
+
var _ref5 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee7(data) {
|
|
681
727
|
var id, config, serialize, _config$layout, template, layout, saveConfig, valid, saveData;
|
|
682
728
|
|
|
683
|
-
return _regeneratorRuntime.wrap(function
|
|
729
|
+
return _regeneratorRuntime.wrap(function _callee7$(_context7) {
|
|
684
730
|
while (1) {
|
|
685
|
-
switch (
|
|
731
|
+
switch (_context7.prev = _context7.next) {
|
|
686
732
|
case 0:
|
|
687
733
|
id = data.id, config = data.config, serialize = data.serialize;
|
|
688
734
|
_config$layout = config === null || config === void 0 ? void 0 : config.layout, template = _config$layout.type, layout = _config$layout.layout;
|
|
689
735
|
|
|
690
736
|
if (!onSave) {
|
|
691
|
-
|
|
737
|
+
_context7.next = 6;
|
|
692
738
|
break;
|
|
693
739
|
}
|
|
694
740
|
|
|
695
741
|
// 自定义保存
|
|
696
742
|
saveConfig = /*#__PURE__*/function () {
|
|
697
|
-
var
|
|
698
|
-
return _regeneratorRuntime.wrap(function
|
|
743
|
+
var _ref6 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee6() {
|
|
744
|
+
return _regeneratorRuntime.wrap(function _callee6$(_context6) {
|
|
699
745
|
while (1) {
|
|
700
|
-
switch (
|
|
746
|
+
switch (_context6.prev = _context6.next) {
|
|
701
747
|
case 0:
|
|
702
|
-
|
|
748
|
+
_context6.next = 2;
|
|
703
749
|
return editDispatchers.saveTopo({
|
|
704
750
|
id: id,
|
|
705
751
|
layout: layout,
|
|
@@ -708,14 +754,14 @@ var useTopoEdit = function useTopoEdit(params) {
|
|
|
708
754
|
|
|
709
755
|
case 2:
|
|
710
756
|
case "end":
|
|
711
|
-
return
|
|
757
|
+
return _context6.stop();
|
|
712
758
|
}
|
|
713
759
|
}
|
|
714
|
-
},
|
|
760
|
+
}, _callee6);
|
|
715
761
|
}));
|
|
716
762
|
|
|
717
763
|
return function saveConfig() {
|
|
718
|
-
return
|
|
764
|
+
return _ref6.apply(this, arguments);
|
|
719
765
|
};
|
|
720
766
|
}();
|
|
721
767
|
|
|
@@ -723,7 +769,7 @@ var useTopoEdit = function useTopoEdit(params) {
|
|
|
723
769
|
data: data,
|
|
724
770
|
saveConfig: saveConfig
|
|
725
771
|
});
|
|
726
|
-
return
|
|
772
|
+
return _context7.abrupt("return");
|
|
727
773
|
|
|
728
774
|
case 6:
|
|
729
775
|
// TODO 以下逻辑移到拓扑中心
|
|
@@ -731,21 +777,21 @@ var useTopoEdit = function useTopoEdit(params) {
|
|
|
731
777
|
saving: true
|
|
732
778
|
}); // 检查权限
|
|
733
779
|
|
|
734
|
-
|
|
780
|
+
_context7.next = 9;
|
|
735
781
|
return checkSavePermission(id);
|
|
736
782
|
|
|
737
783
|
case 9:
|
|
738
|
-
valid =
|
|
784
|
+
valid = _context7.sent;
|
|
739
785
|
|
|
740
786
|
if (valid) {
|
|
741
|
-
|
|
787
|
+
_context7.next = 13;
|
|
742
788
|
break;
|
|
743
789
|
}
|
|
744
790
|
|
|
745
791
|
topoEditDispatchers.update({
|
|
746
792
|
saving: false
|
|
747
793
|
});
|
|
748
|
-
return
|
|
794
|
+
return _context7.abrupt("return");
|
|
749
795
|
|
|
750
796
|
case 13:
|
|
751
797
|
// 保存
|
|
@@ -754,8 +800,8 @@ var useTopoEdit = function useTopoEdit(params) {
|
|
|
754
800
|
layout: layout,
|
|
755
801
|
serialize: serialize
|
|
756
802
|
}, resourceConfig.getConfig());
|
|
757
|
-
rlog.info(
|
|
758
|
-
|
|
803
|
+
rlog.info("保存", saveData);
|
|
804
|
+
_context7.next = 17;
|
|
759
805
|
return editDispatchers.saveTopo(saveData);
|
|
760
806
|
|
|
761
807
|
case 17:
|
|
@@ -763,18 +809,18 @@ var useTopoEdit = function useTopoEdit(params) {
|
|
|
763
809
|
saving: false
|
|
764
810
|
});
|
|
765
811
|
|
|
766
|
-
_Message.success(
|
|
812
|
+
_Message.success("保存成功!");
|
|
767
813
|
|
|
768
814
|
case 19:
|
|
769
815
|
case "end":
|
|
770
|
-
return
|
|
816
|
+
return _context7.stop();
|
|
771
817
|
}
|
|
772
818
|
}
|
|
773
|
-
},
|
|
819
|
+
}, _callee7);
|
|
774
820
|
}));
|
|
775
821
|
|
|
776
|
-
return function onSaveTopo(
|
|
777
|
-
return
|
|
822
|
+
return function onSaveTopo(_x12) {
|
|
823
|
+
return _ref5.apply(this, arguments);
|
|
778
824
|
};
|
|
779
825
|
}();
|
|
780
826
|
|
|
@@ -783,7 +829,7 @@ var useTopoEdit = function useTopoEdit(params) {
|
|
|
783
829
|
type: type,
|
|
784
830
|
data: data
|
|
785
831
|
};
|
|
786
|
-
rlog.debug(
|
|
832
|
+
rlog.debug("TopoCenter:onSaveBind", eventData);
|
|
787
833
|
emitEvent(TopoEvent.EVENT_DATA_RESULT, eventData);
|
|
788
834
|
};
|
|
789
835
|
/**
|
|
@@ -808,12 +854,12 @@ var useTopoEdit = function useTopoEdit(params) {
|
|
|
808
854
|
|
|
809
855
|
|
|
810
856
|
var bindNodeResource = /*#__PURE__*/function () {
|
|
811
|
-
var
|
|
857
|
+
var _ref7 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee8(params) {
|
|
812
858
|
var id, oldResId, newResId, node, groupElement, config, groupId, groupTag, _yield$editDispatcher, elements, nodeRelatedDatas, replaceOrAddRes;
|
|
813
859
|
|
|
814
|
-
return _regeneratorRuntime.wrap(function
|
|
860
|
+
return _regeneratorRuntime.wrap(function _callee8$(_context8) {
|
|
815
861
|
while (1) {
|
|
816
|
-
switch (
|
|
862
|
+
switch (_context8.prev = _context8.next) {
|
|
817
863
|
case 0:
|
|
818
864
|
replaceOrAddRes = function _replaceOrAddRes(resources, oldResId, newResId) {
|
|
819
865
|
return _extends({}, resources, {
|
|
@@ -824,7 +870,7 @@ var useTopoEdit = function useTopoEdit(params) {
|
|
|
824
870
|
};
|
|
825
871
|
|
|
826
872
|
id = params.id, oldResId = params.oldResId, newResId = params.newResId;
|
|
827
|
-
rlog.debug(
|
|
873
|
+
rlog.debug("bindNodeResource", params);
|
|
828
874
|
node = topo.getDataModel().getDataById(id); // 节点所属容器
|
|
829
875
|
|
|
830
876
|
groupElement = node.getParent();
|
|
@@ -834,7 +880,7 @@ var useTopoEdit = function useTopoEdit(params) {
|
|
|
834
880
|
// 在容器中
|
|
835
881
|
groupId = groupElement.getTag(); // 容器业务id
|
|
836
882
|
|
|
837
|
-
groupTag = groupElement.a(
|
|
883
|
+
groupTag = groupElement.a("tag"); // 容器临时id
|
|
838
884
|
|
|
839
885
|
config.groups = config.groups.map(function (g) {
|
|
840
886
|
// 匹配到容器,替换资源或增加
|
|
@@ -852,46 +898,51 @@ var useTopoEdit = function useTopoEdit(params) {
|
|
|
852
898
|
config.resources = replaceOrAddRes(config.resources, oldResId, newResId);
|
|
853
899
|
}
|
|
854
900
|
|
|
855
|
-
|
|
901
|
+
_context8.next = 9;
|
|
856
902
|
return resourceConfig.updateConfig(config);
|
|
857
903
|
|
|
858
904
|
case 9:
|
|
859
|
-
|
|
905
|
+
_context8.next = 11;
|
|
860
906
|
return editDispatchers.fetchDataByConfig();
|
|
861
907
|
|
|
862
908
|
case 11:
|
|
863
|
-
_yield$editDispatcher =
|
|
909
|
+
_yield$editDispatcher = _context8.sent;
|
|
864
910
|
elements = _yield$editDispatcher.topoDataTrans;
|
|
865
911
|
// 过滤出关联的节点和连线,通知ht更新
|
|
866
912
|
nodeRelatedDatas = filterElementsByNodeId(elements, newResId);
|
|
867
913
|
|
|
868
914
|
if (nodeRelatedDatas.length) {
|
|
869
|
-
|
|
915
|
+
_context8.next = 17;
|
|
870
916
|
break;
|
|
871
917
|
}
|
|
872
918
|
|
|
873
|
-
_Message.error(
|
|
919
|
+
_Message.error("关联资源失败");
|
|
874
920
|
|
|
875
|
-
return
|
|
921
|
+
return _context8.abrupt("return", false);
|
|
876
922
|
|
|
877
923
|
case 17:
|
|
878
924
|
saveBind(TopoEvent.DATA_TYPE_RESOURCE_SINGLE, nodeRelatedDatas);
|
|
879
|
-
node.a(
|
|
925
|
+
node.a("customName", null); // 删除关联在节点上的出口链路
|
|
880
926
|
|
|
927
|
+
_context8.next = 21;
|
|
928
|
+
return deleteExLink(node);
|
|
929
|
+
|
|
930
|
+
case 21:
|
|
931
|
+
// 临时放这里,仅拓扑中心有
|
|
881
932
|
if (topo.linkDynamicStyleExecutor) {
|
|
882
933
|
topo.linkDynamicStyleExecutor.execute();
|
|
883
934
|
}
|
|
884
935
|
|
|
885
|
-
case
|
|
936
|
+
case 22:
|
|
886
937
|
case "end":
|
|
887
|
-
return
|
|
938
|
+
return _context8.stop();
|
|
888
939
|
}
|
|
889
940
|
}
|
|
890
|
-
},
|
|
941
|
+
}, _callee8);
|
|
891
942
|
}));
|
|
892
943
|
|
|
893
|
-
return function bindNodeResource(
|
|
894
|
-
return
|
|
944
|
+
return function bindNodeResource(_x13) {
|
|
945
|
+
return _ref7.apply(this, arguments);
|
|
895
946
|
};
|
|
896
947
|
}();
|
|
897
948
|
/**
|
|
@@ -912,7 +963,7 @@ var useTopoEdit = function useTopoEdit(params) {
|
|
|
912
963
|
}
|
|
913
964
|
};
|
|
914
965
|
|
|
915
|
-
var effectsState = store.useModelEffectsState(
|
|
966
|
+
var effectsState = store.useModelEffectsState("topoConfig");
|
|
916
967
|
var topoLoading = effectsState.getTopoByConditions.isLoading;
|
|
917
968
|
return {
|
|
918
969
|
resourceConfig: resourceConfig,
|
|
@@ -986,6 +1037,11 @@ var useTopoEdit = function useTopoEdit(params) {
|
|
|
986
1037
|
*/
|
|
987
1038
|
bindNodeResource: bindNodeResource,
|
|
988
1039
|
|
|
1040
|
+
/**
|
|
1041
|
+
* 删除节点关联的出口链路
|
|
1042
|
+
*/
|
|
1043
|
+
deleteExLink: deleteExLink,
|
|
1044
|
+
|
|
989
1045
|
/**
|
|
990
1046
|
* 关闭资源绑定(单选)抽屉
|
|
991
1047
|
*/
|