mirror of
https://github.com/openmhz/trunk-server.git
synced 2026-11-12 16:57:39 -05:00
Gettign going
This commit is contained in:
@@ -1,15 +1,48 @@
|
||||
import React, { Component } from "react"
|
||||
import React, { Component } from "react"
|
||||
import NavigationContainer from "./NavigationContainer"
|
||||
import { Routes, Route } from 'react-router-dom';
|
||||
|
||||
class App extends Component {
|
||||
render() {
|
||||
return(
|
||||
import Restricted from "./Restricted"
|
||||
|
||||
import About from "../Components/About"
|
||||
import System from "../System/System"
|
||||
import ListSystems from "../System/ListSystems"
|
||||
import UpdateSystemContainer from "../System/UpdateSystemContainer"
|
||||
import CreateSystemContainer from "../System/CreateSystemContainer"
|
||||
|
||||
|
||||
const App = (params) => {
|
||||
const {store} = params;
|
||||
return (
|
||||
<div>
|
||||
<NavigationContainer />
|
||||
{this.props.children}
|
||||
<Routes>
|
||||
<Route path="/about" element={ <Restricted><About/></Restricted>} />
|
||||
<Route path="/system/:shortName" element={ <Restricted><System/></Restricted>} />
|
||||
<Route path="/update-system/:shortName" component={Restricted(UpdateSystemContainer, store)} />
|
||||
<Route path="/create-system" component={Restricted(CreateSystemContainer, store)} />
|
||||
<Route path="/list-systems" element={ <Restricted><ListSystems/></Restricted>} />
|
||||
<Route path="/" element={ <Restricted><ListSystems/></Restricted>} />
|
||||
<Route render={() => (<div>Miss</div>)} />
|
||||
</Routes>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
}
|
||||
/*
|
||||
return (
|
||||
<div>
|
||||
<NavigationContainer />
|
||||
<Routes>
|
||||
<Route path="/about" element={<About />} component={Restricted(About, store)} />
|
||||
<Route path="/system/:shortName" component={Restricted(SystemContainer, store)} />
|
||||
<Route path="/update-system/:shortName" component={Restricted(UpdateSystemContainer, store)} />
|
||||
<Route path="/create-system" component={Restricted(CreateSystemContainer, store)} />
|
||||
<Route path="/list-systems" component={Restricted(ListSystemsContainer, store)} />
|
||||
<Route path="/" component={Restricted(ListSystemsContainer, store)} />
|
||||
<Route render={() => (<div>Miss</div>)} />
|
||||
</Routes>
|
||||
</div>
|
||||
)*/
|
||||
|
||||
};
|
||||
|
||||
export default App
|
||||
|
||||
Reference in New Issue
Block a user