@@ -1,8 +1,8 @@ | |||||
export default [ | export default [ | ||||
{ path: '/user', layout: false, routes: [{ path: '/user/login', component: './user/login' }] }, | { path: '/user', layout: false, routes: [{ path: '/user/login', component: './user/login' }] }, | ||||
{ path: '/', icon: 'SmileOutlined', component: './welcome', name: '欢迎页', routes: []}, | |||||
{ path: '/', component: './welcome', name: '首页', routes: []}, | |||||
{ | { | ||||
icon: 'SettingOutlined', | |||||
path: '/system', | path: '/system', | ||||
name: '系统管理', | name: '系统管理', | ||||
routes: [ | routes: [ | ||||
@@ -13,7 +13,7 @@ | |||||
], | ], | ||||
}, | }, | ||||
{ | { | ||||
path: '/deviceModal', icon: 'SettingOutlined', name: '设备模型管理', | |||||
path: '/deviceModal', name: '设备模型管理', | |||||
routes: [{ | routes: [{ | ||||
name: '设备建模', | name: '设备建模', | ||||
path: '/deviceModal/deviceProduct', | path: '/deviceModal/deviceProduct', | ||||
@@ -23,7 +23,7 @@ | |||||
] | ] | ||||
}, | }, | ||||
{ | { | ||||
path: '/factory', icon: 'SettingOutlined', name: '工厂数据管理', | |||||
path: '/factory', name: '工厂数据管理', | |||||
routes: [ | routes: [ | ||||
{ path: '/factory/process', name: '工序流程', component: './plantModel/process' }, | { path: '/factory/process', name: '工序流程', component: './plantModel/process' }, | ||||
@@ -31,14 +31,14 @@ | |||||
] | ] | ||||
}, | }, | ||||
{ | { | ||||
path: '/production', icon: 'SettingOutlined', name: '生产资料管理', hideInBreadcrumb:false, | |||||
path: '/production', name: '生产资料管理', hideInBreadcrumb:false, | |||||
routes: [ | routes: [ | ||||
{ path: '/production/materials', name: '物料管理', component: './materials/index' }, | { path: '/production/materials', name: '物料管理', component: './materials/index' }, | ||||
{ path: '/production/godown', name: '料仓管理', component: './stock/index' }, | { path: '/production/godown', name: '料仓管理', component: './stock/index' }, | ||||
{ path: '/production/final', name: '成品管理', component: './final/index' }, | { path: '/production/final', name: '成品管理', component: './final/index' }, | ||||
] | ] | ||||
}, | }, | ||||
{ path: '/work',icon: 'SmileOutlined', name: '生产计划管理', | |||||
{ path: '/work', name: '生产计划管理', | |||||
routes: [ | routes: [ | ||||
{ path: '/work/workPlan', name: '生产计划', component: './workInfo/plan', }, | { path: '/work/workPlan', name: '生产计划', component: './workInfo/plan', }, | ||||
{ path: '/work/workInfo', name: '工单管理', component: './workInfo/index', }, | { path: '/work/workInfo', name: '工单管理', component: './workInfo/index', }, | ||||
@@ -68,7 +68,7 @@ | |||||
// { path: '/report/material', name: '原料统计', component: './report/material' }, | // { path: '/report/material', name: '原料统计', component: './report/material' }, | ||||
// ] | // ] | ||||
// }, | // }, | ||||
{ path: '/dataV',icon: 'SmileOutlined', name: '自定义报表', target: '_blank',}, | |||||
{ path: '/dataV', name: '自定义报表', target: '_blank',}, | |||||
{ path: '*', layout: false, component: './404' }, | { path: '*', layout: false, component: './404' }, | ||||
]; | ]; | ||||
@@ -18,7 +18,7 @@ const loopMenuItem = (menus: MenuDataItem[]): MenuDataItem[] => { | |||||
return menus?.map(({ icon, routes, ...item }) => ( | return menus?.map(({ icon, routes, ...item }) => ( | ||||
{ | { | ||||
...item, | ...item, | ||||
icon: (icon as string) !='' ? React.createElement((Icon as any)[icon as string]):React.createElement((Icon as any)['SettingOutlined']), | |||||
icon: '', | |||||
routes: routes && loopMenuItem(routes), | routes: routes && loopMenuItem(routes), | ||||
})); | })); | ||||
}; | }; | ||||
@@ -94,44 +94,44 @@ export const layout: RunTimeLayoutConfig = ({ initialState }) => { | |||||
content: '黑菠萝科技研发部', | content: '黑菠萝科技研发部', | ||||
}, | }, | ||||
token: { | token: { | ||||
layout: { | |||||
bgLayout: '#001529' | |||||
}, | |||||
// colorBgAppListIconHover: '#fff', | |||||
// colorTextAppListIconHover: 'rgba(255,255,255,0.95)', | |||||
// colorTextAppListIcon: 'rgba(255,255,255,0.85)', | |||||
sider: { | |||||
// colorBgCollapsedButton: '#0960bd', | |||||
// colorTextCollapsedButtonHover: '#fff', | |||||
// colorTextCollapsedButton: '#fff', | |||||
colorMenuBackground: '#001529',//菜单背景色 | |||||
//colorBgMenuItemCollapsedHover: '#fff', | |||||
colorBgMenuItemCollapsedElevated: '#001529', | |||||
colorBgMenuItemCollapsedSelected: '#0960bd', | |||||
colorMenuItemDivider: 'rgba(255,255,255,0.15)', | |||||
colorBgMenuItemHover: '#0960bd', | |||||
colorBgMenuItemSelected: '#0960bd', | |||||
colorTextMenuSelected: '#ffffff', | |||||
colorTextMenuItemHover: '#fff', | |||||
colorTextMenu: '#fff', | |||||
colorTextMenuSecondary: '#fff', | |||||
colorTextMenuTitle: '#fff',//系统名称 | |||||
// colorTextMenuActive: '#fff', | |||||
colorTextSubMenuSelected: '#fff', | |||||
// }, | |||||
header: { | |||||
colorBgHeader: '#ffffff', | |||||
colorMenuBackground: '#000', | |||||
colorHeaderTitle: '#ffffff', | |||||
}, | |||||
// layout: { | |||||
// bgLayout: '#001529' | |||||
// }, | |||||
// // colorBgAppListIconHover: '#fff', | |||||
// // colorTextAppListIconHover: 'rgba(255,255,255,0.95)', | |||||
// // colorTextAppListIcon: 'rgba(255,255,255,0.85)', | |||||
// sider: { | |||||
// // colorBgCollapsedButton: '#0960bd', | |||||
// // colorTextCollapsedButtonHover: '#fff', | |||||
// // colorTextCollapsedButton: '#fff', | |||||
// colorMenuBackground: '#001529',//菜单背景色 | |||||
// //colorBgMenuItemCollapsedHover: '#fff', | |||||
// colorBgMenuItemCollapsedElevated: '#001529', | |||||
// colorBgMenuItemCollapsedSelected: '#0960bd', | |||||
// colorMenuItemDivider: 'rgba(255,255,255,0.15)', | |||||
// colorBgMenuItemHover: '#0960bd', | |||||
// colorBgMenuItemSelected: '#0960bd', | |||||
// colorTextMenuSelected: '#ffffff', | |||||
// colorTextMenuItemHover: '#fff', | |||||
// colorTextMenu: '#fff', | |||||
// colorTextMenuSecondary: '#fff', | |||||
// colorTextMenuTitle: '#fff',//系统名称 | |||||
// // colorTextMenuActive: '#fff', | |||||
// colorTextSubMenuSelected: '#fff', | |||||
// // }, | |||||
// header: { | |||||
// colorBgHeader: '#ffffff', | |||||
// colorMenuBackground: '#000', | |||||
// colorHeaderTitle: '#ffffff', | |||||
// }, | |||||
// pageContainer:{ | // pageContainer:{ | ||||
// paddingInlinePageContainerContent: 20, | // paddingInlinePageContainerContent: 20, | ||||
// paddingBlockPageContainerContent:10 | // paddingBlockPageContainerContent:10 | ||||
}, | |||||
pageContainer: { | |||||
colorBgPageContainer: '#f5f5f5', | |||||
colorBgPageContainerFixed: '#0960bd' | |||||
}, | |||||
// }, | |||||
// pageContainer: { | |||||
// colorBgPageContainer: '#f5f5f5', | |||||
// colorBgPageContainerFixed: '#0960bd' | |||||
// }, | |||||
}, | }, | ||||
footerRender: () => <Footer />, | footerRender: () => <Footer />, | ||||
onPageChange: () => { | onPageChange: () => { | ||||
@@ -0,0 +1,17 @@ | |||||
.marquee { | |||||
width:50px; | |||||
overflow: hidden; | |||||
white-space: nowrap; | |||||
box-sizing: border-box; | |||||
} | |||||
.marquee p { | |||||
display: inline-block; | |||||
padding-left: 100%; | |||||
animation: marquee 10s linear infinite; | |||||
} | |||||
@keyframes marquee { | |||||
0% { transform: translateX(0); } | |||||
100% { transform: translateX(-80%); } | |||||
} |
@@ -1,6 +1,7 @@ | |||||
import { Card } from 'antd'; | import { Card } from 'antd'; | ||||
import React from 'react'; | import React from 'react'; | ||||
import dayjs from 'dayjs' | import dayjs from 'dayjs' | ||||
import styles from './index.less'; | |||||
import { PageContainer } from '@ant-design/pro-components'; | import { PageContainer } from '@ant-design/pro-components'; | ||||
@@ -13,6 +14,9 @@ const Welcome: React.FC = () => { | |||||
}} | }} | ||||
> | > | ||||
你好, 欢迎使用中控管理系统,今天是星期{dayjs().day()} | 你好, 欢迎使用中控管理系统,今天是星期{dayjs().day()} | ||||
<div className={styles.marquee}> | |||||
<p>- - - - - - - - - </p> | |||||
</div> | |||||
</Card> | </Card> | ||||
); | ); | ||||
}; | }; | ||||