QAQ
This commit is contained in:
@@ -86,6 +86,10 @@
|
||||
import { ref, computed } from 'vue'
|
||||
import { useLiveListState } from '@/uni_modules/tuikit-atomic-x/state/LiveListState'
|
||||
import { useLiveAudienceState } from '@/uni_modules/tuikit-atomic-x/state/LiveAudienceState'
|
||||
import { useUI } from '../../../../utils/use-ui'
|
||||
import { getUserBanList, getUserAdminList } from '../../../../api'
|
||||
|
||||
const { showLoading, hideLoading } = useUI()
|
||||
const { currentLive } = useLiveListState()
|
||||
const {
|
||||
setAdministrator,
|
||||
@@ -124,6 +128,30 @@
|
||||
emit('update:modelValue', false)
|
||||
}
|
||||
|
||||
/** 获取禁言列表 */
|
||||
const getBanList = async () => {
|
||||
try {
|
||||
showLoading()
|
||||
const res = await getUserBanList(uni?.$liveID)
|
||||
console.log('禁言列表=====', res)
|
||||
hideLoading()
|
||||
} catch (err) {
|
||||
hideLoading()
|
||||
}
|
||||
}
|
||||
|
||||
/** 获取管理员列表 */
|
||||
const getAdminList = async () => {
|
||||
try {
|
||||
showLoading()
|
||||
const res = await getUserAdminList(uni?.$liveID)
|
||||
console.log('管理列表=====', res)
|
||||
hideLoading()
|
||||
} catch (err) {
|
||||
hideLoading()
|
||||
}
|
||||
}
|
||||
|
||||
/** 设置为管理员 */
|
||||
const onDdmini = () => {
|
||||
console.log('====', userData.value)
|
||||
@@ -159,8 +187,10 @@
|
||||
|
||||
const muteSpeak = () => {
|
||||
console.log(
|
||||
`mute or unMute speak, liveID: ${props.liveID}, isMessageDisabled: ${props?.userInfo?.isMessageDisabled}`
|
||||
`${uni?.$liveID} === mute or unMute speak, liveID: ${props.liveID}, isMessageDisabled: ${props?.userInfo?.isMessageDisabled}`
|
||||
)
|
||||
getBanList()
|
||||
|
||||
const isShow = props?.userInfo?.isMessageDisabled
|
||||
uni.showModal({
|
||||
title: `提示`,
|
||||
@@ -219,6 +249,7 @@
|
||||
icon: 'success'
|
||||
})
|
||||
}
|
||||
|
||||
</script>
|
||||
|
||||
<style>
|
||||
|
||||
Reference in New Issue
Block a user