Class zhuravljov\yii\queue\debug\Panel

Inheritancezhuravljov\yii\queue\debug\Panel » yii\debug\Panel
Implementsyii\base\ViewContextInterface
Source Code https://github.com/yiisoft/yii2-queue/blob/master/src/debug/Panel.php

Class Panel

Method Details

Hide inherited methods

getDetail() public method

public void getDetail ( )

                public function getDetail()
{
    return Yii::$app->view->render('detail', [
        'jobs' => array_map(function ($serialized) {
            return unserialize($serialized);
        }, $this->data['jobs']),
    ], $this);
}

            
getName() public method

public void getName ( )

                public function getName()
{
    return 'Queue';
}

            
getSummary() public method

public void getSummary ( )

                public function getSummary()
{
    return Yii::$app->view->render('summary', [
        'url' => $this->getUrl(),
        'count' => count($this->data['jobs']),
    ], $this);
}

            
getViewPath() public method

public void getViewPath ( )

                public function getViewPath()
{
    return __DIR__ . '/views';
}

            
init() public method

public void init ( )

                public function init()
{
    parent::init();
    Event::on(Queue::class, Queue::EVENT_ON_PUSH, function (Event $event) {
        $this->_jobs[] = serialize($event->job);
    });
}

            
save() public method

public void save ( )

                public function save()
{
    return ['jobs' => $this->_jobs];
}