Skip to content
This repository has been archived by the owner on Oct 1, 2022. It is now read-only.

Commit

Permalink
Nashe
Browse files Browse the repository at this point in the history
  • Loading branch information
Bihart committed Oct 21, 2021
1 parent 697d6f0 commit f00c7de
Show file tree
Hide file tree
Showing 5 changed files with 18 additions and 7 deletions.
1 change: 1 addition & 0 deletions client/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
"@types/node": "^16.10.3",
"@types/react": "^17.0.27",
"@types/react-dom": "^17.0.9",
"d3": "^7.1.1",
"react": "^17.0.2",
"react-dom": "^17.0.2",
"react-scripts": "4.0.3",
Expand Down
6 changes: 3 additions & 3 deletions client/src/App.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@ function App() {

return (
<Fragment>
<div className="flex flex-row h-screen w-screen">
<ul className="flex flex-col bg-gray-100 h-1/2 w-1/6">
<div className="flex flex-row min-h-screen w-screen">
<ul className="flex flex-col bg-gray-100 w-1/6">
<li className="bg-green-100 p-1 hover:bg-green-300 text-center cursor-pointer">
<input id="Home"
className="bg-transparent"
Expand All @@ -44,7 +44,7 @@ function App() {
value="Graph"/>
</li>
</ul>
<div className="bg-gray-200 flex-auto h-1/2 p-10">
<div className="bg-gray-200 flex-auto p-10 ">
<Content view={view} />
</div>
</div>
Expand Down
15 changes: 12 additions & 3 deletions client/src/Graph/Graph.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,20 @@ async function fetchData(host) {
return data;
}

const showData = () => {
fetchData('http://localhost:5000/api').then((data) => {
// const ans = Object.values(data[3]);
console.log(data);
});
};

function Graph(){
return (
<p>
Graph is work!
</p>

<button className="bg-blue-400 px-2 py-4"
onClick={showData}>
Graph the info
</button>
)
}

Expand Down
2 changes: 1 addition & 1 deletion server/generate_data/entry_point.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@


class HelloWorld(Resource):
json = pd.read_json('outj.json')
json = pd.read_json('outj2.json')
to_json = json.to_dict()
@cross_origin()
def get(self):
Expand Down
1 change: 1 addition & 0 deletions server/generate_data/outj2.json

Large diffs are not rendered by default.

0 comments on commit f00c7de

Please sign in to comment.