diff --git a/client/src/pages/TicketPage.tsx b/client/src/pages/TicketPage.tsx index df4f640..b31fe93 100644 --- a/client/src/pages/TicketPage.tsx +++ b/client/src/pages/TicketPage.tsx @@ -1,14 +1,41 @@ import React, { FC } from "react"; +import { Link } from "react-router-dom"; +import Table from "@material-ui/core/Table"; +import TableBody from "@material-ui/core/TableBody"; +import TableCell from "@material-ui/core/TableCell"; +import TableContainer from "@material-ui/core/TableContainer"; +import TableHead from "@material-ui/core/TableHead"; +import TableRow from "@material-ui/core/TableRow"; +import Paper from "@material-ui/core/Paper"; import { Header } from "../components/Header"; import { AvatarList } from "../components/AvatarList"; import { TicketVM } from "../VM/TicketVM"; import { getRemainingdays } from "../utils/methods"; -import { Link } from "react-router-dom"; + +import { + Container, + makeStyles, + Theme, + Grid, + Typography, + Chip +} from "@material-ui/core"; +import { Timer, InfoSharp } from "@material-ui/icons"; interface IProps { viewModel: TicketVM; } +const useStyles = makeStyles((theme: Theme) => ({ + root: { + margin: theme.spacing(1), + flexGrow: 1 + }, + table: { + minWidth: 650 + } +})); + export const TicketPage: FC = ({ viewModel }) => { const { title, @@ -23,48 +50,38 @@ export const TicketPage: FC = ({ viewModel }) => { } = viewModel; const daysToEnd: number = getRemainingdays(endingDate); // let notes: string = ""; + const classes = useStyles(); + const infos: InfoProps = { status, category, impact, difficulty }; return ( -
-
+ +
- +
+ -
-
-
+
+ + + In project: {" "} {project.title} -
-
-
- timer - Due in {daysToEnd} days -
-
+ + + + Due in {daysToEnd} days + + +
-
-
- Status: {status} - {/* close */} -
- -
- Category: {category} - {/* close */} -
- -
- Impact: {impact} - {/* close */} -
- -
- Difficulty: {difficulty} - {/* close */} -
- - {/* */} -
- + + ); +}; + +interface InfoProps { + status: string; + category: string; + impact: string; + difficulty: string; +} + +const InfoTable: FC = (info: InfoProps) => { + const classes = useStyles(); + + return ( + + + + + Status + Category + Impact + Difficulty + + + + + {info.status} + {info.category} + {info.impact} + {info.difficulty} + + +
+
); };