Have a read of this thread...might help.

http://groups.google.com/group/cake-php/browse_thread/thread/e01fd12a9d986d4/9fe7a541c10fc919?lnk=gst&q=Manipulating+Data+Based+on+Non+Related+Model+Data#9fe7a541c10fc919

Jeremy Burns
[email protected]
(Skype) +44 208 123 3822 (jeremy_burns)
(m) +44 7973 481949
(h) +44 208 530 7573

On 16 Apr 2010, at 09:44, mivogt-LU wrote:

> I also tried adding var $uses = array('customer','request');  in the
> bookings controller.
> If I do so I get an error inside my find commands:
> 
> if ($rid)     {       $customers = $this->Booking->Customer-
>> find('list',array('conditions' => array('Customer.id' => $cid)));            
>> }
>                       else    {       $customers = 
> $this->Booking->Customer->find('list');
> 
> $rid is the request id passed from request index list to the add
> function of bookings
> $cid is the customer id passed from request index list to the add
> function of bookings
> 
> error:
> Notice (8): Undefined property: BookingsController::$Booking [APP
> \controllers\bookings_controller.php, line 31]
> Code | Context
> 
>        }
> 
> 
> 
>        if ($rid)     {    $customers = $this->Booking->Customer-
>> find('list',array('conditions' => array('Customer.id' =>
> $cid)));        }
> 
> $rid  =       "15"
> $cid  =       "12"
> $nid  =       "R-1271-3641-04"
> 
> BookingsController::add() - APP\controllers\bookings_controller.php,
> line 31
> Dispatcher::_invoke() - CORE\cake\dispatcher.php, line 202
> Dispatcher::dispatch() - CORE\cake\dispatcher.php, line 170
> [main] - APP\webroot\index.php, line 83
> 
> Notice (8): Trying to get property of non-object [APP\controllers
> \bookings_controller.php, line 31]
> 
> Check out the new CakePHP Questions site http://cakeqs.org and help others 
> with their CakePHP related questions.
> 
> 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

Check out the new CakePHP Questions site http://cakeqs.org and help others with 
their CakePHP related questions.

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