Hi,
I need to display some data (initially read from an external file like csv, using Operations, data saved in the form of ArrayList in a pool variable type of java.lang.Object). In my data file first row - is the headers row, all the rest are just data to display in the table…
I’m using both widgets: **TABLE **and DATA TABLE. Now cases 1 and 2:
Case-1) There is NO problems when the data file has ordinary strings starting from letters (“what ever33”, “header1”, “FirstName” etc): all data rows displayed correctly, both widgets TABLE or DATA TABLE;
Case-2) When the data file has a headers starting from any digit (0…9, something like: “1”, “2nd Name” etc ) - then there is a problems displaying the data in the TABLE widget:
- No data rows displayed, instead all rows are populated with the headers row repeatedly (see example);
widget TABLE properties:
- Headers:
- Content: <variable contains original data set in a ‘key’:‘value’, type of an array of objects, JSON>
- Column keys:
(for DATA TABLE only) - Data source: Variable
Example of input data source:
col1,2,3, 4Start,-5,6x,col7
row1-col1-data,row1-col2-data,row1-col3-data,row1-col4-data,row1-col5-data,row1-col6-data,row1-col7-data
row2-col1-data,row2-col2-data,row2-col3-data,row2-col4-data,row2-col5-data,row2-col6-data,row2-col7-data
row3-col1-data,row3-col2-data,row3-col3-data,row3-col4-data,row3-col5-data,row3-col6-data,row3-col7-data
row4-col1-data,row4-col2-data,row4-col3-data,row4-col4-data,row4-col5-data,row4-col6-data,row4-col7-data
row5-col1-data,row5-col2-data,row5-col3-data,row5-col4-data,row5-col5-data,row5-col6-data,row5-col7-data
This is what we can see in the output table:
col1,2,3, 4Start,-5,6x,col7
row1-col1-data 2 3 {{ $eval(column, row) | uiTranslate }} -5 {{ $eval(column, row) | uiTranslate }} row1-col7-data
row2-col1-data 2 3 {{ $eval(column, row) | uiTranslate }} -5 {{ $eval(column, row) | uiTranslate }} row2-col7-data
row3-col1-data 2 3 {{ $eval(column, row) | uiTranslate }} -5 {{ $eval(column, row) | uiTranslate }} row3-col7-data
row4-col1-data 2 3 {{ $eval(column, row) | uiTranslate }} -5 {{ $eval(column, row) | uiTranslate }} row4-col7-data
row5-col1-data 2 3 {{ $eval(column, row) | uiTranslate }} -5 {{ $eval(column, row) | uiTranslate }} row5-col7-data
Chrome console messages:
vendor.min.js:105 Error: [$parse:syntax] http://errors.angularjs.org/1.3.18/$parse/syntax?p0=Start&p1=is%20an%20unexpected%20token&p2=2&p3=4Start&p4=Start
at vendor.min.js:9
at lb.throwError (vendor.min.js:195)
at lb.parse (vendor.min.js:193)
at vendor.min.js:113
at b.$eval (vendor.min.js:129)
at vendor.min.js:203
at vendor.min.js:198
at Object.<anonymous> (vendor.min.js:111)
at m.$digest (vendor.min.js:126)
at b.$apply (vendor.min.js:130)
Any ideas how to fix this issue?
Many thanks!