Professional Documents
Culture Documents
A PROJECT REPORT
By
November, 2017
1
ACKNOWLEDGEMENTS
2
DECLARATION OF THE CANDIDATE
Place: Vellore
Anirban Mukherjee
Vishist Varugeese
Abishek Sreedher
3
CERTIFICATE
This is to certify that the project work titled Vitcoin Management System that
is being submitted by Anirban Mukherjee 16bit0200, Vishist Varugeese
16bit0242, Abishek Sreedher 16bit0446 for Software Engineering
(ITE10005) is a record of bonafide work done under my supervision. The
contents of this Project work, in full or in parts, have neither been taken from
any other source nor have been submitted for any other CAL course.
Anirban Mukherjee
Vishist Varugeese
Abishek Sreedher
Gitanjali J
4
TABLE OF CONTENTS
S NO CONTENTS PAGE NO
1 TITLE
INTRODUCTION 6
OBJECTIVE 7
2 PROBLEM STATEMENT
PROBLEM STATEMENT 8
3 DESIGN AND ARCHITECTURE
ARCHITECTURE 9
USE CASE DIAGRAM 10
CLASS DIAGRAM 11
SEQUENCE DESIGN 12
SYSTEM FLOW CHART 13
TIMELINE CHART 14
ER DIAGRAM 15
SYSTEM INTERFACE DESIGN 16
4 SOFTWARE PROCESS MODEL
SOFTWARE PROCESS MODEL 18
5 IMPLEMENTATION OF THE MODULES
LOGIN PAGE 21
REGISTRATION PAGE 23
PAYMENT PAGE 26
ADDING MONEY TO WALLET 30
TRANSACTION HISTORY 32
DATABASE 34
6 TEST CASES
TEST CASES 37
7 CONCLUSION AND FUTURE WORK
CONCLUSION 38
FUTURE WORK 38
8 REFERENCES 39
5
TITLE: VITCOIN MANAGEMENT SYSTEM
INTRODUCTION
In the ongoing internet boom across the world and the mission of Digital India
to simplify every aspect of life, why should we VITians stay behind? All of us
have experienced that whenever we want to buy/pay for something, we either
don't have the money, or we have too much money, i.e. the shopkeepers have no
change to pay us back!
The project uses evolutionary model, more specifically throwaway prototyping
for the development work. It involves the use of programming languages like
JavaScript, HTML, CSS for the front-end i.e. for developing the website and
PHP and SQL for back-end to ensure data gets stored and retrieved from the
database. It then uses XAMMP for compiling and running the complete project.
6
OBJECTIVE
This project aims to develop a fully functional website that will cater the needs
of tech-savvy VITians which will enable the user to pay for every service
available in VIT minus the hassle of buying goods offline with a comfortable
User Interface with a secure database and a proper transaction history that will
make life much more easier, benefitting both the buyers and the sellers.
.
7
1) PROBLEM STATEMENT
.
As we saw in Demonitization, the cash crunch meant you either have to
pay with card or PayTM only. This project therefore looks to create an
online wallet for VITians where one can buy and pay stuff online without
any worry of cash transactions.
Inclusion of all payable services in VIT with an attractive UI which
appeals to VITians and make a significant contribution towards Digital
India.
A secure database for users, products and transactions as well as
transaction receipts for the web application to avoid unwanted situations.
8
DESIGN AND ARCHITECTURE
ARCHITECTURE
A Web Application architecture can vary greatly depending on the application at hand its
needs, its behavior and of course, the means at hand. That are a lot of layers you can stack up
when building a web application, some are "mandatory" like front-end and back-end, we
have be to able to see and interact with something, for this reason front-end is vital. Also a
good working back-end is required to maintain database of users and transactions.
The top most visible layer is whats called the Front-end. It is usually written in HTML and
CSS for styling and JavaScript for interactivity and function. The data from this layer has to
make it to the user's browser which then turns all the code into something beautiful and
interactive.
The "Backend" is where we usually use a programming language (unlike HTML & CSS
which are markup languages) such as PHP, Python, Ruby , Java, SQL
Database
In order for most web application to function, we need to be able to store data somewhere.
That somewhere is usually a database of some sort. Some big name brands and household
names are MySQL, PostgreSQL, Oracle, CouchDB, Redis,HBase and the list is pretty
endless.
Each one saves data in a different manner and gives different features. Some save tabled data
(relational databases) while other saved "paged" data, or even simple key-value pairs.
It really depends on what we need to save and how we need to save.
9
USE CASE DIAGRAM
A use case diagram at its simplest is a representation of a user'sinteraction with the system
that shows the relationship between the user and the different use cases in which the user is
involved.
10
CLASS DIAGRAM
In software engineering, a class diagram in the Unified Modeling Language (UML) is a type
of static structure diagram that describes the structure of a system by showing the system's
classes, their attributes, operations (or methods), and the relationships among objects.
11
SEQUENCE DIAGRAM
12
SYSTEM FLOW CHART
System flowcharts are a way of displaying how data flows in a system and how decisions are
made to control events. To illustrate this, symbols are used. They are connected together to
show what happens to data and where it goes. The basic ones include: Symbols used in flow
charts.
13
TIMELINE CHART
Timeline charts are User Items that create a chart where a series of events are arranged on a
bar graph. Each event can be a single point in time or a date range.
14
ER DIAGRAM
15
SYSTEM INTERFACE DESIGN
Landing Page
16
Payment Page
17
2) SOFTWARE PROCESS MODEL
Helps finding exact user requirements: much before fully working system is
developed.
We have specifically used Throwaway Prototyping where the objective is to understand the
system requirements. We start with poorly understood requirements to clarify what is really
needed and then implement them into the project.
18
Requirements:
For making front-end we will be using HTML with CSS. For developing back-end we will be
using MySQL which we connect through PHP and we compile using XAMMP.
Design:
We are creating a web-application for our VITCoin Management System. In this web
application we can pay for the services in VIT such as cab fares, library fines as well buy
items such as books, food etc. from the shops present in VIT.
Implementation:
In the process of implementation we look into the steps to make our web-application. It
involved activities such as analysis, generating necessary algorithms, verification of the
requirements of algorithms including their correctness and resource consumption and
implementation of algorithms in a target programming language. The source code is then
written in PHP. The purpose of programming is to find a sequence of instructions that will
automate performing a specific task or solving a given problem. The process of programming
thus often requires expertise in many different subjects, including knowledge of the
application domain, specialized algorithms, and formal logic.
Testing:
19
c) Can be installed and run in its intended environments, and achieves the general result
its stakeholders desire.
Maintenance:
20
3) IMPLEMENTATION OF THE MODULES
Login Page
login.php
<?php
if(isset($_SESSION["username"])){
header("location:index.php");
}
include 'config.php';
?>
<!doctype html>
<html class="no-js" lang="en">
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0"
/>
<title>Login</title>
<link rel="stylesheet" href="css/foundation.css" />
<style type="text/css">
input[type=email], input[type=password]{
width: 70%;
padding: 12px 20px 8px;
margin: 8px 0;
display: inline-block;
border: 1px solid #ccc;
border-radius: 4px;
box-sizing: border-box;
}
input[type=submit],input[type=reset] {
width: 20%;
background-color: #4CAF50;
color: white;
padding: 14px 20px;
margin: 8px 0;
border: none;
border-radius: 4px;
cursor: pointer;
}
input[type=submit]:hover,input[type=reset]:hover {
background-color: #45a049;
}
div {
text-align: center;
border-radius: 5px;
background-color: #f2f2f2;
padding: 20px;
}
21
</style>
<script src="js/vendor/modernizr.js"></script>
</head>
<body>
<section class="top-bar-section">
<!-- Right Nav Section -->
<ul class="right">
<li><a href="about.php">About</a></li>
<?php
if(isset($_SESSION['username'])){
echo '<li><a href="products.php">Pay</a></li>';
echo '<li><a href="addmoney.php">Add VITCoins</a></li>';
echo '<li><a href="orders.php">My Orders</a></li>';
}
?>
<li><a href="contact.php">Contact</a></li>
<?php
if(isset($_SESSION['username'])){
echo '<li><a href="account.php">My Account</a></li>';
echo '<li><a href="logout.php">Log Out</a></li>';
}
else{
echo '<li class="active"><a href="login.php">Log In</a></li>';
echo '<li><a href="register.php">Register</a></li>';
}
?>
</ul>
</section>
</nav>
22
<input type="email" id="right-label" placeholder=""
name="username">
<footer>
<p style="text-align:center; font-size:0.8em;">© VITCoins!
All Rights Reserved.</p>
</footer>
</div>
</div>
<script src="js/vendor/jquery.js"></script>
<script src="js/foundation.min.js"></script>
<script>
$(document).foundation();
</script>
</body>
</html>
Registration Page
registration.php
<?php
23
<ul class="title-area">
<li class="name">
</li>
<li class="toggle-topbar menu-icon"><a
href="#"><span></span></a></li>
</ul>
<section class="top-bar-section">
<!-- Right Nav Section -->
<ul class="right">
<li><a href="about.php">About</a></li>
<?php
if(isset($_SESSION['username'])){
echo '<li><a href="products.php">Pay</a></li>';
echo '<li><a href="cart.php">View Cart</a></li>';
echo '<li><a href="orders.php">My Orders</a></li>';
}
?>
<li><a href="contact.php">Contact</a></li>
<?php
if(isset($_SESSION['username'])){
echo '<li><a href="account.php">My Account</a></li>';
echo '<li><a href="logout.php">Log Out</a></li>';
}
else{
echo '<li><a href="login.php">Log In</a></li>';
echo '<li class="active"><a
href="register.php">Register</a></li>';
}
?>
</ul>
</section>
</nav>
<div class="row">
<div class="small-4 columns">
<label for="right-label" class="right inline">First
Name</label>
</div>
<div class="small-8 columns">
<input type="text" id="right-label" placeholder="Enter first
name" name="fname">
</div>
</div>
<div class="row">
<div class="small-4 columns">
<label for="right-label" class="right inline">Last
Name</label>
</div>
<div class="small-8 columns">
<input type="text" id="right-label" placeholder="Enter last
name" name="lname">
</div>
</div>
24
<div class="row">
<div class="small-4 columns">
<label for="right-label" class="right inline">Address</label>
</div>
<div class="small-8 columns">
<input type="text" id="right-label" placeholder="Enter
address" name="address">
</div>
</div>
<div class="row">
<div class="small-4 columns">
<label for="right-label" class="right inline">City</label>
</div>
<div class="small-8 columns">
<input type="text" id="right-label" placeholder="Enter city"
name="city">
</div>
</div>
<div class="row">
<div class="small-4 columns">
<label for="right-label" class="right inline">Pin
Code</label>
</div>
<div class="small-8 columns">
<input type="number" id="right-label" placeholder="Enter
pincode" name="pin">
</div>
</div>
<div class="row">
<div class="small-4 columns">
<label for="right-label" class="right inline">E-Mail</label>
</div>
<div class="small-8 columns">
<input type="email" id="right-label" placeholder="Enter email
id" name="email">
</div>
</div>
<div class="row">
<div class="small-4 columns">
<label for="right-label" class="right
inline">Password</label>
</div>
<div class="small-8 columns">
<input type="password" id="right-label" placeholder="Enter
password" name="pwd">
</div>
</div>
<div class="row">
<div class="small-4 columns">
<label for="right-label" class="right inline">Security
question: What is your VIT lab password? (In case you forget your
password)</label>
</div>
<div class="small-8 columns">
<input type="text" id="right-label" placeholder="Enter
answer" name="answer">
</div>
</div>
<div class="row">
<div class="small-4 columns">
25
</div>
<div class="small-8 columns">
<input type="submit" id="right-label" value="Register"
style="background: #0078A0; border: none; color: #fff; font-family:
'Helvetica Neue', sans-serif; font-size: 1em; padding: 10px;">
<input type="reset" id="right-label" value="Reset"
style="background: #0078A0; border: none; color: #fff; font-family:
'Helvetica Neue', sans-serif; font-size: 1em; padding: 10px;">
<hr>
</div>
</div>
</div>
</div>
</form>
<footer>
<p style="text-align:center; font-size:0.8em;">© VITCoins!
All Rights Reserved.</p>
</footer>
</div>
</div>
<script src="js/vendor/jquery.js"></script>
<script src="js/foundation.min.js"></script>
<script>
$(document).foundation();
</script>
</body>
</html>
Payment Page
products.php
<?php
?>
<!doctype html>
<html class="no-js" lang="en">
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0"
/>
<title>Pay</title>
<link rel="stylesheet" href="css/foundation.css" />
<script src="js/vendor/modernizr.js"></script>
<style>
input[type=number], input[type=password], select {
width: 70%;
padding: 12px 20px 8px;
26
margin: 8px 0;
display: inline-block;
border: 1px solid #ccc;
border-radius: 4px;
box-sizing: border-box;
}
input[type=submit] {
width: 70%;
background-color: #4CAF50;
color: white;
padding: 14px 20px;
margin: 8px 0;
border: none;
border-radius: 4px;
cursor: pointer;
}
input[type=submit]:hover {
background-color: #45a049;
}
div {
text-align: center;
border-radius: 5px;
background-color: #f2f2f2;
padding: 20px;
}
</style>
</head>
<body>
<section class="top-bar-section">
<!-- Right Nav Section -->
<ul class="right">
<li><a href="about.php">About</a></li>
<li class='active'><a href="products.php">Pay</a></li>
<li><a href="addmoney.php">Add VITCoins</a></li>
<li><a href="orders.php">My Orders</a></li>
<li><a href="contact.php">Contact</a></li>
27
<?php
if(isset($_SESSION['username'])){
echo '<li><a href="account.php">My Account</a></li>';
echo '<li><a href="logout.php">Log Out</a></li>';
}
else{
echo '<li><a href="login.php">Log In</a></li>';
echo '<li><a href="register.php">Register</a></li>';
}
?>
</ul>
</section>
</nav>
</select>
<!-- <?php /*
$i=0;
$product_id = array();
$product_quantity = array();
28
die(mysql_error());
}
echo '<label for="country">Shop</label>';
echo '<select id="country" name="country">';
if($result){
while($obj = $result->fetch_object()) {
echo '<option
value="australia">Australia</option>';
$i++;
}
}
echo '</select>';
echo '<p'
$_SESSION['product_id'] = $product_id;
echo '</div>';
echo '</div>';
*/ ?> //-->
<footer style="margin-top:10px;">
<p style="text-align:center; font-size:0.8em;clear:both;">©
VITCoins! All Rights Reserved.</p>
</footer>
</div>
</div>
<script src="js/vendor/jquery.js"></script>
<script src="js/foundation.min.js"></script>
29
<script>
$(document).foundation();
</script>
</body>
</html>
<?php
<!doctype html>
<html class="no-js" lang="en">
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0"
/>
<title>Pay</title>
<link rel="stylesheet" href="css/foundation.css" />
<script src="js/vendor/modernizr.js"></script>
<style>
input[type=number], input[type=password], select {
width: 70%;
padding: 12px 20px 8px;
margin: 8px 0;
display: inline-block;
border: 1px solid #ccc;
border-radius: 4px;
box-sizing: border-box;
}
input[type=submit] {
width: 70%;
background-color: #4CAF50;
color: white;
padding: 14px 20px;
margin: 8px 0;
border: none;
border-radius: 4px;
cursor: pointer;
}
input[type=submit]:hover {
background-color: #45a049;
}
div {
text-align: center;
border-radius: 5px;
background-color: #f2f2f2;
padding: 20px;
}
30
</style>
</head>
<body>
<section class="top-bar-section">
<!-- Right Nav Section -->
<ul class="right">
<li><a href="about.php">About</a></li>
<li><a href="products.php">Pay</a></li>
<li class='active'><a href="addmoney.php">Add VITCoins</a></li>
<li><a href="orders.php">My Orders</a></li>
<li><a href="contact.php">Contact</a></li>
<?php
if(isset($_SESSION['username'])){
echo '<li><a href="account.php">My Account</a></li>';
echo '<li><a href="logout.php">Log Out</a></li>';
}
else{
echo '<li><a href="login.php">Log In</a></li>';
echo '<li><a href="register.php">Register</a></li>';
}
?>
</ul>
</section>
</nav>
31
<input type="submit" value="Add money">
</form>
</div>
</div>
</div>
<footer style="margin-top:10px;">
<p style="text-align:center; font-size:0.8em;clear:both;">©
VITCoins! All Rights Reserved.</p>
</footer>
</div>
</div>
<?php
if(!isset($_SESSION["username"])){
header("location:index.php");
}
include 'config.php';
?>
<!doctype html>
<html class="no-js" lang="en">
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0"
/>
<title>History</title>
<link rel="stylesheet" href="css/foundation.css" />
<script src="js/vendor/modernizr.js"></script>
</head>
<body>
32
echo '<h1 style="color: white; margin-left: 20px;">Wallet:
'.$obj->wallet.'<img src="images/coi1ns.png"
style="width:40px;height:40px;"></h1>';
}
}
?>
</li>
<li class="toggle-topbar menu-icon"><a
href="#"><span></span></a></li>
</ul>
<section class="top-bar-section">
<!-- Right Nav Section -->
<ul class="right">
<li><a href="about.php">About</a></li>
<li><a href="products.php">Pay</a></li>
<li><a href="addmoney.php">Add VITCoins</a></li>
<li class="active"><a href="orders.php">My Orders</a></li>
<li><a href="contact.php">Contact</a></li>
<?php
if(isset($_SESSION['username'])){
echo '<li><a href="account.php">My Account</a></li>';
echo '<li><a href="logout.php">Log Out</a></li>';
}
else{
echo '<li><a href="login.php">Log In</a></li>';
echo '<li><a href="register.php">Register</a></li>';
}
?>
</ul>
</section>
</nav>
<?php
$user = $_SESSION["username"];
$result = $mysqli->query("SELECT id, payment_to, current_total,
DATE_FORMAT(date_now,'%d.%m.%Y at %k:%i') as posteddate from user_log where
email='".$user."'");
if($result) {
while($obj = $result->fetch_object()) {
//echo '<div class="large-6">';
echo '<h4>Order ID:'.$obj->id.'</h4>';
echo '<p><strong>Date: </strong> '.$obj->posteddate.'</p>';
echo '<p><strong>Payment To:</strong> '.$obj-
>payment_to.'</p>';
echo '<p><strong>Amount:</strong> '.$currency.$obj-
>current_total.'</p>';
//echo '</div>';
//echo '<div class="large-6">';
//echo '<img src="images/products/sports_band.jpg">';
//echo '</div>';
echo '<p><hr></p>';
}
}
33
?>
</div>
<hr>
</div>
<footer style="margin-top:10px;">
<p style="text-align:center; font-size:0.8em;">© VITCoins!
All Rights Reserved.</p>
</footer>
</div>
</div>
<script src="js/vendor/jquery.js"></script>
<script src="js/foundation.min.js"></script>
<script>
$(document).foundation();
</script>
</body>
</html>
MySQL Database
bolt.sql
SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO";
SET time_zone = "+05:30";
--
-- Database: `bolt`
--
-- --------------------------------------------------------
--
-- Table structure for table `orders`
--
34
`id` int(15) NOT NULL auto_increment,
`payment_to` varchar(255) NOT NULL,
`total` int(15) NOT NULL,
`date` timestamp NOT NULL default CURRENT_TIMESTAMP,
PRIMARY KEY (`id`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1 AUTO_INCREMENT=0 ;
--
-- Dumping data for table `users`
35
--
36
TEST CASES
37
CONCLUSIONS AND FUTURE WORK
CONCLUSION
The main objective of this project to develop a web application for VITians which would pay
for shopping, cab fare and fines was achieved which allows VITians to now easily perform
cashless transaction without any hassle and is a great way forward to the mission of Digital
India.
FUTURE WORK
The following section describes the work that will be implemented with future releases of the
software.
Admin Panel: The admin panel will pay all the fees to the shops.
Enhance User Interface: Adding more user interactive features making user
experience better with time.
Payment Options: Add different payment options such as PayPal, Cash, Gift Cards
and wallets.
38
REFERENCES
https://www.w3schools.com/
https://stackoverflow.com/
39