show all failed connections in report

This commit is contained in:
Oliver Gorwits
2017-05-23 20:55:14 +01:00
parent ffce3cee84
commit b5e32c219d
2 changed files with 6 additions and 2 deletions

View File

@@ -14,8 +14,10 @@ register_admin_task({
ajax '/ajax/content/admin/timedoutdevices' => require_role admin => sub {
my @results = schema('netdisco')->resultset('DeviceSkip')->search({
deferrals => { '>=' => setting('workers')->{'max_deferrals'} }
},{ order_by => { -asc => [qw/backend device/] } })->hri->all;
deferrals => { '>' => 0 }
},{ order_by =>
[{ -desc => 'deferrals' }, { -asc => [qw/device backend/] }]
})->hri->all;
content_type('text/html');
template 'ajax/admintask/timedoutdevices.tt', {

View File

@@ -6,6 +6,7 @@
<tr>
<th class="nd_center-cell">Poller Host</th>
<th class="nd_center-cell">Device</th>
<th class="nd_center-cell">Failed Connections</th>
</tr>
</thead>
</tbody>
@@ -14,6 +15,7 @@
<td class="nd_center-cell">[% row.backend | html_entity %]</td>
<td class="nd_center-cell"><a class="nd_linkcell"
href="[% uri_for('/device') %]?q=[% row.device | uri %]">[% row.device | html_entity %]</a></td>
<td class="nd_center-cell">[% row.deferrals | html_entity %]</td>
</tr>
[% END %]
</tbody>