diff --git a/src/components/StupWizard/index.tsx b/src/components/StupWizard/index.tsx
index 9e09414..eeadfae 100644
--- a/src/components/StupWizard/index.tsx
+++ b/src/components/StupWizard/index.tsx
@@ -6,12 +6,14 @@ import { agora } from '@/utils/package/agora'
import { CloseOutlined, LoadingOutlined, QuestionCircleOutlined } from '@ant-design/icons';
import { storage } from '@/utils';
import path from 'path';
-
+import { role } from '@/config/role';
+let meetingUserInfo = '' as any;
const fs = require('fs').promises;
const { exec } = require('child_process');
const StupWizard = forwardRef((_props: any, ref: any) => {
useImperativeHandle(ref, () => ({
- changeModal: (index: number = 0) => {
+ changeModal: (index: number = 0, data: any) => {
+ meetingUserInfo = data;
if (location.hash.indexOf('/meeting') === -1) {
agora.init()
}
@@ -675,22 +677,26 @@ const AudioComponents = () => {
})
agora.setRecordingDevice(e)
}} />;
- {audioDeviceManager.ecordingActive ?
{
- agora.stopRecordingDeviceTest()
- setAudioDeviceManager({
- ...audioDeviceManager,
- playBackActive: false,
- ecordingActive: false,
- })
- }}>结束
: {
- agora.stopPlaybackDeviceTest()
- agora.startRecordingDeviceTest(100)
- setAudioDeviceManager({
- ...audioDeviceManager,
- playBackActive: false,
- ecordingActive: true,
- })
- }}>测试
}
+ {(meetingUserInfo &&
+ (role.ID.includes(meetingUserInfo.roleId) || meetingUserInfo.isRoomManager) &&
+ meetingUserInfo.enableMicr) ||
+ location.hash.indexOf('/meeting') === -1
+ ? audioDeviceManager.ecordingActive ? {
+ agora.stopRecordingDeviceTest()
+ setAudioDeviceManager({
+ ...audioDeviceManager,
+ playBackActive: false,
+ ecordingActive: false,
+ })
+ }}>结束
: {
+ agora.stopPlaybackDeviceTest()
+ agora.startRecordingDeviceTest(100)
+ setAudioDeviceManager({
+ ...audioDeviceManager,
+ playBackActive: false,
+ ecordingActive: true,
+ })
+ }}>测试
: null}
{audioDeviceManager.ecordingActive ?

diff --git a/src/page/Meeting/index.tsx b/src/page/Meeting/index.tsx
index 9b97a7b..d422732 100644
--- a/src/page/Meeting/index.tsx
+++ b/src/page/Meeting/index.tsx
@@ -1426,7 +1426,10 @@ const Meeting: React.FC = () => {
})
break;
case '设置':
- stupWizardRef.current.changeModal()
+ await getUserRoomInfo().then(async (res) => {
+ stupWizardRef.current.changeModal(0, res)
+ })
+
break;
case '邀请人员':
await getUserRoomInfo().then(async (res) => {