GithubHelp home page GithubHelp logo

yemkhaung / thingaha-web Goto Github PK

View Code? Open in Web Editor NEW

This project forked from thingaha/thingaha-web

0.0 1.0 0.0 576 KB

Web Application for Thingaha Donation Management

Python 59.72% HTML 1.17% JavaScript 38.42% Batchfile 0.16% Shell 0.20% Mako 0.33%

thingaha-web's Introduction

Thingaha Donation Project

thingaha-web is a web application to make life easier for thingaha donation group monthly donation data tracking and workflows.

Backend

Pre-requisite

  1. Flask with python3
  2. PostgreSQL == 12.3

Environment setup

  • install anaconda from anaconda webpage
  • install pgadmin4 (optional)
  • create the database with username,password in conf_dev, conf_test
create virtual environment
conda create -n <envname>
conda activate <envname>
pip install -r ~/thingaha/backend/requirements.txt
  • DB migrate
for linux, macOS -> go backend/bin and run -> ./db_migrate.sh
for windows -> go to backend\bin and run -> db_migrate.bat


#memo
postgres url be like [DB_TYPE]+[DB_CONNECTOR]://[USERNAME]:[PASSWORD]@[HOST]:[PORT]/[DB_NAME]
  • DB Seed
for linux, macOS -> go backend/bin and run -> ./db_seed.sh
for windows -> go to backend\bin and run -> db_seed.bat
  • ERD Diagram for Thingaha Project

alt text

  • Start the server
for linux, macOS -> go backend/bin and run -> ./start_app.sh
for windows -> go to backend\bin and run -> start_app.bat
  • Start using API
- Default server port is 5000: 
- All API required JWT token for access data 
- Get the access token from login. 
    -- init user_email: [email protected]
    -- init user_pass: 123
    -- login URL : => 
        -- [POST] http://localhost:5000/api/v1/login
- API docs can be found in https://github.com/thingaha/thingaha-web/tree/master/backend/docs
  • Start the test case
for linux, macOS -> go backend/bin and run -> ./start_test.sh
for windows -> go to backend\bin and run -> start_test.bat
  • For the Postman user, please import bin/db_seed/thingaha.postman_collection.json for API testing

Frontend

This project was bootstrapped with Create React App.

Main UI framework is Material UI. For component styling, styled-components is used.

Pre-requisite

Getting Started

  • First, install tools listed in pre-requisite section.
  • Then, set up the draft api server. We're using a draft api server with canned response before backend is ready
    • To set up draft api server, cd into the draft_server directory and install necessary node modules by running yarn install.
    • Then, run yarn start
    • The draft server is configured to run on port 9000. Try navigating to http://localhost:9000/users to see if draft server is working properly.
  • Then set up the frontend app.
    • To set up frontend dev server, cd into the frontend directory and install necessary node modules by running yarn install.
    • Then, run yarn start
    • The frontend dev server is configured to run on port 5001. Try navigating to http://localhost:5001/ to see the app in action.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.