Online Electronic Shop Using Python New
Online Electronic Shop Using Python New
1. INTRODUCTION
2. SYSTEM STUDY
2.1.1 DESCRIPTION
2.1.2 DRAWBACKS
2.2.1 DESCRIPTION
2.2.2 FEATURES
5. CONCLUSION
6. BIBLIOGRAPHY
APPENDICES
B. TABLE STRUCTURE
C. SAMPLE CODING
D. SAMPLE INPUT
E. SAMPLE OUTPUT
SYNOPSIS
This Online Electronic Shopping project in python was designed to manage the
Electronic information to produce the important Electronic Information. Business is one of
the most important economy generators for each country and since the dawn of the twentieth
century. All business companies turned to technology to improve their business chances and
qualities. Thus, such is the reason of the development of this system. This system is
developed for the Electronic business, where it will be implemented in each of the outlets of
an Electronic company. The system name is Online Electronic Shopping (OES). The system
is developed for making management of products much more systematic, secure and
efficient.
1. INTRODUCTION
Aim:
“To Manage Online Electronic Shopping”.
Objective:
To perform a thorough analysis of working of the whole System.
To study the problems in the System through fact finding techniques.
To follow SDLC to develop the system.
To develop conceptual, logical and physical model for the system.
To develop Graphical User Interface (GUI) as per convenience of the user.
To implement the physical model, being tested as per the standards.
To document our efforts and analysis in a proper comprehensible manner.
Goal:
∙ The project is basically targeted at those people who would like to have Online
Electronic Shop and have an Internet access.
Electronic gadget lovers, who are curious in comparing the
prices for various glasses from their selected category.
To make a database that is consistent, reliable and secure.
To provide correct, complete, ongoing information.
To develop a well-organized information storage system.
To make good documentation so as to facilitate possible
future enhancements.
Need of the System:
There is always a need of a system that will perform to search and buy new
Electronics through Online Shopping.
Thus, there is a need of online Electronic Shopping services, which provides all the
Above- mentioned facilities and many more on their finger tips.
1.Pentium IV Processor
2.512 MB RAM
3.40GB HDD
4.1024 * 768 Resolution Color Monitor
2.1.1 DESCRIPTION
In the existing system, the management of electronic products is likely manual, with
limited or no use of technology. Traditional methods such as paper-based records or
basic computer systems may be in place to handle inventory, sales, and other business
processes.
2.1.2 DRAWBACKS
Security Concerns: Paper-based records and basic computer systems may lack robust
security measures, putting sensitive business information at risk.
Lack of Automation: Tasks such as inventory management, order processing, and customer
interactions may lack automation, leading to delays and potential errors.
2.2.1 DESCRIPTION
The proposed system, Online Electronic Shopping (OES), is designed to address the
limitations of the existing system by leveraging modern technology and electronic commerce
principles. OES aims to streamline the management of electronic products through a
comprehensive online platform.
2.2.2 FEATURES
User Authentication: Secure login system to ensure authorized access to the system,
protecting sensitive business information.
Order Processing: Automation of the order processing system, from order placement
to delivery, to enhance efficiency and reduce errors.
Sales Analytics: Generation of reports and analytics to provide insights into sales
trends, customer preferences, and overall business performance.
The file design involves organizing the files within the project to ensure clarity,
maintainability, and scalability.
File Structure:
cart.py: Manages the shopping cart, allowing users to add, remove, or modify
product items.
order.py: Confirms the order and provides an order summary for the customer.
config.py: Configuration file for storing database credentials and other settings.
static/: Directory for static files such as CSS stylesheets, JavaScript files, and images.
3.2 INPUT DESIGN
Input design focuses on designing the user interface and mechanisms for entering data
into the system. It is essential for ensuring data accuracy, completeness, and user-friendliness.
Key aspects of input design include:
Input design focuses on creating user interfaces for data input, ensuring ease of use and
accurate data capture.
Input Components:
1. User Registration Form: Collects information such as name, email, password, etc.,
for user registration.
2. Login Form: Allows users to enter their credentials to log into the system.
3. Product Search and Filter: Enables users to search for electronic products by
keywords, category, or price range.
4. Add to Cart Button: Allows users to add selected product items to their shopping
cart.
5. Checkout Form: Collects delivery information, payment details, and other necessary
information to complete the order.
Output design focuses on how the system presents information to users. It is crucial for
delivering meaningful and relevant information in a clear and organized manner. Key aspects
of output design include:
Report Design: Creating clear and well-structured reports, including tables, charts,
and graphs, to present data in a comprehensible format.
User Interface Design: Designing user interfaces that display information in an
organized and user-friendly way. This includes font selection, color coding, and
layout design.
Output Medium: Deciding whether output will be displayed on a screen, printed on
paper, or delivered in electronic formats (e.g., PDFs or email).
Customization: Allowing users to customize their output preferences, such as
selecting the information they want to see and how it's presented.
Output design involves presenting information to users in a meaningful and
comprehensible manner.
Output Components:
1. Product Listings: Displays available electronic products with details such as
name, description, price, and image.
2. Shopping Cart Summary: Shows a summary of items added to the shopping cart,
including quantity, price, and total cost.
3. Order Confirmation: Provides users with a confirmation message and order
details after completing a purchase.
4. Admin Dashboard: Displays statistics, reports, and tools for managing products,
orders, and user accounts.
3.4 CODE DESIGN
Code design involves structuring the backend codebase to ensure modularity, readability, and
maintainability.
Code Components:
1. User Authentication: Functions for user registration, login, logout, and session
management.
2. Product Management: Code for adding, updating, and deleting electronic products, as
well as managing categories and subcategories.
3. Shopping Cart Management: Functions for adding, removing, and updating items in
the shopping cart.
4. Order Processing: Code for creating and processing orders, calculating totals, and
updating inventory levels.
5. Database Connectivity: Utilizes SQLite database for storing product information, user
accounts, orders, etc., with Python's built-in SQLite library for database operations.
Database design involves designing the structure of the database tables and defining
relationships between them to store and manage data efficiently.
Database Tables:
1. Users: Stores information about registered users, including user ID, username, email,
password hash, etc.
2. Products: Contains details of available electronic products, such as product ID, name,
description, price, category ID, etc.
4. Orders: Records information about orders placed by users, including order ID, user
ID, status, total amount, delivery address, etc.
5. Order_Items: Stores the relationship between orders and product items, including
quantity, price, and product ID.
System development encompasses the entire process of building and deploying the
system, including coding, testing, and deployment. Key aspects of system development
include:
Coding and Implementation: Writing the software code according to the design
specifications and requirements.
Testing: Conducting various testing phases, including unit testing, integration testing,
and system testing, to identify and rectify defects and ensure the system functions as
expected.
Deployment: Installing the system in a production environment, configuring it, and
ensuring it is available to users.
Documentation: Creating comprehensive documentation, including user manuals,
technical documentation, and training materials.
User Training: Training end-users and administrators on how to use and maintain the
system.
Ongoing Maintenance: Planning for ongoing system maintenance, updates, and
support to ensure its continued functionality and relevance.
Effective system development involves careful planning, design, and implementation to
create a system that meets user needs, is reliable, and can adapt to changing requirements.
3.6.1 DESCRIPTION OF MODULES
This project have 2 module first is user and second one is admin. Firstly here admin
can login, after that admin can add items and view item details with delete option. You can
also delete the item through the deletion option. Admin can view orders placed by user. In
this Electronic shop management project application User can register account and then can
fill a login form after that, user can see different types of electronic products and purchase
them online over the internet and also make online payments.
TYPES OF TESTS:
4.1.1 Unit Testing:
Unit testing involves the design of test cases that validate that the internal program
logic is functioning properly, and that program inputs produce valid outputs. All decision
branches and internal code flow should be validated. It is the testing of individual software
units of the application .It is done after the completion of an individual unit before
integration. This is a structural testing that relies on knowledge of its construction and is
invasive. Unit tests perform basic tests at component level and test a specific business
process, application, and/or system configuration. Unit tests ensure that each unique path of a
business process performs accurately to the documented specifications and contains clearly
defined inputs and expected results.
Features to be tested:
WEBSITES:
www.google.com
www.w3schools.com
www.tutorialspoint.php
http://stackoverflow.com
APPENDICES
Customer
Management
Shopping Payment
Management Management
Shopping Portal
Order Products
Management Management
Login
Management
Context Diagram 1
Shopping
Management Generate Order
Report
Second Level DFD
Check Roles of access
Login to system Manage
Admin Category
Manage Sub
Category
Manage
Products
Forgot Password Check Credential
Manage Order
Details
Generate Order
Report
Manage Modules
Generate Sales
Report
Update Profile
Change
Password
Add to wishlist
ok
E-R Diagrams:
The Entity-Relationship (ER) model was originally proposed by Peter in 1976
[Chen76] as a way to unify the network and relational database views. Simply stated the ER
model is a conceptual data model that views the real world as entities and relationships. A
basic component of the model is the Entity-Relationship diagram which is used to visually
represents data objects. Since Chen wrote his paper the model has been extended and today it
is commonly used for database design For the database designer, the utility of the ER model
is:
it maps well to the relational model. The constructs used in the ER model can easily be
transformed into relational tables.
it is simple and easy to understand with a minimum of training. Therefore, the model can be
used by the database designer to communicate the design to the end user.
In addition, the model can be used as a design plan by the database developer to implement a
data model in a specific database management software.
Connectivity and Cardinality
The basic types of connectivity for relations are: one-to-one, one-to-many, and many-to-
many. A one-to-one (1:1) relationship is when at most one instance of a entity A is associated
with one instance of entity B. For example, "employees in the company are each assigned
their own office. For each employee there exists a unique office and for each office there
exists a unique employee.
A one-to-many (1:N) relationships is when for one instance of entity A, there are zero, one, or
many instances of entity B, but for one instance of entity B, there is only one instance of
entity A. An example of a 1:N relationships is
a department has many employees
each employee is assigned to one department
A many-to-many (M:N) relationship, sometimes called non-specific, is when for one instance
of entity A, there are zero, one, or many instances of entity B and for one instance of entity B
there are zero, one, or many instances of entity A. The connectivity of a relationship
describes the mapping of associated
ER Notation
There is no standard for representing data objects in ER diagrams. Each modeling
methodology uses its own notation. The original notation used by Chen is widely used in
academics texts and journals but rarely seen in either CASE tools or publications by non-
academics. Today, there are a number of notations used, among the more common are
Bachman, crow's foot, and IDEFIX.
All notational styles represent entities as rectangular boxes and relationships as lines
connecting boxes. Each style uses a special set of symbols to represent the cardinality of a
connection. The notation used in this document is from Martin. The symbols used for the
basic ER constructs are:
entities are represented by labeled rectangles. The label is the name of the entity. Entity
names should be singular nouns.
relationships are represented by a solid line connecting two entities. The name of the
relationship is written above the line. Relationship names should be verbs
attributes, when included, are listed inside the entity rectangle. Attributes which are
identifiers are underlined. Attribute names should be singular nouns.
cardinality of many is represented by a line ending in a crow's foot. If the crow's foot is
omitted, the cardinality is one.
existence is represented by placing a circle or a perpendicular bar on the line. Mandatory
existence is shown by the bar (looks like a 1) next to the entity for an instance is required.
Optional existence is shown by placing a circle next to the entity that is optional
ER DIAGRAM
B. TABLE STRUCTURE
Tables
The data in the system has to be stored and retrieved from database.
Designing the database is part of system design. Data elements and data
structures to be stored have been identified at analysis stage. They are structured
and put together to design the data storage and retrieval system.
B. SAMPLE CODING.
Initial.py
Auto.py
# Generated by Django 2.1.5 on 2019-02-13 05:52
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('shop', '0001_initial'),
]
operations = [
migrations.RemoveField(
model_name='product',
name='product_desc',
),
migrations.AddField(
model_name='product',
name='category',
field=models.CharField(default='', max_length=50),
),
migrations.AddField(
model_name='product',
name='desc',
field=models.CharField(default='nothing is to describe', max_length=300),
),
migrations.AddField(
model_name='product',
name='image',
field=models.ImageField(default='', upload_to='shop/images'),
),
migrations.AddField(
model_name='product',
name='price',
field=models.IntegerField(default=0),
),
migrations.AddField(
model_name='product',
name='subcategory',
field=models.CharField(default='', max_length=50),
),
migrations.AlterField(
model_name='product',
name='product_name',
field=models.CharField(max_length=50),
),
]
Contact.py
dependencies = [
('shop', '0003_contact'),
]
operations = [
migrations.CreateModel(
name='Orders',
fields=[
('order_id', models.AutoField(primary_key=True, serialize=False)),
('items_json', models.CharField(max_length=5000)),
('name', models.CharField(max_length=5000)),
('email', models.CharField(default='', max_length=70)),
('city', models.CharField(max_length=111)),
('address', models.CharField(max_length=11)),
('state', models.CharField(max_length=111)),
('zip_code', models.CharField(max_length=111)),
],
),
]
Orders_phone.py
operations = [
migrations.AddField(
model_name='orders',
name='phone',
field=models.CharField(default='', max_length=70),
),
]
Product_cart.py
class Migration(migrations.Migration):
dependencies = [
('shop', '0007_auto_20190222_0908'),
operations = [
migrations.AddField(
model_name='product',
name='cart',
field=models.BooleanField(default=False),
),
Product_qty.php
# Generated by Django 2.1.5 on 2019-02-24 08:52
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('shop', '0008_product_cart'),
]
operations = [
migrations.AddField(
model_name='product',
name='qty',
field=models.CharField(default='0', max_length=1000),
),
]
Product_total.py
# Generated by Django 2.1.5 on 2019-02-24 11:41
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('shop', '0011_auto_20190224_1640'),
]
operations = [
migrations.AddField(
model_name='product',
name='total',
field=models.IntegerField(default=0),
),
]
C. SAMPLE INPUT
Home Page
ADMIN PAGE
CHANGE/ UPDATE PRODUCTS
ADD PRODUCT
SEE UPDATDED PRODUCTS
CHANGE ORDERS
VIEW PRODUCTS & ADD TO CARTS
REVIEW CART
COMPLETE THE CHECKOUT DETAILS