[Uptime] Feature/expandable row in details ping list (#51890)

* update columns

* update expand row in ping list
This commit is contained in:
Shahzad 2019-12-10 12:37:57 +01:00 committed by GitHub
parent c4e4da377d
commit f6c44df066
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 13 additions and 9 deletions

View file

@ -67,7 +67,7 @@ exports[`MonitorList component renders a no items message when no data is provid
"name": "",
"render": [Function],
"sortable": true,
"width": "40px",
"width": "24px",
},
]
}
@ -174,7 +174,7 @@ exports[`MonitorList component renders the monitor list 1`] = `
"name": "",
"render": [Function],
"sortable": true,
"width": "40px",
"width": "24px",
},
]
}

View file

@ -67,7 +67,7 @@ exports[`MonitorList component renders a no items message when no data is provid
"name": "",
"render": [Function],
"sortable": true,
"width": "40px",
"width": "24px",
},
]
}
@ -174,7 +174,7 @@ exports[`MonitorList component renders the monitor list 1`] = `
"name": "",
"render": [Function],
"sortable": true,
"width": "40px",
"width": "24px",
},
]
}

View file

@ -208,7 +208,7 @@ export const MonitorListComponent = (props: Props) => {
field: 'monitor_id',
name: '',
sortable: true,
width: '40px',
width: '24px',
isExpander: true,
render: (id: string) => {
return (

View file

@ -145,7 +145,7 @@ exports[`PingList component renders sorted list without errors 1`] = `
"render": [Function],
},
Object {
"align": "right",
"align": "center",
"field": "http.response.status_code",
"name": "Response code",
"render": [Function],
@ -154,10 +154,12 @@ exports[`PingList component renders sorted list without errors 1`] = `
"align": "right",
"isExpander": true,
"render": [Function],
"width": "40px",
"width": "24px",
},
]
}
hasActions={true}
isExpandable={true}
itemId="id"
itemIdToExpandedRowMap={Object {}}
items={

View file

@ -190,7 +190,7 @@ export const PingListComponent = ({
if (hasStatus) {
columns.push({
field: 'http.response.status_code',
align: 'right',
align: 'center',
name: i18n.translate('xpack.uptime.pingList.responseCodeColumnLabel', {
defaultMessage: 'Response code',
}),
@ -200,7 +200,7 @@ export const PingListComponent = ({
columns.push({
align: 'right',
width: '40px',
width: '24px',
isExpander: true,
render: (item: Ping) => (
<EuiButtonIcon
@ -300,6 +300,8 @@ export const PingListComponent = ({
<EuiBasicTable
loading={loading}
columns={columns}
isExpandable={true}
hasActions={true}
items={pings}
itemId="id"
itemIdToExpandedRowMap={itemIdToExpandedRowMap}