diff --git a/src/components/room/lobby.vue b/src/components/room/lobby.vue index c0ddde7..c95b25c 100644 --- a/src/components/room/lobby.vue +++ b/src/components/room/lobby.vue @@ -52,9 +52,10 @@ onMounted(() => { if (detailRoom.value.id) { const data: IRoomSocket = { - roomPin: detailRoom.value.room_pin, - userId: authStore.getUser?.id, - name: 'name', + room_pin: detailRoom.value.room_pin, + room_id: detailRoom.value.id, + user_id: authStore.getUser?.id, + nick_name: 'name', } socketStore.handleCreateRoomData(data) @@ -69,14 +70,16 @@ watch(listMember.value, (val) => { const handleLocked = () => { const data: ILocked = { - roomPin: detailRoom.value.room_pin, + room_pin: detailRoom.value.room_pin, + host_id: authStore.getUser?.id as string, } socketStore.handleLockRoomData(data) } const handleUnlocked = () => { const data: ILocked = { - roomPin: detailRoom.value.room_pin, + room_pin: detailRoom.value.room_pin, + host_id: authStore.getUser?.id as string, } socketStore.handleUnlockRoomData(data) } @@ -90,8 +93,9 @@ const addAvatarOnList = (data: IMember[]) => { const removeMember = (item: IMember) => { const data: IKickMem = { - roomPin: detailRoom.value.room_pin, - socketId: item.new_player.socket_id, + room_pin: detailRoom.value.room_pin, + participant_id: item.new_participant.id, + host_id: authStore.getUser?.id as string, } socketStore.handleKickMember(data) @@ -223,7 +227,7 @@ const copyCode = async () => { >
{{ item.new_player.name }}
+{{ item.new_participant.nick_name }}
- {{ user.name }} + {{ user.nick_name }}
- {{ user.name }} + {{ user.nick_name }}