1
0
Fork 0
mirror of https://git.rwth-aachen.de/acs/public/villas/web/ synced 2025-03-09 00:00:01 +01:00

Add state updated column to simulator table

This commit is contained in:
Markus Grigull 2018-06-07 21:17:13 +02:00
parent d3364ed010
commit 3e1edcd2a3

View file

@ -199,6 +199,12 @@ class Simulators extends Component {
return 'offline';
}
stateUpdateModifier = updatedAt => {
const date = new Date(updatedAt);
return date.toLocaleString('de-DE');
}
render() {
const buttonStyle = {
marginLeft: '10px'
@ -212,7 +218,7 @@ class Simulators extends Component {
<TableColumn checkbox onChecked={(index, event) => this.onSimulatorChecked(index, event)} width='30' />
<TableColumn title='Name' dataKeys={['properties.name', 'rawProperties.name']} />
<TableColumn title='State' dataKey='state' labelKey='state' labelModifier={this.stateLabelModifier} labelStyle={this.stateLabelStyle} />
<TableColumn title='Model' dataKey='model' />
<TableColumn title='State Update' dataKey='stateUpdatedAt' modifier={this.stateUpdateModifier} />
<TableColumn title='Endpoint' dataKeys={['properties.endpoint', 'rawProperties.endpoint']} />
<TableColumn title='Host' dataKey='host' />
<TableColumn title='UUID' dataKey='uuid' />