Sales Management System
Sales Management System
PROJECT REPORT ON
ROLL NO : 7
CLASS : XII C
PGT (CS)
1|Page
MAYOOR SCHOOL, NOIDA
CERTIFICATE
This is to certify that Ansh Thakur Roll No: 7 has successfully completed the project
work entitled Mobile Sales Billing in the subject Computer Science (083) laid down
in the regulations of CBSE for the purpose of Practical Examination in Class XII
Sonia Pardasani
PGT Computer Science
External Examiner:
Name: _______________
Signature:
2|Page
TABLE OF CONTENTS [ T O C ]
01 ACKNOWLEDGEMENT 04
02 INTRODUCTION 05
04 PROPOSED SYSTEM 06
07 FLOW CHART 16
08 SOURCE CODE 17
09 OUTPUT 24
10 TESTING 28
INSTALLATION PROCEDURE
12 31
13 BIBLIOGRAPHY 32
ACKNOWLEDGEMENT
3|Page
Apart from the efforts of me, the success of any project depends largely on
the encouragement and guidelines of many others. I take this opportunity to express
my gratitude to the people who have been instrumental in the successful completion
of this project.
4|Page
INTRODUCTION
The mobile sales billing is basically a database project done with help of python
language. this project is very useful for the retailers to keep a count on what types of
be extremely useful for every one of those understudies,
the program.
5|Page
Description of System
In Mobile Store Management System use to maintain their sales detail in files and
folders. They use to keep the record of product sold, Customers, Suppliers,
etc in a register. A daily register is maintained to keep track of complaints. Preparing
report is very time consuming and tedious task. For searching of single record, whole
register is to be searched which is very time-consuming task.
Proposed System
The proposed system is computerized and has been developed using advance
language therefore it gives more facilities than present system. It provides quick
access to any data. In this system user have to enter the data only once and then it
get linked with all files. This reduces the workload of user and it is also a time saving
process.The information about any Subscriber can be easily retrieved. The system
maintains all records easy.
6|Page
Modules
import mysql.connecter:
By importing this package, we are able to
establish the connection between SQL and
Python.
import datetime:
This package provides basic functions for
display date related values in the program.
import random:
This package has functionality to generate
random numbers and select numbers within a
range.
Admin Functionalities:
o Login module
o Manage Category: Add, update or delete
o Manage Item: Add, update or delete
User Functionalities:
o Registration module
o Login module
o Place Order module
o Shopping Cart module
o Manage profile
7|Page
Functions
connect():
This function establishes connection between
Python and MySQL.
cursor():
It is a special control structure that facilitates
the row-by-row processing of records in the
result set.
The syntax is:
<cursor object>=<connection object>.cursor()
execute():
This function is use to execute the sql query
and retrieve records using python.
The syntax is:
<cursor object>.execute(<sql query string>)
fetchall():
This function will return all the rows from the
result set in the form of a tuple containing the
records.
commit():
This function provides changes in the
database physically.
8|Page
REQUIREMENTS ANALYSIS PHASE
The Online Mobile Shopping website is a web based application, which helps
consumer to find latest mobile with different specifications on internet. This website
allow people to directly buy latest mobile from website. Online Mobile Shopping
project has two main modules : Customer and Admin. Admin will maintain whole
system. The customer is a user who want to buy products from website. To buy
mobiles user need to register first and after that he can buy product and finally make
a online payment(dummy) to confirm the order.
9|Page
SYSTEM ANALYSIS AND DESIGN
Defining A System
Collections of components, which are interconnected, and work together to realize some
objective, form a system. There are three major components in every system, namely input,
processing and output.
Problem Definition
Systems analysis
Drawbacks of the existing system
Systems Requirement study Data flow analysis
Feasibility study
Systems design
Input Design (Database & Forms)
Updating
Query /Report Design
Testing
Implementation
Maintenance
System Analysis
System analysis is a logical process; the objective of this phase is not actually to
solve the problem but to determine what must be done to solve the problem. The
basic objective of the analysis stage is to develop the logical model of the
system using tools such as the data flow diagram and elementary data
description of the elementary algorithm. The logical model is Subject to review
10 | P a g e
Project Overview
Product prospective
It will be able to manage information about different tutorial in more user
friendly way. This system will manage tutorial information at various pages.
User ID and password has been given to all the field in admin accounts so
that they can enter their see by these information to login from admin and.
User Interface
11 | P a g e
LOW CHART
2.AS THE PYTHON AND MYSQL ARE CONNECTED THE COMMAND WILL BE SENT TO MYSQL.
SOURCE CODE
12 | P a g e
import mysql.connector as sql
conn= sql.connect(host='localhost', user = 'root',
password ='manager')
c1=conn.cursor()
c1.execute("create database "+name_of_database)
c1.execute('use {}'.format(puj))
c1.execute("create table stock (product_no int(10)
primary key,product_name varchar(30),cost_per_product
int(10),stock int(10),purchased int(10) );")
c1.execute("create table user(username
varchar(255),passwd varchar(255));")
conn.commit()
for i in range(0,int(len(peee))):
print(peee[i] )
it=0
bill=0
while 5>1:
13 | P a g e
print("==============================================
=============================================")
print("1. CUSTOMER")
print("2. ADMIN")
print("3.EXIT")
loggin=int(input('enter the
choice:'))
if loggin==1:
while 3>1:
print("==============================================
=============================================")
data1=list(data[0])
bill+=int(data1[1])
it+=1
print("bought successfully!!!!")
14 | P a g e
if opn == 'y' or opn == 'Y':
continue
break
elif
appr =='n' or appr =='N':
continue
print(' BILL')
print('''MODE OF PAYMENT:''',just)
print('''*******THANK YOU*******
*******PLEASE VIST AGAIN*******''')
break
else:
print('####invalid command####')
break
conn.commit()
elif loggin==2:
dt=c1.fetchall()
dt1=list(dt[0])
print("stock available:",dt1[3])
conn.commit()
elif
ch==3:
16 | P a g e
stock12=input('Enter the number of stocks of the new
product arrived:')
pch='0'
print("Added sucessfully!!!!!!!")
conn.commit()
else:
elif loggin== 3:
print("...QUITING...
")
break
else:
print("###INVALID
OPTION####")
print("==============================================
==============================")
if choice == 1:
us=input('USERNAME:')
ps=input('PASSWORD:')
c1.execute("select *
from user where username = '{}' and passwd =
'{}'".format(us , ps))
data = c1.fetchall()
if any(data) :
import main
else:
print('''..SORRY..
WRONG.......USERNAME OR PASSWORD''')
elif choice == 2:
print("==============================================
=============================================")
li=input('ENTER THE
NEW USER ID:')
while 8>1:
18 | P a g e
c1.execute("insert into user
values("+'"'+li+'",'+'"'+li3+'")')
conn.commit()
break
elif choice ==3:
c1.execute("select
username from user")
data = c1.fetchall()
for row in data :
print(row)
elif choice == 4:
print(".......................LOGGING...........OUT..
..............")
break
else:
print('please enter
the right option')
OUTPUT
MAIN WINDOW
19 | P a g e
LOGIN WINDOW
CUSTOMER WINDOW
20 | P a g e
ADMIN WINDOW
REGISTER WINDOW
21 | P a g e
VEIW THE USERS WINDOW
22 | P a g e
EXIITING WINDOW
TESTING
23 | P a g e
Testing is vital to the success of any system. Testing is done at different stages
within the phase. System testing makes a logical assumption that if all phases of
the system are correct, the goals will be achieved successfully.
Inadequate
testing at all leads to errors that may come up after a long time when correction
would be extremely difficult. Another objective of testing is its utility as a user-
oriented vehicle before implementation. The testing of the system was done on
both artificial and live data.
24 | P a g e
ATHALON(3800+- 4200+ DUAL CORE)
SOFTWARE REQUIREMENTS:
• Windows OS
• Python
• mysql connector modulle
INSTALLATION PROCEDURE
25 | P a g e
1. THE SALES MANAGEMENT SYSTEM FILE SHOULD
BE PLACED AT THE MAIN PYTHON FILE.
2. FIRST, REGISTER YOUR ACCOUNT.
3.THEN ENTER YOUR PRODUCT DETAILS.
BIBLIOGRAPHY
26 | P a g e