00
    Full-Stack / E-Commerce

    ElegantJewels

    A production-ready e-commerce platform for a jewellery business, covering everything from product browsing and checkout to admin analytics, staff management, and virtual consultations.

    React
    Vite
    Redux Toolkit
    Express.js
    MongoDB
    Socket.io
    Razorpay
    Cloudinary
    Firebase
    JWT
    Bootstrap
    ApexCharts
    Live Demo

    The Problem

    Jewellery retailers manage intricate product catalogues with variants like ring size, carat weight, and metal type, each with its own pricing and stock level. Off-the-shelf platforms cannot handle this complexity: pricing changes per gram of gold, and the business needs its own content, appointments, and return workflows, all under one roof with multiple staff roles.

    The Outcome

    Delivered a fully functional two-app platform: a customer storefront and a role-controlled admin dashboard powered by a single Express/MongoDB backend. Admins get live order and revenue data via Socket.io; customers get a smooth checkout flow end-to-end with Razorpay.

    Overview

    ElegantJewels is a full-stack e-commerce platform built for a jewellery retail business. It replaces manual processes with two dedicated applications: a customer-facing storefront and a staff-facing admin dashboard, both served by a single Node.js/Express backend with MongoDB. The platform handles the complete retail lifecycle: product discovery, cart and checkout, payment, order fulfilment, returns, and refunds. On the admin side it adds content management, appointment and video-call scheduling, real-time business analytics, and a role-based staff system with seven distinct access levels.

    Approach

    The backend follows a feature-based folder structure where each domain (authentication, orders, products, payment) is a self-contained module with its own model, controller, service, route, and validation. Role-based access is enforced at the middleware layer so route handlers never need to check permissions themselves. The frontend is split into two React apps within the same Vite project, sharing a Redux Toolkit store and a common component library. The admin dashboard receives live data through a Socket.io connection, with the server broadcasting aggregate metrics whenever orders or payments are created or updated.

    Architecture Highlights

    Dual-App Architecture

    Customer storefront and admin dashboard as two separate React apps sharing one Express/MongoDB backend and a common Redux store.

    Real-time Dashboard

    Socket.io broadcasts live order and revenue aggregates to the admin panel the moment a transaction is created or updated.

    Seven-Role RBAC

    Middleware-enforced access control across seven staff roles: admin, seller, manager, product manager, content editor, customer service, and customer.

    Key Features

    • Product catalogue with multi-variant support: ring size, carat, metal type, purity, and colour, each with independent pricing and cost breakdown
    • Cost tracking per material: gold priced per gram, diamonds per carat, gemstones and other costs, summed automatically into the final selling price
    • Persistent cart stored in the database with coupon validation, per-item tax calculation, and automatic total recalculation on every change
    • End-to-end Razorpay checkout: backend order creation, frontend capture, failure and timeout handling, and admin-initiated refunds
    • Admin dashboard with real-time metrics via Socket.io: live revenue, order counts, customer growth, and best-selling product rankings
    • Seven-role access control system: customer, admin, seller, manager, product manager, content editor, and customer service, each enforced at the API middleware level
    • Cloudinary image management for products and blog content with organised folder structure and direct upload from the admin panel
    • Blog CMS with Quill rich-text editor, image and video content support, and a public comment system
    • Appointment booking and video-call consultation scheduling with an admin approval and status workflow
    • Return and refund workflow: customer raises a request, admin processes it, status tracked end-to-end and tied back to the payment record

    Challenges Solved

    • Designing the multi-variant product schema so each variant stores its own cost array, pricing, stock level, and attributes while remaining queryable in a single aggregation for the product listing page
    • Building the RBAC middleware to handle seven roles with overlapping permissions without scattering permission checks across controller logic
    • Wiring Socket.io to order and payment events so the admin dashboard receives accurate, low-latency metric updates without polling, while avoiding duplicate event emissions on reconnect
    • Managing the Razorpay payment lifecycle across two apps: creating the order on the backend, handing off to the SDK on the frontend, verifying the signature server-side, then propagating the captured or failed status back to the order and cart records
    • Keeping the cart consistent under concurrent updates: coupon validity checks, tax recalculation, and variant-level price changes all resolve against the current database state rather than cached frontend values

    By the Numbers

    14+

    DB Models

    7

    User Roles

    50+

    API Endpoints

    2

    Applications

    Interested in this project?

    Let's discuss how I can build something similar for you.