CS Project L
CS Project L
S
DRONACHARYA, MUNDAMVELI, KOCHI
REQUIREMENTS
COMPUTERSCIENCE(OS3)
TERM 2 PROJECT 2021-22
TOPIC: -
1
CERTIFICATE
Smt. Ramadevi R
Principal I/C
Kendriya Vidyalaya INS Dronacharya
- 682 507
l.N.s
KOCHIa582 507
&OR/YA
2
ACKNOWLEDGEMENT
First of all we would like to thank our computer Science teacher, "Mr. Soju
Swami (PGT Computer Science)" whose valuable guidance has made the
project possible. Sir's suggestions and instructions have served as a major
contributorto this project. We would also like to express our gratitude to our
principal I/C, "Smt. Remadevi R" who gave us this opportunity to do this
wonderful project.
We are also thankful to each and everyone who have given their valuable time
and cooperated with us for the success of this project.
We would like to thank our families and friends for their constant cooperation
and supportthroughoutthe project within the limited time and in midst of this
difficult situation prevailing till date.
Last but not the least, our heartfelt thanks to God Almighty! !
If we had left out anyone to thank by name, kindly pardon us. We extend our
gratitudeto them also for their support and help.. ..
3
DECLARATION
We hereby declare that the term 2 project work entitled "Hotel management
System (Interview based project)" is a record of compilation carried out by
Abhijit Anil & Abhinav V.V, under the guidance and supervisionof Mr. Soju
Swami (PGT Computer Science) of Kendriya Vidyalaya INS Dronacharya
for the award of CBSE AISSE class MI certificate. We have not plagiarized
or submittedthe same work for the award of any other examination. In case this
undertaking is found incorrect, I accept that my certificate may be
unconditionallywithdrawn.
Submittedby:
• AbhinavV.V
Abhijit Anil
4
INDEX
I Abstract 06
2 Introduction 07-08
3 Statement of pumose 09
5 System Requirements Il
6 Python source code 12-26
10 Conclusion 44
Il Students Reflection 45
12 Bibliography 46
5
ABSTRACT
Name of the Project: Ilotcl NfanagernentSystem
Vi<ion•-
The ultimate motto of this project is to help the travellers to get all the info
about rooms
Prices, availability, food and other necessary information for hotel room
booking.
This project helps the users to carry this task online easily.
l) Economical Feasibility
2) Technical Feasibility
3) Operational Feasibility
6
INTRODUCTIONOF THE PROJECT
checking whether
I Iotcl Management System is a system that provides us to reserving rooms,
very useful to all
the rooms are vacant are or not etc by using online browsing. This system is
time for these
espectally for business people. For Business people they don't have sufficient
project we will
then they can use these type of online Hotel Management Systems. By this
the bills to the
reduce the faults in bills of their expenditure and decrease time of delay to give
can al,so include all
customers. We can also save the bills of the customer. By this project we
reduce the errors in
the taxes on the bills according to their expenditures. It has a scope to
seconds. Online
making the bills. Computerized bill can be printed within fraction of
on php. If any
ordering of Booking is possible by using this software. This Project is based
number by seeing
one wants to hook the room for few days then they can specify the specific
type of room they
the types of rooms we have. The bill of this online booking is based on the
reservation site script
can select is displayed. HOTEL MANAGEMENT SYSTEM is a hotel
booking reservations
where site users will be able to search rooms availability with an online
availability, and book
system. Site users can also browse hotels, view room inventory, check
search for
rcscrvations in rcal-timc. Sitc users cntcr check in dateÅnd check out datc thcn
availability and rates. After choosing the right roo m the wanted hotel —
all booking and
reservation process is done on the site and an SM s sent to confirm the booking
RECORD
The project starts with Enter 1 - CUSTOMER DETAILS Enter 2 - BOOKING
6
Enter 3 - ROOM RENT Enter 4 - RESTAURENT BILL Enter 5 - GAMING BILL Enter
- FASHION STORE BILL Enter 7 - DISPLAY CUSTOMER DETAILS Enter 8 - TOTAL
BILL Enter 9 - OLD BILL Enter 10- EXIT
We are so glad that this work has been assigned to us, yet we haven't done this work before.
Soju Swami, our subject teacher have also helped us a lot to complete this project. We feel so
blessed that we have learnt all this work with the help of our sir, we are also thankful to our
7
respected principal Mrs Remadevi R for providing us various facilities to complete this
project.
project before, we
As we are the students of CLASS Xll B and we haven't done this type of
.Hence, we
have performed all that which we have learnt from our CBSE PROGRAMMING
we have stancd
know that this programming would be further done on a big platform. Since
help us a lot in our
with this programming we believe that this programming would further
future.
while performing
We are also thankful to our group mates for cooperating with each other
this task we have also polished the skills of group activity.
PROCESS
have to do on the
FIRSTLY, we have done the planning in a paper work regarding what
assigned project HOTEL MANAGEMENT SYSTEM.
he provided us the
SECONDLY, we discussed our p!anning with our subje eacher and then
right path to perform the work.
NEXT, we started our project on foot paths of o subject teacher.
months for completion.
THEN, we started our coding, coding took aro nd 2 and half
THANK YOU!!!!!
8
STATEMENT OF PURPOSE
The purpose of hotel booking system is to automate the existing manual system by the help of
computerized equipmenCs and full-fledged coloputer software, filliilling their requirement,
so that their valuable or information can be stored for a longer period with easy accesing and
manipulating of the same . The required soiiware and hardware are easily available and easy
to work with. This proposes that elliciency oc hotel organizationscould be improved by
integrating service-oriented operations service-oriented operations with project management
principles. Such integration would instil innovation, proactive attitudes and regulated risk-
taking needed to pursue ongoing improvement and proactive response to change. By
managing each change as a project, embedded in smoothly running operations, hotels would
extend their life span by continuously reinventing themselves.
nr»vnnnues
The advantages of booking a hotel online add up long before your arrival. The most
importantadvantageof online hotel booking is convenience, you can book your room by
simply sitting in home. Internet helps you to browse through the hotels around the world and
compare the f'acilities and rates easily.
9
require hardware, so it is cheaper and easier to use. In spite of that, it requires internet access
to run on it. It can become a weakness to the hotel or guest that does not have internet
connection with power failure happens. If power cuts happen when hotel staff is updating the
information of guests, there will be a high to lose the information.
CHARACTERSTICS
Data Storage
contact
As standard the Hotel Booking System h o be capable of storing basic customer
needs to
information such as name, phone nu be , address etc. Most importantly the system
room status
be able to details in regards to the cust ers room preferences/extras, pricing,
hence why this is
etc. All of which are necessary for most of the functions within the system,
a high priority feature that needs to be implemented.
Payments
The Hotel Booking System needs to be able to check if customers have made payments or
not. The implementation of this feature is crucial to the functionality of the entire system,
reason being that a lot of the other features and operations within the system (i.e. placing
room reservations), thus making this a high priority that is mandatory to the systems design.
10
SYSTEM REQUIREMENTS OF THE PROJECT
RECOMMENDEDSYSTEM REQUIREMENTS
Processors: Intel@ CoreTMi3 processor 4300M at 2.60 GHz.
Disk space: 2 to 4 GB.
Operating systems: Windows@ 10, MACOS, and UBUNTU.
Python Versions: 3.X.X or Higher.
MINIMUMSYSTEM REQUIREMENTS
Note: MySQL Connector Python requires python to be in the system's PATH. Installation
fails if it doesn't find Python.
On Windows, If Python doesn't exist in the system's PATH, please manually add the
directory containing python.exe yourself.
11
CODING
INS IARYA
MANAGEMENT
import mysql.connector
# GLOBALVARIABLES DECLARATION
myConnnection —
cursor=""
userName=""
password =""
roomrent =0
restaurentbill=0
gaming bill=0
fashionbill=()
totalAmount=0
12
gk»bA) toyConncct von
gk)tul uscfNamc
global password
- USERNAME :
ENTER MYSQL SERVER%S
password ENTER MYSQL SERVERS PASSWORD
myConnect jon=mysql.connector.connect(host —"loca a tne,passwd password
if myConnection:
CONGRATULATIONS ! YOUR MYSQL CONNECTION HAS BEEN
ESTABLISHED
def MYSQLconnection ()
global userName
global password
global myConnection
global cid
myConnection=mysql.connector.connect(host="localhost",
, database="HMS" ,
auth_plugin='mysql_native_password' )
if myConnection:
return myConnection
else:
13
nnConnecuonac lose( )
VARC11AR(30).
C COUNTRYVARCllAR(30) VARCHAR(30))
cursor.execute(createTable)
cursor.execute(sql,values)
cursor.execute("COMMlT")
print("\nNewCustomer Entered In The System Successfully !")
cursor.close()
else:
ESTABLISHING MYSQL CONNECTION
def bookingRecord():
global cid
customer—searchCustomer()
if customer:
14
If myConnectnn:
cursor.close()
else:
ESTABLISHING MYSQL CO CTION Y')
def roomRent():
global cid
customer=searchCustomer()
if customer:
giobai roomrent
if myConnection:
cursor=myConnection.cursor()
createTable-"""CREATE TABLE IF NOT EXISTS ROOM RENT(CID
INT,NO OF DAYS INT,ROOMNO INT ,ROOMRENT
cursor.execute(createTable)
print We have The Foliowing Rooms For You
print (" 1. Ultra Royal 10000 Rs.")
print (" 2. Royal 5000 RS. o)
15
print (h 4. Budget ----> 2500 USD
roomchovce Your Option : "))
if roomchoice— i :
roomrent = noofdays * 10000
print("\nUltra Royal Room Rent : ",roomrent)
elifroomchoice==2.
roomrent = noofdays * 5000
print("\nRoyal Room Rent : ",roomrent)
elifroomchoice==3:
roomrent = noofdays * 3500
print("\nElite Royal Room Rent ",roomrent)
elif
roomrent = noofdays * 2500
print("\nBudget Room Rent : ",roomrent)
else:
print("Sorry ,May Be You Are Giving Me Wrong Input, Please Try Again !!! ")
return
sql= "INSERT INTO ROOM RENT
values= (cid,roomchoice,noofdays,roomno,roomrent,)
cursor.execute(sql,values)
print("Thank You , Your Room Has Been Booked For : ",noofdays , "Days" )
print("Your Total Room Rent is : Rs. ",roomrent)
cursor.close()
else:
16
customer=searchCustomer()
If customer:
global restaurentbill
if myConncction:
cursor=myConneciion.cursor(
VARCHAR(30))
cursor-execute(createTable)
print("l. Vegetarian Combo 300 Rs.")
if choice dish==l:
YOU HAVE ORDER: Vegetarian Combo
print("Sorry ,May Be You Are Giving Me Wrong Input, Please Try Again !!!
return
17
Is Re •.rrstaurcntbdl)
int! •••• WE 1101b}: YOU WILL i YOUR Mi AL
ck»scf)
cusc:
7. Exit
if :
HAVE SELECTED TO PLAY : Table Tennis")
gamingbill = hour * 150
18
elif game==2:
HAVE SELECTED TO PLAY Bowling")
elif game—4:
HAVE SELECTED TO PLAY VR World Gaming")
elif game==5 :
HAVE SELECTED TO PLAY Video Games")
print("Sorry ,May Be You Are Giving e Wrong Input, Please Try Again !!! ")
return
cursor.close()
else:
def Fashion():
19
global cid
if customer:
global fashionbill
if myConnection:
cursor=myConnection.cursor()
createTable TABLE IF NOT EXISTS FASHION(CID
VARCHAR(30))'""'
cursor.execute(createTable)
print("""
i. Shirts 1500 Rs.
print("\nShirts")
20
tashtonblll quantity 2000
elif
print("\nJeans")
fashionbiil —quantity * 4000
elifdress==5:
print("\nTassel top")
fashionbill = quantity * 500
elif dress-—6•.
print("\nGown")
fashionbill = quantity * 3000
elifdress==7:
print("\nWestern dress")
fashionbill = quantity * 3000
elif
print("\nSkirts")
elif dress==9:
print("\nTrousers")
print("Sorry ,May Be You Are Giving Me Wrong Input, Please Try Again !!!
return
sql= "INSERT INTO FASHION
values= (cid,dress,quantity,fashionbill)
cursor.execute(sqi,values)
21
pnnt(nnYOtJ SEtycr ITEM NO : QUANTITY IS : ",quantlty,"
YOU FOR SHOPPING VISIT AGAIN!!!" )
cursor.close()
else:
ESTABLISHING MYSQL CONNECTION
deftotalAmount():
global cid
customer=searchCustomer()
if customer:
global grandTotal
global roomrent
global restaurentbill
global fashionbill
global gamingbill
if myConnection:
cursor=myConnection.cursor()
createTabie TABLE IF NOT EXISTS TOTAL(CID
INT ,RESTAURENTBILL INT
,GAMINGBILL INT,FASHIONBILL INT,TOTALAMOUNT INT)
cursor.execute(createTable)
sql= "INSERT INTO TOTAL
name = input("Enter Customer Name : ")
grandTotal=roomrent + restaurentbill + fashionbill + gamingbill
values= (cid,name,roomrent,restaurentbiii , gamingbiii,fashionbiij,grandTotai)
cursor.execute(sql,values)
cursor.execute("COMMIT")
cursor.close()
22
CROWN PLAZA MIAMI CUSTOMER BIILING
CUSTOMER NAME : " ,name)
print("
AMOUNT Rs. ",grandTctal)
cursor.close()
else:
ESTABLISHING MYSQL CONNECTION
def searchOldBill():
global cid
customer—searchCustomer()
if customer:
if myConnection:
cursor=myConnection.cursor()
* FROM TOT ERE CID-
cursor.execute(sql,(cid,))
data—cursor.fetchall()
if data:
print(data)
else:
else:
def searchCustomer():
global cid
23
if myConnect ion:
cursor—myConnect Ion-cursor( )
CUSTOMER ID :
sql-"SELECT * FROM C DETAILS WHERE CID-
cursor.execute(sqi,(cid,))
data—cursor.fetchall()
if data:
print(data)
return True
else:
print("Record Not Found Try Again !")
return False
cursor.close()
else:
print("\nSomthing Went Wrong ,Please Try Again !")
print(
INS
MANAGEMENT
* PLAZA *
24
myConnecuon MYSQLconnect10nCheck ()
if myConnection:
MYSQLconnection ()
while(True):
print(
I --->Enter Customer Details
Record
elif choice
Restaurent()
elif choice ==5:
Gaming()
elifchoice
Fashion()
elifchoice -—7:
25
searchCustomer()
clifchotce
totalAmount()
elif choice —=9•.
searchOidBili()
elif choice —
break
else:
print("Sorry ,May Be You Are Giving Me Wrong Input, Please Try Again !!!
else:
ESTABLISHING MYSQL CONNECTION
# END OF PROJECT