Hi mate, this code is for 1.2:

$this->User->find('all', array(
   'conditions' => array(
     'User.id' => $this->Auth->user('id'),
     'ListOffer.id' => $offerid
   )
));

Petr
http://blog.pepa.info/

Dne 16.11.2008 19:06, thatsgreat2345 napsal(a):
> I have a HABTM association between user and listoffer however when I
> run
> $this->User->findAll(array('User.id'=>$this->Auth->user
> ('id'),'ListOffer.id'=>$offerid));
> the debug doesn't show the sql for grabbing the ListOffer, and so it
> wont get the offer for that userid has completed. So is there some way
> to add a where statement on a HABTM association.
> > 

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to