Hanarebanare no machi o tsunagu ressha wa itte shimatta ne
DNATrain is a web application for diagnosing sickness on a patient by doing pattern matching on patient's DNA with the pattern on Database.
- Front-End : React
- Back-End : Golang with Echo
- Database : MySQL on Planetscape
- Node (Node 16)
- Golang (go 1.18)
└── src // All code directory
├── backend // Backend code directory
│ ├── libs // Custom libs used by backend
│ └── web // Backend web module
│ ├── database
│ ├── handler
│ ├── model
│ ├── router
│ └── server
└── frontend_next // Frontend code directory
├── components
├── pages
├── public
└── styles
How to start server locally
- Change directory to
src/backend
- Duplicate
.env.example
and rename it into.env
, then put the DB_URL using your own url, example:root@tcp(localhost:1234)/dnatrain?parseTime=true
.dnatrain
is the name of the database. make sure the last argument?parseTime=true
is used; - Install golang packages using
go get
command - Run server using
go run main.go
- Check running server on
localhost:$PORT
- Change directory to
src/frontend_next
- Install node packages using
npm i
command - Open
axios.js
insrc/frontend_next/lib
, locate variablebaseURL
, change the string tohttp://localhost:$PORT
and replacing$PORT
with the actualy port number on the.env
file (check Backend section) - Run server using
npm run dev
- Check running server on
localhost:$PORT
Adjust to the existing local DBMS if necessary
- Create new database named
dnatrain
- make sure the name of the database is the same as written on DB_URL (Refer to backend section). - Create table named
penyakit
with attributename
with typevarchar(255)
(string) and attributedna
with typevarchar(255)
. - Create table named
test
with attributetanggal
with typedatetime
, attributename
with typevarchar(255)
, attributenama_penyakit
with typevarchar(255)
,kecocokan
with typedouble
, and attributecocok
with typeboolean
The Tambah Test
requires the list of penyakit
(diseases) to not be empty, therefore, add any penyakit
in Tambah Penyakit
page before proceeding to do Tambah Test
- Dzaky Fattan Rizqullah (13520003)
- Yohana Golkaria Nainggolan (13520053)
- Rifqi Naufal Abdjul (13520062)