updated Pools to Group

This commit is contained in:
Joshua Hsueh 2021-04-10 13:37:35 -04:00
parent 100f2f815f
commit 4d7de9d014
2 changed files with 51 additions and 54 deletions

View File

@ -1,8 +1,7 @@
import React from 'react'; import React from 'react';
import { BrowserRouter, Route, Switch } from 'react-router-dom'; import { BrowserRouter, Route, Switch } from 'react-router-dom';
import Nav from './components/Nav'; import Nav from './components/Nav';
import Signin from './components/auth/Signin';
import Signup from './components/auth/Signup';
import Group from './components/Group'; import Group from './components/Group';
import Pool from './components/Pool'; import Pool from './components/Pool';
import Profile from './components/Profile'; import Profile from './components/Profile';

View File

@ -3,58 +3,56 @@ import { API_ENDPOINT } from '../api';
const Group = (props) => { const Group = (props) => {
const id = props.match.params.id; const id = props.match.params.id;
const [state, setState] = useState({ const [pools, setPools] = useState([
Pools: [ {
{ id: 1,
id: 1, pool_title: 'TJ Carpool',
pool_title: 'TJ Carpool', pool_text: 'Carpool from TJ track to homes',
pool_text: 'Carpool from TJ track to homes', start_time: '4/10/2021 3:00 PM',
start_time: '4/10/2021 3:00 PM', end_time: '4/10/2021 4:00 PM',
end_time: '4/10/2021 4:00 PM', capacity: 2,
capacity: 2, participants: [],
participants: [], comments: [
comments: [ 'What is the covid vaccination status of all the participants?',
'What is the covid vaccination status of all the participants?', ],
], },
}, {
{ id: 2,
id: 2, pool_title: 'TJ Carpool',
pool_title: 'TJ Carpool', pool_text: 'Carpool from TJ track to homes',
pool_text: 'Carpool from TJ track to homes', start_time: '4/10/2021 3:00 PM',
start_time: '4/10/2021 3:00 PM', end_time: '4/10/2021 4:00 PM',
end_time: '4/10/2021 4:00 PM', capacity: 2,
capacity: 2, participants: [],
participants: [], comments: [
comments: [ 'What is the covid vaccination status of all the participants?',
'What is the covid vaccination status of all the participants?', ],
], },
}, {
{ id: 3,
id: 3, pool_title: 'TJ Carpool',
pool_title: 'TJ Carpool', pool_text: 'Carpool from TJ track to homes',
pool_text: 'Carpool from TJ track to homes', start_time: '4/10/2021 3:00 PM',
start_time: '4/10/2021 3:00 PM', end_time: '4/10/2021 4:00 PM',
end_time: '4/10/2021 4:00 PM', capacity: 2,
capacity: 2, participants: [],
participants: [], comments: [
comments: [ 'What is the covid vaccination status of all the participants?',
'What is the covid vaccination status of all the participants?', ],
], },
}, {
{ id: 4,
id: 4, pool_title: 'TJ Carpool',
pool_title: 'TJ Carpool', pool_text: 'Carpool from TJ track to homes',
pool_text: 'Carpool from TJ track to homes', start_time: '4/10/2021 3:00 PM',
start_time: '4/10/2021 3:00 PM', end_time: '4/10/2021 4:00 PM',
end_time: '4/10/2021 4:00 PM', capacity: 2,
capacity: 2, participants: [],
participants: [], comments: [
comments: [ 'What is the covid vaccination status of all the participants?',
'What is the covid vaccination status of all the participants?', ],
], },
}, ]);
],
});
useEffect(() => { useEffect(() => {
console.log(process.env); console.log(process.env);