Skip to content

Latest commit

 

History

History
64 lines (49 loc) · 1.37 KB

README.md

File metadata and controls

64 lines (49 loc) · 1.37 KB

Web-Based Sales and Inventory System for LAKBAY

This project is a sales inventory management system built with React for the frontend and Node.js with Express for the backend. It uses PostgreSQL as the database.

Prerequisites

Before you begin, ensure you have met the following requirements:

  • Node.js and npm installed on your machine.
  • PostgreSQL installed and running.
  • A PostgreSQL database created with the necessary tables.

Installation

  1. Clone the repository:

    git clone https://github.com/miigo-dev/react-sales-inventory.git
    cd react-sales-inventory
  2. Install the backend dependencies:

    cd server
    npm install
  3. Install the frontend dependencies:

    cd client
    npm install

Configuration

  1. Create a .env file in the server directory and add your environment variables:
    PORT = 8080
    SECRET = supersecret
    
    CLIENT_URL = http://localhost:3000
    SERVER_URL = http://localhost:8080
    
    DB_USER = user
    DB_HOST = host
    DB_DATABASE = db
    DB_PASSWORD = password
    DB_PORT = port
    SSL_MODE = require

Running the Project

  1. Start the backend server:

    cd server
    npm run dev
  2. Start the frontend development server:

    cd client
    npm start
  3. Open your browser and navigate to http://localhost:3000.