Computer Science Final Chirag
Computer Science Final Chirag
C PUBLIC SCHOOL
TATA BENZ SQUARE, BRAHMAPUR
Submitted to – Submitted By -
Rabindra Sahu N. Chirag
P.G.T (computer science) XII “C” 23
CERTIFICATE
This is to certify that N. Chirag of class: Xll C of
K.C PUBLIC SCHOOL has done this project on GROCERY
SHOP MANAGEMENT SYSTEM under my supervision. He
has taken interest and has shown at most sincerity in completion
of this project.
Principal
ACKNOWLEDGMENT
OBJECTIVE OF THE
02. PROJECT
1
2
PROPOSED
03.
SYSTEM
PROBLEMS WITH
04. EXISTING 2
SYSTEM
SYSTEM
3
05. DEVELOPMENT
WORKFLOW
5-8
07. SOURCE CODE
08. OUTPUT
HARDWARE AND
09. SOFTWARE
RE UIREMENTS
10 BIBLIOGRAPHY
Introduction-
To keep a count of products sold and count of products kept in inventory to restock
them.
To keep up with the pace of digitalization and bring about the best results with minimal
mistakes and greater efficiency, one has to upgrade to using data management system for
running one's grocery store.
Many companies that have created the software have implemented them in the markets
which have received positive feedback and helped in improving the product further.
These have also benefited the organizations and shop owners who use them, making
their work easier and efficient. The software needs to be easy to operate and accessible
through just loading the program in their existing computers.
This lets the owner as well as the country take a step in the modern era of
digitalization and automation, making work fully automated and accessible by the
click of a button.
Problems with existing system-
Manual calculations may lead to human error and result into loss.
The products that arrive at the store needs to be loaded into the system's database.
The products will be entered after accounting for the taxes applied on each,
commission, shelf life and quantity.
After the data has been loaded into the database by the data entry operator, the
products will be stocked on shelf for the customers.
The system is able to enter and display one or all workers details, such as his
name, work, age, contact information. This makes it easy to access their details
and store the same.
The system keeps a track about the customer details about his name, purchase and
contact information.
After a customer has made a purchase, the system can take the input of their final
cost and store them.
It also displays the stock available in a pie chart format for easy analysis.
The manager can have quick access to all his worker, customer, product details... in
a click.
SOURCE CODE
import mysql.connector as sql conn=sql.connect(host="localhost",
user="root", password="Sujay@sql 1234", database="Grocery_shop") if
conn.is connected():
print("Connected..."
) c=conn.cursor() def
main():
print("Welcome Tejas") an='y' while an=='y' or an=='Y': print('Grocery
Shop') print(' I .customer details') print('2.product details') print('3.worker
details') print('4.see all customer details') print('5.see all product details')
print(t6.see all worker details') print('7.see one customer details')
print('8.see one product details') print('9.see one worker details') print('l
O.pie chart for avalibility of stock') choice=int(input('enter the choice: '))
if cust_namea=input('enter your name: ')
phone_noa=int(input('enter your phone number: ')) sql_insert="insert into
customer_details values("+str(phone_noa)+","'+
(cust_namea)+""'+ )
c.execute(sql_insert) conn.commit() print('data is
updated') an=input("Do you want to make another
choice(y/n): ") elifchoice==2:
product_name=input('enter product name: ')
product_cost=float(input('enter the cost: ')) sql_insert="insert into
product_details values("+""'+(product_name)
+"',"+str(product_cost)+ )
c.execute(sql_insert) conn.commit() print('data is
updated') an=input("Do you want to make another
choice(y/n): ") elifchoice==3:
worker_name=input('enter worker name: ')
worker work=input('enter worker work:
worker_age=int(input('enter worker age: '))
worker_salary=float(input('enter worker salary:
'))
phone_no =int(input('enter worker phone number: ')) sql_insert="insert into
worker details values("+""'+(worker_name)+
(worker_work)+"', "+str(worker_age)+", "+str(worker_salary) +","+str(phone_no)+ )
c.execute(sql_insert) conn.commit() an=input("Do
you want to make another choice(y/n): ")
elifchoice==4:
t=conn.cursor()
t.execute('select*from customer_details')
record=t.fetchall() for i in record: print(i)
an=input("Do you want to make another choice(y/n):
")
elif
t=conn.cursor()
t.execute('select*from product_details')
record=t.fetchall () for i in record: print(i)
an=input("Do you want to make another choice(y/n):
")
elif
t=conn.cursor()
t.execute('select*from worker details')
record=t.fetchall() for i in record: print(i)
an=input("Do you want to make another choice(y/n):
elifchoice == 8:
a = input('enter your product_name: ') t='select*from
product_details where product_name=(" { } ")'.format(a)
c.execute(t)
v=c.fetchall(
) for i in v:
print (v)
an=input("D
o you want
to make
another
choice(y/n):
")
elif choice==9:
a=inputCenter worker name: t) t=tselect*from worker details where
worker_name=(" { }
c.execute(t)
v=c.fetchall()
for i in v:
print (v) an=input("Do you want to make another
choice(y/n): ")
elif choice—10:
import matplotlib.pyplot as plt
t
'watch', 'house use' , 'food items')
196] colors=['red% 'blue', 'gold', 'light_coral']
plt.pie(availability, labels—items, colors—colors)
plt.titleCavailability of items in shop') plt.show() you
want to make another choice(y/n): ")
else:
exit()
def login():
u n=input("Enter your Username: ")
pwd=input("Enter your password:
while u_n=="Tejas" and pwd=="PCMCE@24":
main() else:
ans=input('wrong password, do you want to try
again(y/n): t) if or ans=="Y". login()
if : login()
elif ans==2:
exit()
Do you want to make another choice (y/n) :
OUTPUT-
Welcome re-jas
Connected... Grocery Shop
Grocery Shop Management System 1. customer details
1. Login 2. product details
2. Exit 3. worker details
Enter your choice (1/2) : 1 4 . see all customer details
Enter your Username: Tejas 5. see all product details
Enter your password: PCMCE@24
6. see all worker details
Welcome Tejas
7 . see one customer details
Grocery Shop
8. see one product details
1. customer details
9. see one worker details
2. product details
10. pie chart for avalibility of
3. worker details
stock enter the choice: 2 enter
4. see all customer details
product name: bread enter the cost:
5. see all product details 40 data is updated
6.see all worker details Do you want to make another choice
7.see one customer details (y/n) :
8. see one product details Welcome Tejas
9. see one worker details 10. pie Grocery Shop
chart for avalibility of stock enter the 1. customer details
choice: 1 enter your name: sujay enter
2. product details
your phone number: 1234567891 data is
3. worker details
updated
4. see all customer details
Do you want to make another choice (y/n) : 5 . see all product details
6. see all worker details
Welcome Tejas Grocery 7 . see one customer details
Shop 8. see one product details
l.customer details 9. see one worker details
2. product details 10. pie chart for avalibility of
3. worker details stock enter the choice: 3 enter
4. see all customer details worker name: hayabuza enter worker
5. see all product details work: cashier enter worker age: 27
6. see all worker details
enter worker salary: 200000
7. see one customer details
enter worker phone ntmber:
8. see one product details 1234776537 Do you want to make
9. see one worker details 10. pie chart
another choice (y/n) :
for avalibility of stock enter the choice:
Welcome Tejas
1 enter your name: yash enter your phone Grocery Shop
number: 1234561234 data is updated 1. customer details
Do you want to make another choice (y/n) : 2. product details
3.worker details
4. see all customer details
Welcome Tejas
5. see all product details
Grocery Shop
6. see all worker details 7 . see one
1. customer details
customer details
2.product details
8 . see one product details
3.worker details
9. see one worker details
4. see all customer details 10 . pie chart for
5. see all product details avalibility of stock
6. see all worker details enter the choice: 4
7 . see one customer details (1234567890, •asdfgh t )
8. see one product details (1234567891
9. see one worker details 10. pie chart (1234561234, •yash')
for avalibility of stock enter the choice: 1 (1231233458, 'rudransh')
enter your name: rudransh enter your phone
number: 1231233458 data is updated Do you want to make another choice (yin) :
Welcome Tejas
DO you want to make another choice (y/ n) : Grocery Shop
Welcome Tejas 1. customer details
Grocery Shop 2. product details
1. customer details 3. worker details
2.product details 4. see all customer details
3.worker details 5. see all product details
4. see all customer details 6. see all worker details
5. see all product details 7 . see one customer details
6. see all worker details 8. see one product details
7 . see one customer details 9. see one worker details
8. see one product details 10.pie chart for avalibility of
9. see one worker details 10. pie chart stock enter the choice: 5
for avalibility of stock enter the choice: 2 ('asdfg% 1234)
enter product name: pencil box enter the cost: ('pencil box % 157)
157 data is updated ('bread', 40)
Welcome Tejas
Grocery Shop Do you want to make another choice (y/
1 . customer details n) :
2 . product details Grocery Shop
1 . customer details
3 .worker details
2. product details
4 . see all customer details 3. worker details
S . see all product details 4. see all customer details
6. see all worker details 5.see all product details
7 . see one customer details 6. see all worker details
8 . see one product details 7. see one customer details
8. see one product details
9 . see one worker details 9. see one worker details
10. pie chart for avalibility of 10. pie chart for avalibiiity of
stock enter the choice: 6 stock enter the choice: 9 enter
( ' hayabuza' , ' cashier% 27, 200000, worker name: hayabuza
1234776537) Do you want to make another ('hayabuza', 'cashier' 27,
choice (y/n) : 200000, 1234776537) )
Welcome Tejas Do you want to make another choice
Grocery Shop (y/n) : y
I . customer details Grocery Shop
2. product details 1. customer details
3 . worker details 2. product details
4 . see all customer details 3. worker details
S . see ail product details 4 . see all customer details
6 . see all worker 5. see all product details
details 7 . see one 6 . see all worker details
customer details 7 . see one customer details
8 . see one product details 8. see one product details
9. see one worker details 9 . see one worker details 10. pie
10. pie chart for avalibility of chart for avalibility of stock enter
stock enter the choice: 7 enter the choice: 10
customer name: asdfgh t avalibility of items in shop
(1234567890, 'asdfgh'))
Do you want to make another choice
(yin) : Welcome Tejas
Grocery Shop
I. customer details
2 . product details
3. worker details
4. see all customer details
5 . see all product details
6. see ail worker details
7 . see one customer details
8. see one product details house
9. see one worker details stationary shoes watch food items
10. pie chart for avalibiiity of stock
enter the choice: 8 enter your product
name: asdfg [ ('asdfg', 1234) )
SOFTWARE REQUIREMENTS
1. WINDOWS OS
2. PYTHON
3. MYSQL
4. MYSQL PYTHON CONNECTOR
BIBLIOGRAPHY-