fix: rewrite backend hooks, fix invitation flow, align frontend API, fix component naming
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
@@ -21,12 +21,18 @@ const idleMembers = computed(() =>
|
||||
)
|
||||
|
||||
async function inviteMember(userId: string, username: string) {
|
||||
const { getActiveTeamSession } = await import('@/api/sessions')
|
||||
const session = await getActiveTeamSession()
|
||||
|
||||
if (!session) {
|
||||
ElMessage.warning('请先创建临时小组')
|
||||
return
|
||||
}
|
||||
|
||||
try {
|
||||
// 这里需要先创建临时小组,或者检查是否有活跃的临时小组
|
||||
// 简化版本:发送邀请
|
||||
await sendInvitation({
|
||||
to: userId,
|
||||
teamSession: '' // 实际使用时需要先创建临时小组
|
||||
teamSession: session.id
|
||||
})
|
||||
ElMessage.success(`已邀请 ${username}`)
|
||||
} catch (error: any) {
|
||||
|
||||
Reference in New Issue
Block a user