9.2 增加电子评标室菜单icon,修改回放

This commit is contained in:
jl-zhoujl2
2022-09-02 10:40:26 +08:00
parent 44f2b35998
commit 424711f3c6
3 changed files with 33 additions and 78 deletions

View File

@ -197,7 +197,7 @@ const ScreenVideoPlay: React.FC<ScreenVideoPlayProps> = (props) => {
var cameraIndexCode = caremaCode; //获取输入的监控点编号值,必填 var cameraIndexCode = caremaCode; //获取输入的监控点编号值,必填
var startTimeStamp = new Date(startTime?.replace('-', '/').replace('-', '/')).getTime(); //回放开始时间戳,必填 var startTimeStamp = new Date(startTime?.replace('-', '/').replace('-', '/')).getTime(); //回放开始时间戳,必填
var endTimeStamp = new Date(endTime?.replace('-', '/').replace('-', '/')).getTime(); //回放结束时间戳,必填 var endTimeStamp = new Date(endTime?.replace('-', '/').replace('-', '/')).getTime(); //回放结束时间戳,必填
var recordLocation = 0; //录像存储位置0-中心存储1-设备存储 var recordLocation = 1; //录像存储位置0-中心存储1-设备存储
var transMode = 1; //传输协议0-UDP1-TCP var transMode = 1; //传输协议0-UDP1-TCP
var gpuMode = 0; //是否启用GPU硬解0-不启用1-启用 var gpuMode = 0; //是否启用GPU硬解0-不启用1-启用
var wndId = -1; //播放窗口序号在2x2以上布局下可指定播放窗口 var wndId = -1; //播放窗口序号在2x2以上布局下可指定播放窗口

View File

@ -29,68 +29,33 @@ import {
WalletOutlined, WalletOutlined,
AppstoreOutlined, AppstoreOutlined,
ShopOutlined, ShopOutlined,
FundProjectionScreenOutlined,
PlaySquareOutlined,
BankOutlined,
IdcardOutlined,
} from '@ant-design/icons'; } from '@ant-design/icons';
import { getAuthority } from '@/utils/authority';
import { JumpToOutside } from '@/utils/CommonUtils';
const menuImgList = [ const menuIconMap = {
{ "HomeOutlined": <HomeOutlined />,
key: 'HomeOutlined', "ContactsOutlined": <ContactsOutlined />,
value: <HomeOutlined /> "DesktopOutlined": <DesktopOutlined />,
}, "NotificationOutlined": <NotificationOutlined />,
{ "BookOutlined": <BookOutlined />,
key: 'ContactsOutlined', "ProfileOutlined": <ProfileOutlined />,
value: <ContactsOutlined /> "CommentOutlined": <CommentOutlined />,
}, "MacCommandOutlined": <MacCommandOutlined />,
{ "ProjectOutlined": <ProjectOutlined />,
key: 'DesktopOutlined', "PartitionOutlined": <PartitionOutlined />,
value: <DesktopOutlined /> "PayCircleOutlined": <PayCircleOutlined />,
}, "WalletOutlined": <WalletOutlined />,
{ "AppstoreOutlined": <AppstoreOutlined />,
key: 'NotificationOutlined', "ShopOutlined": <ShopOutlined />,
value: <NotificationOutlined /> "FundProjectionScreenOutlined": <FundProjectionScreenOutlined />,
}, "PlaySquareOutlined": <PlaySquareOutlined />,
{ "BankOutlined": <BankOutlined />,
key: 'BookOutlined', "IdcardOutlined": <IdcardOutlined />,
value: <BookOutlined /> }
},
{
key: 'ProfileOutlined',
value: <ProfileOutlined />
},
{
key: 'CommentOutlined',
value: <CommentOutlined />
},
{
key: 'MacCommandOutlined',
value: <MacCommandOutlined />
},
{
key: 'ProjectOutlined',
value: <ProjectOutlined />
},
{
key: 'PartitionOutlined',
value: <PartitionOutlined />
},
{
key: 'PayCircleOutlined',
value: <PayCircleOutlined />
},
{
key: 'WalletOutlined',
value: <WalletOutlined />
},
{
key: 'AppstoreOutlined',
value: <AppstoreOutlined />
},
{
key: 'ShopOutlined',
value: <ShopOutlined />
},
]
const noMatch = ( const noMatch = (
<Result <Result
status={403} status={403}
@ -156,22 +121,12 @@ const BasicLayout: React.FC<BasicLayoutProps> = (props) => {
} }
}, []); }, []);
function menuICon(menuData: any) { const menuICon = (menus: any[]): any[] =>
if (menuData != undefined && menuData != null && menuData.length > 0) { menus && menus.map(({ icon, ...item }) => ({
let data: any[] = [...menuData] ...item,
let arr3 = data.map((item: any) => { icon: icon && menuIconMap[icon as string],
menuImgList.forEach((item3: any) => { }));
if (item.icon == item3.key) {
item.icon = item3.value
}
})
return item
})
return arr3
} else {
return []
}
}
const handleMenuCollapse = (payload: boolean): void => { const handleMenuCollapse = (payload: boolean): void => {
if (dispatch) { if (dispatch) {
dispatch({ dispatch({

View File

@ -56,7 +56,7 @@
.screen-flex-center; .screen-flex-center;
flex: 1; flex: 1;
color: #facd91; color: #facd91;
justify-content: flex-start; justify-content: center;
} }
} }