diff options
author | Emiliano Ciavatta | 2020-09-23 18:19:09 +0000 |
---|---|---|
committer | Emiliano Ciavatta | 2020-09-23 18:19:09 +0000 |
commit | 8d07bfe5f17534b7301a064aeaf8ed8071f10a40 (patch) | |
tree | f645b9f033d878d54175705c1d1909e0420c54f4 /frontend/src/views/MainPane.js | |
parent | 8c8487b79300342b4c6dafe9c3691d43b8dc8e37 (diff) |
Frontend refactor: checkpoint
Diffstat (limited to 'frontend/src/views/MainPane.js')
-rw-r--r-- | frontend/src/views/MainPane.js | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/frontend/src/views/MainPane.js b/frontend/src/views/MainPane.js index 69de725..3c0d795 100644 --- a/frontend/src/views/MainPane.js +++ b/frontend/src/views/MainPane.js @@ -3,7 +3,8 @@ import './MainPane.scss'; import Connections from "./Connections"; import ConnectionContent from "../components/ConnectionContent"; import {withRouter} from "react-router-dom"; -import axios from 'axios'; +import PcapPane from "../components/panels/PcapPane"; +import backend from "../backend"; class MainPane extends Component { @@ -17,9 +18,9 @@ class MainPane extends Component { componentDidMount() { if ('id' in this.props.match.params) { const id = this.props.match.params.id; - axios.get(`/api/connections/${id}`).then(res => { + backend.get(`/api/connections/${id}`).then(res => { if (res.status === 200) { - this.setState({selectedConnection: res.data}); + this.setState({selectedConnection: res}); } }); } @@ -34,6 +35,7 @@ class MainPane extends Component { <Connections onSelected={(c) => this.setState({selectedConnection: c})} /> </div> <div className="col-md-6 pl-0 pane"> + {/*<PcapPane />*/} <ConnectionContent connection={this.state.selectedConnection}/> </div> </div> |