Advertisement
Guest User

Untitled

a guest
Mar 1st, 2017
68
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.49 KB | None | 0 0
  1. public function worklist()
  2. {
  3.  
  4. $worklist = TableRegistry::get('Fincas');
  5. $query = $worklist
  6. ->find()
  7. ->select(['id', 'prov', 'municipio', 'paraje', 'poligono', 'parcela', 'f_ult_poda' , 'f_ult_recog' ]);
  8.  
  9. foreach ($query as $worklist) {
  10. if ( $worklist->f_ult_poda > $worklist->f_ult_recog )
  11. debug($worklist); //it works fine
  12. }
  13.  
  14. $this->set('finca', $this->$query); //I have tried also $this->$worklist
  15.  
  16. }
  17.  
  18. <?php debug($finca);?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement