yangjie #45

Merged
yangqiang merged 19 commits from yangjie into master 2024-12-18 13:52:10 +08:00
2 changed files with 15 additions and 1 deletions
Showing only changes of commit 631dbf26b1 - Show all commits

View File

@ -7,6 +7,7 @@ import Avatar from '@/components/Avatar';
import { useEffect, useState, useRef } from "react"; import { useEffect, useState, useRef } from "react";
import { storage } from '@/utils'; import { storage } from '@/utils';
import EquipmentManagement from '@/components/EquipmentManagement'; import EquipmentManagement from '@/components/EquipmentManagement';
import UserName from '@/components/UserName';
const { confirm } = Modal; const { confirm } = Modal;
const UserListWindow: React.FC = () => { const UserListWindow: React.FC = () => {
@ -14,6 +15,7 @@ const UserListWindow: React.FC = () => {
const [user, setUser] = useState<any>({}); const [user, setUser] = useState<any>({});
const [roomUserList, setRoomUserList] = useState<any>([]) const [roomUserList, setRoomUserList] = useState<any>([])
const equipmentManagementRef = useRef<any>(); const equipmentManagementRef = useRef<any>();
const userNameRef = useRef<any>();
const channel = new BroadcastChannel('meeting_channel'); const channel = new BroadcastChannel('meeting_channel');
const userInfo = JSON.parse(storage.getItem('user') as string) const userInfo = JSON.parse(storage.getItem('user') as string)
useEffect(() => { useEffect(() => {
@ -149,6 +151,18 @@ const UserListWindow: React.FC = () => {
}); });
}} }}
></Button> ></Button>
<Button
type="primary"
className='m-ant-btn'
style={{ width: '100%', marginTop: '10px' }}
size={'small'}
onClick={() => {
userNameRef.current.changeModal({
userName: item.userName,
uid: item.uid
})
}}
></Button>
</div> </div>
}> }>
<EllipsisOutlined style={{ <EllipsisOutlined style={{
@ -192,6 +206,7 @@ const UserListWindow: React.FC = () => {
}}></div> }}></div>
</div> </div>
</div> </div>
<UserName ref={userNameRef} />
<EquipmentManagement ref={equipmentManagementRef} getDriver={(uid: string) => { <EquipmentManagement ref={equipmentManagementRef} getDriver={(uid: string) => {
channel.postMessage({ channel.postMessage({
type: 'userListWindowEquipmentManagement', type: 'userListWindowEquipmentManagement',

View File

@ -2347,7 +2347,6 @@ const Meeting: React.FC = () => {
{item.uid !== user.uid ? <Button {item.uid !== user.uid ? <Button
type="primary" type="primary"
className='m-ant-btn' className='m-ant-btn'
style={{ width: '100%', marginTop: '10px' }}
size={'small'} size={'small'}
onClick={() => { onClick={() => {
userNameRef.current.changeModal({ userNameRef.current.changeModal({