mirror of
https://github.com/pandorafms/pandorafms.git
synced 2025-09-26 11:29:12 +02:00
#12176 control error legacy
This commit is contained in:
parent
e7ebbedabc
commit
4ce47cec8e
@ -1422,6 +1422,14 @@ class DiscoveryTaskList extends HTML
|
|||||||
$table->rowid = [];
|
$table->rowid = [];
|
||||||
$table->data = [];
|
$table->data = [];
|
||||||
|
|
||||||
|
$countErrors = 1;
|
||||||
|
$tableErrors = new StdClasS();
|
||||||
|
$tableErrors->class = 'databox data';
|
||||||
|
$tableErrors->width = '75%';
|
||||||
|
$tableErrors->styleTable = 'margin: 2em auto 0;border: 1px solid #ddd;background: white;';
|
||||||
|
$tableErrors->rowid = [];
|
||||||
|
$tableErrors->data = [];
|
||||||
|
|
||||||
if ($task['review_mode'] == DISCOVERY_RESULTS) {
|
if ($task['review_mode'] == DISCOVERY_RESULTS) {
|
||||||
$agents_review = db_get_all_rows_filter(
|
$agents_review = db_get_all_rows_filter(
|
||||||
'tdiscovery_tmp_agents',
|
'tdiscovery_tmp_agents',
|
||||||
@ -1474,13 +1482,6 @@ class DiscoveryTaskList extends HTML
|
|||||||
} else if ((int) $task['type'] === DISCOVERY_EXTENSION) {
|
} else if ((int) $task['type'] === DISCOVERY_EXTENSION) {
|
||||||
// Content.
|
// Content.
|
||||||
$countSummary = 1;
|
$countSummary = 1;
|
||||||
$countErrors = 1;
|
|
||||||
$tableErrors = new StdClasS();
|
|
||||||
$tableErrors->class = 'databox data';
|
|
||||||
$tableErrors->width = '75%';
|
|
||||||
$tableErrors->styleTable = 'margin: 2em auto 0;border: 1px solid #ddd;background: white;';
|
|
||||||
$tableErrors->rowid = [];
|
|
||||||
$tableErrors->data = [];
|
|
||||||
if (is_array($task['stats']) === true && count(array_filter(array_keys($task['stats']), 'is_numeric')) === count($task['stats'])) {
|
if (is_array($task['stats']) === true && count(array_filter(array_keys($task['stats']), 'is_numeric')) === count($task['stats'])) {
|
||||||
foreach ($task['stats'] as $key => $summary) {
|
foreach ($task['stats'] as $key => $summary) {
|
||||||
if (is_array($summary) === true) {
|
if (is_array($summary) === true) {
|
||||||
@ -1571,7 +1572,13 @@ class DiscoveryTaskList extends HTML
|
|||||||
$table->data[$i++][1] .= '</span>';
|
$table->data[$i++][1] .= '</span>';
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
$table->data[$i][0] = $task['stats']['summary'];
|
$tableErrors->data[$i][0] = '<b>'.__('Error %s', $countErrors).'</b>';
|
||||||
|
$tableErrors->data[$i][1] = '';
|
||||||
|
$i++;
|
||||||
|
$tableErrors->data[$i][0] = $task['stats']['summary'];
|
||||||
|
$tableErrors->data[$i][1] = '';
|
||||||
|
$countErrors++;
|
||||||
|
$i++;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user