Skip to content

Commit 8a75a6f

Browse files
committed
Retrieve sample data types from fields API
This allows suites other than nts to work.
1 parent a980860 commit 8a75a6f

File tree

1 file changed

+4
-10
lines changed

1 file changed

+4
-10
lines changed

lnt/server/ui/static/lnt_tableau.js

Lines changed: 4 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -8,15 +8,9 @@
88
// TODO: make the server report types.
99
// Map LNT types to Tableau datatypes.
1010
var col_type_mapper = {
11-
"compile_status": tableau.dataTypeEnum.int,
12-
"execution_status": tableau.dataTypeEnum.int,
13-
"compile_time": tableau.dataTypeEnum.float,
14-
"execution_time": tableau.dataTypeEnum.float,
15-
"score": tableau.dataTypeEnum.int,
16-
"mem_bytes": tableau.dataTypeEnum.int,
17-
"hash_status": tableau.dataTypeEnum.int,
18-
"hash": tableau.dataTypeEnum.string,
19-
"code_size": tableau.dataTypeEnum.int};
11+
"INTEGER": tableau.dataTypeEnum.int,
12+
"FLOAT": tableau.dataTypeEnum.float,
13+
"VARCHAR": tableau.dataTypeEnum.string};
2014

2115
/** Get a json payload from the LNT server asynchronously or error.
2216
* @param {string} payload_url JSON payloads URL.
@@ -108,7 +102,7 @@
108102
sample_cols.push({
109103
id: field.column_name,
110104
alias: field.column_name,
111-
dataType: col_type_mapper[field.column_name]
105+
dataType: col_type_mapper[field.column_type]
112106
});
113107
});
114108

0 commit comments

Comments
 (0)