Binding multiple models Cakephp

后端 未结 1 1695
轻奢々
轻奢々 2021-01-16 01:10

I am trying to bind 3 models in cakephp.The relation is as follows

Member hasMany Member_Organaization Member_Organisations belongs to Organaizatio

1条回答
  •  礼貌的吻别
    2021-01-16 01:39

    Use recursive the cakephp functionality for this type of purpose.

    In your controller: $this->Member->recursive = 2; use this before your find query.

    Refrence : http://book.cakephp.org/view/1063/recursive

    0 讨论(0)
提交回复
热议问题