Wednesday, August 29, 2012

Re: Paginate Multiple Models in the same view

Hi everyone.

I did this:

$this->paginate = array( 
            'limit' => 10, 
            'conditions' => array(' Model1 .eliminado'=>'0'), 
  ); 
            $model1 = $this->paginate('Model1'); 

$this->paginate = array( 
                'limit' => 10, 
 ); 
            $model2= $this->paginate(' Model2'); 

$this->set(compact(' model1  ',' model2 '));


And that works for me, i hope this ccan help you!

--
You received this message because you are subscribed to the Google Groups "CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com.
To unsubscribe from this group, send email to cake-php+unsubscribe@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php?hl=en-US.
 
 

No comments: