Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

9 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

๐Ÿ›’ Ecommerce Multiโ€‘Vendor Platform

Java React Database Auth Status License

An advanced multiโ€‘vendor eโ€‘commerce web application with a Spring Boot backend and a React + TypeScript frontend.
Supports customers, sellers, and admins with authentication, product/catalog management, checkout with Razorpay/Stripe, analytics, and more.


๐Ÿ“ Monorepo Layout

Ecommerce-react-spring-boot/
โ”œโ”€ Ecomm-react-tsx-frontend/     # React + TypeScript app (Redux Toolkit, MUI, Tailwind)
โ””โ”€ Ecomm-springboot-backend/      # Spring Boot REST API (JWT, Spring Security, MySQL)

๐Ÿงฐ Tools

  • IntelliJ IDEA โ€ข VS Code โ€ข Node.js โ€ข MySQL

๐Ÿงฑ Tech Stack

Backend

  • Spring Boot, Spring Security, JWT
  • Java Mail Sender
  • MySQL (JPA/Hibernate)

Frontend

  • React (TypeScript)
  • Redux Toolkit, React Router DOM, Axios
  • Tailwind CSS, MUI
  • React Chart
  • Formik + Yup

Payments

  • Razorpay (India)
  • Stripe (International)

โœจ Features

๐Ÿ‘ค Customer

  • Chatbot for queries (order history, cart, product details)
  • Browse products with filter, sort, pagination
  • Cart: add/update/remove
  • Checkout: coupons, addresses, Razorpay/Stripe
  • Orders: view/cancel
  • Account management
  • Wishlist (add/remove)
  • Reviews & ratings

๐Ÿ›๏ธ Seller

  • Dashboard with earnings graphs (today / last 7 days / last 12 months)
  • Reports: sales, earnings, refunds, cancellations
  • Product CRUD
  • Order management
  • Payment & transaction history
  • Profile management

๐Ÿ› ๏ธ Admin

  • Admin dashboard
  • Seller approval/suspension
  • Coupon CRUD
  • Home page management
  • Deal/promo management

๐Ÿ—‚๏ธ Core Entities (ER Overview)

erDiagram
  User ||--o{ Address : has
  User ||--o{ Order : places
  User ||--o{ Review : writes
  User ||--o{ Transaction : performs
  User ||--|| Wishlist : "has 1"
  User ||--|| Cart : "has 1"

  Cart ||--o{ CartItem : contains
  CartItem }o--|| Product : refers

  Product }o--|| Category : belongs_to
  Product ||--o{ Review : receives
  Product }o--|| Seller : offered_by

  Order ||--o{ OrderItem : contains
  OrderItem }o--|| Product : refers
  Order }o--|| Address : ships_to
  PaymentOrder ||--o{ Order : includes

  Coupon }o--o{ User : used_by

  Seller ||--o{ Product : sells
  Seller ||--o{ Transaction : participates_in
  Seller ||--|| SellerReport : "has 1"

  VerificationCode ||--|| User : "may belong to"
  VerificationCode ||--|| Seller : "may belong to"
Loading

Note: Diagram is indicative; actual fields/constraints live in the code.


๐Ÿš€ Getting Started

1) Backend (Spring Boot)

cd Ecomm-springboot-backend

# If using Maven Wrapper (recommended)
./mvnw spring-boot:run    # Linux/macOS
# or
mvn spring-boot:run       # Windows if mvnw not available

Create src/main/resources/application.properties:

spring.datasource.url=jdbc:mysql://localhost:3306/ecommerce_multi_vendor?useSSL=false&serverTimezone=UTC
spring.datasource.username=YOUR_DB_USER
spring.datasource.password=YOUR_DB_PASSWORD

spring.jpa.hibernate.ddl-auto=update
spring.jpa.show-sql=true

# JWT
app.jwt.secret=change-me
app.jwt.expiration-ms=86400000

# Mail (configure if needed)
spring.mail.host=smtp.gmail.com
spring.mail.port=587
spring.mail.username=YOUR_EMAIL
spring.mail.password=YOUR_APP_PASSWORD
spring.mail.properties.mail.smtp.auth=true
spring.mail.properties.mail.smtp.starttls.enable=true

# Payment keys (use env vars / config server for production)
razorpay.key_id=YOUR_RAZORPAY_KEY
razorpay.key_secret=YOUR_RAZORPAY_SECRET
stripe.secret_key=YOUR_STRIPE_SECRET

2) Frontend (React + TS)

cd Ecomm-react-tsx-frontend
npm install
npm run dev   # http://localhost:5173 or http://localhost:3000 depending on tooling

Create .env (example):

VITE_API_BASE_URL=http://localhost:8080/api
VITE_RAZORPAY_KEY_ID=YOUR_RAZORPAY_PUBLIC_KEY
VITE_STRIPE_PK=YOUR_STRIPE_PUBLISHABLE_KEY

๐Ÿ”Œ API & Integration Flow (High Level)

  1. React UI action โ†’ 2. Axios call to /api/ โ†’
  2. Spring Service + Repository โ†’ 4. MySQL โ†’
  3. JSON response โ†’ 6. Redux/Component state โ†’ 7. Render UI

๐Ÿงช Scripts

Frontend

npm run dev       # start dev server
npm run build     # production build
npm run preview   # preview production build

Backend (Maven)

mvn spring-boot:run
mvn test
mvn package

๐Ÿ›ฃ๏ธ Roadmap

  • MySQL setup
  • First API & entity models
  • Spring Security (login/signup) + JWT
  • Services & Controllers
  • API testing
  • Full frontend integration
  • Seller/admin advanced dashboards
  • Production hardening (Docker, CI/CD, metrics, logs)

๐Ÿ“ธ Screenshots

Homepage

Homepage

Login Page

Login:


๐Ÿ” Security Notes

  • Store secrets in environment variables or a vault (never commit keys).
  • Use HTTPS in production.
  • Validate & sanitize all inputs (backend + frontend).
  • Apply CORS rules to allowed origins only.

๐Ÿค Contributing

  1. Fork โ†’ create feature branch โ†’ commit โ†’ open PR.
  2. Prefer small, focused changes.
  3. Add/adjust tests when touching business logic.

๐Ÿ“„ License

MIT โ€” see LICENSE for details.

About

An advanced E-commerce Multi-Vendor Web Application built with Spring Boot for the backend and React + TypeScript for the frontend. The platform supports multiple vendors, secure authentication, and seamless payment integration for both Indian and international users.

Topics

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages