Thanks for your input. It looks like below. I think I may have the Model name
in the wrong place?? I'm using: echo $form->create('Rental', array('type' =>
'file', 'action' => 'edit'));  to create the form.

Array
(
    [Rental] => Array
        (
            [id] => 60
            [rental_code] => code
            [location_id] => 37
            [rental_agent] => [email protected]
            [rental_meta_title] => meta title
            [rental_meta_desc] => meta desc
            [rental_meta_tags] => meta kewords
            [rental_short_title] => location title
            [rental_short_desc] => location desc
            [rental_title] => prop title
            [rental_location] => prop location desc
            [rental_description] => prop desc
            [rental_features] => feature list
            [rental_reviews] => review link
            [rental_availability] => availability link
            [rental_gallery] => slideshow link
            [rental_weather] => weather widget
            [rental_extra_info] => extra info
            [Rate/s1_title] => 1
            [Rate/s1_day] => 
            [Rate/s1_week] => 
            [Rate/s1_month] => 
            [Rate/s2_title] => 
            [Rate/s2_day] => 
            [Rate/s2_week] => 
            [Rate/s2_month] => 
            [Rate/s3_title] => 
            [Rate/s3_day] => 
            [Rate/s3_week] => 
            [Rate/s3_month] => 
            [Rate/s4_title] => 
            [Rate/s4_day] => 
            [Rate/s4_week] => 
            [Rate/s4_month] => 
            [Rate/extra_info] => 
            [rental_short_thumb] => holder.gif
        )

)



John Andersen-6 wrote:
> 
> How does your data look like before the saveAll statement?
> Enjoy,
>    John
> 
> On Jan 14, 12:41 am, koala kid <[email protected]> wrote:
>> Hi all,
>>
>> using ORM for the first time and I'm having trouble getting my
>> associations
>> all worked out. I'm unable to get my associated table data to save.Here's
>> a
>> basic overview of my models:
>>
>> Locations -> Parent
>> Rentals -> Belongs to Locations
>> Rates -> Belongs to Rentals
>>
>> My code looks like this:
>>
>> <?php
>> class Rental extends AppModel
>> {
>>        var $name = 'Rental';
>>
>>        var $hasOne = array(
>>        'Rate' => array(
>>            'className'    => 'Rate',
>>            'dependent'    => true
>>        )
>>    );
>>        var $belongsTo = array(
>>        'Location' => array(
>>            'className'         => 'Location',
>>            'fields'            => 'city'
>>        )
>>    );
>>
>> }
>>
>> ?>
>>
>> class Rate extends AppModel
>> {
>>        var $name = 'Rate';
>>
>>        var $belongsTo = 'Rentals';
>>
>> }
>>
>> And my save looks like this:
>>
>> $this->Rental->saveAll($this->data)
>>
>> However only data to the Rental table is being saved and not to the Rate
>> table. Can anyone tell me what I am missing. I don't have a controller
>> for
>> Rates as there are no direct functions to run against them, does this
>> matter?
>>
>> Thanks.
>> --
>> View this message in
>> context:http://old.nabble.com/Unable-to-save-related-table-information-tp2715...
>> Sent from the CakePHP mailing list archive at Nabble.com.
> 
> 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
> 
> 

-- 
View this message in context: 
http://old.nabble.com/Unable-to-save-related-table-information-tp27153345p27170133.html
Sent from the CakePHP mailing list archive at Nabble.com.

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