This is a server application for a medicine management system, developed as part of a Problem-Based Learning (PBL) project.
To run the application, you need to have Node.js and MongoDB installed on your system.
- Clone this repository to your local machine using
git clone https://github.com/varadpundlik/PBL_medicines_server.git
- Navigate to the project directory using
cd PBL_medicines_server
- Install the dependencies using
npm install
To start the server, run the following command: node index.js
Port :5000
Endpoint : http://localhost:5000/med
Parameters:
name
quantity
expiry date
purchase date
description
price
Description: To get all medicines data to medical store admin
Description: Post a new medicine stock in store database
Endpoint : http://localhost:5000/presc
Parameters:
name
doctor's name
email
med : (array of medicine name)
name:
quantity:
date:
Decription: Create a new prescription and recompute medical store stock according to medicines quantity
Endpoint : http://localhost:5000/check
Parameters:
name
doctor's name
email
med : (array of medicine name)
name:
quantity:
date:
Decription: Returns wheather a medicine is present in medical shop inventory or not
Endpoint : http://localhost:5000/mail
Parameters:
name
doctor's name
email
med : (array of medicine name)
name:
quantity:
date:
Decription: Sends a mail using nodemailer that prescription is ready
Endpoint : http://localhost:5000/mail/not
Parameters:
name
doctor's name
email
med : (array of medicine name)
name:
quantity:
date:
Decription: Sends a mail using nodemailer that prescription is ready but medicines are not available
Endpoint : http://localhost:5000/mail/delivered
Parameters:
name
doctor's name
email
med : (array of medicine name)
name:
quantity:
date:
Decription: Sends a mail using nodemailer that medicines are delivered
- Node.js - A JavaScript runtime built on Chrome's V8 JavaScript engine
- Express - A minimalist web framework for Node.js
- MongoDB - A document-based NoSQL database
Contributions to the project are welcome. To contribute, please follow these steps:
- Fork this repository to your own account
- Create a new branch for your feature or bug fix
- Make your changes and commit them with descriptive messages
- Push your changes to your fork
- Submit a pull request to this repository with a description of your changes
- Varad Pundlik (https://github.com/varadpundlik)