Aufgrund einer Wartung wird GitLab am 29.10. zwischen 9:00 und 10:00 Uhr kurzzeitig nicht zur Verfügung stehen. / Due to maintenance, GitLab will be temporarily unavailable on 29.10. between 9:00 and 10:00 am.

Commit 3c055ebe authored by Laura Fuentes Grau's avatar Laura Fuentes Grau

Table Widget now displays 'no entries' when it contains no elements

parent e43c780b
......@@ -92,6 +92,14 @@ class WidgetTable extends Component {
}
render() {
let rows = this.state.rows;
if(rows.length === 0){
rows.push({
name: "no entries"
})
}
var columns = [
<TableColumn key={1} title="Signal" dataKey="name" width={120} />,
<TableColumn key={2} title="Value" dataKey="value" modifier={format('.4s')} />
......@@ -102,7 +110,7 @@ class WidgetTable extends Component {
return (
<div className="table-widget">
<Table data={this.state.rows}>
<Table data={rows}>
{ columns }
</Table>
</div>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment