* @since 2.0 */ class LogPanel extends Panel { public function getName() { return 'Logs'; } public function getSummary() { $count = count($this->data['messages']); return << Log messages: $count EOD; } public function getDetail() { return '

Logs

'; } public function save() { return array( 'messages' => Yii::$app->getLog()->targets['debug']->messages, ); } }