Update main routes
This commit is contained in:
parent
d723b0bc1d
commit
ec4aff68ef
3 changed files with 6 additions and 5 deletions
|
|
@ -2,10 +2,7 @@ import React from 'react'
|
||||||
import WeaponGrid from '../../components/WeaponGrid/WeaponGrid'
|
import WeaponGrid from '../../components/WeaponGrid/WeaponGrid'
|
||||||
|
|
||||||
const New = () => (
|
const New = () => (
|
||||||
<div>
|
<WeaponGrid key="weapon_grid"/>
|
||||||
<h1>New party</h1>
|
|
||||||
<WeaponGrid />
|
|
||||||
</div>
|
|
||||||
)
|
)
|
||||||
|
|
||||||
export default New
|
export default New
|
||||||
|
|
@ -13,6 +13,7 @@ class Parties extends React.Component {
|
||||||
parties: []
|
parties: []
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
getParties() {
|
getParties() {
|
||||||
fetch('http://localhost:3001/parties/')
|
fetch('http://localhost:3001/parties/')
|
||||||
.then(response => response.json())
|
.then(response => response.json())
|
||||||
|
|
|
||||||
|
|
@ -1,12 +1,15 @@
|
||||||
import React from 'react'
|
import React from 'react'
|
||||||
import { withRouter } from 'react-router'
|
import { withRouter } from 'react-router'
|
||||||
|
|
||||||
|
import WeaponGrid from '../../components/WeaponGrid/WeaponGrid'
|
||||||
|
|
||||||
class Party extends React.Component {
|
class Party extends React.Component {
|
||||||
render() {
|
render() {
|
||||||
var hash = this.props.match.params.hash
|
var hash = this.props.match.params.hash
|
||||||
return (
|
return (
|
||||||
<div>
|
<div>
|
||||||
<h1>A specific party with hash: {hash}</h1>
|
<h1>{hash}</h1>
|
||||||
|
<WeaponGrid />
|
||||||
</div>
|
</div>
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue