@riil-frontend/component-topology 11.0.34 → 12.0.0-dev.1
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 +2 -2
- package/build/2.js +1 -1
- package/build/index.css +4 -2
- package/build/index.js +57 -34
- package/es/components/BatchAttrMetric/setting.js +1 -1
- package/es/components/MultiResourceDrawer/index.js +16 -18
- package/es/components/ResourceList/ResourceSelect.js +48 -50
- package/es/components/ResourceSelectDrawer/ResourceSelectDrawer.js +24 -26
- package/es/components/SingleResourceDrawer/SelectDrawer.js +18 -20
- package/es/core/components/DisplaySettingDrawer/DisplaySettingDrawer.js +23 -25
- package/es/core/components/DisplaySettingDrawer/hooks/useDisplaySetting.js +78 -84
- package/es/core/components/titlebar/widgets/TitleWidget.js +5 -3
- package/es/core/editor/components/BackgroundView/UploadDialog/index.js +17 -18
- package/es/core/editor/components/BackgroundView/index.js +119 -129
- package/es/core/editor/components/CustomIconPlugin/RenameDialog.js +20 -22
- package/es/core/editor/components/CustomIconPlugin/UploadIconDialog.js +33 -34
- package/es/core/editor/components/CustomIconPlugin/utils/svgToShape.js +15 -17
- package/es/core/editor/components/GroupAddResourceDrawerPlugin/GroupAddResourceDrawer.js +7 -9
- package/es/core/editor/components/Sidebar/views/CanvasPanel/hooks/useCanvasThemeConfig.js +37 -41
- package/es/core/editor/components/Toolbar/widgets/BoxBackgroundButton/BoxBackgroundSetting.js +50 -54
- package/es/core/editor/components/Toolbar/widgets/FontColorButton.js +50 -54
- package/es/core/editor/components/settings/propertyViews/layer/DataTab/DefaultLayerAddResourceDrawer.js +11 -13
- package/es/core/editor/components/settings/propertyViews/node/data/BindResourceDrawer.js +21 -23
- package/es/core/editor/components/settings/propertyViews/node/data/Data.js +15 -17
- package/es/core/editor/components/settings/propertyViews/view/BackgroundSize.js +10 -12
- package/es/core/editor/components/titlebar/TopoEditorTitleBar.js +21 -27
- package/es/core/editor/hooks/useKeyboardShortcut.js +36 -32
- package/es/core/editor/hooks/useNewElementTheme.js +2 -2
- package/es/core/editor/store/background.js +8 -10
- package/es/core/editor/store/topoEdit.js +4 -6
- package/es/core/editor/utils/copyElementUtil.js +171 -0
- package/es/core/editor/utils/edgeTypeStyleUtil.js +2 -4
- package/es/core/hooks/usePolling.js +117 -121
- package/es/core/hooks/useResourceConfig.js +58 -66
- package/es/core/hooks/useTopoEdit.js +473 -503
- package/es/core/models/Alarm.js +281 -298
- package/es/core/models/AttributeMetricDisplay.js +101 -107
- package/es/core/models/PluginManager.js +4 -3
- package/es/core/models/SelectionModel.js +4 -5
- package/es/core/models/TopoApp.js +205 -240
- package/es/core/models/TopoGraphView.js +18 -21
- package/es/core/models/cache/CiCache.js +28 -27
- package/es/core/models/cache/CiTypeCache.js +37 -41
- package/es/core/models/cache/DictCache.js +33 -35
- package/es/core/models/graph/Background.js +15 -17
- package/es/core/models/plugins/resourceWebControllUrl.js +76 -82
- package/es/core/models/tagstips/ElementTagTipConfig.js +34 -38
- package/es/core/models/topoData.js +68 -70
- package/es/core/models/utils/linkUtils.js +41 -43
- package/es/core/models/utils/nodeNameVisibleUtil.js +4 -4
- package/es/core/services/alarm.js +14 -16
- package/es/core/services/background.js +59 -67
- package/es/core/services/cmdb/metric.js +9 -11
- package/es/core/services/cmdb.js +20 -20
- package/es/core/services/index.js +39 -45
- package/es/core/services/overview.js +131 -151
- package/es/core/services/topo/basic.js +37 -41
- package/es/core/services/topo/tagtip.js +10 -12
- package/es/core/store/models/ciModel.js +58 -62
- package/es/core/store/models/customIcon.js +120 -134
- package/es/core/store/models/displayConfig.js +15 -19
- package/es/core/store/models/selection.js +4 -6
- package/es/core/store/models/topoAlarm.js +162 -145
- package/es/core/store/models/topoBaseInfoOverview.js +4 -6
- package/es/core/store/models/topoBizMod.js +9 -11
- package/es/core/store/models/topoConfig.js +215 -231
- package/es/core/store/models/topoGraphView.js +4 -6
- package/es/core/store/models/topoMod.js +373 -395
- package/es/core/utils/imageUtil.js +18 -20
- package/es/core/utils/metricUtil.js +5 -0
- package/es/core/utils/saveSerialize.js +9 -11
- package/es/core/viewer/components/plugins/ResourceDetail/components/ClusterMemberTable.js +56 -58
- package/es/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/EventsCard.js +15 -17
- package/es/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/ResourceOverview.js +343 -357
- package/es/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/components/Configurator/index.js +86 -92
- package/es/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/components/LinkTopo/LinkTopoCard.js +39 -41
- package/es/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/components/LinkTopo/services/index.js +189 -205
- package/es/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/hooks/useAlarmAndRiskData.js +107 -109
- package/es/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/hooks/useMetricModels.js +57 -59
- package/es/core/viewer/components/plugins/ResourceDetail/components/WebConsole/WebConsoleForm/hooks/useWebConsole.js +33 -37
- package/es/core/viewer/components/plugins/ResourceDetail/getCiDisplayMetricModels.js +25 -29
- package/es/core/viewer/components/plugins/ResourceDetail/hooks/useUserId.js +32 -36
- package/es/core/viewer/components/plugins/ResourceWebControllUrlSettingDialog.js +17 -19
- package/es/networkTopo/components/Link/hook.js +73 -77
- package/es/networkTopo/components/Link/index.js +86 -94
- package/es/networkTopo/components/Link/setting.js +42 -44
- package/es/networkTopo/getTopoData.js +63 -69
- package/es/networkTopo/hooks/viewer/useRelateTopo.js +30 -32
- package/es/networkTopo/models/LinkDynamicStyleExecutor.js +2 -2
- package/es/networkTopo/models/TopoCenter.js +18 -22
- package/es/networkTopo/services/alert.js +18 -22
- package/es/networkTopo/services/authorization.js +45 -55
- package/es/networkTopo/services/cmdb.js +422 -470
- package/es/networkTopo/services/funcAuth.js +22 -24
- package/es/networkTopo/services/link.js +107 -117
- package/es/networkTopo/services/mdc.js +18 -24
- package/es/networkTopo/services/metric.js +23 -27
- package/es/networkTopo/services/model.js +445 -509
- package/es/networkTopo/services/risk.js +9 -11
- package/es/networkTopo/services/topo/auth.js +27 -33
- package/es/networkTopo/services/topo/basic.js +251 -289
- package/es/networkTopo/services/topo/blacklist.js +20 -24
- package/es/networkTopo/services/topo/ciInfo.js +27 -31
- package/es/networkTopo/services/topo/icon.js +49 -59
- package/es/networkTopo/services/topo/networkLink.js +32 -36
- package/es/networkTopo/services/topo/relation.js +9 -11
- package/es/networkTopo/services/topo/resourceWebUrl.js +36 -42
- package/es/networkTopo/store/functionAuth.js +31 -37
- package/es/networkTopo/store/topoCenter.js +142 -152
- package/es/networkTopo/store/topoLinkMod.js +4 -6
- package/es/networkTopo/store/topoTreeMod.js +170 -182
- package/es/networkTopo/utils/exportData.js +52 -54
- package/lib/components/BatchAttrMetric/setting.js +1 -1
- package/lib/components/MultiResourceDrawer/index.js +16 -18
- package/lib/components/ResourceList/ResourceSelect.js +48 -50
- package/lib/components/ResourceSelectDrawer/ResourceSelectDrawer.js +27 -29
- package/lib/components/SingleResourceDrawer/SelectDrawer.js +18 -20
- package/lib/core/components/DisplaySettingDrawer/DisplaySettingDrawer.js +30 -32
- package/lib/core/components/DisplaySettingDrawer/hooks/useDisplaySetting.js +78 -84
- package/lib/core/components/titlebar/widgets/TitleWidget.js +5 -3
- package/lib/core/editor/components/BackgroundView/UploadDialog/index.js +18 -18
- package/lib/core/editor/components/BackgroundView/index.js +118 -128
- package/lib/core/editor/components/CustomIconPlugin/RenameDialog.js +22 -24
- package/lib/core/editor/components/CustomIconPlugin/UploadIconDialog.js +34 -34
- package/lib/core/editor/components/CustomIconPlugin/utils/svgToShape.js +19 -21
- package/lib/core/editor/components/GroupAddResourceDrawerPlugin/GroupAddResourceDrawer.js +8 -10
- package/lib/core/editor/components/Sidebar/views/CanvasPanel/hooks/useCanvasThemeConfig.js +37 -41
- package/lib/core/editor/components/Toolbar/widgets/BoxBackgroundButton/BoxBackgroundSetting.js +50 -54
- package/lib/core/editor/components/Toolbar/widgets/FontColorButton.js +50 -54
- package/lib/core/editor/components/settings/propertyViews/layer/DataTab/DefaultLayerAddResourceDrawer.js +12 -14
- package/lib/core/editor/components/settings/propertyViews/node/data/BindResourceDrawer.js +26 -28
- package/lib/core/editor/components/settings/propertyViews/node/data/Data.js +15 -17
- package/lib/core/editor/components/settings/propertyViews/view/BackgroundSize.js +12 -14
- package/lib/core/editor/components/titlebar/TopoEditorTitleBar.js +25 -31
- package/lib/core/editor/hooks/useKeyboardShortcut.js +37 -34
- package/lib/core/editor/hooks/useNewElementTheme.js +2 -2
- package/lib/core/editor/store/background.js +8 -10
- package/lib/core/editor/store/topoEdit.js +4 -6
- package/lib/core/editor/utils/copyElementUtil.js +182 -0
- package/lib/core/editor/utils/edgeTypeStyleUtil.js +2 -4
- package/lib/core/hooks/usePolling.js +116 -120
- package/lib/core/hooks/useResourceConfig.js +58 -66
- package/lib/core/hooks/useTopoEdit.js +465 -495
- package/lib/core/models/Alarm.js +275 -292
- package/lib/core/models/AttributeMetricDisplay.js +104 -110
- package/lib/core/models/PluginManager.js +4 -3
- package/lib/core/models/SelectionModel.js +4 -5
- package/lib/core/models/TopoApp.js +205 -240
- package/lib/core/models/TopoGraphView.js +18 -21
- package/lib/core/models/cache/CiCache.js +33 -32
- package/lib/core/models/cache/CiTypeCache.js +38 -42
- package/lib/core/models/cache/DictCache.js +33 -35
- package/lib/core/models/graph/Background.js +16 -18
- package/lib/core/models/plugins/resourceWebControllUrl.js +74 -80
- package/lib/core/models/tagstips/ElementTagTipConfig.js +34 -38
- package/lib/core/models/topoData.js +69 -71
- package/lib/core/models/utils/linkUtils.js +41 -43
- package/lib/core/models/utils/nodeNameVisibleUtil.js +4 -4
- package/lib/core/services/alarm.js +18 -20
- package/lib/core/services/background.js +70 -78
- package/lib/core/services/cmdb/metric.js +10 -12
- package/lib/core/services/cmdb.js +22 -22
- package/lib/core/services/index.js +45 -51
- package/lib/core/services/overview.js +131 -151
- package/lib/core/services/topo/basic.js +37 -41
- package/lib/core/services/topo/tagtip.js +12 -14
- package/lib/core/store/models/ciModel.js +66 -70
- package/lib/core/store/models/customIcon.js +120 -134
- package/lib/core/store/models/displayConfig.js +15 -19
- package/lib/core/store/models/selection.js +4 -6
- package/lib/core/store/models/topoAlarm.js +163 -145
- package/lib/core/store/models/topoBaseInfoOverview.js +4 -6
- package/lib/core/store/models/topoBizMod.js +9 -11
- package/lib/core/store/models/topoConfig.js +222 -238
- package/lib/core/store/models/topoGraphView.js +4 -6
- package/lib/core/store/models/topoMod.js +375 -397
- package/lib/core/utils/imageUtil.js +22 -24
- package/lib/core/utils/metricUtil.js +5 -0
- package/lib/core/utils/saveSerialize.js +9 -11
- package/lib/core/viewer/components/plugins/ResourceDetail/components/ClusterMemberTable.js +56 -58
- package/lib/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/EventsCard.js +15 -17
- package/lib/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/ResourceOverview.js +344 -358
- package/lib/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/components/Configurator/index.js +86 -92
- package/lib/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/components/LinkTopo/LinkTopoCard.js +39 -41
- package/lib/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/components/LinkTopo/services/index.js +190 -206
- package/lib/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/hooks/useAlarmAndRiskData.js +107 -109
- package/lib/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/hooks/useMetricModels.js +57 -59
- package/lib/core/viewer/components/plugins/ResourceDetail/components/WebConsole/WebConsoleForm/hooks/useWebConsole.js +29 -33
- package/lib/core/viewer/components/plugins/ResourceDetail/getCiDisplayMetricModels.js +25 -29
- package/lib/core/viewer/components/plugins/ResourceDetail/hooks/useUserId.js +32 -36
- package/lib/core/viewer/components/plugins/ResourceWebControllUrlSettingDialog.js +18 -20
- package/lib/networkTopo/components/Link/hook.js +73 -77
- package/lib/networkTopo/components/Link/index.js +87 -95
- package/lib/networkTopo/components/Link/setting.js +42 -44
- package/lib/networkTopo/getTopoData.js +63 -69
- package/lib/networkTopo/hooks/viewer/useRelateTopo.js +31 -33
- package/lib/networkTopo/models/LinkDynamicStyleExecutor.js +2 -2
- package/lib/networkTopo/models/TopoCenter.js +18 -22
- package/lib/networkTopo/services/alert.js +18 -22
- package/lib/networkTopo/services/authorization.js +55 -65
- package/lib/networkTopo/services/cmdb.js +422 -470
- package/lib/networkTopo/services/funcAuth.js +24 -26
- package/lib/networkTopo/services/link.js +108 -118
- package/lib/networkTopo/services/mdc.js +21 -27
- package/lib/networkTopo/services/metric.js +27 -31
- package/lib/networkTopo/services/model.js +445 -509
- package/lib/networkTopo/services/risk.js +11 -13
- package/lib/networkTopo/services/topo/auth.js +27 -33
- package/lib/networkTopo/services/topo/basic.js +252 -290
- package/lib/networkTopo/services/topo/blacklist.js +20 -24
- package/lib/networkTopo/services/topo/ciInfo.js +34 -38
- package/lib/networkTopo/services/topo/icon.js +59 -69
- package/lib/networkTopo/services/topo/networkLink.js +32 -36
- package/lib/networkTopo/services/topo/relation.js +11 -13
- package/lib/networkTopo/services/topo/resourceWebUrl.js +44 -50
- package/lib/networkTopo/store/functionAuth.js +31 -37
- package/lib/networkTopo/store/topoCenter.js +142 -152
- package/lib/networkTopo/store/topoLinkMod.js +4 -6
- package/lib/networkTopo/store/topoTreeMod.js +166 -178
- package/lib/networkTopo/utils/exportData.js +59 -61
- package/lib/utils/htElementDataUtil.js +4 -2
- package/package.json +5 -3
@@ -74,58 +74,56 @@ function _default(topoApp) {
|
|
74
74
|
return (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee() {
|
75
75
|
var topoModState, type, id;
|
76
76
|
return _regenerator["default"].wrap(function _callee$(_context) {
|
77
|
-
while (1) {
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
|
100
|
-
|
101
|
-
|
102
|
-
|
103
|
-
|
104
|
-
|
105
|
-
if (!id) {
|
106
|
-
_context.next = 9;
|
107
|
-
break;
|
108
|
-
}
|
109
|
-
|
77
|
+
while (1) switch (_context.prev = _context.next) {
|
78
|
+
case 0:
|
79
|
+
if (params === void 0) {
|
80
|
+
params = {};
|
81
|
+
}
|
82
|
+
|
83
|
+
topoModState = rootState.topoMod; // 处理URL参数
|
84
|
+
|
85
|
+
type = params.type || 'view';
|
86
|
+
id = params.id || topoModState.topoId || '';
|
87
|
+
|
88
|
+
_rlog["default"].debug("topoMod.init \u521D\u59CB\u5316(" + id + ")...", {
|
89
|
+
params: params,
|
90
|
+
rootState: rootState
|
91
|
+
});
|
92
|
+
|
93
|
+
_this.update({
|
94
|
+
viewState: type,
|
95
|
+
currentTopo: id ? {
|
96
|
+
id: id
|
97
|
+
} : null,
|
98
|
+
topoId: id,
|
99
|
+
graphLoaded: false,
|
100
|
+
graphLoaded2: false,
|
101
|
+
initParams: params
|
102
|
+
});
|
103
|
+
|
104
|
+
if (!id) {
|
110
105
|
_context.next = 9;
|
111
|
-
|
112
|
-
|
113
|
-
|
114
|
-
|
115
|
-
|
116
|
-
|
117
|
-
|
118
|
-
|
119
|
-
|
120
|
-
|
121
|
-
|
122
|
-
|
123
|
-
|
124
|
-
|
125
|
-
|
126
|
-
|
127
|
-
|
128
|
-
|
106
|
+
break;
|
107
|
+
}
|
108
|
+
|
109
|
+
_context.next = 9;
|
110
|
+
return _this.openTopoPage({
|
111
|
+
id: id,
|
112
|
+
viewState: type
|
113
|
+
});
|
114
|
+
|
115
|
+
case 9:
|
116
|
+
_this.update({
|
117
|
+
loading: false
|
118
|
+
});
|
119
|
+
|
120
|
+
_rlog["default"].debug('topoMod.initTopoCenter 初始化完成', {
|
121
|
+
rootState: rootState
|
122
|
+
});
|
123
|
+
|
124
|
+
case 11:
|
125
|
+
case "end":
|
126
|
+
return _context.stop();
|
129
127
|
}
|
130
128
|
}, _callee);
|
131
129
|
}))();
|
@@ -159,43 +157,41 @@ function _default(topoApp) {
|
|
159
157
|
return (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee2() {
|
160
158
|
var id, data, linkTo, viewState, topoId;
|
161
159
|
return _regenerator["default"].wrap(function _callee2$(_context2) {
|
162
|
-
while (1) {
|
163
|
-
|
164
|
-
|
165
|
-
|
166
|
-
|
167
|
-
|
168
|
-
|
160
|
+
while (1) switch (_context2.prev = _context2.next) {
|
161
|
+
case 0:
|
162
|
+
id = playload.id, data = playload.data, linkTo = playload.linkTo;
|
163
|
+
viewState = playload.mode || playload.viewState || 'view';
|
164
|
+
topoId = id || data.config.id;
|
165
|
+
|
166
|
+
_this2.update({
|
167
|
+
viewState: viewState,
|
168
|
+
currentTopo: playload,
|
169
|
+
topoId: topoId,
|
170
|
+
graphLoaded: false,
|
171
|
+
graphLoaded2: false,
|
172
|
+
topoPermission: undefined
|
173
|
+
});
|
174
|
+
|
175
|
+
_context2.next = 6;
|
176
|
+
return _this2.initTopoData({
|
177
|
+
topoId: topoId,
|
178
|
+
data: data,
|
179
|
+
linkTo: linkTo
|
180
|
+
});
|
181
|
+
|
182
|
+
case 6:
|
183
|
+
if (viewState === 'edit') {
|
184
|
+
// TODO 待优化进入编辑模式方式
|
169
185
|
_this2.update({
|
170
|
-
|
171
|
-
currentTopo: playload,
|
172
|
-
topoId: topoId,
|
173
|
-
graphLoaded: false,
|
174
|
-
graphLoaded2: false,
|
175
|
-
topoPermission: undefined
|
176
|
-
});
|
177
|
-
|
178
|
-
_context2.next = 6;
|
179
|
-
return _this2.initTopoData({
|
180
|
-
topoId: topoId,
|
181
|
-
data: data,
|
182
|
-
linkTo: linkTo
|
186
|
+
graphLoaded2: false
|
183
187
|
});
|
184
188
|
|
185
|
-
|
186
|
-
|
187
|
-
// TODO 待优化进入编辑模式方式
|
188
|
-
_this2.update({
|
189
|
-
graphLoaded2: false
|
190
|
-
});
|
191
|
-
|
192
|
-
_this2.enterEditMode();
|
193
|
-
}
|
189
|
+
_this2.enterEditMode();
|
190
|
+
}
|
194
191
|
|
195
|
-
|
196
|
-
|
197
|
-
|
198
|
-
}
|
192
|
+
case 7:
|
193
|
+
case "end":
|
194
|
+
return _context2.stop();
|
199
195
|
}
|
200
196
|
}, _callee2);
|
201
197
|
}))();
|
@@ -236,34 +232,32 @@ function _default(topoApp) {
|
|
236
232
|
return (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee3() {
|
237
233
|
var topoId, treeData;
|
238
234
|
return _regenerator["default"].wrap(function _callee3$(_context3) {
|
239
|
-
while (1) {
|
240
|
-
|
241
|
-
|
242
|
-
|
243
|
-
|
244
|
-
|
245
|
-
|
246
|
-
|
247
|
-
|
248
|
-
|
249
|
-
|
250
|
-
|
251
|
-
|
252
|
-
|
253
|
-
|
254
|
-
|
255
|
-
|
256
|
-
} // 右侧切换拓扑图
|
235
|
+
while (1) switch (_context3.prev = _context3.next) {
|
236
|
+
case 0:
|
237
|
+
if (conditions === void 0) {
|
238
|
+
conditions = {};
|
239
|
+
}
|
240
|
+
|
241
|
+
topoId = rootState.topoTreeMod.defId;
|
242
|
+
|
243
|
+
if (!topoId) {
|
244
|
+
// 查找第一个
|
245
|
+
treeData = rootState.topoTreeMod.treeData;
|
246
|
+
(0, _tree.loopTreeByKey)(treeData, 'type', 1, function (item, index, arr) {
|
247
|
+
if (!topoId) {
|
248
|
+
topoId = item.id;
|
249
|
+
}
|
250
|
+
});
|
251
|
+
} // 右侧切换拓扑图
|
257
252
|
|
258
253
|
|
259
|
-
|
260
|
-
|
261
|
-
|
254
|
+
_this3.openTopoPage({
|
255
|
+
id: topoId
|
256
|
+
});
|
262
257
|
|
263
|
-
|
264
|
-
|
265
|
-
|
266
|
-
}
|
258
|
+
case 4:
|
259
|
+
case "end":
|
260
|
+
return _context3.stop();
|
267
261
|
}
|
268
262
|
}, _callee3);
|
269
263
|
}))();
|
@@ -273,20 +267,18 @@ function _default(topoApp) {
|
|
273
267
|
|
274
268
|
return (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee4() {
|
275
269
|
return _regenerator["default"].wrap(function _callee4$(_context4) {
|
276
|
-
while (1) {
|
277
|
-
|
278
|
-
|
279
|
-
|
280
|
-
|
281
|
-
|
282
|
-
|
283
|
-
|
284
|
-
|
285
|
-
|
286
|
-
|
287
|
-
|
288
|
-
return _context4.stop();
|
289
|
-
}
|
270
|
+
while (1) switch (_context4.prev = _context4.next) {
|
271
|
+
case 0:
|
272
|
+
_context4.next = 2;
|
273
|
+
return dispatch.functionAuth.refresh();
|
274
|
+
|
275
|
+
case 2:
|
276
|
+
_context4.next = 4;
|
277
|
+
return _this4.refreshTopoTree();
|
278
|
+
|
279
|
+
case 4:
|
280
|
+
case "end":
|
281
|
+
return _context4.stop();
|
290
282
|
}
|
291
283
|
}, _callee4);
|
292
284
|
}))();
|
@@ -294,16 +286,14 @@ function _default(topoApp) {
|
|
294
286
|
refreshTopoTree: function refreshTopoTree() {
|
295
287
|
return (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee5() {
|
296
288
|
return _regenerator["default"].wrap(function _callee5$(_context5) {
|
297
|
-
while (1) {
|
298
|
-
|
299
|
-
|
300
|
-
|
301
|
-
|
302
|
-
|
303
|
-
|
304
|
-
|
305
|
-
return _context5.stop();
|
306
|
-
}
|
289
|
+
while (1) switch (_context5.prev = _context5.next) {
|
290
|
+
case 0:
|
291
|
+
_context5.next = 2;
|
292
|
+
return dispatch.topoTreeMod.refreshTree();
|
293
|
+
|
294
|
+
case 2:
|
295
|
+
case "end":
|
296
|
+
return _context5.stop();
|
307
297
|
}
|
308
298
|
}, _callee5);
|
309
299
|
}))();
|
@@ -328,197 +318,195 @@ function _default(topoApp) {
|
|
328
318
|
var startTime, topoId, data, linkToData, refresh, clear, linkTo, startState, permission, result, graphConfig, topoConfig, extraConfig, _combTopoData, topoData, resAndMetrics, _yield$Promise$all, newData, endTime;
|
329
319
|
|
330
320
|
return _regenerator["default"].wrap(function _callee6$(_context6) {
|
331
|
-
while (1) {
|
332
|
-
|
333
|
-
|
334
|
-
|
335
|
-
|
336
|
-
|
337
|
-
|
338
|
-
|
339
|
-
|
340
|
-
|
341
|
-
|
342
|
-
|
343
|
-
|
344
|
-
|
345
|
-
|
346
|
-
|
347
|
-
|
348
|
-
|
349
|
-
|
350
|
-
|
351
|
-
Object.assign(startState, {
|
352
|
-
topoData: null,
|
353
|
-
data: null,
|
354
|
-
globalConfig: null // 全局配置
|
355
|
-
|
356
|
-
});
|
357
|
-
}
|
358
|
-
|
359
|
-
_this5.update(startState);
|
360
|
-
|
361
|
-
dispatch.topoBizMod.update({
|
362
|
-
pollingSwitch: false
|
363
|
-
});
|
364
|
-
topoApp.options.onLoadStart(); // TODO 待移到拓扑中心
|
365
|
-
|
366
|
-
permission = 'write';
|
367
|
-
|
368
|
-
if (!topoApp.options.usePermission) {
|
369
|
-
_context6.next = 19;
|
370
|
-
break;
|
371
|
-
}
|
372
|
-
|
373
|
-
_context6.next = 14;
|
374
|
-
return _this5.getTopoPermission({
|
375
|
-
id: topoId
|
376
|
-
});
|
377
|
-
|
378
|
-
case 14:
|
379
|
-
permission = _context6.sent;
|
380
|
-
|
381
|
-
if (_topoPermissionUtil["default"].isReadable(permission)) {
|
382
|
-
_context6.next = 19;
|
383
|
-
break;
|
384
|
-
}
|
385
|
-
|
386
|
-
_this5.update({
|
387
|
-
loading: false,
|
321
|
+
while (1) switch (_context6.prev = _context6.next) {
|
322
|
+
case 0:
|
323
|
+
startTime = (0, _moment["default"])();
|
324
|
+
topoId = props.topoId, data = props.data, linkToData = props.linkTo, refresh = props.refresh, clear = props.clear;
|
325
|
+
_context6.next = 4;
|
326
|
+
return topoApp.open(topoId);
|
327
|
+
|
328
|
+
case 4:
|
329
|
+
// 关联拓扑图
|
330
|
+
linkTo = refresh === true ? state.topoMod.linkTo : linkToData || null;
|
331
|
+
startState = {
|
332
|
+
loading: true,
|
333
|
+
graphLoaded: false,
|
334
|
+
graphLoaded2: false,
|
335
|
+
topoLoadError: false,
|
336
|
+
linkTo: linkTo
|
337
|
+
};
|
338
|
+
|
339
|
+
if (clear === true || topoId < 0) {
|
340
|
+
Object.assign(startState, {
|
388
341
|
topoData: null,
|
389
342
|
data: null,
|
390
343
|
globalConfig: null // 全局配置
|
391
344
|
|
392
345
|
});
|
346
|
+
}
|
393
347
|
|
394
|
-
|
395
|
-
return _context6.abrupt("return");
|
348
|
+
_this5.update(startState);
|
396
349
|
|
397
|
-
|
398
|
-
|
399
|
-
|
400
|
-
|
401
|
-
}
|
402
|
-
|
403
|
-
graphConfig = {};
|
350
|
+
dispatch.topoBizMod.update({
|
351
|
+
pollingSwitch: false
|
352
|
+
});
|
353
|
+
topoApp.options.onLoadStart(); // TODO 待移到拓扑中心
|
404
354
|
|
405
|
-
|
406
|
-
_context6.next = 27;
|
407
|
-
break;
|
408
|
-
}
|
355
|
+
permission = 'write';
|
409
356
|
|
410
|
-
|
411
|
-
|
412
|
-
|
413
|
-
case 24:
|
414
|
-
topoConfig = _context6.sent;
|
415
|
-
if (!topoConfig) _rlog["default"].error("\u672A\u67E5\u8BE2\u5230\u62D3\u6251id " + topoId + " \u7684\u6570\u636E\uFF0C\u8BF7\u68C0\u67E5");
|
416
|
-
graphConfig = {
|
417
|
-
global: topoConfig === null || topoConfig === void 0 ? void 0 : topoConfig.global,
|
418
|
-
customGlobal: data.global,
|
419
|
-
serialize: topoConfig === null || topoConfig === void 0 ? void 0 : topoConfig.serialize
|
420
|
-
};
|
421
|
-
|
422
|
-
case 27:
|
423
|
-
result = (0, _extends2["default"])({}, data, graphConfig);
|
424
|
-
_context6.next = 33;
|
357
|
+
if (!topoApp.options.usePermission) {
|
358
|
+
_context6.next = 19;
|
425
359
|
break;
|
360
|
+
}
|
426
361
|
|
427
|
-
|
428
|
-
|
429
|
-
|
430
|
-
|
431
|
-
case 32:
|
432
|
-
result = _context6.sent;
|
433
|
-
|
434
|
-
case 33:
|
435
|
-
if (result) {
|
436
|
-
_context6.next = 37;
|
437
|
-
break;
|
438
|
-
}
|
439
|
-
|
440
|
-
_this5.update({
|
441
|
-
loading: false,
|
442
|
-
data: null,
|
443
|
-
globalConfig: null,
|
444
|
-
// 全局配置
|
445
|
-
topoData: null
|
446
|
-
});
|
447
|
-
|
448
|
-
topoApp.options.onLoad();
|
449
|
-
return _context6.abrupt("return");
|
450
|
-
|
451
|
-
case 37:
|
452
|
-
result = (0, _topoData.parseTopoData)(result);
|
453
|
-
|
454
|
-
_rlog["default"].debug('topoMod.initTopoData 查询数据完成', topoId, linkTo, result);
|
455
|
-
|
456
|
-
_context6.next = 41;
|
457
|
-
return dispatch.customIcon.loadCustomIcons();
|
458
|
-
|
459
|
-
case 41:
|
460
|
-
extraConfig = result.global.extraConfig;
|
461
|
-
_context6.next = 44;
|
462
|
-
return dispatch.displayConfig.setConfig((0, _extends2["default"])({}, extraConfig, {
|
463
|
-
alarmSwitch: result.global.alarmSwitch,
|
464
|
-
alarmListDefaultOpen: result.global.alarmListDefaultOpen
|
465
|
-
}));
|
466
|
-
|
467
|
-
case 44:
|
468
|
-
_combTopoData = (0, _topoData.combTopoData)({
|
469
|
-
engine: topoApp,
|
470
|
-
data: result,
|
471
|
-
linkTo: linkTo,
|
472
|
-
globalConfig: extraConfig
|
473
|
-
}), topoData = _combTopoData.topoData, resAndMetrics = _combTopoData.resAndMetrics; // rlog.debug("topoMod.initTopoData combTopoData", { topoData, resAndMetrics, });
|
474
|
-
|
475
|
-
_context6.next = 47;
|
476
|
-
return _this5.update({
|
477
|
-
currentTopo: topoData.config,
|
478
|
-
data: result,
|
479
|
-
globalConfig: extraConfig,
|
480
|
-
type: (_result$config = result.config) === null || _result$config === void 0 ? void 0 : _result$config.showType,
|
481
|
-
topoData: topoData,
|
482
|
-
resAndMetrics: resAndMetrics
|
483
|
-
});
|
362
|
+
_context6.next = 14;
|
363
|
+
return _this5.getTopoPermission({
|
364
|
+
id: topoId
|
365
|
+
});
|
484
366
|
|
485
|
-
|
486
|
-
|
487
|
-
dispatch.background.init(extraConfig); // TODO 优化打开拓扑图显示告警速度:打开拓扑图立即请求告警
|
367
|
+
case 14:
|
368
|
+
permission = _context6.sent;
|
488
369
|
|
489
|
-
|
370
|
+
if (_topoPermissionUtil["default"].isReadable(permission)) {
|
371
|
+
_context6.next = 19;
|
372
|
+
break;
|
373
|
+
}
|
490
374
|
|
491
|
-
|
492
|
-
|
493
|
-
|
375
|
+
_this5.update({
|
376
|
+
loading: false,
|
377
|
+
topoData: null,
|
378
|
+
data: null,
|
379
|
+
globalConfig: null // 全局配置
|
494
380
|
|
495
|
-
|
496
|
-
_yield$Promise$all = _context6.sent;
|
497
|
-
newData = _yield$Promise$all[0];
|
498
|
-
_context6.next = 56;
|
499
|
-
return _this5.update({
|
500
|
-
data: newData
|
501
|
-
});
|
502
|
-
|
503
|
-
case 56:
|
504
|
-
dispatch.topoBizMod.update({
|
505
|
-
pollingSwitch: true
|
506
|
-
});
|
507
|
-
topoApp.onTopoDataLoaded(topoData);
|
508
|
-
endTime = (0, _moment["default"])();
|
381
|
+
});
|
509
382
|
|
510
|
-
|
383
|
+
topoApp.options.onLoad();
|
384
|
+
return _context6.abrupt("return");
|
511
385
|
|
512
|
-
|
386
|
+
case 19:
|
387
|
+
if (!data) {
|
388
|
+
_context6.next = 30;
|
389
|
+
break;
|
390
|
+
}
|
513
391
|
|
514
|
-
|
515
|
-
loading: false
|
516
|
-
});
|
392
|
+
graphConfig = {};
|
517
393
|
|
518
|
-
|
519
|
-
|
520
|
-
|
521
|
-
|
394
|
+
if (!topoId) {
|
395
|
+
_context6.next = 27;
|
396
|
+
break;
|
397
|
+
}
|
398
|
+
|
399
|
+
_context6.next = 24;
|
400
|
+
return _topo["default"].getTopoData(topoId);
|
401
|
+
|
402
|
+
case 24:
|
403
|
+
topoConfig = _context6.sent;
|
404
|
+
if (!topoConfig) _rlog["default"].error("\u672A\u67E5\u8BE2\u5230\u62D3\u6251id " + topoId + " \u7684\u6570\u636E\uFF0C\u8BF7\u68C0\u67E5");
|
405
|
+
graphConfig = {
|
406
|
+
global: topoConfig === null || topoConfig === void 0 ? void 0 : topoConfig.global,
|
407
|
+
customGlobal: data.global,
|
408
|
+
serialize: topoConfig === null || topoConfig === void 0 ? void 0 : topoConfig.serialize
|
409
|
+
};
|
410
|
+
|
411
|
+
case 27:
|
412
|
+
result = (0, _extends2["default"])({}, data, graphConfig);
|
413
|
+
_context6.next = 33;
|
414
|
+
break;
|
415
|
+
|
416
|
+
case 30:
|
417
|
+
_context6.next = 32;
|
418
|
+
return topoApp.options.loadData(topoId, topoApp.serverApi);
|
419
|
+
|
420
|
+
case 32:
|
421
|
+
result = _context6.sent;
|
422
|
+
|
423
|
+
case 33:
|
424
|
+
if (result) {
|
425
|
+
_context6.next = 37;
|
426
|
+
break;
|
427
|
+
}
|
428
|
+
|
429
|
+
_this5.update({
|
430
|
+
loading: false,
|
431
|
+
data: null,
|
432
|
+
globalConfig: null,
|
433
|
+
// 全局配置
|
434
|
+
topoData: null
|
435
|
+
});
|
436
|
+
|
437
|
+
topoApp.options.onLoad();
|
438
|
+
return _context6.abrupt("return");
|
439
|
+
|
440
|
+
case 37:
|
441
|
+
result = (0, _topoData.parseTopoData)(result);
|
442
|
+
|
443
|
+
_rlog["default"].debug('topoMod.initTopoData 查询数据完成', topoId, linkTo, result);
|
444
|
+
|
445
|
+
_context6.next = 41;
|
446
|
+
return dispatch.customIcon.loadCustomIcons();
|
447
|
+
|
448
|
+
case 41:
|
449
|
+
extraConfig = result.global.extraConfig;
|
450
|
+
_context6.next = 44;
|
451
|
+
return dispatch.displayConfig.setConfig((0, _extends2["default"])({}, extraConfig, {
|
452
|
+
alarmSwitch: result.global.alarmSwitch,
|
453
|
+
alarmListDefaultOpen: result.global.alarmListDefaultOpen
|
454
|
+
}));
|
455
|
+
|
456
|
+
case 44:
|
457
|
+
_combTopoData = (0, _topoData.combTopoData)({
|
458
|
+
engine: topoApp,
|
459
|
+
data: result,
|
460
|
+
linkTo: linkTo,
|
461
|
+
globalConfig: extraConfig
|
462
|
+
}), topoData = _combTopoData.topoData, resAndMetrics = _combTopoData.resAndMetrics; // rlog.debug("topoMod.initTopoData combTopoData", { topoData, resAndMetrics, });
|
463
|
+
|
464
|
+
_context6.next = 47;
|
465
|
+
return _this5.update({
|
466
|
+
currentTopo: topoData.config,
|
467
|
+
data: result,
|
468
|
+
globalConfig: extraConfig,
|
469
|
+
type: (_result$config = result.config) === null || _result$config === void 0 ? void 0 : _result$config.showType,
|
470
|
+
topoData: topoData,
|
471
|
+
resAndMetrics: resAndMetrics
|
472
|
+
});
|
473
|
+
|
474
|
+
case 47:
|
475
|
+
dispatch.topoBizMod.combBatchCiInfo(resAndMetrics);
|
476
|
+
dispatch.background.init(extraConfig); // TODO 优化打开拓扑图显示告警速度:打开拓扑图立即请求告警
|
477
|
+
|
478
|
+
topoApp.alarm.open(); // 加载标注悬浮框数据
|
479
|
+
|
480
|
+
_context6.next = 52;
|
481
|
+
return Promise.all([(0, _getTopoData.addLinkData)(result), topoApp.ciTyeCache.load((0, _topoData.getCiTypes)(result)), topoApp.elementTagTipConfig.init(result) // 暂停新配置开发
|
482
|
+
]);
|
483
|
+
|
484
|
+
case 52:
|
485
|
+
_yield$Promise$all = _context6.sent;
|
486
|
+
newData = _yield$Promise$all[0];
|
487
|
+
_context6.next = 56;
|
488
|
+
return _this5.update({
|
489
|
+
data: newData
|
490
|
+
});
|
491
|
+
|
492
|
+
case 56:
|
493
|
+
dispatch.topoBizMod.update({
|
494
|
+
pollingSwitch: true
|
495
|
+
});
|
496
|
+
topoApp.onTopoDataLoaded(topoData);
|
497
|
+
endTime = (0, _moment["default"])();
|
498
|
+
|
499
|
+
_rlog["default"].info('topoMod.initTopoData 初始化拓扑图数据完成. 耗时: ', endTime.diff(startTime, 'seconds', true));
|
500
|
+
|
501
|
+
topoApp.options.onLoad();
|
502
|
+
|
503
|
+
_this5.update({
|
504
|
+
loading: false
|
505
|
+
});
|
506
|
+
|
507
|
+
case 62:
|
508
|
+
case "end":
|
509
|
+
return _context6.stop();
|
522
510
|
}
|
523
511
|
}, _callee6);
|
524
512
|
}))();
|
@@ -534,25 +522,23 @@ function _default(topoApp) {
|
|
534
522
|
var _payload, clear;
|
535
523
|
|
536
524
|
return _regenerator["default"].wrap(function _callee7$(_context7) {
|
537
|
-
while (1) {
|
538
|
-
|
539
|
-
|
540
|
-
|
541
|
-
|
542
|
-
|
543
|
-
|
544
|
-
|
545
|
-
|
546
|
-
|
547
|
-
|
548
|
-
|
549
|
-
|
550
|
-
|
551
|
-
|
552
|
-
|
553
|
-
|
554
|
-
return _context7.stop();
|
555
|
-
}
|
525
|
+
while (1) switch (_context7.prev = _context7.next) {
|
526
|
+
case 0:
|
527
|
+
if (payload === void 0) {
|
528
|
+
payload = {};
|
529
|
+
}
|
530
|
+
|
531
|
+
_payload = payload, clear = _payload.clear;
|
532
|
+
_context7.next = 4;
|
533
|
+
return _this6.initTopoData({
|
534
|
+
topoId: rootState.topoMod.topoId,
|
535
|
+
refresh: true,
|
536
|
+
clear: clear
|
537
|
+
});
|
538
|
+
|
539
|
+
case 4:
|
540
|
+
case "end":
|
541
|
+
return _context7.stop();
|
556
542
|
}
|
557
543
|
}, _callee7);
|
558
544
|
}))();
|
@@ -563,37 +549,35 @@ function _default(topoApp) {
|
|
563
549
|
return (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee8() {
|
564
550
|
var td;
|
565
551
|
return _regenerator["default"].wrap(function _callee8$(_context8) {
|
566
|
-
while (1) {
|
567
|
-
|
568
|
-
|
569
|
-
|
570
|
-
|
552
|
+
while (1) switch (_context8.prev = _context8.next) {
|
553
|
+
case 0:
|
554
|
+
if (conditions === void 0) {
|
555
|
+
conditions = {};
|
556
|
+
}
|
557
|
+
|
558
|
+
if (conditions.id === state.topoMod.topoId) {
|
559
|
+
if (conditions.type === 'delete') {
|
560
|
+
_this7.update({
|
561
|
+
topoId: conditions.defId
|
562
|
+
});
|
571
563
|
}
|
572
564
|
|
573
|
-
if (conditions.
|
574
|
-
|
575
|
-
|
576
|
-
|
577
|
-
})
|
578
|
-
}
|
579
|
-
|
580
|
-
if (conditions.type === 'rename') {
|
581
|
-
td = (0, _extends2["default"])({}, state.topoMod.topoData, {
|
582
|
-
config: (0, _extends2["default"])({}, state.topoMod.topoData.config, {
|
583
|
-
name: conditions.name
|
584
|
-
})
|
585
|
-
});
|
565
|
+
if (conditions.type === 'rename') {
|
566
|
+
td = (0, _extends2["default"])({}, state.topoMod.topoData, {
|
567
|
+
config: (0, _extends2["default"])({}, state.topoMod.topoData.config, {
|
568
|
+
name: conditions.name
|
569
|
+
})
|
570
|
+
});
|
586
571
|
|
587
|
-
|
588
|
-
|
589
|
-
|
590
|
-
}
|
572
|
+
_this7.update({
|
573
|
+
topoData: td
|
574
|
+
});
|
591
575
|
}
|
576
|
+
}
|
592
577
|
|
593
|
-
|
594
|
-
|
595
|
-
|
596
|
-
}
|
578
|
+
case 2:
|
579
|
+
case "end":
|
580
|
+
return _context8.stop();
|
597
581
|
}
|
598
582
|
}, _callee8);
|
599
583
|
}))();
|
@@ -601,15 +585,13 @@ function _default(topoApp) {
|
|
601
585
|
openPermissionSetting: function openPermissionSetting(payload, rootState) {
|
602
586
|
return (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee9() {
|
603
587
|
return _regenerator["default"].wrap(function _callee9$(_context9) {
|
604
|
-
while (1) {
|
605
|
-
|
606
|
-
|
607
|
-
|
608
|
-
|
609
|
-
|
610
|
-
|
611
|
-
return _context9.stop();
|
612
|
-
}
|
588
|
+
while (1) switch (_context9.prev = _context9.next) {
|
589
|
+
case 0:
|
590
|
+
dispatch.permissionSetting.open();
|
591
|
+
|
592
|
+
case 1:
|
593
|
+
case "end":
|
594
|
+
return _context9.stop();
|
613
595
|
}
|
614
596
|
}, _callee9);
|
615
597
|
}))();
|
@@ -617,19 +599,17 @@ function _default(topoApp) {
|
|
617
599
|
updateDelId: function updateDelId(conditions, state) {
|
618
600
|
return (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee10() {
|
619
601
|
return _regenerator["default"].wrap(function _callee10$(_context10) {
|
620
|
-
while (1) {
|
621
|
-
|
622
|
-
|
623
|
-
|
624
|
-
|
625
|
-
}
|
602
|
+
while (1) switch (_context10.prev = _context10.next) {
|
603
|
+
case 0:
|
604
|
+
if (conditions === void 0) {
|
605
|
+
conditions = '';
|
606
|
+
}
|
626
607
|
|
627
|
-
|
608
|
+
_rlog["default"].debug('updateDelId', conditions);
|
628
609
|
|
629
|
-
|
630
|
-
|
631
|
-
|
632
|
-
}
|
610
|
+
case 2:
|
611
|
+
case "end":
|
612
|
+
return _context10.stop();
|
633
613
|
}
|
634
614
|
}, _callee10);
|
635
615
|
}))();
|
@@ -640,42 +620,40 @@ function _default(topoApp) {
|
|
640
620
|
return (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee11() {
|
641
621
|
var id, update, topoPermission;
|
642
622
|
return _regenerator["default"].wrap(function _callee11$(_context11) {
|
643
|
-
while (1) {
|
644
|
-
|
645
|
-
|
646
|
-
|
647
|
-
|
648
|
-
|
649
|
-
return topoApp.serverApi.auth.getTopoPermission(id);
|
623
|
+
while (1) switch (_context11.prev = _context11.next) {
|
624
|
+
case 0:
|
625
|
+
id = playload.id, update = playload.update;
|
626
|
+
_context11.prev = 1;
|
627
|
+
_context11.next = 4;
|
628
|
+
return topoApp.serverApi.auth.getTopoPermission(id);
|
650
629
|
|
651
|
-
|
652
|
-
|
630
|
+
case 4:
|
631
|
+
topoPermission = _context11.sent;
|
653
632
|
|
654
|
-
|
633
|
+
_rlog["default"].debug('查询拓扑权限', topoPermission);
|
655
634
|
|
656
|
-
|
657
|
-
|
635
|
+
_context11.next = 11;
|
636
|
+
break;
|
658
637
|
|
659
|
-
|
660
|
-
|
661
|
-
|
638
|
+
case 8:
|
639
|
+
_context11.prev = 8;
|
640
|
+
_context11.t0 = _context11["catch"](1);
|
662
641
|
|
663
|
-
|
642
|
+
_rlog["default"].error("\u67E5\u8BE2\u62D3\u6251" + id + "\u7684\u6743\u9650\u5931\u8D25", _context11.t0); // 尚未区分拓扑图不存在还是接口请求报错
|
664
643
|
|
665
644
|
|
666
|
-
|
667
|
-
|
668
|
-
|
669
|
-
|
670
|
-
|
671
|
-
|
645
|
+
case 11:
|
646
|
+
if (update !== false) {
|
647
|
+
_this8.update({
|
648
|
+
topoPermission: topoPermission
|
649
|
+
});
|
650
|
+
}
|
672
651
|
|
673
|
-
|
652
|
+
return _context11.abrupt("return", topoPermission);
|
674
653
|
|
675
|
-
|
676
|
-
|
677
|
-
|
678
|
-
}
|
654
|
+
case 13:
|
655
|
+
case "end":
|
656
|
+
return _context11.stop();
|
679
657
|
}
|
680
658
|
}, _callee11, null, [[1, 8]]);
|
681
659
|
}))();
|