2022-09-08 17:21:17 +00:00
|
|
|
import * as React from "react";
|
|
|
|
import { Box } from "@mui/material";
|
2022-09-20 17:55:21 +00:00
|
|
|
import Users from "./Users";
|
2022-10-20 03:05:10 +00:00
|
|
|
import Entities from "./Entities";
|
|
|
|
import Tariffs from "./Tariffs";
|
|
|
|
import Discounts from "./Discounts";
|
2022-09-20 17:55:21 +00:00
|
|
|
import Promocode from "./Promocode";
|
2022-10-20 03:05:10 +00:00
|
|
|
|
|
|
|
|
2022-09-20 17:55:21 +00:00
|
|
|
import Support from "./Support";
|
2022-10-20 03:05:10 +00:00
|
|
|
import Error404 from "../../Error404";
|
2022-09-08 17:21:17 +00:00
|
|
|
|
|
|
|
|
2022-09-20 17:55:21 +00:00
|
|
|
export interface MWProps {
|
|
|
|
section: number
|
|
|
|
}
|
|
|
|
|
|
|
|
const Content: React.FC<MWProps> = ({ section }) => {
|
2022-10-20 03:05:10 +00:00
|
|
|
const componentsArray = [
|
|
|
|
<Error404 />,
|
|
|
|
<Users />,
|
|
|
|
<Entities />,
|
|
|
|
<Tariffs />,
|
|
|
|
<Discounts />,
|
|
|
|
<Promocode />,
|
|
|
|
<Error404 />,
|
|
|
|
<Error404 />,
|
|
|
|
<Support />
|
|
|
|
];
|
2022-09-20 17:55:21 +00:00
|
|
|
|
2022-09-08 17:21:17 +00:00
|
|
|
return (
|
|
|
|
<React.Fragment>
|
|
|
|
<Box sx={{
|
|
|
|
width: "100%",
|
2022-09-10 18:39:16 +00:00
|
|
|
height: "calc(100vh - 85px)",
|
2022-09-08 17:21:17 +00:00
|
|
|
display: "flex",
|
|
|
|
flexDirection: "column",
|
2022-09-10 18:39:16 +00:00
|
|
|
alignItems: "center",
|
2022-09-12 10:32:05 +00:00
|
|
|
overflow: "auto",
|
|
|
|
overflowY: "auto",
|
2022-12-19 20:15:00 +00:00
|
|
|
padding: "60px 0"
|
2022-09-08 17:21:17 +00:00
|
|
|
}}>
|
2022-09-20 17:55:21 +00:00
|
|
|
|
|
|
|
{ componentsArray[ section ] }
|
2022-09-08 17:21:17 +00:00
|
|
|
</Box>
|
|
|
|
</React.Fragment>
|
|
|
|
);
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
export default Content;
|