Project Overview
The Advanced Pharmacy Management System Using MERN Stack is a web-based application designed to organize pharmacy operations through a centralized digital platform. It helps manage medicine records, stock availability, customer orders, supplier information, prescription reviews and sales reports.
Developed using MongoDB, Express.js, React.js and Node.js, the application includes a responsive interface built with Tailwind CSS. It supports three user roles: Administrator, Pharmacist and Customer, with access to relevant features according to each role.
Available Features
1. User Registration and Authentication
- Customer registration and login.
- JWT-based authentication for protected API endpoints.
- Password hashing using bcrypt.
- Profile information updates.
- Role-based access for administrators, pharmacists and customers.
2. Medicine Catalogue
- Maintain medicine names, SKU codes, categories and manufacturers.
- Store medicine descriptions, prices and product images.
- Record prescription requirements.
- Search and filter medicines by category.
- Sort products by price.
3. Shopping Cart and Order Management
- Add medicines to the shopping cart.
- Update product quantities and cart totals.
- Enter shipping addresses and place orders.
- Maintain customer order history.
- Track order status.
- Download order invoices.
4. Inventory and Batch Management
- Maintain medicine batch numbers and expiry dates.
- Record stock quantities and purchase prices.
- Add medicines and update inventory records.
- Check eligible, unexpired stock before accepting orders.
- Deduct quantities from eligible batches when orders are processed.
5. Low-Stock and Expiry Alerts
The dashboard identifies medicines with low stock and displays batches approaching their expiry dates. These indicators help pharmacy staff identify inventory that requires attention.
6. Prescription Management
- Upload prescriptions for medicines that require them.
- Accept supported PDF and image formats.
- Allow authorized staff to review submitted prescriptions.
- Update prescription approval status.
7. Supplier Management
Administrators and pharmacists can maintain supplier information, including supplier names, contact persons, email addresses, phone numbers and addresses.
8. Admin Dashboard and Reports
- Display medicine and customer counts.
- Show order counts and recorded sales statistics.
- Generate monthly sales summaries.
- Review top-selling items.
- View order status totals.
- Retrieve dashboard statistics from MongoDB records.
9. PDF Invoices and Email Notifications
The system generates downloadable PDF invoices containing order details, customer information, purchased items and totals. Email notifications can be enabled by configuring SMTP settings.
Administrator Workspace
- Manage medicines, inventory and suppliers.
- Manage users and customer records.
- Review orders and monitor pharmacy activity.
- Access inventory alerts and sales reports.
Pharmacist Workspace
- Manage medicine records and stock.
- Review prescription submissions.
- Process orders and monitor stock availability.
- Maintain supplier information.
Customer Workspace
- Browse and search the medicine catalogue.
- View medicine details.
- Manage the shopping cart.
- Place orders and review order history.
- Update profile information.
- Upload prescriptions when required.
- Download available invoices.
Technology Stack
- Frontend: React.js
- Styling: Tailwind CSS
- Backend: Node.js and Express.js
- Database: MongoDB
- Authentication: JSON Web Tokens (JWT)
- Password Security: bcrypt
- API Architecture: RESTful APIs
Software and Tools Required
- Node.js and npm
- MongoDB installed locally or a MongoDB Atlas database
- Visual Studio Code
- A web browser
- Environment configuration for database connectivity and JWT secrets
More Details and Full Documentation
View Advanced Pharmacy Management System Using MERN Stack Details
- Install Node.js and npm on your computer.
- Install MongoDB locally or create a MongoDB Atlas database.
- Install Visual Studio Code.
- Extract the project ZIP file and open the pharmacy-management-mern folder in VS Code.
- Open a terminal and navigate to the backend folder using: cd backend
- Install backend dependencies using: npm install
- Copy .env.example to .env and configure the MongoDB connection.
- Set a strong random JWT secret in the backend .env file.
- Ensure MongoDB is running and the connection string is correct.
- Initialize the database using: npm run seed
- Start the backend server using: npm run dev
- Confirm that the backend API is running, normally at http://localhost:5000.
- Open a second terminal in VS Code.
- Navigate to the frontend folder using: cd frontend
- Install frontend dependencies using: npm install
- Start the frontend using: npm run dev
- Open the frontend URL displayed in the terminal, usually http://localhost:5173.
- Register or sign in with an appropriate account.
- Test medicine browsing, cart management, order placement, inventory updates and prescription workflows.
- Verify that dashboard statistics and reports reflect the database records.
- Configure SMTP settings if email notifications are required.
- Remember that online payment processing and live order tracking are not included in the current implementation.
Stuck while running it? Chat with us on WhatsApp for free installation help.
No reviews yet. Be the first to review this project.