📅  最后修改于: 2022-03-11 14:58:51.727000             🧑  作者: Mango
代码示例1
$game->users()->attach($user->id); // add user
$game->users()->attach([1,3,7]); // add multiple users via an array of IDs