| | |
| | | |
| | | const [unreadCount, setUnreadCount] = useState(0); |
| | | useEffect(() => { |
| | | // const timer = setInterval(() => { |
| | | // getUnreadCount().then((res: any) => { |
| | | // setUnreadCount(res.data || 0); |
| | | // }); |
| | | // }, 1000 * 5) |
| | | const timer = setInterval(() => { |
| | | getUnreadCount().then((res: any) => { |
| | | setUnreadCount(res.data || 0); |
| | | }); |
| | | }, 1000 * 5) |
| | | |
| | | // return () => clearInterval(timer); |
| | | return () => clearInterval(timer); |
| | | }, []); |
| | | |
| | | |
| | |
| | | return ( |
| | | <Space> |
| | | { |
| | | record.roleId != 1 && |
| | | record.id != 1 && |
| | | <Access accessible={access['/system_setting/role_management/edit']}> |
| | | <Button |
| | | type="link" |
| | |
| | | </Access> |
| | | } |
| | | { |
| | | record.roleId != 1 && |
| | | record.id != 1 && |
| | | <Access accessible={access['/system_setting/role_management/del']}> |
| | | <Button |
| | | type="link" |