mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-01-21 17:22:55 -05:00
Apply changes from remote database to sqlproj - sql-database-projects changes (#17738)
* update project from database * update project from database * Leftover merge update * Slight refactor to add vscode entrypoints * Re-adding leftover schemacompare bits that reference database project changes * Removing unnecessary function * Addiung GetDSP command to package.json * tests and a race condition fix * remove custom UUID generation code * swapping awaits for voids on promises * PR feedback * PR feedback * Hide update project command from vscode * Swapping cross-extension commands for bound extension contract * Re-adding schema compare radio buttons for sqlproj * Adding refresh after project update * Populating list of project scripts just before comparison to avoid missing script errors of project was separately edited * Adding missing await for okay button enable check * Correcting schema compare source when populated from a project * Rename UpdateDataModel to be more clear * Fix incorrectly changed type * Added new runComparison schema compare command, hooked up to sqlproj extension * Added progress indicator for "apply now" option * moved string literal to constant * Added missing await * Setting missing "saveScmpButton" state to fix test * Revert "Setting missing "saveScmpButton" state to fix test" This reverts commit 55612c9def24ac9e3398f5bbd153d21d9d3ca37f. * Removing preemptive resetWindow() call * general cleanup * PR feedback * property renames * Reverting rename; requires Tools Service change first * Adding header to updateProject * Adding missing header * PR feedback * adding missing await * Handing race condition for UI enable * Fixing broken okay enable case * Fixing enum comparison wonk Co-authored-by: Noureldine Yehia <t-nyehia@microsoft.com>
This commit is contained in:
@@ -62,7 +62,9 @@ export const at = localize('at', "at");
|
||||
// commands
|
||||
export const revealFileInOsCommand = 'revealFileInOS';
|
||||
export const schemaCompareStartCommand = 'schemaCompare.start';
|
||||
export const schemaCompareRunComparisonCommand = 'schemaCompare.runComparison';
|
||||
export const vscodeOpenCommand = 'vscode.open';
|
||||
export const refreshDataWorkspaceCommand = 'dataworkspace.refresh';
|
||||
|
||||
// UI Strings
|
||||
|
||||
@@ -241,6 +243,7 @@ export const targetProject = localize('targetProject', "Target project");
|
||||
export const createProjectSettings = localize('createProjectSettings', "Settings");
|
||||
export const projectNameLabel = localize('projectNameLabel', "Name");
|
||||
export const projectNamePlaceholderText = localize('projectNamePlaceholderText', "Enter project name");
|
||||
export const projectLocationLabel = localize('projectLocationLabel', "Location");
|
||||
export const projectLocationPlaceholderText = localize('projectLocationPlaceholderText', "Select location to create project");
|
||||
export const browseButtonText = localize('browseButtonText', "Browse folder");
|
||||
export const selectFolderStructure = localize('selectFolderStructure', "Select folder structure");
|
||||
@@ -251,9 +254,28 @@ export const selectProjectLocation = localize('selectProjectLocation', "Select p
|
||||
export const ProjectParentDirectoryNotExistError = (location: string): string => { return localize('dataworkspace.projectParentDirectoryNotExistError', "The selected project location '{0}' does not exist or is not a directory.", location); };
|
||||
export const ProjectDirectoryAlreadyExistError = (projectName: string, location: string): string => { return localize('dataworkspace.projectDirectoryAlreadyExistError', "There is already a directory named '{0}' in the selected location: '{1}'.", projectName, location); };
|
||||
|
||||
// Update Project From Database dialog strings
|
||||
|
||||
export const updateProjectFromDatabaseDialogName = localize('updateProjectFromDatabaseDialogName', "Update project from database");
|
||||
export const updateText = localize('updateText', "Update");
|
||||
export const noSqlProjFile = localize('noSqlProjFile', "The selected project file does not exist");
|
||||
export const noSchemaCompareExtension = localize('noSchemaCompareExtension', "The Schema Compare extension must be installed to a update a project from a database.");
|
||||
export const projectToUpdatePlaceholderText = localize('projectToUpdatePlaceholderText', "Select project file");
|
||||
export const updateAction = localize('updateAction', "Update action");
|
||||
export const compareActionRadioButtonLabel = localize('compareActionRadiButtonLabel', "View changes in Schema Compare");
|
||||
export const updateActionRadioButtonLabel = localize('updateActionRadiButtonLabel', "Apply all changes");
|
||||
export const actionLabel = localize('actionLabel', "Action");
|
||||
|
||||
// Update project from database
|
||||
|
||||
export const applySuccess = localize('applySuccess', "Project was successfully updated.");
|
||||
export const equalComparison = localize('equalComparison', "The project is already up to date with the database.");
|
||||
export function applyError(errorMessage: string): string { return localize('applyError', "There was an error updating the project: {0}", errorMessage); }
|
||||
export function updatingProjectFromDatabase(projectName: string, databaseName: string): string { return localize('updatingProjectFromDatabase', "Updating {0} from {1}...", projectName, databaseName); }
|
||||
|
||||
// Error messages
|
||||
|
||||
export function compareErrorMessage(errorMessage: string): string { return localize('schemaCompare.compareErrorMessage', "Schema Compare failed: {0}", errorMessage ? errorMessage : 'Unknown'); }
|
||||
export const multipleSqlProjFiles = localize('multipleSqlProjFilesSelected', "Multiple .sqlproj files selected; please select only one.");
|
||||
export const noSqlProjFiles = localize('noSqlProjFilesSelected', "No .sqlproj file selected; please select one.");
|
||||
export const noDataSourcesFile = localize('noDataSourcesFile', "No {0} found", dataSourcesFileName);
|
||||
|
||||
@@ -20,6 +20,9 @@ export namespace cssStyles {
|
||||
export const createProjectFromDatabaseLabelWidth = '110px';
|
||||
export const createProjectFromDatabaseTextboxWidth = '310px';
|
||||
|
||||
export const updateProjectFromDatabaseLabelWidth = '110px';
|
||||
export const updateProjectFromDatabaseTextboxWidth = '310px';
|
||||
|
||||
// font-styles
|
||||
export namespace fontStyle {
|
||||
export const normal = 'normal';
|
||||
|
||||
Reference in New Issue
Block a user