mirror of
https://github.com/Icinga/icingaweb2.git
synced 2025-07-20 04:14:24 +02:00
parent
4a95ba3468
commit
7a7c10e8df
@ -384,12 +384,27 @@ class Monitoring_ListController extends MonitoringController
|
|||||||
|
|
||||||
public function eventhistoryAction()
|
public function eventhistoryAction()
|
||||||
{
|
{
|
||||||
$query = EventHistoryView::fromRequest($this->_request)->getQuery();
|
$query = EventHistoryView::fromRequest(
|
||||||
|
$this->getRequest(),
|
||||||
|
array(
|
||||||
|
'host_name',
|
||||||
|
'service_description',
|
||||||
|
'object_type',
|
||||||
|
'timestamp',
|
||||||
|
'raw_timestamp',
|
||||||
|
'state',
|
||||||
|
'attempt',
|
||||||
|
'max_attempts',
|
||||||
|
'output',
|
||||||
|
'type',
|
||||||
|
'host',
|
||||||
|
'service'
|
||||||
|
)
|
||||||
|
)->getQuery();
|
||||||
$this->handleFormatRequest($query);
|
$this->handleFormatRequest($query);
|
||||||
$this->view->history = $query->paginate();
|
$this->view->history = $query->paginate();
|
||||||
$this->setupSortControl(
|
$this->setupSortControl(
|
||||||
array(
|
array()
|
||||||
)
|
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -52,7 +52,9 @@ class EventHistory extends DataView
|
|||||||
'attempt',
|
'attempt',
|
||||||
'max_attempts',
|
'max_attempts',
|
||||||
'output',
|
'output',
|
||||||
'type'
|
'type',
|
||||||
|
'host',
|
||||||
|
'service'
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -75,34 +77,3 @@ class EventHistory extends DataView
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
=======
|
|
||||||
'type',
|
|
||||||
'host',
|
|
||||||
'service'
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Return the table name
|
|
||||||
*
|
|
||||||
* @return string
|
|
||||||
*/
|
|
||||||
public static function getTableName()
|
|
||||||
{
|
|
||||||
return 'eventhistory';
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Retrieve default sorting rules for particular columns. These involve sort order and potential additional to sort
|
|
||||||
*
|
|
||||||
* @return array
|
|
||||||
*/
|
|
||||||
public function getSortRules()
|
|
||||||
{
|
|
||||||
return array(
|
|
||||||
'raw_timestamp' => array(
|
|
||||||
'order' => self::SORT_DESC
|
|
||||||
)
|
|
||||||
);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
@ -155,7 +155,7 @@ class TabTest extends PHPUnit_Framework_TestCase
|
|||||||
$this->assertEquals(
|
$this->assertEquals(
|
||||||
1,
|
1,
|
||||||
preg_match(
|
preg_match(
|
||||||
'/<li *><i class="icon-myIcon"><\/i> Title text<\/li>/i',
|
'/<li *><i class="myIcon"><\/i> Title text<\/li>/i',
|
||||||
$html
|
$html
|
||||||
),
|
),
|
||||||
'Asserting an url being rendered inside an HTML anchor. got ' . $html
|
'Asserting an url being rendered inside an HTML anchor. got ' . $html
|
||||||
|
Loading…
x
Reference in New Issue
Block a user