mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-01-13 17:22:15 -05:00
Add tool path column to the deployment tools table (#8597)
* remove redundan console.warn messages * add tool path, trim existing columns in tools table * Update dockerTool.ts
This commit is contained in:
@@ -246,14 +246,14 @@ export interface ITool {
|
||||
readonly homePage: string;
|
||||
readonly displayStatus: string;
|
||||
readonly dependencyMessages: string[];
|
||||
readonly statusDescription: string | undefined;
|
||||
readonly statusDescription?: string;
|
||||
readonly autoInstallSupported: boolean;
|
||||
readonly autoInstallNeeded: boolean;
|
||||
readonly isNotInstalled: boolean;
|
||||
readonly isInstalled: boolean;
|
||||
readonly installationPath: string;
|
||||
readonly installationPath?: string;
|
||||
readonly outputChannelName: string;
|
||||
readonly fullVersion: string | undefined;
|
||||
readonly fullVersion?: string;
|
||||
readonly onDidUpdateData: vscode.Event<ITool>;
|
||||
|
||||
showOutputChannel(preserveFocus?: boolean): void;
|
||||
|
||||
@@ -24,7 +24,7 @@ export class AzCliTool extends ToolBase {
|
||||
}
|
||||
|
||||
get description(): string {
|
||||
return localize('resourceDeployment.AzCLIDescription', "A command-line tool for managing Azure resources");
|
||||
return localize('resourceDeployment.AzCLIDescription', "A tool for managing Azure resources");
|
||||
}
|
||||
|
||||
get type(): ToolType {
|
||||
|
||||
@@ -28,7 +28,7 @@ export class AzdataTool extends ToolBase {
|
||||
}
|
||||
|
||||
get description(): string {
|
||||
return localize('resourceDeployment.AzdataDescription', "A command-line utility written in Python that enables cluster administrators to bootstrap and manage the Big Data Cluster via REST APIs");
|
||||
return localize('resourceDeployment.AzdataDescription', "A utility to bootstrap and manage the Big Data Cluster");
|
||||
}
|
||||
|
||||
get type(): ToolType {
|
||||
|
||||
@@ -21,7 +21,7 @@ export class DockerTool extends ToolBase {
|
||||
}
|
||||
|
||||
get description(): string {
|
||||
return localize('resourceDeployment.DockerDescription', "Provides the ability to package and run an application in isolated containers");
|
||||
return localize('resourceDeployment.DockerDescription', "A utility to package and run an application in isolated containers");
|
||||
}
|
||||
|
||||
get type(): ToolType {
|
||||
|
||||
@@ -24,7 +24,7 @@ export class KubeCtlTool extends ToolBase {
|
||||
}
|
||||
|
||||
get description(): string {
|
||||
return localize('resourceDeployment.KubeCtlDescription', "A command-line tool allows you to run commands against Kubernetes clusters");
|
||||
return localize('resourceDeployment.KubeCtlDescription', "A tool to run commands against Kubernetes clusters");
|
||||
}
|
||||
|
||||
get type(): ToolType {
|
||||
|
||||
@@ -138,7 +138,7 @@ export abstract class ToolBase implements ITool {
|
||||
return this._statusDescription;
|
||||
}
|
||||
|
||||
public get installationPath(): string {
|
||||
public get installationPath(): string | undefined {
|
||||
return this._installationPath;
|
||||
}
|
||||
|
||||
@@ -300,5 +300,5 @@ export abstract class ToolBase implements ITool {
|
||||
private _status: ToolStatus = ToolStatus.NotInstalled;
|
||||
private _version?: SemVer;
|
||||
private _statusDescription?: string;
|
||||
private _installationPath!: string;
|
||||
private _installationPath?: string;
|
||||
}
|
||||
|
||||
@@ -90,28 +90,31 @@ export class ResourceTypePickerDialog extends DialogBase {
|
||||
this._agreementContainer = view.modelBuilder.divContainer().component();
|
||||
const toolColumn: azdata.TableColumn = {
|
||||
value: localize('deploymentDialog.toolNameColumnHeader', "Tool"),
|
||||
width: 70
|
||||
width: 55
|
||||
};
|
||||
const descriptionColumn: azdata.TableColumn = {
|
||||
value: localize('deploymentDialog.toolDescriptionColumnHeader', "Description"),
|
||||
width: 650
|
||||
width: 270
|
||||
};
|
||||
const installStatusColumn: azdata.TableColumn = {
|
||||
value: localize('deploymentDialog.toolStatusColumnHeader', "Status"),
|
||||
width: 70
|
||||
};
|
||||
const versionColumn: azdata.TableColumn = {
|
||||
value: localize('deploymentDialog.toolVersionColumnHeader', "Installed Version"),
|
||||
width: 90
|
||||
value: localize('deploymentDialog.toolVersionColumnHeader', "Version"),
|
||||
width: 60
|
||||
};
|
||||
const minVersionColumn: azdata.TableColumn = {
|
||||
value: localize('deploymentDialog.toolMinimumVersionColumnHeader', "Required Version"),
|
||||
width: 90
|
||||
};
|
||||
|
||||
const installedPathColumn: azdata.TableColumn = {
|
||||
value: localize('deploymentDialog.toolDiscoveredPathColumnHeader', "Discovered Path"),
|
||||
width: 570
|
||||
};
|
||||
this._toolsTable = view.modelBuilder.table().withProperties<azdata.TableComponentProperties>({
|
||||
data: [],
|
||||
columns: [toolColumn, descriptionColumn, installStatusColumn, versionColumn, minVersionColumn],
|
||||
columns: [toolColumn, descriptionColumn, installStatusColumn, versionColumn, minVersionColumn, installedPathColumn],
|
||||
width: tableWidth,
|
||||
ariaLabel: localize('deploymentDialog.RequiredToolsTitle', "Required tools")
|
||||
}).component();
|
||||
@@ -234,7 +237,7 @@ export class ResourceTypePickerDialog extends DialogBase {
|
||||
messages.push(localize('deploymentDialog.ToolDoesNotMeetVersionRequirement', "'{0}' [ {1} ] does not meet the minimum version requirement, please uninstall it and restart Azure Data Studio.", tool.displayName, tool.homePage));
|
||||
}
|
||||
installationNeeded = installationNeeded || tool.autoInstallNeeded;
|
||||
return [tool.displayName, tool.description, tool.displayStatus, tool.fullVersion || '', toolRequirement.version || ''];
|
||||
return [tool.displayName, tool.description, tool.displayStatus, tool.fullVersion || '', toolRequirement.version || '', tool.installationPath || ''];
|
||||
});
|
||||
|
||||
this._installToolButton.hidden = minVersionCheckFailed || !installationNeeded;
|
||||
@@ -319,7 +322,7 @@ export class ResourceTypePickerDialog extends DialogBase {
|
||||
protected updateToolsDisplayTableData(tool: ITool) {
|
||||
this._toolsTable.data = this._toolsTable.data.map(rowData => {
|
||||
if (rowData[0] === tool.displayName) {
|
||||
return [tool.displayName, tool.description, tool.displayStatus, tool.fullVersion || '', rowData[4]];
|
||||
return [tool.displayName, tool.description, tool.displayStatus, tool.fullVersion || '', rowData[4]/* required version*/, tool.installationPath || ''];
|
||||
} else {
|
||||
return rowData;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user