Revision: 70158
Updated Code
at December 4, 2015 01:47 by guimarca
Updated Code
public function getLab() { return $this->hasOne(Lab::className(), ['id' => 'id_lab'] );} 'lab.name_lab',
Revision: 70157
Initial Code
Initial URL
Initial Description
Initial Title
Initial Tags
Initial Language
at December 3, 2015 23:20 by guimarca
Initial Code
public function getLab() { return $this->hasOne(Lab::className(), ['id_lab' => 'id_lab'] );} 'lab.name_lab',
Initial URL
Initial Description
The 1stline in the function that generates the Foreign key relation in the model, 2nd is the name of the attribute in the gridview
Initial Title
Yii2 Gridview Foreign Key
Initial Tags
php
Initial Language
PHP