hasOne(Etablissement::className(), ['id'=>'id_etablissement']) ; } /** * @inheritdoc */ public function rules() { return [ [['date'], 'required'], [['date'], 'safe'], [['actif'], 'integer'] ]; } /** * @inheritdoc */ public function attributeLabels() { return [ 'id' => 'ID', 'date' => 'Date', 'actif' => 'Actif', ]; } }