QAQ
This commit is contained in:
@@ -83,6 +83,7 @@
|
||||
import TUIChatConfig from '../config'
|
||||
import { useAuthUser } from '../../../../composables/useAuthUser'
|
||||
import { useUI } from '../../../../utils/use-ui'
|
||||
import { getGroupBanList } from '../../../../api'
|
||||
|
||||
interface IProps {
|
||||
placeholder: string
|
||||
@@ -171,15 +172,23 @@
|
||||
const getMuteTime = async (displayType: ToolbarDisplayType) => {
|
||||
TUIGroupService.getGroupProfile({
|
||||
groupID: props.groupID
|
||||
}).then(res => {
|
||||
}).then(async res => {
|
||||
// muteAllMembers
|
||||
console.log(res.data.group.muteAllMembers)
|
||||
if (res.data.group.muteAllMembers) {
|
||||
// 禁言了
|
||||
showDialog('提示', '当前群组已全员禁言', false)
|
||||
} else {
|
||||
// emits('changeToolbarDisplayType', displayType)
|
||||
// 判断某个成员是不是禁言
|
||||
const list = await getGroupBanList(props.groupID)
|
||||
const show = list.data.MutedAccountList.find(
|
||||
(v: any) => v.Member_Account === tencentUserSig.value.userId
|
||||
)
|
||||
if (show?.Member_Account) {
|
||||
showDialog('提示', '你被禁言了', false)
|
||||
} else {
|
||||
emits('changeToolbarDisplayType', displayType)
|
||||
}
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user