0% found this document useful (0 votes)
9 views22 pages

cs project n

cs investigatory project on medical shop
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
9 views22 pages

cs project n

cs investigatory project on medical shop
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 22

CERTIFICATE

CERTIFICATE

This is to certify that, Akilesh a student of class XII has successfully


completed the research project on the topic “MEDICAL SHOP
MANAGEMNT SYSTEM” under the guidance of Mr.Saravanan (Subject
Teacher).

This project is absolutely genuine and does not indulge in plagiarism of


any kind.

The references taken in making this project have been declared at the end
of this report.

Signature ( Subject Teacher) Signature ( Examiner)


ACKNOWLEDEMENT
ACKNOWLEDGEMENT

I feel proud to present my Investigatory project in Computer on the topic


“MEDICAL SHOP MANAGEMENT SYSTEM” which aims at using
Bleaching powder as a disinfectant and purifier to make water fit for
drinking.

This project wouldn’t have been feasible without the proper and rigorous
guidance of my Compter teacher Mr.Sarvanan who guided me throughout
this project in every possible way. An investigatory project involves various
difficult lab experiments which have to be carried out by the student to
obtain the observations and conclude the report on a meaningful note.
These experiments are very critical and in the case of failure, may result in
disastrous consequences. Thereby, I would like to thank both Mr.Saravanan
for guiding me on a step by step basis and ensuring that I completed all my
PROBLEMS with ease.

Rigorous hard work has been put in this project to ensure that it proves to be
the best. I hope that this project will prove to be a breeding ground for the next
generation of students and will guide them in every possible way.
Project
overview
Project overview

A Medical Shop Management System is a computerized program


designed to streamline the operations of a medical store, pharmacy, or
clinic. The system aims to automate and manage various aspects of the
medical shop, including inventory, sales, customer information,
employee management, and reporting.

Objectives:

1. To reduce manual errors and increase efficiency in managing medical


supplies and inventory.

2. To provide accurate and up-to-date information on stock levels, sales,


and customer transactions.

3. To improve customer service by enabling easy access to product


information and facilitating efficient billing and payment processes.

4. To enhance employee management by tracking work hours, attendance,


and performance.

5. To generate reports and analytics to aid in business decision-making


and strategic planning.

Conclusion:

The Medical Shop Management System program is a valuable tool for


medical stores, pharmacies, and clinics, enabling them to streamline
operations, improve customer service, and make data-driven decisions
System analysis
SYSTEM
ANALYSIS
3.1. THEORETICAL BACKGROUND

► WHAT IS PYTHON?

Python is an interpreted, object-oriented, high-level


progra1n1ning language with dyna1nic semantics. Its high-
level built in data structures, combined with dynamic typing
and dynamic binding, make it very attractive for Rapid
Application Develop1nent, as well as for use as a scripting or
glue language to connect existing con1ponents together.
Python's simple, easy to lean1 syntax emphasizes readability
and therefore reduces the cost of progran1 maintenance.
Python supports 1nodules and packages, which encourages
program modularity and code reuse. The Python interpreter
and the extensive standard library are available in source or
binary form without charge for all major platforms, and can
be freely distributed.
► WHAT IS MySQL?

The management of data in a database systen1 is done by means


of a general-purpose software package called a Database
Manage1nent Syste1n (DBMS). So1ne commercially available
RDBMS are MS SQL Server, MS ACCESS, INGRES,
ORACLE, and Sybase. MySQL, the 1nost popular Open-Source
SQL database management system, is developed, distributed,
and supported by Oracle Corporation.
It is possible for anyone to use and modify the software.
Anybody can download the MySQL software fro1n the
Internet and use it without paying anything. If you wish, you
may study the source code and change it to suit your needs.
The MySQL Database Server is very fast, reliable, and easy to
use. MySQL Server can handle large databases much faster
than existing solutions and is successfully used in highly
demanding production environments for several years.
Although under constant development, MySQL Server today
offers a rich and useful set of functions. Its connectivity, speed,
and security make MySQL Server highly suited for accessing
databases on the Internet.
WHAT IS PYTHON IDLE?

Every Python installation co1nes with an Integrated


Development and Learning Environn1ent, which you'll see
shortened to IDLE or even IDE. These are a class of applications that
help you write code 1nore efficiently. While there are many IDEs for
you to choose from, Python IDLE is very bare-bones, which 1nakes it
the perfect tool for a beginning prograrn1ner. Python IDLE as an
interactive interpreter or as a file editor.

The Python shell is an excellent place to experiment with small


code snippets. You can access it through the terminal or
command line app on your 1nachine. You can silnplify your
workflow with Python IDLE, which will immediately start a
Python shell when you open it. Every programmer needs to be
able to edit and save text files. Python programs are files with
the .py extension that contain lines of Python code. Python IDLE
gives you the ability to create and edit these files with ease.
Python IDLE also provides several useful features that you'll see
in professional IDEs, like basic syntax highlighting, code
co1npletion, and auto-indentation.
TABLE .DESIGN

Database Design:

An important aspect of system design is the design of


data storage structure. To begin with a logical 1nodel of
data structure is developed first. A database is a
container object which contains tables, queries,
reports and data validation policies enforcement rules
or constraints etc. A logical data often represented as
records are kept in different tables after reducing
anomalies and redundancies. The goodness of data
base design lies in the table structure and its
relationship. This software project 1naintains a
database named medicalshop.db which contains the
following tables.
COMPUTER SPECS
COMPUTER SPECS

 Processor: Intel Core i5 or i7, or AMD Ryzen 5 or 7, which offer good


performance at a decent price.
 RAM: 8GB or 16GB, which is sufficient for general use and can handle
more intense tasks.
 Storage: 512GB or 1TB SSD, which provides fast storage and loading
times.
 Graphics: Integrated graphics, such as Intel Xe, or a discrete graphics
card like Nvidia GeForce RTX 3050Ti, which can handle casual gaming
and graphics-intensive tasks.
 Display: 14-inch or 15.6-inch Full HD or 1600p touchscreen, which offers
a good balance between screen real estate and portability
CODING
import sqlite3

# Connect to SQLite database (or create it if it doesn't exist)


conn = sqlite3.connect('medical_shop.db')
cursor = conn.cursor()

# Create table for medicines


cursor.execute('''
CREATE TABLE IF NOT EXISTS medicines (
id INTEGER PRIMARY KEY AUTOINCREMENT,
name TEXT NOT NULL,
quantity INTEGER NOT NULL,
price REAL NOT NULL
)
''')

# Create table for bills


cursor.execute('''
CREATE TABLE IF NOT EXISTS bills (
id INTEGER PRIMARY KEY AUTOINCREMENT,
medicine_id INTEGER,
quantity INTEGER,
total_price REAL,
FOREIGN KEY (medicine_id) REFERENCES medicines (id)
)
''')
# Commit changes and close the connection
conn.commit()
conn.close()

import sqlite3

def connect_db():
return sqlite3.connect('medical_shop.db')

def add_medicine(name, quantity, price):


conn = connect_db()
cursor = conn.cursor()
cursor.execute('INSERT INTO medicines (name, quantity, price) VALUES (?, ?, ?)', (name,
quantity, price))
conn.commit()
conn.close()

def update_medicine_quantity(medicine_id, quantity):


conn = connect_db()
cursor = conn.cursor()
cursor.execute('UPDATE medicines SET quantity = quantity - ? WHERE id = ?', (quantity,
medicine_id))
conn.commit()
conn.close()

def get_all_medicines():
conn = connect_db()
cursor = conn.cursor()
cursor.execute('SELECT * FROM medicines')
medicines = cursor.fetchall()
conn.close()
return medicines

def generate_bill(medicine_id, quantity):


conn = connect_db()
cursor = conn.cursor()

# Check if enough stock is available


cursor.execute('SELECT quantity, price FROM medicines WHERE id = ?', (medicine_id,))
medicine = cursor.fetchone()

if medicine and medicine[0] >= quantity:


total_price = medicine[1] * quantity
cursor.execute('INSERT INTO bills (medicine_id, quantity, total_price) VALUES (?, ?, ?)',
(medicine_id, quantity, total_price))
update_medicine_quantity(medicine_id, quantity)
conn.commit()
print(f'Bill generated: Medicine ID {medicine_id}, Quantity {quantity}, Total Price
{total_price}')
else:
print('Insufficient stock or invalid medicine ID.')

conn.close()

def view_medicines():
medicines = get_all_medicines()
print("Available Medicines:")
for medicine in medicines:
print(f"ID: {medicine[0]}, Name: {medicine[1]}, Quantity: {medicine[2]}, Price:
{medicine[3]}")

def main():
while True:
print("\n1. Add Medicine")
print("2. View Medicines")
print("3. Generate Bill")
print("4. Exit")

choice = input("Enter your choice: ")

if choice == '1':
name = input("Enter medicine name: ")
quantity = int(input("Enter quantity: "))
price = float(input("Enter price: "))
add_medicine(name, quantity, price)
print("Medicine added.")

elif choice == '2':


view_medicines()

elif choice == '3':


medicine_id = int(input("Enter medicine ID: "))
quantity = int(input("Enter quantity to purchase: "))
generate_bill(medicine_id, quantity)

elif choice == '4':


break
else:
print("Invalid choice. Please try again.")

if __name__ == "__main__":
main()
OUTPUT
1. Add Medicine
2. View Medicines
3. Generate Bill
4. Exit
Enter your choice: 1
Enter medicine name: dolo
Enter quantity: 987
Enter price: 5464
Medicine added.

1. Add Medicine
2. View Medicines
3. Generate Bill
4. Exit
Enter your choice: 2
Available Medicines:
ID: 1, Name: paracetamol, Quantity: 500, Price: 12.0
ID: 2, Name: aspirin, Quantity: 50, Price: 1500.0
ID: 3, Name: dolo650, Quantity: 200, Price: 2000.0
ID: 4, Name: Endrogermina, Quantity: 100, Price: 2900.0
ID: 5, Name: amoxicillin 500mg, Quantity: 6, Price: 180.0
ID: 6, Name: sepiro, Quantity: 120, Price: 1900.0
ID: 7, Name: aspirin, Quantity: 12, Price: 212.0
ID: 8, Name: dermcoool, Quantity: 12, Price: 232.0
ID: 9, Name: dolo, Quantity: 987, Price: 5464.0
1. Add Medicine
2. View Medicines
3. Generate Bill
4. Exit
Enter your choice: 4

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy