mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-02-16 18:46:40 -05:00
Apply changes from Remote Database to sqlproj - mssql changes (#17655)
* update project from database * update project from database * update project from database * Re-adding schemaComparePublishChanges for temporary backcompat * Adding comment for keeping enum values in sync * Correcting enum value Co-authored-by: Noureldine Yehia <t-nyehia@microsoft.com>
This commit is contained in:
@@ -55,11 +55,31 @@ export class SchemaCompareService implements mssql.ISchemaCompareService {
|
||||
}
|
||||
|
||||
public schemaComparePublishChanges(operationId: string, targetServerName: string, targetDatabaseName: string, taskExecutionMode: azdata.TaskExecutionMode): Thenable<azdata.ResultStatus> {
|
||||
const params: contracts.SchemaComparePublishChangesParams = { operationId: operationId, targetServerName: targetServerName, targetDatabaseName: targetDatabaseName, taskExecutionMode: taskExecutionMode };
|
||||
return this.client.sendRequest(contracts.SchemaComparePublishChangesRequest.type, params).then(
|
||||
const params: contracts.SchemaComparePublishDatabaseChangesParams = { operationId: operationId, targetServerName: targetServerName, targetDatabaseName: targetDatabaseName, taskExecutionMode: taskExecutionMode };
|
||||
return this.client.sendRequest(contracts.SchemaComparePublishChangesRequest.type, params).then(undefined,
|
||||
e => {
|
||||
this.client.logFailedRequest(contracts.SchemaComparePublishChangesRequest.type, e); return Promise.resolve(undefined);
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
public schemaComparePublishDatabaseChanges(operationId: string, targetServerName: string, targetDatabaseName: string, taskExecutionMode: azdata.TaskExecutionMode): Thenable<azdata.ResultStatus> {
|
||||
const params: contracts.SchemaComparePublishDatabaseChangesParams = { operationId: operationId, targetServerName: targetServerName, targetDatabaseName: targetDatabaseName, taskExecutionMode: taskExecutionMode };
|
||||
return this.client.sendRequest(contracts.SchemaComparePublishDatabaseChangesRequest.type, params).then(
|
||||
undefined,
|
||||
e => {
|
||||
this.client.logFailedRequest(contracts.SchemaComparePublishChangesRequest.type, e);
|
||||
this.client.logFailedRequest(contracts.SchemaComparePublishDatabaseChangesRequest.type, e);
|
||||
return Promise.resolve(undefined);
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
public schemaComparePublishProjectChanges(operationId: string, targetProjectPath: string, targetFolderStructure: mssql.ExtractTarget, taskExecutionMode: azdata.TaskExecutionMode): Thenable<mssql.SchemaComparePublishProjectResult> {
|
||||
const params: contracts.SchemaComparePublishProjectChangesParams = { operationId: operationId, targetProjectPath: targetProjectPath, targetFolderStructure: targetFolderStructure, taskExecutionMode: taskExecutionMode };
|
||||
return this.client.sendRequest(contracts.SchemaComparePublishProjectChangesRequest.type, params).then(
|
||||
undefined,
|
||||
(e: any) => {
|
||||
this.client.logFailedRequest(contracts.SchemaComparePublishProjectChangesRequest.type, e);
|
||||
return Promise.resolve(undefined);
|
||||
}
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user