Skip to content

vadhh/contactless-ordering-platform

Repository files navigation

Contactless Ordering Platform

A full-stack digital menu and ordering system designed for high-turnover restaurant environments. This solution provides a dual-interface architecture: a responsive client-side application for customers to browse and order, and a secured administration dashboard for real-time inventory and order management.

Built with Next.js, TypeScript, and MongoDB to ensure type safety, scalability, and performance.

Ask DeepWiki

🏗 Technical Architecture

Core Stack

  • Framework: Next.js (App Router)
  • Language: TypeScript (Strict mode enabled)
  • Database: MongoDB (Atlas) via Mongoose ODM
  • Authentication: NextAuth.js (JWT-based session management)
  • Styling: Tailwind CSS + Shadcn UI

Key Features

🟢 Client-Facing Application

  • Dynamic Routing: Category and product pages generated server-side for SEO optimization.
  • State Management: Local cart management with immediate UI feedback.
  • Responsive Design: Mobile-first approach optimized for QR code scanning contexts.

🔴 Admin Dashboard (Protected)

  • Authentication: Secure login gateway using NextAuth credentials provider.
  • Inventory Management: Full CRUD capabilities for Categories and Products.
  • Order Workflow: Real-time status updates (Pending -> Processed -> Completed).
  • Data Integrity: Mongoose schemas enforce strict typing on all database entries.

📂 Project Structure

├── src
│   ├── app          # Next.js App Router (Pages & API)
│   │   ├── (public) # Customer-facing routes
│   │   └── admin    # Protected admin routes
│   ├── components   # Reusable UI components (Shadcn/Custom)
│   ├── lib          # Utilities, Database Connectors, Models
│   └── types        # Global TypeScript definitions

##🚀 Getting Started Prerequisites Node.js (v18+) MongoDB Cluster (Local or Atlas)

##Installation Clone the repository

git clone [https://github.com/vadhh/contactless-ordering-platform.git](https://github.com/vadhh/contactless-ordering-platform.git)
cd contactless-ordering-platform
Install dependencies
npm install
Environment Configuration Create a .env.local file in the root directory. Configure the following variables:

Code snippet

Database Connection

MONGODB_URI=mongodb+srv://:@cluster.mongodb.net/menu_db

Authentication

Generate via: openssl rand -base64 32

NEXTAUTH_SECRET=your_generated_secret_key NEXTAUTH_URL=http://localhost:3000 Database Seeding (Optional) Populate the database with initial categories and products.

npx ts-node scripts/seed.ts
Run Development Server
npm run dev

🗺 Roadmap & Optimization

Payment Gateway: Integration with Stripe/Xendit for in-app payments.

RBAC Implementation: Differentiating roles between 'Manager' (Full Access) and 'Kitchen Staff' (Order View only).

Image Optimization: Integration with Cloudinary/AWS S3 for scalable asset hosting.

Analytics: Dashboard visualization for peak ordering times and best-selling items.

© 2025 Vadhh. MIT License.

About

A full-stack digital menu and ordering system designed for high-turnover restaurant environments.

Topics

Resources

License

Stars

Watchers

Forks