mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-02-17 02:51:36 -05:00
use culture invariant display value for number conversion
This commit is contained in:
@@ -231,7 +231,7 @@ export class InsightsWidget extends DashboardWidget implements IDashboardWidget,
|
|||||||
if (componentInstance.setConfig) {
|
if (componentInstance.setConfig) {
|
||||||
componentInstance.setConfig(this.insightConfig.type[this._typeKey]);
|
componentInstance.setConfig(this.insightConfig.type[this._typeKey]);
|
||||||
}
|
}
|
||||||
componentInstance.data = { columns: result.columnInfo.map(item => item.columnName), rows: result.rows.map(row => row.map(item => item.displayValue)) };
|
componentInstance.data = { columns: result.columnInfo.map(item => item.columnName), rows: result.rows.map(row => row.map(item => (item.invariantCultureDisplayValue === null || item.invariantCultureDisplayValue === undefined) ? item.displayValue : item.invariantCultureDisplayValue)) };
|
||||||
|
|
||||||
if (componentInstance.init) {
|
if (componentInstance.init) {
|
||||||
componentInstance.init();
|
componentInstance.init();
|
||||||
|
|||||||
@@ -329,7 +329,7 @@ export class ChartViewerComponent implements OnInit, OnDestroy, IChartViewAction
|
|||||||
this._executeResult = <IInsightData>{};
|
this._executeResult = <IInsightData>{};
|
||||||
this._executeResult.columns = dataSet.columnDefinitions.map(def => def.name);
|
this._executeResult.columns = dataSet.columnDefinitions.map(def => def.name);
|
||||||
this._executeResult.rows = dataSet.dataRows.getRange(0, dataSet.dataRows.getLength()).map(gridRow => {
|
this._executeResult.rows = dataSet.dataRows.getRange(0, dataSet.dataRows.getLength()).map(gridRow => {
|
||||||
return gridRow.values.map(cell => cell.displayValue);
|
return gridRow.values.map(cell => (cell.invariantCultureDisplayValue === null || cell.invariantCultureDisplayValue === undefined) ? cell.displayValue : cell.invariantCultureDisplayValue);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
1
src/sql/sqlops.d.ts
vendored
1
src/sql/sqlops.d.ts
vendored
@@ -816,6 +816,7 @@ declare module 'sqlops' {
|
|||||||
export interface DbCellValue {
|
export interface DbCellValue {
|
||||||
displayValue: string;
|
displayValue: string;
|
||||||
isNull: boolean;
|
isNull: boolean;
|
||||||
|
invariantCultureDisplayValue: string;
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface ResultSetSubset {
|
export interface ResultSetSubset {
|
||||||
|
|||||||
Reference in New Issue
Block a user