私は2つのテーブルを持っています、1. Students
2.SrkParents.
学生モデルの関係は、
'srkParents' => array(self::HAS_MANY, 'SrkParents', 'studentID'),
SrkParentsモデルの関係は、
'student' => array(self::BELONGS_TO, 'Students', 'studentID'),
ビューは、
<?php $this->widget('zii.widgets.grid.CGridView', array(
'id'=>'students-grid',
'dataProvider'=>$dataProvider,
'filter'=>$model,
'columns'=>array('studentID','status','del',
array('name'=>'SrkParents.fathers_name',
'value'=>'$data->Students->fathers_name',
'type'=>'raw'),
array('class'=>'CButtonColumn',),),));
どこを間違えたのかわかりません。以下のようなエラーが発生します。
Property "Students.Students" is not defined.