优化&bug修复
This commit is contained in:
parent
dc9ee39a1e
commit
0fbcb32565
|
|
@ -47,6 +47,10 @@ const UserName = forwardRef((props: any, ref: any) => {
|
||||||
onClick={async () => {
|
onClick={async () => {
|
||||||
const stateInfo = await JSON.parse(storage.getItem('stateInfo') as string);
|
const stateInfo = await JSON.parse(storage.getItem('stateInfo') as string);
|
||||||
if (info.userName) {
|
if (info.userName) {
|
||||||
|
if (info.userName.length > 10) {
|
||||||
|
message.error('用户名称最多10个字!')
|
||||||
|
return
|
||||||
|
}
|
||||||
PutAlterUname({
|
PutAlterUname({
|
||||||
nickName: info.userName,
|
nickName: info.userName,
|
||||||
roomNum: stateInfo.channelId,
|
roomNum: stateInfo.channelId,
|
||||||
|
|
|
||||||
|
|
@ -458,6 +458,9 @@ const User: React.FC = () => {
|
||||||
if (!addUserFrom.UserName && isCreateUser !== 'batch') {
|
if (!addUserFrom.UserName && isCreateUser !== 'batch') {
|
||||||
return message.error('请输入用户名称!')
|
return message.error('请输入用户名称!')
|
||||||
}
|
}
|
||||||
|
if (addUserFrom.UserName.length > 10) {
|
||||||
|
return message.error('用户名称最多10个字!')
|
||||||
|
}
|
||||||
if (addUserFrom.year === '') {
|
if (addUserFrom.year === '') {
|
||||||
return message.error('请输入届!')
|
return message.error('请输入届!')
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -315,6 +315,9 @@ const Login: React.FC = () => {
|
||||||
if (!anonInfo.nickName) {
|
if (!anonInfo.nickName) {
|
||||||
return message.error('请输入参会昵称!')
|
return message.error('请输入参会昵称!')
|
||||||
}
|
}
|
||||||
|
if (anonInfo.nickName.length > 10) {
|
||||||
|
return message.error('参会昵称最多10个字!')
|
||||||
|
}
|
||||||
storage.setItem('loading', true)
|
storage.setItem('loading', true)
|
||||||
PostAnonLogin(anonInfo).then(async (res) => {
|
PostAnonLogin(anonInfo).then(async (res) => {
|
||||||
if (res.code == 200) {
|
if (res.code == 200) {
|
||||||
|
|
|
||||||
|
|
@ -46,6 +46,8 @@
|
||||||
font-size: 14px;
|
font-size: 14px;
|
||||||
color: #F3F3F5;
|
color: #F3F3F5;
|
||||||
margin-left: 4px;
|
margin-left: 4px;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
>div {}
|
>div {}
|
||||||
|
|
@ -77,6 +79,8 @@
|
||||||
>span {
|
>span {
|
||||||
font-size: 14px;
|
font-size: 14px;
|
||||||
color: #F3F3F5;
|
color: #F3F3F5;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
>div {
|
>div {
|
||||||
|
|
|
||||||
|
|
@ -206,19 +206,30 @@ const ChatBigWindow: React.FC = () => {
|
||||||
>移出会议</Button> : null}
|
>移出会议</Button> : null}
|
||||||
</div> : <div style={{ color: 'white' }}>用户不在房间内</div>
|
</div> : <div style={{ color: 'white' }}>用户不在房间内</div>
|
||||||
}>
|
}>
|
||||||
<div>
|
<div title={item.userName}>
|
||||||
<div><Avatar name={item.userName} /></div>
|
<div><Avatar name={item.userName} /></div>
|
||||||
{item.uid !== user.uid ?
|
{item.uid !== user.uid ?
|
||||||
<span>{item.userName} <span style={{ fontSize: '12px', color: '#ccc', marginLeft: '4px' }}>{dayjs(item.timestamp).format('HH:mm:ss')}</span></span> :
|
<span>
|
||||||
<span> <span style={{ fontSize: '12px', color: '#ccc', marginRight: '4px' }}>{dayjs(item.timestamp).format('HH:mm:ss')} </span>{item.userName}</span>
|
<span style={{ overflow: 'hidden', textOverflow: 'ellipsis', whiteSpace: 'nowrap', maxWidth: '150px' }}>{item.userName}</span>
|
||||||
|
<span style={{ fontSize: '12px', color: '#ccc', marginLeft: '4px' }}>{dayjs(item.timestamp).format('HH:mm:ss')}</span>
|
||||||
|
</span> :
|
||||||
|
<span>
|
||||||
|
<span style={{ fontSize: '12px', color: '#ccc', marginRight: '4px' }}>{dayjs(item.timestamp).format('HH:mm:ss')}</span>
|
||||||
|
<span style={{ overflow: 'hidden', textOverflow: 'ellipsis', whiteSpace: 'nowrap', maxWidth: '150px' }}>{item.userName}</span>
|
||||||
|
</span>
|
||||||
}
|
}
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</Popover> : <div>
|
</Popover> : <div title={item.userName}>
|
||||||
<div><Avatar name={item.userName} /></div>
|
<div><Avatar name={item.userName} /></div>
|
||||||
{item.uid !== user.uid ?
|
{item.uid !== user.uid ?
|
||||||
<span>{item.userName}<span style={{ fontSize: '12px', color: '#ccc', marginLeft: '4px' }}>{dayjs(item.timestamp).format('HH:mm:ss')}</span></span> :
|
<span>
|
||||||
<span><span style={{ fontSize: '12px', color: '#ccc', marginRight: '4px' }}>{dayjs(item.timestamp).format('HH:mm:ss')} </span>{item.userName}</span>
|
<span style={{ overflow: 'hidden', textOverflow: 'ellipsis', whiteSpace: 'nowrap', maxWidth: '150px' }}>{item.userName}</span>
|
||||||
|
<span style={{ fontSize: '12px', color: '#ccc', marginLeft: '4px' }}>{dayjs(item.timestamp).format('HH:mm:ss')}</span>
|
||||||
|
</span> :
|
||||||
|
<span>
|
||||||
|
<span style={{ fontSize: '12px', color: '#ccc', marginRight: '4px' }}>{dayjs(item.timestamp).format('HH:mm:ss')}</span>
|
||||||
|
<span style={{ overflow: 'hidden', textOverflow: 'ellipsis', whiteSpace: 'nowrap', maxWidth: '150px' }}>{item.userName}</span>
|
||||||
|
</span>
|
||||||
}
|
}
|
||||||
</div>}
|
</div>}
|
||||||
<div>{item.message}</div>
|
<div>{item.message}</div>
|
||||||
|
|
|
||||||
|
|
@ -31,7 +31,7 @@
|
||||||
display: flex;
|
display: flex;
|
||||||
|
|
||||||
>span:nth-child(1) {
|
>span:nth-child(1) {
|
||||||
white-space: nowrap;
|
word-break: break-all;
|
||||||
color: #ff970f;
|
color: #ff970f;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -21,7 +21,10 @@ const NoticeWindow: React.FC = () => {
|
||||||
api.open({
|
api.open({
|
||||||
message: '',
|
message: '',
|
||||||
description: <div>
|
description: <div>
|
||||||
<span style={{ fontSize: '16px' }}>{noticeItem.uname}申请发言</span>
|
<div style={{ fontSize: '16px' }}>
|
||||||
|
<div style={{ overflow: 'hidden', textOverflow: 'ellipsis', whiteSpace: 'nowrap' }} title={noticeItem.uname}>{noticeItem.uname}</div>
|
||||||
|
<div>申请发言</div>
|
||||||
|
</div>
|
||||||
<div style={{ display: 'flex', justifyContent: 'flex-end' }} className='drag'>
|
<div style={{ display: 'flex', justifyContent: 'flex-end' }} className='drag'>
|
||||||
<Button
|
<Button
|
||||||
type="primary"
|
type="primary"
|
||||||
|
|
|
||||||
|
|
@ -549,6 +549,8 @@
|
||||||
font-size: 14px;
|
font-size: 14px;
|
||||||
color: #F3F3F5;
|
color: #F3F3F5;
|
||||||
margin-left: 4px;
|
margin-left: 4px;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
>div {
|
>div {
|
||||||
|
|
@ -660,6 +662,8 @@
|
||||||
font-size: 14px;
|
font-size: 14px;
|
||||||
color: #F3F3F5;
|
color: #F3F3F5;
|
||||||
margin-left: 4px;
|
margin-left: 4px;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -689,6 +693,8 @@
|
||||||
>span {
|
>span {
|
||||||
font-size: 14px;
|
font-size: 14px;
|
||||||
color: #F3F3F5;
|
color: #F3F3F5;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
>div {
|
>div {
|
||||||
|
|
|
||||||
|
|
@ -2943,7 +2943,7 @@ const Meeting: React.FC = () => {
|
||||||
<div>
|
<div>
|
||||||
<div><Avatar name={item.userName} /></div>
|
<div><Avatar name={item.userName} /></div>
|
||||||
<span>
|
<span>
|
||||||
{item.userName}{item.uid === user.uid ? '(我)' : ''}
|
<span style={{ overflow: 'hidden', textOverflow: 'ellipsis', whiteSpace: 'nowrap', maxWidth: '80px' }} title={item.userName}>{item.userName}</span>{item.uid === user.uid ? '(我)' : ''}
|
||||||
{role.ID.includes(item.roleId) || item.isRoomManager ?
|
{role.ID.includes(item.roleId) || item.isRoomManager ?
|
||||||
<span style={{ color: '#02B188', marginLeft: '4px' }}>
|
<span style={{ color: '#02B188', marginLeft: '4px' }}>
|
||||||
{role.ID.includes(item.roleId) ? '管理员' : '发言人'}
|
{role.ID.includes(item.roleId) ? '管理员' : '发言人'}
|
||||||
|
|
@ -3163,19 +3163,30 @@ const Meeting: React.FC = () => {
|
||||||
>移出会议</Button> : null}
|
>移出会议</Button> : null}
|
||||||
</div> : <div style={{ color: 'white' }}>用户不在房间内</div>
|
</div> : <div style={{ color: 'white' }}>用户不在房间内</div>
|
||||||
}>
|
}>
|
||||||
<div>
|
<div title={item.userName}>
|
||||||
<div><Avatar name={item.userName} /></div>
|
<div><Avatar name={item.userName} /></div>
|
||||||
{item.uid !== user.uid ?
|
{item.uid !== user.uid ?
|
||||||
<span>{item.userName} <span style={{ fontSize: '12px', color: '#ccc', marginLeft: '4px' }}>{dayjs(item.timestamp).format('HH:mm:ss')}</span></span> :
|
<span>
|
||||||
<span> <span style={{ fontSize: '12px', color: '#ccc', marginRight: '4px' }}>{dayjs(item.timestamp).format('HH:mm:ss')} </span>{item.userName}</span>
|
<span style={{ overflow: 'hidden', textOverflow: 'ellipsis', whiteSpace: 'nowrap', maxWidth: '150px' }}>{item.userName}</span>
|
||||||
|
<span style={{ fontSize: '12px', color: '#ccc', marginLeft: '4px' }}>{dayjs(item.timestamp).format('HH:mm:ss')}</span>
|
||||||
|
</span> :
|
||||||
|
<span>
|
||||||
|
<span style={{ fontSize: '12px', color: '#ccc', marginRight: '4px' }}>{dayjs(item.timestamp).format('HH:mm:ss')}</span>
|
||||||
|
<span style={{ overflow: 'hidden', textOverflow: 'ellipsis', whiteSpace: 'nowrap', maxWidth: '150px' }}>{item.userName}</span>
|
||||||
|
</span>
|
||||||
}
|
}
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</Popover> : <div>
|
</Popover> : <div title={item.userName}>
|
||||||
<div><Avatar name={item.userName} /></div>
|
<div><Avatar name={item.userName} /></div>
|
||||||
{item.uid !== user.uid ?
|
{item.uid !== user.uid ?
|
||||||
<span>{item.userName}<span style={{ fontSize: '12px', color: '#ccc', marginLeft: '4px' }}>{dayjs(item.timestamp).format('HH:mm:ss')}</span></span> :
|
<span>
|
||||||
<span><span style={{ fontSize: '12px', color: '#ccc', marginRight: '4px' }}>{dayjs(item.timestamp).format('HH:mm:ss')} </span>{item.userName}</span>
|
<span style={{ overflow: 'hidden', textOverflow: 'ellipsis', whiteSpace: 'nowrap', maxWidth: '150px' }}>{item.userName}</span>
|
||||||
|
<span style={{ fontSize: '12px', color: '#ccc', marginLeft: '4px' }}>{dayjs(item.timestamp).format('HH:mm:ss')}</span>
|
||||||
|
</span> :
|
||||||
|
<span>
|
||||||
|
<span style={{ fontSize: '12px', color: '#ccc', marginRight: '4px' }}>{dayjs(item.timestamp).format('HH:mm:ss')}</span>
|
||||||
|
<span style={{ overflow: 'hidden', textOverflow: 'ellipsis', whiteSpace: 'nowrap', maxWidth: '150px' }}>{item.userName}</span>
|
||||||
|
</span>
|
||||||
}
|
}
|
||||||
</div>}
|
</div>}
|
||||||
<div>{item.message}</div>
|
<div>{item.message}</div>
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue