Array ( [0] => Array ( [Venue] => Array ( [id] => 6 ) [Review] => Array ( [0] => Array ( [id] => 9 [rating] => 4 [venue_id] => 6 ) [1] => Array ( [id] => 10 [rating] => 3 [venue_id] => 6 ) [2] => Array ( [id] => 11 [rating] => 3 [venue_id] => 6 ) ) ) [1] => Array ( [Venue] => Array ( [id] => 15 ) [Review] => Array ( [0] => Array ( [id] => 16 [rating] => 5 [venue_id] => 15 ) [1] => Array ( [id] => 17 [rating] => 4 [venue_id] => 15 ) ) ) [2] => Array ( [Venue] => Array ( [id] => 17 ) [Review] => Array ( [0] => Array ( [id] => 15 [rating] => 4 [venue_id] => 17 ) ) ) [3] => Array ( [Venue] => Array ( [id] => 31 ) [Review] => Array ( ) ) [4] => Array ( [Venue] => Array ( [id] => 32 ) [Review] => Array ( [0] => Array ( [id] => 18 [rating] => 1 [venue_id] => 32 ) [1] => Array ( [id] => 19 [rating] => 1 [venue_id] => 32 ) [2] => Array ( [id] => 20 [rating] => 1 [venue_id] => 32 ) [3] => Array ( [id] => 21 [rating] => 1 [venue_id] => 32 ) [4] => Array ( [id] => 22 [rating] => 1 [venue_id] => 32 ) ) ) )
if ($order == 'popularity') { $order = array('COUNT(Review) DESC'); } $this->Paginator->settings = array('conditions' => $conditions, 'limit' => 10, 'order' => $order, 'page' => @$data['page']); $sqql = $this->Paginator->paginate('Venue');
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)