Devise\Support\Sortable\Manager::addToStack PHP Метод

addToStack() публичный Метод

public addToStack ( $all )
$all
    public function addToStack($all)
    {
        $newSort = array_only($all, array('dir', 'orderBy', 'relationship'));
        $cookie = $this->getStack();
        $cookie = $this->setCookie($all, $cookie, $newSort);
        $this->writeCookie($cookie);
    }

Usage Example

Пример #1
0
 public function test_it_adds_to_stack()
 {
     $Framework = new \Devise\Support\Framework();
     $Framework->Session = m::mock('Mock\\Session');
     $Framework->Session->shouldReceive('get')->times(1)->andReturn([]);
     $Framework->Session->shouldReceive('put')->times(1);
     $Manager = new Manager($Framework);
     $Manager->addToStack([]);
 }
All Usage Examples Of Devise\Support\Sortable\Manager::addToStack