This commit is contained in:
禺狨 2023-03-07 15:16:14 +08:00
commit 1e37e7ee1b
7 changed files with 34 additions and 16 deletions

View File

@ -1,6 +1,6 @@
export * from "./footer"; export * from "./footer";
export * from "./header"; export * from "./header";
export * from "./leftMenu"; export * from "./left-menu";
export * from "./upload-image-button"; export * from "./upload-image-button";
export * from "./treeDepartment"; export * from "./treeDepartment";
export * from "./back-bar"; export * from "./back-bar";

View File

@ -21,15 +21,13 @@ function getItem(label: any, key: any, icon: any, children: any, type: any) {
} }
const items = [ const items = [
getItem("首页概览", "/", <SettingOutlined />, null, null), getItem("首页概览", "/", <SettingOutlined />, null, null),
getItem("网校装修", "/decoration", <SettingOutlined />, null, null),
getItem( getItem(
"课程内容", "资源管理",
"3", "3",
<MailOutlined />, <MailOutlined />,
[ [
getItem("视频", "/vod", null, null, null), getItem("视频", "/videos", null, null, null),
getItem("文章", "/topic", null, null, null), getItem("图片", "/images", null, null, null),
getItem("试卷", "/paper", null, null, null),
], ],
null null
), ),
@ -47,7 +45,6 @@ const items = [
[getItem("部门", "/department", null, null, null)], [getItem("部门", "/department", null, null, null)],
null null
), ),
getItem("证书管理", "5", <SettingOutlined />, [], null),
getItem( getItem(
"系统设置", "系统设置",
"6", "6",

View File

@ -161,6 +161,7 @@ export const DepartmentPage: React.FC = () => {
</div> </div>
<div className="float-left"> <div className="float-left">
<Table <Table
pagination={false}
key={tableKey} key={tableKey}
columns={columns} columns={columns}
dataSource={list} dataSource={list}

View File

@ -0,0 +1,4 @@
.main {
width: 100vw;
height: 100vh;
}

View File

@ -1,11 +1,27 @@
import { Button, Result } from "antd";
import React from "react"; import React from "react";
import { useNavigate } from "react-router-dom";
import styles from "./index.module.less"; import styles from "./index.module.less";
export const ErrorPage: React.FC<any> = () => { export const ErrorPage: React.FC<any> = () => {
const navigate = useNavigate();
return ( return (
<div id="error-page"> <Result
<h1>Oops!</h1> status="404"
<p></p> title="404"
</div> subTitle="您访问的页面不存在"
className={styles["main"]}
extra={
<Button
type="primary"
onClick={() => {
navigate("/");
}}
>
</Button>
}
/>
); );
}; };

View File

@ -17,11 +17,11 @@ export function dateFormat(dateStr: string) {
} }
export const generateUUID = (): string => { export const generateUUID = (): string => {
var guid = ""; let guid = "";
for (var i = 1; i <= 32; i++) { for (let i = 1; i <= 32; i++) {
var n = Math.floor(Math.random() * 16.0).toString(16); let n = Math.floor(Math.random() * 16.0).toString(16);
guid += n; guid += n;
if (i == 8 || i == 12 || i == 16 || i == 20) guid += "-"; if (i === 8 || i === 12 || i === 16 || i === 20) guid += "-";
} }
return guid; return guid;
}; };