Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 42

KENDRIYA VIDYALAYA

ONGC MEHSANA

COMPUTER
SCIENCE Submited By:
RITIK KUMAR

PROJECT ON
FOOD
ORDERING
Session 2019-20
SOFTWARE
Submited to:
Mrs. NAMRATA SHAH
CERTIFICATE
This is to certify that the project work on “FOOD
ORDERING SOFTWARE” has been satisfactorily
conducted under the guidance of Mrs. Namrata Shah
and hence recorded here is the bonafide work of
RITIK KUMAR of class XII ‘A’ of KV ONGC, Mehsana
during the academic year 2019-20.

External Mrs Namrata Mr. Rishi


Examiner Shah Kumar
PGT CS/IP Principal
DECLARATION

I hereby declare that the project work


entitled “FOOD ORDERING
SOFTWARE”, submitted to Department
of Computer Science Kendriya
Vidyalaya ONGC Mehsana ,Gujarat is
prepare by me. All the coding are
result of my personal efforts.
RITIK
KUMAR
CLASS XII-
A
ACKNOWLEDGEMENT
I am deeply indebted to my respected
teacher Mrs. Namrata Shah who not
only gave my intellectual guidance but
also helped me to shape and reshape
my thoughts and provided me much
needed warmth of encouragement that
has made this project successfully
possible.
I am heartily thankful to my respected
principal Mr. Rishi Kumar to encourage
me and give this opportunity to show
my talent and help me to proceed
towards my destiny. I also thank my
parents, and classmates for the
constant support of enthusiasm.
CONTENT
 MAIN SCREEN OF THE PROJECT …………………
 FEATURES OF THE PROJECT ……………………..
 MODULES USED ……………………………………….
 FUNCTIONS USED………………………………….....
 WORKING DESCRIPTION……………………………
 FLOW CHART…………………………………………….
 CODING…………………………………………………….
 OUTPUT SCREENS …………………………………….
 LIMITATIONS …………………………………………...
 FUTURE SCOPE………………………………………….
 BIBLIOGRAPHY…………………………………………..
FEATURES O F THE PROJECT
This software is for taking orders at restaurant
or any food corner.

Software stores the orders given by customer.

It stores Name and Phone number of


customer.

Stores Time and Date of Order.

All the data is saved in backend MySQL


database.

Generates Unique Bill number for every Order.

We can search any order that has been saved


by use of its Unique Bill number.

Displays Advertisement of Food Corner or


Restaurant.
MODULES USED
Os :- The OS module in python provides
functions for interacting with the operating
system. OS, comes under Python’s standard
utility modules. This module provides a
portable way of using operating system
dependent functionality.

Tkinter :- Python offers multiple options for


developing GUI (Graphical User Interface). Out
of all the GUI methods, tkinter is most
commonly used method. Python with tkinter
outputs the fastest and easiest way to create
the GUI applications. Creating a GUI using
tkinter is an easy task.

Messagebox (tkinter) :- The tkMessageBox


module is used to display message boxes in
your applications. This module provides a
number of functions that you can use to
display an appropriate message.
Time :- Used to get access to computers date
and time and use it.

Random :- Python defines a set of functions


that are used to generate or manipulate
random numbers. This particular type of
functions are used in a lot of games, lotteries
or any application requiring random number
generation.

MySQL.connector :- To access the MySQL


database from Python, you need a database
driver. MySQL Connector/Python is a
standardized database driver provided by
MySQL.
FUNCTIONS USED
USER DEFINED FUNCTIONS PURPOSE

Def time(): This function displays live time.

Def total(): This function calculates Cost of Meal , GST


applied and Grand Total.

Def reset(): This clears all the entry fields and resets the whole
Program.

Def nameclick(event): This clears the entry field of ‘NAME’ on left click
of mouse.

Def phoneclick(event): This clears the entry field of ‘PHONE NO.’ of


left click of mouse.

Def um_click(event) This clears the entry fields of ORDER Frame on left
Def bf_click(event): click of mouse.
Def smb_click(event):
Def stb_click(event):
USER DEFINED FUNCTIONS PURPOSE

Def order_number_click(): This function generates unique bill number.

Def generate_bill(): This function generates the bill.


Creates a ‘save file’ button.
Saves all the information of order and customer
in MySQL database.

Def search_order(): This function searches customer bill saved in text


file by their UNIQUE BILL NUMBER.

Def add(): This function shows advertisement on click of


button on the bottom right side of program.

Def ec_click(event):
Def fd_click(event):
Def cn_click(event):
Def kb_click(event):

Def um_click_desc(): This opens up a tab that shows the product


Def bf_click_desc(): description on click of product images.
Def smb_click_desc():
Def stb_click_desc():
Def ec_click_desc():
Def ec_click_desc():
Def fd_click_desc():
Def cn_click_desc():
Def kb_click_desc():
WORKING OF PROJECT
First of all the python code is executed.

After Successful execution the GUI of


Ordering Software opens up.

The software is handled by only Counter


Attendant.

At very first Customer’s ‘NAME’ and ‘PHONE


NUMBER’ is entered.

Then if customer want’s to see the Item


description then counter attendant will opens
up description by clicking on Images of Items.
On clicking of Images , a window pops up
which shows the description of Project.

Then the orders are taken from Customer.


After taking orders the Total amount of order
is calculated.
On clicking of ‘Total’ button it will calculate :
o Cost of meal
o GST applied
o Grand Total
If no Orders are placed , then system will
generates a Message which says ‘No Orders
Placed’.
Now, when Total Amount of meal is calculated
, we can process further to generate the BILL.

On clicking of ‘GENERATE BILL’ button :


o Software creates bill in the Bill Box.
o Bill contains Name and Phone number of
customer, List of Orders, Date, Time,
Unique Bill number, cost of meal, GST
applied and Total amount.
o All the data is saved in Backend in MySQL
database.
o A small button ‘save bill’ is created on
top-left side of Bill Box.
On clicking of ‘save bill button’ it will ask if
we want to save bill in Text format.
If YES – the bill is saved in Text file.
If NO – we can process further.

(If correct phone number is not entered


then system generates a Message which
says ‘Phone Number Is Not Valid.’
If phone number entered is valid then it
will process further.)

Now Order is Placed Successfully.

If we want to search order then we can search


it by the help of Unique Bill Number.
FLOW CHART
CODING
from tkinter import*
from tkinter import messagebox
from time import strftime
import random
import time
import mysql.connector
import os

root = Tk()
root.geometry("1366x768+0+0")
root.title("WELCOME TO PLAYERS UNKNOWN BELLY GROUNDS")
root.iconbitmap(r'frostbite.ico')

mydb =
mysql.connector.connect(host='localhost',user='ritik',passwd='ritik')
mycursor = mydb.cursor()

try:
mycursor.execute('create database frost_db')
mycursor.execute('use frost_db')
print("database frost_db is created")
except:
print('Database Matched')
mycursor.execute('use frost_db')

try:
mycursor.execute('create table FROSTBITE(orderno int(6),name
varchar(30),phoneno varchar(10),date date,um int(3),'
'bf int(3),stb int(3),smb int(3),ec int(3),fd
int(3),cn int(3),kb int(3),total float(6,2));')
print('Table FROSTBITE is created ')
except:
print('Table FOUND')
#=================================Variables================================

um_v=IntVar()
bf_v=IntVar()
smb_v=IntVar()
stb_v=IntVar()
ec_v=IntVar()
fd_v=IntVar()
cn_v=IntVar()
kb_v=IntVar()

name_v=StringVar()
name_v.set('customer name')

phone_v=StringVar()
phone_v.set('mobile number')

bill_number=StringVar()

cost_of_meal=IntVar()
cost_of_meal.set(0.0)

gst_applied=IntVar()
gst_applied.set(0.0)

total_cost=IntVar()
total_cost.set(0.0)

order_number_v=StringVar()
order_number_v.set("****")

#======================================functions===========================

def time():
string = strftime('%H:%M:%S %p')
time_label.config(text = string)
time_label.after(1000, time)

def total():

No_um = um_v.get()
No_bf = bf_v.get()
No_smb = smb_v.get()
No_stb = stb_v.get()
No_ec = ec_v.get()
No_fd = fd_v.get()
No_cn = cn_v.get()
No_kb = kb_v.get()

if No_um==0 and No_bf==0 and No_smb==0 and No_stb==0 and No_ec==0 and
No_fd==0 and No_cn==0 and No_kb==0:
messagebox.showerror('ERROR', 'NO ORDERS PLACED')
else:

Co_um = float(No_um * 450)


Co_bf = float(No_bf * 100)
Co_smb = float(No_smb * 120)
Co_stb = float(No_stb * 150)
Co_ec = float(No_ec * 45)
Co_fd = float(No_fd * 35)
Co_cn = float(No_cn * 70)
Co_kb = float(No_kb * 135)

meal = Co_bf + Co_smb + Co_stb + Co_cn + Co_ec + Co_fd + Co_kb +


Co_um
gst = ((Co_bf + Co_smb + Co_stb + Co_cn + Co_ec + Co_fd + Co_kb +
Co_um) * 0.18)
total_price =meal + gst

cost_of_meal.set(meal)
gst_applied.set(gst)
total_cost.set(total_price)

def reset():
um_v.set(0)
bf_v.set(0)
smb_v.set(0)
stb_v.set(0)
ec_v.set(0)
fd_v.set(0)
cn_v.set(0)
kb_v.set(0)

cost_of_meal.set(0.0)
gst_applied.set(0.0)
total_cost.set(0.0)

name_v.set('customer name')
phone_v.set('mobile number')

bill_area.delete("1.0", END)

order_number_v.set("****")

try:
save_bill_btn.destroy()
except:
return

def nameclick(event):
name_v.set("")

def phoneclick(event):
phone_v.set("")

def um_click(event):
um_v.set('')

def bf_click(event):
bf_v.set('')

def smb_click(event):
smb_v.set('')

def stb_click(event):
stb_v.set('')

def ec_click(event):
ec_v.set('')

def fd_click(event):
fd_v.set('')

def cn_click(event):
cn_v.set('')

def kb_click(event):
kb_v.set('')

def um_click_desc():
pricelist = Tk()
pricelist.title('300 MAGNUM')
pricelist.iconbitmap(r'frostbite.ico')

prod_name =LabelFrame(pricelist, width = 525, height=350 , text='300


MAGNUM : Rs.450', font=('Agency FB',30,'bold'),bd=5)
prod_name.pack(side=BOTTOM)

Label(prod_name, text='1 Stun Burger Special', font=('Agency FB' , 20),


justify=CENTER).grid(row=0,column=0)
Label(prod_name, text='1 Bullet Fries', font=('Agency FB', 20),
justify=CENTER).grid(row=1, column=0)
Label(prod_name, text='1 Energy Coke/Flare Drink', font=('Agency FB',
20),
justify=CENTER).grid(row=2, column=0)
Label(prod_name, text='1 Choco Nade/Killer Brownie', font=('Agency FB',
20),
justify=CENTER).grid(row=3, column=0)
Label(prod_name, text='1 Special Chicken Lollipop', font=('Agency FB',
20),
justify=CENTER).grid(row=4, column=0)
pricelist.mainloop()

def bf_click_desc():
pricelist = Tk()
pricelist.title('BULLET FRIES')
pricelist.iconbitmap(r'frostbite.ico')

prod_name = LabelFrame(pricelist, width=525, height=350, text='BULLET


FRIES : Rs.100', font=('Agency FB', 30, 'bold'),
bd=5)
prod_name.pack(side=BOTTOM)

Label(prod_name, text='Shredded aged sharp cheddar cheese AND\n mildly


spiced cheese sauce add a '
'\ndefinitive hearty heft to your already
delectable fries.', font=('Agency FB', 20),
justify=CENTER).grid(row=0, column=0)
pricelist.mainloop()

def smb_click_desc():
pricelist = Tk()
pricelist.title('SMOKE BURGER')
pricelist.iconbitmap(r'frostbite.ico')

prod_name = LabelFrame(pricelist, width=525, height=350, text='SMOKE


BURGER : Rs.120', font=('Agency FB', 30, 'bold'),
bd=5)
prod_name.pack(side=BOTTOM)

Label(prod_name, text='The crisp patty is made with 100% vegetables and


served in a\n 5-inch freshly toasted sesame'
' seed bun. The tangy pickles,\n fresh tomatoes,
onions & lettuce, laced with \npure-veg'
' mayonnaise and ketchup, complete the taste \nof
the King of burgers. \nOur advice: hold it'
' with both your hands to eat it.', font=('Agency
FB', 20),
justify=CENTER).grid(row=0, column=0)
pricelist.mainloop()

def stb_click_desc():
pricelist = Tk()
pricelist.title('STUN BURGER')
pricelist.iconbitmap(r'frostbite.ico')

prod_name = LabelFrame(pricelist, width=525, height=350, text='STUN


BURGER : Rs.150', font=('Agency FB', 30, 'bold'),
bd=5)
prod_name.pack(side=BOTTOM)

Label(prod_name, text='One bite of this flavourful burger, starring a


flame-grilled, \njuicy 100%* chicken patty,'
' will make you go mmmmm. \nIt is served in a
freshly-toasted 5” sesame seed bun, \ncomplemented'
' perfectly with tangy pickles, fresh tomatoes,
\nlettuce and onions, laced with mayonnaise &'
' ketchup. \nOur advice: hold it with both hands
to eat it.', font=('Agency FB', 20),
justify=CENTER).grid(row=0, column=0)
pricelist.mainloop()

def ec_click_desc():
pricelist = Tk()
pricelist.title('ENERGY COKE')
pricelist.iconbitmap(r'frostbite.ico')

prod_name = LabelFrame(pricelist, width=525, height=350, text='ENERGY


COKE : Rs.45', font=('Agency FB', 30, 'bold'),
bd=5)
prod_name.pack(side=BOTTOM)

Label(prod_name, text='The calories do matter, but so does taste.\n


Which is why the taste of '
'NOW comes in a version fit\n for those who want
to stay fit.\n'
'Gives you the Ultimate Energy', font=('Agency
FB', 20),
justify=CENTER).grid(row=0, column=0)
pricelist.mainloop()

def fd_click_desc():
pricelist = Tk()
pricelist.title('FLARE DRINK')
pricelist.iconbitmap(r'frostbite.ico')

prod_name = LabelFrame(pricelist, width=525, height=350, text='FLARE


DRINK : Rs.35', font=('Agency FB', 30, 'bold'),
bd=5)
prod_name.pack(side=BOTTOM)

Label(prod_name, text='Flare Drink exhilarates like no other because


\nof its extreme citrus taste and a rush\n'
' of caffeine, celebrating the \nbold adventurous
spirit of the youth.', font=('Agency FB', 20),
justify=CENTER).grid(row=0, column=0)
pricelist.mainloop()

def cn_click_desc():
pricelist = Tk()
pricelist.title('CHOCO NADE')
pricelist.iconbitmap(r'frostbite.ico')

prod_name = LabelFrame(pricelist, width=525, height=350, text='CHOCO


NADE : Rs.70', font=('Agency FB', 30, 'bold'),
bd=5)
prod_name.pack(side=BOTTOM)

Label(prod_name, text='A cool, creamy indulgence, featuring a swirl of


\nchocolate '
'fudge with our trademark \nvanilla soft serve.',
font=('Agency FB', 20),
justify=CENTER).grid(row=0, column=0)
pricelist.mainloop()

def kb_click_desc():
pricelist = Tk()
pricelist.title('KILLER BROWNIE')
pricelist.iconbitmap(r'frostbite.ico')

prod_name = LabelFrame(pricelist, width=525, height=350, text='KILLER


BROWNIE : Rs.135', font=('Agency FB', 30, 'bold'),
bd=5)
prod_name.pack(side=BOTTOM)

Label(prod_name, text='The Brownie has multiple layers of \nchocolate


sponge cake,cherries and whipped cream.'
'\nIt is frosted with whipped cream and covered\n
with chocolate shavings and\n'
' a few cherries for decoration.', font=('Agency
FB', 20),
justify=CENTER).grid(row=0, column=0)
pricelist.mainloop()

def order_number_click(event):
order_number_v.set('')

def generate_bill():
random_bill = random.randint(11111,100000)
bill_number.set(str(random_bill))
bill_time = strftime('%H:%M:%S %p')
bill_date = strftime("%d/%m/%y")

if name_v.get()=="customer name" or phone_v.get()=="mobile number":

messagebox.showerror('ERROR', 'CUSTOMER DETAILS ARE NECESSARY')


elif name_v.get()!="customer name" or phone_v.get()!="mobile number":

if len(str(phone_v.get()))<10 or len(str(phone_v.get()))>10:

messagebox.showerror('ERROR', 'Phone number is not Valid')

else:
bill_area.insert(END, '\t\tFROSTBITE\n')
bill_area.insert(END, '\t PUBG RESTAURANT\n')
bill_area.insert(END, '--------------------------------------
\n')
bill_area.insert(END, f'\n Bill Number :
{bill_number.get()}')
bill_area.insert(END, f'\n Date : {bill_date}')
bill_area.insert(END, f'\n Time : {bill_time}')
bill_area.insert(END, f'\n Customer Name: {name_v.get()}')
bill_area.insert(END, f'\n Phone Number : {phone_v.get()}')
bill_area.insert(END, '\n\n------------------------------------
--\n')
bill_area.insert(END, '\t\tORDERS\n')
bill_area.insert(END, '\n ITEMS\t\tQuantity\t\tCost\n')

#bill_area.insert(END, '')

if um_v.get()!=0:
qty_um=um_v.get()
cost_um=qty_um*450
bill_area.insert(END, f'\n 300 Magnum\t\t
{qty_um}\t\t{cost_um}')

if bf_v.get()!=0:
qty_bf=bf_v.get()
cost_bf=qty_bf*100
bill_area.insert(END, f'\n Bullet Fries\t\t
{qty_bf}\t\t{cost_bf}')

if smb_v.get()!=0:
qty_smb=smb_v.get()
cost_smb=qty_smb*120
bill_area.insert(END, f'\n Smoke Burger\t\t
{qty_smb}\t\t{cost_smb}')

if stb_v.get()!=0:
qty_stb=stb_v.get()
cost_stb=qty_stb*150
bill_area.insert(END, f'\n Stun Burger\t\t
{qty_stb}\t\t{cost_stb}')

if ec_v.get()!=0:
qty_ec=ec_v.get()
cost_ec=qty_ec*45
bill_area.insert(END, f'\n Energy Coke\t\t
{qty_ec}\t\t{cost_ec}')

if fd_v.get()!=0:
qty_fd=fd_v.get()
cost_fd=qty_fd*35
bill_area.insert(END, f'\n Flare Drink\t\t
{qty_fd}\t\t{cost_fd}')
if cn_v.get()!=0:
qty_cn=cn_v.get()
cost_cn=qty_cn*70
bill_area.insert(END, f'\n Choco Nade\t\t
{qty_cn}\t\t{cost_cn}')

if kb_v.get()!=0:
qty_kb=kb_v.get()
cost_kb=qty_kb*135
bill_area.insert(END, f'\n Killer Brownie\t\t
{qty_kb}\t\t{cost_kb}')

bill_area.insert(END, '\n\n------------------------------------
--\n')

No_um = um_v.get()
No_bf = bf_v.get()
No_smb = smb_v.get()
No_stb = stb_v.get()
No_ec = ec_v.get()
No_fd = fd_v.get()
No_cn = cn_v.get()
No_kb = kb_v.get()

if No_um == 0 and No_bf == 0 and No_smb == 0 and No_stb == 0


and No_ec == 0 and No_fd == 0 and No_cn == 0 and No_kb == 0:
messagebox.showerror('ERROR', 'NO ORDERS PLACED')
else:

Co_um = float(No_um * 450)


Co_bf = float(No_bf * 100)
Co_smb = float(No_smb * 120)
Co_stb = float(No_stb * 150)
Co_ec = float(No_ec * 45)
Co_fd = float(No_fd * 35)
Co_cn = float(No_cn * 70)
Co_kb = float(No_kb * 135)

meal = Co_bf + Co_smb + Co_stb + Co_cn + Co_ec + Co_fd +


Co_kb + Co_um
gst = ((Co_bf + Co_smb + Co_stb + Co_cn + Co_ec + Co_fd +
Co_kb + Co_um) * 0.18)
total_price = meal + gst

bill_area.insert(END, f'\n Cost of Meal : {meal}')


bill_area.insert(END, f'\n GST applied : {gst}')
bill_area.insert(END, f'\n Total : {total_price}')

billno_sql = random_bill
name_sql = name_v.get()
phone_sql = phone_v.get()
date_sql = bill_date
um_sql = um_v.get()
bf_sql = bf_v.get()
stb_sql = stb_v.get()
smb_sql = smb_v.get()
ec_sql = ec_v.get()
fd_sql = fd_v.get()
cn_sql = cn_v.get()
kb_sql = kb_v.get()
total_sql = total_cost.get()

query = 'insert into frostbite


(orderno,name,phoneno,date,um,bf,stb,smb,ec,fd,cn,kb,total)' \
' values(%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s)'
values =
(billno_sql,name_sql,phone_sql,date_sql,um_sql,bf_sql,stb_sql,
smb_sql,ec_sql,fd_sql,cn_sql,kb_sql,total_sql)
mycursor.execute(query,values)
mydb.commit()
#tabledata=mycursor.execute('select * from frostbite')
#print(tabledata)

def save_bill():
savebill = messagebox.askyesno('save bill', 'Do you want to
save the bill?')
if savebill > 0:
bill_data = bill_area.get('1.0', END)
bill_file = open('E:\\CS PROJECT
NEW\\newproject\\ORDERS\\order ' + str(bill_number.get()) + '.txt', 'w')
bill_file.write(bill_data)
bill_file.close()
messagebox.showinfo('saved', "Saved successfuly")
else:
return

global save_bill_btn

save_bill_btn = Button(f5, text='SAVE BILL',


activebackground='#FF8C00',command=save_bill,
activeforeground='black', relief=RIDGE,
overrelief=RAISED)
save_bill_btn.place(x=0, y=8)

def search_order():
bill_area.delete("1.0", END)
if order_number_v.get()=='****':
return
else:
try:
bill_file = open('E:\\CS PROJECT NEW\\newproject\\ORDERS\\order
' + str(order_number_v.get()) + '.txt', 'r')
order_text = bill_file.read()
bill_area.insert(END, f'{order_text}')
bill_file.close()
except:
messagebox.showinfo('order not found', f"There is NO order with
Order No.{order_number_v.get()}")

def add():
os.system("C:\\Users\\RITIK\\Downloads\\frostbiteadd.mp4")

#=======================================IMAGESET===========================

um=PhotoImage(file="um.png")
bf=PhotoImage(file="bf.png")
smb=PhotoImage(file="smb.png")
stb=PhotoImage(file="stb.png")
ec=PhotoImage(file="ec.png")
fd=PhotoImage(file="fd.png")
cn=PhotoImage(file="cn.png")
kb=PhotoImage(file="kb.png")

pubg=PhotoImage(file='pubg.png')
frostbite=PhotoImage(file="frostbite.png")
pubg_tops=PhotoImage(file="pubg_tops.png")
background=PhotoImage(file="background.png")

#========================================FRAMES============================

wall = Label(root,image = background)


wall.pack()

Tops = LabelFrame(root,width =1366,height=100,relief=RIDGE,bd=8)


Tops.place(x=0,y=5)

f1 = LabelFrame(root, width = 1050, height=350 ,


text='MENU', font=('Agency FB',30,),bd=5,relief=SUNKEN)
f1.place(x=5, y=115)

f2 = LabelFrame(root, width = 525, height=350 ,


text='ORDERS', font=('Agency FB',30,),bd=5)
f2.place(x=5, y=451)

f3 = LabelFrame(root,width=525,text='DETAILS & PAYMENT',


font=('Agency FB',30,),bd=5)
f3.place(x=575, y=451)

f4 =Frame(root,bd=2,relief=RIDGE)
f4.place(x=842, y=475)

f5 = LabelFrame(root,width=450,height=668, text='BILL',
font=('Agency FB',30,))
f5.place(x=1045, y=115)

#=======================================TOPS===============================

frostbite_img_1=Label(Tops,image=frostbite)
frostbite_img_1.place(x=515,y=0)

frostbite_img_2=Label(Tops,image=frostbite)
frostbite_img_2.place(x=800,y=0)

pubg_tops_img=Label(Tops,image=pubg_tops)
pubg_tops_img.place(x=600,y=0)

#======================================MENU================================

um_img=Button(f1,image=um,command=um_click_desc,
relief=RIDGE,overrelief=RAISED)
um_img.grid(row=0,column=0)

bf_img=Button(f1,image=bf,command=bf_click_desc
,relief=RIDGE,overrelief=RAISED)
bf_img.grid(row=1,column=0)

smb_img=Button(f1,image=smb,command=smb_click_desc,
relief=RIDGE,overrelief=RAISED)
smb_img.grid(row=0,column=2)
stb_img=Button(f1,image=stb,command=stb_click_desc,
relief=RIDGE,overrelief=RAISED)
stb_img.grid(row=1,column=2)

ec_img=Button(f1,image=ec,command=ec_click_desc,
relief=RIDGE,overrelief=RAISED)
ec_img.grid(row=0,column=4)

fd_img=Button(f1,image=fd,command=fd_click_desc,
relief=RIDGE,overrelief=RAISED)
fd_img.grid(row=1,column=4)

cn_img=Button(f1,image=cn,command=cn_click_desc,
relief=RIDGE,overrelief=RAISED)
cn_img.grid(row=0,column=6)

kb_img=Button(f1,image=kb,command=kb_click_desc,
relief=RIDGE,overrelief=RAISED)
kb_img.grid(row=1,column=6)

um_menu=Label(f1,text='300 Magnum Meal',font=('Agency FB',19,),


width=16,anchor=W,height=3)
um_menu.grid(row=0,column=1)

bf_menu=Label(f1,text='Bullet fries',font=('Agency FB',19,),


width=15,anchor=W,height=4)
bf_menu.grid(row=1,column=1)

smb_menu=Label(f1,text='Smoke Burger',font=('Agency FB',19,),


width=14,anchor=W)
smb_menu.grid(row=0,column=3)

stb_menu=Label(f1,text='Stun Burger',font=('Agency FB',19,),


width=14,anchor=W)
stb_menu.grid(row=1,column=3)

ec_menu=Label(f1,text='Energy Coke',font=('Agency FB',19,),


width=13,anchor=W)
ec_menu.grid(row=0,column=5)

fd_menu=Label(f1,text='Flare Cocktail',font=('Agency FB',19,),


width=13,anchor=W)
fd_menu.grid(row=1,column=5)

cn_menu=Label(f1,text='Choco Nade',font=('Agency FB',19,),


width=15,anchor=W)
cn_menu.grid(row=0,column=7)

kb_menu=Label(f1,text='Killer Brownie',font=('Agency FB',19,),


width=15,anchor=W)
kb_menu.grid(row=1,column=7)

#========================================ORDER=============================

um_lbl=Label(f2,text='300 Magnum',font=('Agency FB',25,))


um_lbl.grid(row=0,column=0)
um_ord=Entry(f2,textvar=um_v, justify='right',fg='#A52A2A')
um_ord.grid(row=0,column=1)
um_ord.bind("<Button-1>",um_click)
bf_lbl=Label(f2,text='Bullet fries',font=('Agency FB',25,))
bf_lbl.grid(row=1,column=0)
bf_ord=Entry(f2,textvar=bf_v, justify='right',fg='#A52A2A')
bf_ord.grid(row=1,column=1)
bf_ord.bind("<Button-1>",bf_click)

smb_lbl=Label(f2,text='Smoke Burger',font=('Agency FB',25,))


smb_lbl.grid(row=2,column=0)
smb_ord=Entry(f2,textvar=smb_v, justify='right',fg='#A52A2A')
smb_ord.grid(row=2,column=1)
smb_ord.bind("<Button-1>",smb_click)

stb_lbl=Label(f2,text='Stun Burger',font=('Agency FB',25,),)


stb_lbl.grid(row=3,column=0)
stb_ord=Entry(f2,textvar=stb_v, justify='right',fg='#A52A2A')
stb_ord.grid(row=3,column=1)
stb_ord.bind("<Button-1>",stb_click)

ec_lbl=Label(f2,text='Energy Coke',font=('Agency FB',25,))


ec_lbl.grid(row=0,column=3)
ec_ord=Entry(f2,textvar=ec_v, justify='right',fg='#A52A2A')
ec_ord.grid(row=0,column=4)
ec_ord.bind("<Button-1>",ec_click)

fd_lbl=Label(f2,text='Flare Cocktail',font=('Agency FB',25,))


fd_lbl.grid(row=1,column=3)
fd_ord=Entry(f2,textvar=fd_v, justify='right',fg='#A52A2A')
fd_ord.grid(row=1,column=4)
fd_ord.bind("<Button-1>",fd_click)

cn_lbl=Label(f2,text='Choco Nade',font=('Agency FB',25,))


cn_lbl.grid(row=2,column=3)
cn_ord=Entry(f2,textvar=cn_v, justify='right',fg='#A52A2A')
cn_ord.grid(row=2,column=4)
cn_ord.bind("<Button-1>",cn_click)

kb_lbl=Label(f2,text='Killer Brownie',font=('Agency FB',25,))


kb_lbl.grid(row=3,column=3)
kb_ord=Entry(f2,textvar=kb_v, justify='right',fg='#A52A2A')
kb_ord.grid(row=3,column=4)
kb_ord.bind("<Button-1>",kb_click)

#=======================================CALCULATION========================

name_lbl=Label(f3,text="NAME",font=('Agency FB',20,),
fg='#FF4500')
name_lbl.grid(row=0,column=0)

name_ent=Entry(f3,justify='right' , textvar=name_v,
fg='#A52A2A')
name_ent.grid(row=0,column=1)
name_ent.bind("<Button-1>", nameclick)

phone_lbl=Label(f3,text="PHONE NO.",font=('Agency FB',20,),


fg='#FF4500')
phone_lbl.grid(row=1,column=0)
phone_ent=Entry(f3,justify='right' , textvar=phone_v,
fg='#A52A2A')
phone_ent.grid(row=1,column=1)
phone_ent.bind("<Button-1>", phoneclick)

com_lbl=Label(f3,text="COST OF MEAL",font=('Agency FB',20,),


fg='#FF8C00')
com_lbl.grid(row=3,column=0)

com_ent=Entry(f3, justify='right', textvar=cost_of_meal)


com_ent.grid(row=3,column=1)

gst_lbl=Label(f3,text="GST APPLIED",font=('Agency FB',20,),


fg='#FF8C00')
gst_lbl.grid(row=4,column=0)

gst_ent=Entry(f3, justify='right', textvar=gst_applied)


gst_ent.grid(row=4,column=1)

grand_lbl=Label(f3,text="TOTAL",font=('Agency FB',30,'bold'),
fg='#DAA520')
grand_lbl.grid(row=5,column=0)

grand_ent=Entry(f3, justify='right', textvar=total_cost)


grand_ent.grid(row=5,column=1)

#=====================================BUTTON===============================

tot_btn=Button(f4,text='TOTAL',pady=22.5, width=25,
command=total,activebackground='#FF8C00',

activeforeground='black',relief=RIDGE,overrelief=RAISED,bd=3)
tot_btn.grid(row=0,column=0)

res_btn=Button(f4,text='RESET', pady=22.5, width=25,


command=reset,activebackground='#FF8C00',
activeforeground='black',relief=RIDGE,overrelief=RAISED)
res_btn.grid(row=2,column=0)

gen_btn=Button(f4,text='GENERATE BILL', pady=22.5, width=25,


command=generate_bill,activebackground='#FF8C00',
activeforeground='black',relief=RIDGE,overrelief=RAISED)
gen_btn.grid(row=1,column=0)

search_order_btn = Button(f4,text='SEARCH
ORDER',activebackground='#FF8C00',
command = search_order,activeforeground='black',
relief=RIDGE,overrelief=RAISED)
search_order_btn.grid(row=3,column=0,sticky=E)

search_order_ent = Entry(f4, justify='right',fg='#A52A2A',


width=14,textvar=order_number_v)
search_order_ent.grid(row=3,column=0,sticky=W)
search_order_ent.bind("<Button-1>",order_number_click)

#=====================================BILLFRAME============================
bill_area=Text(f5,width=38,height=23)
bill_area.grid(row=1,column=0)

time_label = Label(f5, font = ('Agency FB', 20, 'bold'),foreground =


'orange')
time_label.grid(row=0,column=0)
time()

pubg_img=Button(f5,image=pubg,relief=RIDGE,command = add)
pubg_img.grid(row=2,column=0)

#==========================================================================

root.state("zoom")
root.mainloop()

OUTPUT SCREENS
1). Folder of project
2). If database and table
doesn’t exist then software
creates it.

3). If database and


table exist

4). Main screen


5). Item Description
6). Entering Order

11). Saving Bill


10). Generating Bill
7). Calculating Total
Amount
12). Reseting software for
next order
13). Folder where Order details save in
text format

14). Text file of order


15). Searching Order by using Unique
bill number
16). MySQL database
Displays Message if
No Orders were
placed

Displays Message if
Phone Number is not
of 10 digit
FUTURE SCOPE

This is a simple Billing system which is being


used world wide at different restaurants and
food corners from a very long time. So there is
not future scope for this project.

But we can Modify these type of billing


system with Artificial intelligence and other
useful Features and Quirks to make it more
easy and convenient to use.
LIMITATIONS
There is no inventory management system.

Software doesn’t require any verification of


user.
Anyone can use this.

We didn’t implemented any function to take


records of Payment methods.
BIBLIOGRAPHY:-
Sumita Arora Class XII
Preeti Arora Class XII
https://www.google.com/
https://stackoverflow.com/
https://pythontrends.wordpress.com/
https://www.geeksforgeeks.org/
https://www.youtube.com/
https://www.geeksforgeeks.org/python-gui-
tkinter/
https://www.tutorialspoint.com/python/pytho
n_gui_programming.htm
https://www.rapidtables.com/web/color/RGB_
Color.html#color-table
https://www.quackit.com/python/reference/py
thon_3_escape_sequences.cfm
https://resizeimage.net/

You might also like