belongsTo('\app\rongyu\model\JsRongyu','rongyuid','id'); } // 教师关联 public function teacher() { return $this->belongsTo('\app\renshi\model\Teacher','teacherid','id'); } }