On Jul 11, 12:26 pm, hinge <[EMAIL PROTECTED]> wrote:
> Hi
>
> I have a question...
>
> I have tow models :
>
> class Bankpost extends AppModel
> {
> var $name = 'Bankpost';
> var $belongsTo = 'Category';
> var $recursive = 0;
>
> }
class Bankpost extends AppModel {
var $name = 'Bankpost';
var $belongsTo = array(
'Category',
'ParentCat' => array(
'className' => 'Category',
'foreignKey' => false,
'conditions' => array('ParentCat.id =
Category.parent_id')
),
);
var $recursive = 0;
}
Try that or something v. similar
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---