Hi,

I need some help! - I've 3 models as following:

User --[ hasMany ]-> Address --[ hasMany ]-> Phone

With the following data, I can save the data into the model 'User' and
'Address' successfully but not for the 'Phone'.

$data = array(
  User => array(
    'uid' => 'myUID',
    'firstname' => 'myFirstName',
    'lastname' => 'myLastName'
  ),

  Address => array(
    0 => array(
      'street' => 'myStreetAddr',
      'zip' => '12345',
      'Phone' => array(
        0 => array(
          'area_code' => '012',
          'number' => '345-6789'
        ),
        1 => array(
          'area_code' => '012',
          'number' => '987-6543'
        ),
      )
    )
  )
);

What is the correct structure to make the data being saved using a
single '$this->User->saveAll($data)' call?

Thanks!

-- 
------------------------------
Chawalit Limsowan
[email protected]

--~--~---------~--~----~------------~-------~--~----~
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