mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-01-18 01:25:37 -05:00
Added error node to OE tree (#3889)
* Add error node to OE tree * Add globalerror_red.svg for error node. * Fixed wrong import resolved automatically * Resolve PR comments
This commit is contained in:
@@ -139,6 +139,14 @@ export class MssqlObjectExplorerNodeProvider extends ProviderBase implements sql
|
||||
let children = await node.getChildren(true);
|
||||
if (children) {
|
||||
expandResult.nodes = children.map(c => c.getNodeInfo());
|
||||
// There is only child returned when failure happens
|
||||
if (children.length === 1) {
|
||||
let child = children[0].getNodeInfo();
|
||||
if (child && child.nodeType === constants.MssqlClusterItems.Error) {
|
||||
expandResult.errorMessage = child.label;
|
||||
expandResult.nodes = [];
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
} catch (error) {
|
||||
|
||||
Reference in New Issue
Block a user