Add support for System database package references for SDK-style sql projects (#23309)

* add package reference type for system db references

* Add radio buttons

* hookup

* add test

* handle changing reference type radio buttons

* cleanup

* update strings

* change style to type

* change more places with style to type

* blank lines
This commit is contained in:
Kim Santiago
2023-06-13 13:06:12 -10:00
committed by GitHub
parent 398a91456d
commit 1ff0a07217
12 changed files with 136 additions and 24 deletions

View File

@@ -70,10 +70,11 @@ export class SqlProjectsService extends BaseService implements mssql.ISqlProject
* @param projectUri Absolute path of the project, including .sqlproj
* @param systemDatabase Type of system database
* @param suppressMissingDependencies Whether to suppress missing dependencies
* @param SystemDbReferenceType Type of reference - ArtifactReference or PackageReference
* @param databaseLiteral Literal name used to reference another database in the same server, if not using SQLCMD variables
*/
public async addSystemDatabaseReference(projectUri: string, systemDatabase: mssql.SystemDatabase, suppressMissingDependencies: boolean, databaseLiteral?: string): Promise<azdata.ResultStatus> {
const params: contracts.AddSystemDatabaseReferenceParams = { projectUri: projectUri, systemDatabase: systemDatabase, suppressMissingDependencies: suppressMissingDependencies, databaseLiteral: databaseLiteral };
public async addSystemDatabaseReference(projectUri: string, systemDatabase: mssql.SystemDatabase, suppressMissingDependencies: boolean, SystemDbReferenceType: mssql.SystemDbReferenceType, databaseLiteral?: string): Promise<azdata.ResultStatus> {
const params: contracts.AddSystemDatabaseReferenceParams = { projectUri: projectUri, systemDatabase: systemDatabase, suppressMissingDependencies: suppressMissingDependencies, referenceType: SystemDbReferenceType, databaseLiteral: databaseLiteral };
return await this.runWithErrorHandling(contracts.AddSystemDatabaseReferenceRequest.type, params);
}