First3pages-Shray

Download as pdf or txt
Download as pdf or txt
You are on page 1of 36

DELHI PUBLIC SCHOOL

CIVIL LINES, ALIGARH

SESSION:-2024-25
COMPUTER SCIENCE PROJECT

FOOD PORTAL

SUBMITTED TO:- SUBMITTED BY:-


Mr. SANTOSH SINGH SHRAY SAGAR
( COMPUTER SCIENCE) XII- SCIENCE (A)
ACKNOWLEDGEMENT

I would like to express my special thanks of


gratitude to my Computer Science teacher Mr.
Santosh Singh as well as our Principal Sir Mrs.
Rajni Singh who gave me the golden
opportunity to do this wonderful project on
“FOOD PORTAL”, which also helped me in
doing practical work and I gained extra
knowledge.

And I would also like to thank my parents and


friends who helped me a lot in finishing this
project within the time limit.

SHRAY SAGAR
XII- SCIENCE(A)
CERTIFICATE

This is to certify that the project on “FOOD


PORTAL” submitted to DELHI PUBLIC
SCHOOL CIVIL LINES ALIGARH by SHRAY
SAGAR of class XII- SCIENCE(A) with the
partial fulfilment of requirements for the
award of Senior Secondary in Computer
Science, embodies the reward of her own
work carried out under my supervision and
guidance.
It is an informative and appreciable piece of
work worthwhile to be approved.

Mr. Santosh Singh Mr. Rajni Singh


(Computer Science) (Principal)
TABLE OF CONTENTS

S.NO. TOPICS

1. PROJECT SYNOPSIS

2. ABOUT FRONTEND (PYTHON)

3. ABOUT BACKEND(MySQL)

4. HARDWARE AND SOFTWARE


REQUIREMENTS

5. CODING

6. SCREENSHOTS

7. ADVANTAGES AND FUTURE


SCOPE

8. CONCLUSION

9. REFERENCES
PROJECT
SYNOPSIS
OBJECTIVE

 The main objective to develop Food Portal is to simplify the


task for handling the information of school. This will provide
an effective way to keep the data of school safe.

 Our Food Portal deals with the various activities related to the
school. It allow the administrator of any organization to edit
and find out the details of a school and allows the school to
keep their profile up to date.

 This Food Portal will be user-friendly and requires minimum


human intervention. This helps the school to register, update
and access records of students and teacher about their
personal detail, attendance, fee structure or salary etc. . It also
manages the library.

PROJECT CATEGORY

 Python programming and MySQL database.

RESOURCES USED

 Python IDLE
 MySQL 5.1
 Python and MySQL connector
ABOUT FRONTEND (PYTHON)

Python is an object-oriented programming language that is designed


in C. By nature, it is a high-level programming language that allows for
the creation of both simple as well as complex operations.
HISTORY:

Python was created in the early 1990s by Guido van Rossum at


Stichting Mathematisch Centrum in the Netherlands as a successor of
a language called ABC. Guido remains Python's principal author,
although it includes many contributions from others.

In 1995, Guido van Rossum continued his work on Python at the


Corporation for National Research Initiatives in Reston, Virginia
where he released several versions of the software.

In May 2000, Guido van Rossum and the Python core development
team moved to BeOpen.com to form the Be Open Python Labs team. In
October of the same year, the Python Labs team moved to Digital
Creations, which became Zope Corporation. In 2001, the Python
Software Foundation was formed, a non-profit organization created
specifically to own Python-related Intellectual Property. Zope
Corporation was a sponsoring member of the PSF.

STORY BEHIND THE NAME:

Guido van Rossum, the creator of the Python language, named the
language after the BBC show "Monty Python's Flying Circus". He
doesn't particularly like snakes that kill animals for food by winding
their long bodies around them and crushing them.
FEATURES OF PYTHON:-

1. Simple and Easy


Python is a simple and minimalistic language. Reading a good
Python program feels almost like reading English, although very
strict English! Python is extremely easy to get started with.
Python has an extraordinarily simple syntax.
2. Free and Open Source
Python is an example of FLOSS (Free/Libré and Open Source
Software). In simple terms, anyone can freely distribute copies of
this software, read its source code, make changes to it, and use
pieces of it in new free programs. FLOSS is based on the concept
of a community which shares knowledge. This is one of the
reasons why Python is so good - it has been created and is
constantly improved by a community who just want to see a
better Python.
3. Portable
Python programs work on any platforms without requiring any
changes at all if you are careful enough to avoid any system-
dependent features.
4. Interpreted
Python does not need compilation to binary. It just runs the
program directly from the source code. Internally, Python
converts the source code into an intermediate form called byte
codes and then translates this into the native language of
computer and then runs it.
5. Object Oriented
Python supports procedure-oriented programming as well as
object-oriented programming. In object-oriented languages, the
program is built around objects which combine data and
functionality.
6. Extensive Libraries
Along with this Python comes inbuilt with a wide array of
modules as well as libraries which allows it to support many
different programming languages like Java, C, C++, and JSON .
ABOUT BACKEND (MySQL)

MySQL is a relational database management system (RDBMS)


developed by Oracle that is based on structured query language
(SQL).

MySQL is one of the most recognizable technologies in the


modern big data ecosystem. Often called the most popular
database and currently enjoying widespread, effective use
regardless of industry, it’s clear that anyone involved with
enterprise data or general IT should at least aim for a basic
familiarity of MySQL.

MySQL is integral to many of the most popular software stacks for


building and maintaining everything from customer-facing web
applications to powerful, data-driven B2B services. Its open-
source nature, stability, and rich feature set, paired with ongoing
development and support from Oracle, have meant that internet-
critical organizations such as Facebook, Flickr, Twitter, Wikipedia,
and YouTube all employ MySQL backend.

With MySQL, even those new to relational systems can


immediately build fast, powerful and secure data storage systems.
MySQL’s programmatic syntax and interfaces are also perfect
gateways into the wide world of other popular query languages
and structured data stores.

FEATURES OF MYSQL:-
1. Free and Open Source
Any individual or enterprise may freely use, modify, publish, and
expand on Oracle’s open-source MySQL code base. The software
is released under the GNU General Public License (GPL).
For MySQL code needing to be integrated or included in a
commercial application (or if open-source software is not a
priority), enterprises can purchase a commercially licensed
version from Oracle.

2. MySQL Is Easy To Use


Though MySQL’s relational nature and the ensuing rigid storage
structures might seem restrictive, the tabular paradigm is
perhaps the most intuitive, and ultimately allows for greater
usability.
3. Compatible on Many Operating Systems
MySQL is compatible to run on many operating systems, like
Windows, Linux, etc.

4. Portable
MySQL also provides a facility that the clients can run on the same
computer as the server or on another computer.

5. High Flexibility
MySQL supports a large number of embedded applications, which
makes MySQL very flexible.

6. Memory Efficiency
Its efficiency is high because it has a very low memory leakage
problem.

THE FUTURE OF MYSQL:-


MySQL was originally envisioned to manage massive databases,
faster than existing database software. Used in demanding
operational, transactional, and production environments for
decades, MySQL evolved alongside the move of computation and
storage into the cloud.
Relative to many data storage and processing solutions on the
market today, MySQL is an older technology, but it shows no signs
of flagging in either popularity or utility. In fact, MySQL has
enjoyed a recent resurgence over even more specialized modern
storage systems, due to its speed, reliability, ease of use, and wide
compatibility.
HARDWARE AND SYSTEM
REQUIREMENTS

OPERATING SYSTEM:-
WINDOWS 7 OR ABOVE

PROCESSOR: -
PENTIUM (ANY) OR AMD ATHALON (DUAL CORE)

RAM:-
4 GB (RECOMMENDED)

HARD DISK:-
6 GB (MINIMUM)

SOFTWARES:-
Front End: PYTHON 3.X
Back End: MySQL 5.X.X
CODING
#Main Program
import mysql.connector as a
con=a.connect(host='localhost',user='root',passwd='root',
database ='school')
def addst ():
n=input("Student name : ")
cl=input ("Class : ")
r=int(input("Roll no. : "))
a=input("Address : ")
ph= int(input("Phone no. : "))
data= (n,cl,r,a,ph)
sql='insert into student values (%s,%s,%s,%s,%s)'
c=con.cursor()
c.execute(sql,data)
con.commit()
print("data entered successfully")
print ("")
def removest():
cl=input ("class : ")
r=input("roll no. : ")
data=(cl,r)
sql='delete from student where class=%s and roll=%s'
c=con.cursor()
c.execute(sql,data)
con.commit()
print("data deleted successfully")
print ("")
def displayst():
cl=input("class : ")
data=(cl,)
sql='select * from student where class=%s'
c=con.cursor()
c.execute(sql,data)
d=c.fetchall()
for i in d :
print ("Name : ", i[0])
print("class : ",i[1])
print ("roll no. : ",i[2])
print ("address : ",i[3])
print("phone no. : ",i[4])
print ("")
print ("")
def addt():
tid=int(input("teacher ID : "))
n=input ("Name : ")
s=int(input("Salary : "))
a=input("Address : ")
ph= int(input("Phone no. : "))
data= (tid,n,s,a,ph)
sql='insert into teacher values (%s,%s,%s,%s,%s)'
c=con.cursor()
c.execute(sql,data)
con.commit()
print("data entered successfully")
print ("")
def removet():
n=input ("Teacher name : ")
tid=int(input("teacher ID : "))
data=(n,tid)
sql='delete from teacher where name=%s and id=%s'
c=con.cursor()
c.execute(sql,data)
con.commit()
print("data deleted successfully")
print ("")
def updatesal():
n=input ("Name : ")
tid=int(input("teacher ID : "))
s=int(input("Salary : "))
data=(n,tid)
sql='update teacher set salary=%s where name=%s and
id=%s'
c=con.cursor()
c.execute(sql,data)
con.commit()
print("salary updated successfully")
print ("")
def displayt():
sql='select * from teacher'
c=con.cursor()
c.execute(sql)
d=c.fetchall()
for i in d :
print ("teacher ID: ", i[0])
print("name : ",i[1])
print ("salary : ",i[2])
print ("address : ",i[3])
print("phone no. : ",i[4])
print ("")
print ("")
def clattd():
d=input("class : ")
clt=input ("Class teacher : ")
t=int(input("Class strenght : "))
d=input("date : ")
ab= int(input("No. of absentess : "))
data= (n,cl,r,a,ph)
sql='insert into ClAttendance values (%s,%s,%s,%s,%s)'
c=con.cursor()
c.execute(sql,data)
con.commit()
print("data entered successfully")
print ("")
def displayclattd():
sql='select * from CLAttendance'
c=con.cursor()
c.execute(sql)
d=c.fetchall()
for i in d :
print ("class : ", i[0])
print("class teacher : ",i[1])
print ("total student : ",i[2])
print ("date : ",i[3])
print("absentees : ",i[4])
print ("")
print ("")
def tattd():
d=input("date : ")
t=input ("total teacher : ")
ta=input("no. of teacher absent : ")
data= (d,t,ta)
sql='insert into tattendance values (%s,%s,%s)'
c=con.cursor()
c.execute(sql,data)
con.commit()
print("data entered successfully")
print ("")
def displaytattd():
sql='select * from tattendance'
c=con.cursor()
c.execute(sql)
d=c.fetchall()
for i in d :
print ("date : ", i[0])
print("total teachers : ",i[1])
print ("no. of teacher absent : ",i[2])
print ("")
print ("")
def updatefees():
cl=input("class : ")
m=input ("monthly : ")
b=input("Busfee : ")
sc=input("scfee : ")
tc=input ("techfee : ")
t=input("total : ")
data=(cl,m,b,sc,tc,t)
sql='insert into Feestructure values
(%s,%s,%s,%s,%s,%s)'
c=con.cursor()
c.execute(sql,data)
con.commit()
print("data updated successfully")
print ("")
def displayfees():
sql='select * from Feestructure'
c=con.cursor()
c.execute(sql)
d=c.fetchall()
for i in d :
print ("class : ", i[0])
print("monthly : ",i[1])
print ("busfee : ",i[2])
print ("scfee: ",i[3])
print("techfee : ",i[4])
print("total : ",i[5])
print ("")
print ("")
def addbook():
bid=input("Book ID : ")
t=input ("Title: ")
a=input("Author : ")
p=input("Publisher : ")
g= input("Genre : ")
data= (bid,t,a,p,g)
sql='insert into library values (%s,%s,%s,%s,%s)'
c=con.cursor()
c.execute(sql,data)
con.commit()
print("data entered successfully")
print ("")
def removeb():
title=input ("title: ")
id=int(input("book id : "))
data=(title,id)
sql='delete from library where title=%s and id=%s'
c=con.cursor()
c.execute(sql,data)
con.commit()
print("Book deleted successfully")
print ("")
def displayb():
sql='select * from library'
c=con.cursor()
c.execute(sql)
d=c.fetchall()
for i in d :
print ("book id : ", i[0])
print("title : ",i[1])
print ("author : ",i[2])
print ("publisher : ",i[3])
print("genre : ",i[4])
print ("")
print ("")
def main():
ch='y'
while ch in ['y','Y'] :
print (" SCHOOL MANAGEMENT SYSTEM")
print (''' 1. student
2.teacher
3.CLAttendance
4.TAttendance
5.fee structure
6.library''')
table=int(input("enter table no. : "))
print ("")
if table==1 :
op='y'
while op in ['y','Y']:
print (''' 1. add student
2. delete student
3. display student detail ''')
task=int(input("enter task no. : "))
if task==1:
addst()
elif task==2:
removest()
elif task==3:
displayst()
else :
print ("enter valid choice ")
op=input ("continue in this table (y/n): ")
elif table==2 :
op='y'
while op in ['y','Y']:
print (''' 1. add teacher
2. remove teacher
3. update salary
4. display teacher detail''')
task=int(input("enter task no. : "))
if task==1:
addt()
elif task==2:
removet()
elif task==3:
updatesal()
elif task==4:
displayt()
else :
print ("enter valid choice ")
op=input ("continue in this table (y/n): ")
elif table==3:
op='y'
while op in ['y','Y']:
print (''' 1. class attendance
2. display class attendance detail''')
task=int(input("enter task no. : "))
if task==1:
clattd()
elif task==2:
displayclattd()
else :
print ("enter valid choice ")
op=input ("continue in this table (y/n): ")
elif table==4 :
op='y'
while op in ['y','Y']:
print (''' 1. teacher attendance
2.display teacher attendance detail''')
task=int(input("enter task no. : "))
if task==1:
tattd()
elif task==2:
displaytattd()
else :
print ("enter valid choice ")
op=input ("continue in this table (y/n): ")
elif table==5 :
op='y'
while op in ['y','Y']:
print (''' 1. update fees
2.display fees detail''')
task=int(input("enter task no. : "))
if task==1:
updatefees()
elif task==2:
displayfees()
else :
print ("enter valid choice ")
op=input ("continue in this table (y/n): ")
elif table==6 :
op='y'
while op in ['y','Y']:
print (''' 1. add book
2. remove book
3. display book ''')
task=int(input("enter task no. : "))
if task==1:
addbook()
elif task==2:
removeb()
elif task==3:
displayb()
else :
print ("enter valid choice ")
op=input ("continue in this table (y/n): ")
else:
print ("enter valid choice ")
ch=input("do you want to continue (y/n):")
main()
SCREENSHOTS
Student management

Teacher management
Class attendance
Teacher attendance

Fee structure
Library
ADVANTAGE
AND
FUTURE
SCOPE
ADVANTAGES

 Saves time for teachers and administration


 Fee collection
 Improving teaching standard
 Complete attendance automation
 Keeping control of absentees
 Easy management of class information analytical report
 Improving library management
 Easy handling of teacher information and their salary

FUTURE SCOPE

 In future our system can include accounting system,


good backup, and restore facility.
 System is so much flexible so in future it can
increase easily and new modules can be added
easily.
 . You can add student admission as well as pay
online fees.
 . Make online exams more effective, efficient and
more dynamic so that it helps to get good support
from the student.
CONCLUSION

As for the conclusion, the objectives for


this project were achieved and functioned
well as the desired target. The School
Information System database works
systematically and will make ease the user
in order to manage all the school data in
the system. This system will give a better
performance in arranging the library and
school information without having to do it
manually. This system will help faculty’s
staff to access the data od students and
teachers faster and easier.
REFERENCES

 Google.co.in
 Wikipedia.com
 Text Book:

Computer Science with Python


-Author Sumita Arora

You might also like