An open API service indexing awesome lists of open source software.

https://github.com/hode2002/smart-tech-store


https://github.com/hode2002/smart-tech-store

Last synced: about 1 year ago
JSON representation

Awesome Lists containing this project

README

          


Next.js Logo
Nest Logo



typescript
nextdotjs
tailwindcss
nestjs
mysql
mongodb
redis
prisma
docker
swagger

Smart Tech Store


## 📝 Project Description

Smart Tech Store is an e-commerce platform for electronic devices such as phones, laptops, and tech accessories. Users can easily search for products, view detailed information, read customer reviews, and take advantage of special offers.

## 🛠️ Tech Stack

- **TypeScript** - Programming language
- **Next.js** - Frontend framework
- **TailwindCSS** - CSS framework
- **ShadCN** - UI component library
- **Nest.js** - Backend framework
- **Prisma** - ORM
- **MySQL** - Primary database
- **MongoDB** - NoSQL database
- **Redis** - In-memory data store
- **Docker** - Containerization

## ✨ Key Features

### 👤 Customer Features

- **🔐 Authentication with JWT/Passport**: Create accounts or sign in through Facebook or Google
- **👤 Profile Management**: Update customer information (name, phone number, address, password)
- **🛒 Order Management**: Search products by keyword or category, add to cart, and checkout with COD or VNPAY
- **📦 Order Tracking**: Check order status, receive or cancel orders
- **⭐ Product Reviews**: View and submit product reviews after purchase

### 👑 Admin Features

- **📊 Admin Dashboard**: View statistics on revenue, product count, users, feedback, and orders
- **📋 Order Management**: Check revenue, approve orders by week/month/year, search orders by phone number or status
- **👥 Customer Management**: View registered users, their purchase history, and manage user accounts
- **🏷️ Product Management**: Add, edit, and view products, categories, brands, and product bundles
- **📰 News Management**: Create tech and product-related news articles
- **🎟️ Voucher Management**: Create, edit, and delete vouchers
- **🔔 Notification Management**: Create announcements about vouchers and promotions

## 🚀 Getting Started

### Prerequisites

- Node.js
- Docker and Docker Compose
- MySQL (if running locally)
- MongoDB (if running locally)
- Redis (if running locally)

### Installation

1. Clone the repository
```bash
git clone https://github.com/hode2002/smart-tech-store.git
cd smart-tech-store
```

2. Install dependencies
```bash
npm install --legacy-peer-deps
```

3. Create an `.env` file based on the example provided

4. Start the application with Docker
```bash
docker-compose up -d api
```

> ⚠️ **Note**: When running the application in a local environment, the Nginx service is not required. Nginx is only configured for use in a production environment.

### API Endpoints

The application includes RESTful API endpoints for:
- Products
- Orders
- Users
- Authentication
- Vouchers
- and more

### Project Structure

- `/src` - Main application source code
- `/api` - API endpoints
- `/v1` - API version 1
- `/v2` - API version 2
- `/common` - Common components
- `/config` - Configuration
- `/prisma` - Prisma service

### API Documentation

API documentation is automatically generated with Swagger and can be accessed at the root path of the application.