Skip to content

Latest commit

 

History

History
239 lines (154 loc) · 13.8 KB

README.md

File metadata and controls

239 lines (154 loc) · 13.8 KB

Pharma Space (Virtual Pharmacy)

App Screenshot Pharma space is a comprehensive and innovative platform designed to enhance the efficiency and accessibility of healthcare services. The system caters to the needs of patients, pharmacists, and administrators, providing a seamless experience for managing medical information, prescriptions, and medication inventory.

Motivation

The motivation behind this project stems from a deep commitment to enhancing healthcare accessibility. By creating a centralized platform, the goal is to make healthcare services readily available to a wider audience, ensuring patients can easily connect with pharmacists and access vital medical information.

Build Status

The project is currently in the development stage, progressing through milestones with continuous improvements in code implementation and execution. Notable learning curves were experienced during sprints 2 and 3, particularly in the areas of authentication and user login.

Challenges Faced

One prominent issue encountered was the slowness in fetching data from the backend to the frontend. Despite this challenge, the frontend functionality remains robust, albeit with some organizational improvements needed.

Future Considerations

Looking ahead, the project will require deployment, likely through platforms such as Google Cloud or similar services, to ensure accessibility and scalability in the near future.

Code Style

This project follows a specific code style to ensure consistency and readability across the codebase. Adopting a consistent coding style is important for collaboration and maintenance.

We adhere to the Standard Code Style Guide for this project. Please review the guide before contributing to ensure that your code aligns with our established conventions.

Screenshots

Screenshot1

Screenshot2

Screenshot3

Screenshot4

Screenshot5

Screenshot6

Tech/Framework used

  • MERN Stack (MongoDB, Express.js, React.js, Node.js)
  • JavaScript

Key Features

1. User Registration and Authentication:

  • Guests can register as patients, providing essential details such as username, name, email, password, date of birth, gender, and emergency contact information.
  • Pharmacists can submit requests for registration, including details like username, name, email, and professional qualifications.

2. User Management:

  • Administrators have the ability to add or remove other administrators, ensuring smooth system operation.
  • Removal of patients or pharmacists from the system is facilitated by administrators.

3. Medicine Information:

  • Patients, pharmacists, and administrators can access a detailed list of available medicines, including images, prices, and descriptions.
  • Pharmacists can view the quantity and sales data for each medicine.

4. Cart Management and Checkout:

  • Patients can add both over-the-counter and prescription medicines to their cart.
  • Multiple delivery addresses can be added and selected during the checkout process.
  • Flexible payment options include wallet, credit card (using Stripe), or cash on delivery.

5. Order Management:

  • Patients can view detailed order information, check the status, and cancel orders if needed.
  • Pharmacies receive notifications for out-of-stock medicines and can manage inventory accordingly.

6. Reporting and Analysis:

  • Administrators and pharmacists can generate total sales reports based on a chosen month.
  • Pharmacists can filter sales reports based on specific medicines or dates.

7. Communication Features:

  • A chat feature allows patients and pharmacists to communicate with each other.
  • Pharmacists can also engage in doctor-patient communication.

8. Wallet and Refunds:

  • Patients can view the amount in their wallet, including funds due to order cancellations.
  • Pharmacists can track wallet funds related to monthly salary payments.

9. Additional Functionalities:

  • Patients can view current and past orders, search for medicines, and explore alternatives for out-of-stock items.
  • Pharmacists have the ability to archive and unarchive medicines, ensuring sales information is preserved.

Code Examples

Ex1

Ex2

Ex3

Ex4

Ex5

Installation

These instructions will help you get a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.

  1. Click on code -> Download ZIP

  2. Extract the zip file and open it in visual studio code.

  3. Navigate to the server folder using the terminal and run the following command:

     npm install
    
  4. Next, navigate to the client folder in the terminal and run the following command:

     npm install
    

How To Use

To launch the project locally, follow these steps:

Navigate to the server folder using the terminal and run the following command:

    npm start

Next, navigate to the client folder in the terminal and run the following command:

    npm start

API References

1. Express.js(express)

  • Description: Web application framework for Node.js, used for building the backend server and handling HTTP requests.
  • Documentation: Express.js Documentation

2. Mongoose(mongoose)

  • Description: Elegant Object Data Modeling (ODM) library for MongoDB and Node.js, streamlining interaction with MongoDB.
  • Documentation: Mongoose Documentation

3. Axios(axios)

  • Description: Promise-based HTTP client for making HTTP requests, facilitating seamless communication with external APIs.
  • Documentation: Axios Documentation

4. Bcrypt(bcrypt)

  • Description: Library for hashing and salting passwords, fortifying the project's password security.
  • Documentation: Bcrypt Documentation

5. Cors(cors)

  • Description: Middleware for Express.js enabling Cross-Origin Resource Sharing (CORS), granting controlled access to server resources.
  • Documentation: Cors Documentation

6. Dotenv(dotenv)

  • Description: Zero-dependency module seamlessly loading environment variables from a .env file into process.env.
  • Documentation: Dotenv Documentation

7. Jsonwebtokens(jsonwebtoken)

  • Description: Robust library for creating and verifying JSON Web Tokens (JWT), a cornerstone for user authentication.
  • Documentation: Jsonwebtoken Documentation

8. Morgan(morgan)

  • Description: Express.js middleware providing an HTTP request logger, capturing essential information about incoming requests.
  • Documentation: Morgan Documentation

9. Multer(multer)

  • Description: Middleware tailored for handling multipart/form-data, an essential tool for efficient file uploads.
  • Documentation: Multer Documentation

10. Nodemailer(nodemailer)

  • Description: Powerful module for sending emails, often utilized for tasks like dispatching confirmation emails.
  • Documentation: Nodemailer Documentation

11. Nodemon(nodemon)

  • Description: Intelligent utility monitoring changes in source code and autonomously restarting the server.
  • Documentation: Nodemon Documentation

12. Socket.io(^4.7.2)

  • Description: Real-time bidirectional event-based communication library for Node.js. Facilitates real-time communication between web clients and servers.
  • Documentation: Socket.IO Documentation

13. Stripe(@stripe/stripe-js and stripe)

For detailed information and usage instructions, refer to the official documentation linked above for each API.

Tests

To ensure the proper functioning of this project, you can perform various tests using tools like Postman. Below are some examples demonstrating how to test different aspects of the code.

Prerequisites

  • Before running the tests, make sure you have Postman installed on your machine.

Ex1

Ex2

Ex3

Ex4

Contribute

We welcome contributions from the community! If you'd like to contribute to the development of this project, follow these guidelines:

  1. Fork the Repository: Click on the "Fork" button on the top right corner of this repository's page.

  2. Clone the Repository: Clone the forked repository to your local machine using the following terminal command:

     git clone https://github.com/your-username/your-forked-repo.git
    
  3. Create a Branch: Create a new branch for your contributions:

     git checkout -b feature/your-feature-name
    
  4. Make Changes: Make your desired changes to the codebase.

  5. Commit Changes: Commit your changes with a meaningful commit message:

     git commit -m "Add your meaningful commit message here"
    
  6. Push Changes: Push your changes to your forked repository:

     git push origin feature/your-feature-name
    
  7. Create a Pull Request (PR): Open a Pull Request against the main branch of the original repository. Provide a clear title and description for your changes.

  8. Code Review: Participate in the code review process. Make any requested changes if needed.

  9. Merge: Once your changes are approved, they will be merged into the main branch.

Thank you for contributing to our project! 🚀

Credits

License

This project is licensed under the MIT License & Apache License