Update default values for Owner and Collation in Create Database dialog (#23332)

This commit is contained in:
Cory Rivera
2023-06-07 09:47:16 -07:00
committed by GitHub
parent a1ab537094
commit 9dcb7e4ee5
2 changed files with 3 additions and 1 deletions

View File

@@ -1,6 +1,6 @@
{ {
"downloadUrl": "https://github.com/Microsoft/sqltoolsservice/releases/download/{#version#}/microsoft.sqltools.servicelayer-{#fileName#}", "downloadUrl": "https://github.com/Microsoft/sqltoolsservice/releases/download/{#version#}/microsoft.sqltools.servicelayer-{#fileName#}",
"version": "4.8.0.16", "version": "4.8.0.17",
"downloadFileNames": { "downloadFileNames": {
"Windows_86": "win-x86-net7.0.zip", "Windows_86": "win-x86-net7.0.zip",
"Windows_64": "win-x64-net7.0.zip", "Windows_64": "win-x64-net7.0.zip",

View File

@@ -35,6 +35,7 @@ export class DatabaseDialog extends ObjectManagementDialogBase<ObjectManagement.
containers.push(this.createLabelInputContainer(localizedConstants.NameText, this._nameInput)); containers.push(this.createLabelInputContainer(localizedConstants.NameText, this._nameInput));
if (this.viewInfo.loginNames?.length > 0) { if (this.viewInfo.loginNames?.length > 0) {
this.objectInfo.owner = this.viewInfo.loginNames[0];
let ownerDropbox = this.createDropdown(localizedConstants.OwnerText, async () => { let ownerDropbox = this.createDropdown(localizedConstants.OwnerText, async () => {
this.objectInfo.owner = ownerDropbox.value as string; this.objectInfo.owner = ownerDropbox.value as string;
}, this.viewInfo.loginNames, this.viewInfo.loginNames[0]); }, this.viewInfo.loginNames, this.viewInfo.loginNames[0]);
@@ -47,6 +48,7 @@ export class DatabaseDialog extends ObjectManagementDialogBase<ObjectManagement.
private initializeOptionsSection(): azdata.GroupContainer { private initializeOptionsSection(): azdata.GroupContainer {
let containers: azdata.Component[] = []; let containers: azdata.Component[] = [];
if (this.viewInfo.collationNames?.length > 0) { if (this.viewInfo.collationNames?.length > 0) {
this.objectInfo.collationName = this.viewInfo.collationNames[0];
let collationDropbox = this.createDropdown(localizedConstants.CollationText, async () => { let collationDropbox = this.createDropdown(localizedConstants.CollationText, async () => {
this.objectInfo.collationName = collationDropbox.value as string; this.objectInfo.collationName = collationDropbox.value as string;
}, this.viewInfo.collationNames, this.viewInfo.collationNames[0]); }, this.viewInfo.collationNames, this.viewInfo.collationNames[0]);