CS432-Databases-Assignment Svelte Themes

Cs432 Databases Assignment

A full stack web application (Svelte + Flask) designed as a buy-and-sell portal, developed as a course project to showcase real-world applications of database management principles

CS432-Databases-Assignment

A full stack web application (Svelte + Flask) designed as a buy-and-sell portal, developed as a course project to showcase real-world applications of database management principles

Installation Guide

  1. Clone the repository:

        git clone https://github.com/Naman-Dharmani/CS432-Databases-Assignment.git
    
  2. Navigate to the project directory:

        cd CS432-Databases-Assignment
    
  3. Create a virtual environment and make sure to activate it:

        python -m venv .venv
        source .venv/bin/activate # Linux
        .\.venv\Scripts\activate  # Windows CMD
        .\.venv\Scripts\Activate.ps1  # Windows PowerShell
    
  4. Install the server dependencies in virtual environment:

        pip install -r server/requirements.txt
        # pip3 in Linux
    
  5. Install Nodejs v18:

  6. Now, open the terminal/MySQL workbench and create a mysql database:

        CREATE DATABASE buy_sell;
    
  7. Change the config.yaml file inside server directory:

        mysql_host: "localhost"
        mysql_user: <mysql_username>
        mysql_password: <user_password>
        mysql_db: "buy_sell"
    
  8. Install the client dependencies:

        cd client
        npm install
    
  9. Go to the project dir and start the server, and wait until it starts

        cd ..
        python server/run.py
    
  10. In a new terminal, start the client:

        cd client
        npm run dev
    
  11. Now, visit the url shown in the terminal.

NOTE: The frontend is not available for some of the routes. For this we have created a api_test.rest file inside server directory that covers all the methods used in the routes file. Therefore, to test it out install a VSCode extension named REST Client by Huachao Mao. Inorder to test it use the send request option that appears before each of the routes in the api_test.rest file itself.

Top categories

Loading Svelte Themes