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