mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-02-16 18:46:40 -05:00
Feat/import/language used (#2204)
Updated language used by flat file import
This commit is contained in:
@@ -40,7 +40,7 @@ export class FlatFileWizard {
|
|||||||
}
|
}
|
||||||
|
|
||||||
this.wizard = sqlops.window.modelviewdialog.createWizard(localize('flatFileImport.wizardName', 'Import flat file wizard'));
|
this.wizard = sqlops.window.modelviewdialog.createWizard(localize('flatFileImport.wizardName', 'Import flat file wizard'));
|
||||||
let page1 = sqlops.window.modelviewdialog.createWizardPage(localize('flatFileImport.page1Name', 'New Table Details'));
|
let page1 = sqlops.window.modelviewdialog.createWizardPage(localize('flatFileImport.page1Name', 'Specify Input File'));
|
||||||
let page2 = sqlops.window.modelviewdialog.createWizardPage(localize('flatFileImport.page2Name', 'Preview Data'));
|
let page2 = sqlops.window.modelviewdialog.createWizardPage(localize('flatFileImport.page2Name', 'Preview Data'));
|
||||||
let page3 = sqlops.window.modelviewdialog.createWizardPage(localize('flatFileImport.page3Name', 'Modify Columns'));
|
let page3 = sqlops.window.modelviewdialog.createWizardPage(localize('flatFileImport.page3Name', 'Modify Columns'));
|
||||||
let page4 = sqlops.window.modelviewdialog.createWizardPage(localize('flatFileImport.page4Name', 'Summary'));
|
let page4 = sqlops.window.modelviewdialog.createWizardPage(localize('flatFileImport.page4Name', 'Summary'));
|
||||||
|
|||||||
@@ -136,18 +136,18 @@ export class ModifyColumnsPage extends ImportPage {
|
|||||||
width: '150px',
|
width: '150px',
|
||||||
isReadOnly: false
|
isReadOnly: false
|
||||||
}, {
|
}, {
|
||||||
displayName: localize('flatFileImport.dataType', 'Data type'),
|
displayName: localize('flatFileImport.dataType', 'Data Type'),
|
||||||
valueType: sqlops.DeclarativeDataType.editableCategory,
|
valueType: sqlops.DeclarativeDataType.editableCategory,
|
||||||
width: '150px',
|
width: '150px',
|
||||||
isReadOnly: false,
|
isReadOnly: false,
|
||||||
categoryValues: this.categoryValues
|
categoryValues: this.categoryValues
|
||||||
}, {
|
}, {
|
||||||
displayName: localize('flatFileImport.primaryKey', 'Primary key'),
|
displayName: localize('flatFileImport.primaryKey', 'Primary Key'),
|
||||||
valueType: sqlops.DeclarativeDataType.boolean,
|
valueType: sqlops.DeclarativeDataType.boolean,
|
||||||
width: '100px',
|
width: '100px',
|
||||||
isReadOnly: false
|
isReadOnly: false
|
||||||
}, {
|
}, {
|
||||||
displayName: localize('flatFileImport.allowNull', 'Allow null'),
|
displayName: localize('flatFileImport.allowNulls', 'Allow Nulls'),
|
||||||
valueType: sqlops.DeclarativeDataType.boolean,
|
valueType: sqlops.DeclarativeDataType.boolean,
|
||||||
isReadOnly: false,
|
isReadOnly: false,
|
||||||
width: '100px'
|
width: '100px'
|
||||||
|
|||||||
@@ -42,7 +42,7 @@ export class ProsePreviewPage extends ImportPage {
|
|||||||
this.form = this.view.modelBuilder.formContainer().withFormItems([
|
this.form = this.view.modelBuilder.formContainer().withFormItems([
|
||||||
{
|
{
|
||||||
component: this.table,
|
component: this.table,
|
||||||
title: localize('flatFileImport.prosePreviewMessage', 'This operation analyzed the input file structure to generate the preview below'),
|
title: localize('flatFileImport.prosePreviewMessage', 'This operation analyzed the input file structure to generate the preview below for up to the first 50 rows.'),
|
||||||
actions: [this.refresh]
|
actions: [this.refresh]
|
||||||
}
|
}
|
||||||
]).component();
|
]).component();
|
||||||
|
|||||||
@@ -67,11 +67,11 @@ export class SummaryPage extends ImportPage {
|
|||||||
private populateTable() {
|
private populateTable() {
|
||||||
this.table.updateProperties({
|
this.table.updateProperties({
|
||||||
data: [
|
data: [
|
||||||
['Server name', this.model.server.providerName],
|
[localize('flatFileImport.serverName', 'Server name'), this.model.server.providerName],
|
||||||
['Database name', this.model.database],
|
[localize('flatFileImport.databaseName', 'Database name'), this.model.database],
|
||||||
['Table name', this.model.table],
|
[localize('flatFileImport.tableName', 'Table name'), this.model.table],
|
||||||
['Table schema', this.model.schema],
|
[localize('flatFileImport.tableSchema', 'Table schema'), this.model.schema],
|
||||||
['File to be imported', this.model.filePath]],
|
[localize('flatFileImport.fileImport', 'File to be imported'), this.model.filePath]],
|
||||||
columns: ['Object type', 'Name'],
|
columns: ['Object type', 'Name'],
|
||||||
width: 600,
|
width: 600,
|
||||||
height: 200
|
height: 200
|
||||||
@@ -115,9 +115,9 @@ export class SummaryPage extends ImportPage {
|
|||||||
// TODO: When sql statements are in, implement this.
|
// TODO: When sql statements are in, implement this.
|
||||||
//let rows = await this.getCountRowsInserted();
|
//let rows = await this.getCountRowsInserted();
|
||||||
//if (rows < 0) {
|
//if (rows < 0) {
|
||||||
updateText = localize('flatFileImport.success.norows', '✔ Awesome! You have successfully inserted the data into a table.');
|
updateText = localize('flatFileImport.success.norows', '✔ You have successfully inserted the data into a table.');
|
||||||
//} else {
|
//} else {
|
||||||
//updateText = localize('flatFileImport.success.rows', '✔ Awesome! You have successfully inserted {0} rows.', rows);
|
//updateText = localize('flatFileImport.success.rows', '✔ You have successfully inserted {0} rows.', rows);
|
||||||
//}
|
//}
|
||||||
}
|
}
|
||||||
this.statusText.updateProperties({
|
this.statusText.updateProperties({
|
||||||
|
|||||||
Reference in New Issue
Block a user