added routing for resources + resourcecharts #1 #9

This commit is contained in:
2020-04-18 01:06:51 +02:00
parent 9edeb83fea
commit 02c14e1541
7 changed files with 72 additions and 10 deletions

View File

@@ -4,6 +4,8 @@ import Overview from "./overview/overview";
import {
Route,
} from "react-router-dom";
import SelectResource from './selectResource';
import ResourceChart from './resourcechart/resourcechart';
const useStyles = makeStyles(theme => ({
root: {
@@ -19,7 +21,9 @@ export default function Content() {
return (
<div className={classes.root}>
<Route path="/overview" component={Overview} />
<Route exact path="/" component={Overview} />
<Route path="/resources" component={SelectResource} />
<Route path="/resourcechart/:id" render={() => <ResourceChart day={Date.now()} kind={-1} ></ResourceChart>} />
</div>
);