0
以下のステートメントのリレーショナル・データをwith文を使用して呼び出すにはどうすればよいですか。リストと他のモデルとのコール・コレクション
$suppliers = Supplier::with('user')->lists('user.company', 'user.id'); // doesn't work
class Supplier extends Model
{
protected $table = "suppliers";
protected $fillable = ['email'];
public function user() {
return $this->belongsTo('App\User', 'email', 'email');
}
}