[go: up one dir, main page]

0% found this document useful (0 votes)
331 views74 pages

Doctor Appointment1

This document provides a project report for a Doctor Appointment System developed by three students at St. John's College of Arts & Science to fulfill the requirements of a Bachelor of Computer Science degree. The report includes an introduction to the project, specifications for the hardware and software used, an analysis of the existing manual appointment system compared to the benefits of the new online system, descriptions of the programming languages and project, designs for the system and database, screenshots of the user interface, testing procedures, and conclusions.

Uploaded by

Misba Ayat
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
331 views74 pages

Doctor Appointment1

This document provides a project report for a Doctor Appointment System developed by three students at St. John's College of Arts & Science to fulfill the requirements of a Bachelor of Computer Science degree. The report includes an introduction to the project, specifications for the hardware and software used, an analysis of the existing manual appointment system compared to the benefits of the new online system, descriptions of the programming languages and project, designs for the system and database, screenshots of the user interface, testing procedures, and conclusions.

Uploaded by

Misba Ayat
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 74

DOCTOR APPOINTMENT SYSTEM

Project Report

Submitted to the fulfilment of requirement for the award of degree

Bachelor of Computer Science

Manonmaniam Sundaranar University, Tirunelveli

Submitted By,

S. SAHAYA ANUSHA(20193221506235)

M. SAHAYA MISBA(20193221506236)

V. SAHAYA SOFIA(20193221506237)

Under the Guidance of

Dr. KAVITHA JEBA MALAR.,

(Asst.Professor Department of Computer Science)

Department of Computer Science

ST. JOHN’S COLLEGE OF ARTS & SCIENCE


(Affiliated to Manonmaniam Sundaranar University, Tirunelveli)
AMMANDIVILAI-629702
2021-2022

1
ST. JOHN’S COLLEGE OF ARTS & SCIENCE
(Affiliated to Manonmaniam Sundaranar University, Tirunelveli)

AMMANDIVILAI-629702

DEPARTMENT OF COMPUTER SCIENCE

This is certify that the Project Report entitled “DOCTOR APPOINTMENT


SYSTEM” is the bonafide record of the project work done by S.Sahaya
Anusha(20193221506235), M.Sahaya Misba(20193221506236), V.Sahaya
Sofia(20193221506237), in partial fulfillment of the requirement for the award
of the degree of Bachelor of Science in Computer Science of Manonmaniam
Sundaranar University, Tirunelveli during the academic Year-2021-2022.

Mrs.R.Amala Rose, MCA, M.Phil.,Ph.D Dr.R.Kavitha Jaba malar

(Head of the Department) (ProjectGuide)

This Project is submitted for the Viva-Voce held at St. Johns College Of Arts
And Science, Ammandivillai on ……………....

Internal Examiner External Examiner

2
DECLARATION

This is declare that the present entitled “DOCTOR APPOINTMENT


SYSTEM” done at St. John’s College of Arts & Science, Ammandivilai
submitted in partial fulfillment of the requirement for the award of the Degree
of Bachelor of Science in Computer Science. Is a report of the original work
done by me during the period of our studies 2021-2022 under the guidance of Dr.
Kavitha Jeba Malar(Assistant professor Department of Computer Science)
and the work reported there in does not form part of any other thesis or work.

Place: Done by,

Date: S. SAHAYA ANUSHA (20193221506235)


M.SAHAYA MISBA (20193221506236)
V. SAHAYA SOFIA (20193221506237)

3
ACKNOWLEDGEMENT

With immense pleasure, I praise and thank almighty for enabling me to complete
this project in time to his mighty grace and blessing

I wish to express my deep gratitude to the Founder & Chairman


Rev.Fr.Dr.V.JOHN BOSCO, and the Secretary Rev.Fr.SAM F.MATHEW,
for providing me an opportunity to do this project work in this esteemed
institution.

We would like to express our gratitude to our beloved principle Dr.M.Edwin


Gnanadhas Ph.D., and our vice principal Dr.R.Jeba malar.M.A. M.Phil.,
Ph.D., for providing us the congenial environment to work in.

We would like to express our profuse gratitude to Mrs.R.Amala Rose MSC.


, M.PHIL., PH.D (pursuing) Hod. Department of computer science for giving
us the support, encouragement and providing us the required lab facilities that
was necessary for the completion of this project.

As a token of gratitude to our internal guide Dr.Kavitha Jebamalar, Ph.D.,


assistant professor, department of computer science far her unlimited support and
encouragement provided through the process.

We also express our gratitude and sincere thanks to all the teaching and non-
teaching staff of Computer Science.

Finally, yet importantly, we would like to express our heartfelt thanks to our
beloved parents and friends for their help and wishes for the successful
completion of this project report.

S.SAHAYA ANUSHA(20193221506235)

M.SAHAYA MISBA(20193221506236)

V.SAHAYA SOFIA(20193221506237)

4
CONTENTS
TITLE PG NO
1) INTRODUCTION 7

2) SYSTEM SPECIFICATION 9

3) SYSTEM ANALYSIS 11

4) LANGUAGE DESCRIPTION 13

5) PROJECT DESCRIPTION 18

6) SYSTEM DESIGN 22

7) DATABASE DESIGN 29

8) SOURCE CODE 35

9) SCREEN SHOT 53

10) SYSTEM TESTING 65

11) CONCLUSION 70

12) FUTURE ENHANCEMENT 72

13) BIBLIOGRAPHY 74

5
ABSTRACT
The project entitled “Doctor Appointment System” was designed and developed
in PHP, MySQL and Bootstrap. The purpose of the study is to implement an
online database system that caters the doctor appointment scheduling, reservation
and records management of consultation for a hospital or clinic. In this era of
pandemic, medical clinic and hospital imposed strict guidelines on the number of
person who can enter their facility. Consultations to doctors are also very limited
and can facilitate a limited number of patients. The online system for appointment
and consultation is one of the solutions that can be used in order to give the people
a way on how to contact their doctors and reserve an appointment for
consultation. The implementation of the said project will help hospital and clinic
provide better client management while ease and comfort is the advantage on the
patient end. The analysis and implementation result shows that the project is
feasible and implementation is highly recommended by the researchers. This
software is supported to eliminate and in some cases reduce the hardships faced
by this existing system. Moreover this system is designed for the particular need
of the company to carry out operations in a smooth and effective manner. The
application is reduced as much as possible to avoid errors while entering the data.
It also provides error message while entering invalid data. No formal knowledge
is needed for the user to use this system. Thus by this all it proves it is user-
friendly. Doctor Appointment System , as described above, can lead to error free,
secure, reliable and fast management system. It can assist the user to concentrate
on their other activities rather to concentrate on the record keeping. Thus it will
help organization in better utilization of resources.

6
INTRODUCTION

7
1.INTRODUCTION

This project is developed a PHP based web page name “Doctor Appointment
System” that covers all the aspects of making appointment of doctors. It enables
healthcare providers to improve operational effectiveness, reduce costs, reduce
medical errors, reduce time consumption and enhance delivery of quality of
care. This system help reduce the problems occur when using the manual
system and helps patients to skip endless queues. The important thing is it will
become easier for the data record and retrieval.

This software also stores all the patient details, patient profile and etc. This
system enables doctors and clinic assistant to manage patient records and
appointments. User can enter their details and they can select doctors to make
appointments. Other than that, the system is user friendly and it can help the
clinic to manage their appointments. The system helps to avoid making
duplicate appointments. Users can view available doctor and his timings and
can make appointments according to it. The system also has an administration
can add/remove patients, doctors and departments and search for appointments.

The system also allows doctors to log in. Doctor can edit their profile and view
their upcoming appointments, patient etc. The database of the doctor
appointment system can hold up to more individual’s information. The
appointment process can be done for multiple user at a time. The targeted to
groups of appointment management system are the doctors and patient of an
hospital. Online systems make patient management easier and more efficient. In
online scheduling systems for appointments also have management of patient
health records as part of the package. The organization can create a single point
from which to save, update, manage and analyze patient information. Our
system will provides best result and save their valuable time too.

8
SYSTEM SPECIFICATION

9
2. SYSTEM SPECIFICATION
HARDWARE SPECIFICATION

• Processor: intel core i5

• Speed: 2.42GHZ

• RAM: 8GB

• Input device: Touchpad, Keyboard

• Output device: Monitor

SOFTWARE SPECIFICATION

• Operating System: Window 7/8/10/11

• Front end: PHP, HTML, JavaScript, Bootstrap & CSS.

• Back end: MySQL.

• Web browser: Mozilla Firefox, Google Chrome, Apple Safari or any Web

based browser.

10
SYSTEM ANALYSIS

11
3. SYSTEM ANALYSIS

EXISTING SYSTEM
Presently people are making appointments manually. This is a time consuming
process, patient has to physically go to the clinic in order to make appointment.
Some clinicsprovide the opportunity to make appointment by placing phone call.
But in this case, people are often left unattended.

LIMITATIONS OF EXISTING SYSTEM

By analyzing the existing system, some of its drawbacks are listed.

• Time consuming.
• Lack of efficiency
• Needs to be physically present at the clinic
• Can’t make appointment in advance for long intervals

PROPOSED SYSTEM
The use of proposed system will avoid the problem of the existing system and w
also get a new system for managing information under the Doctor appointment
system. The proposed system offers:

• Manual work which is time consuming can be reduced.


• Easy to store data in database.
• Administrator can add/remove new doctors, patients.
• Increase processing speed.
• An easily access environment for users.
• Doctors can view/cancel appointment.
• Improve security.

12
LANGUAGE DESCRIPTION

13
4. LANGUAGE DESCRIPTION

PHP (Hypertext Preprocessor) is known as a general-purpose scripting language


that can be used to develop dynamic and interactive websites. It was among the
first server-side languages that could be embedded into HTML, making it easier
to add functionality to web pages without needing to call external files for data.
Its use has evolved over the years, with regular upgrades (version 8.0 was
released in November 2020) adding features and unlocking new capabilities.
Though these days it is not considered the sexiest of languages, here are some key
PHP benefits that help explain why it is still so important in web development.

• It’s easy to learn and use


• It’s open source (and therefore free!)
• It’s versatile
• It enjoys strong community support
• It’s fast and secure
• It is well connected with databases
• It is tried and tested
• There’s a lot of legacy code

One of the main reasons PHP became so commonplace is that it is relatively


simple to get started with. Even without extensive knowledge or experience in
web development, most people could create a web page with a single PHP file in
a relatively short period of time. The syntax is simple and command functions are
easy to learn, meaning the barriers to entry with PHP are lower than with many
other languages. This also helps developers get started with PHP. It can be
installed quickly and at zero cost. There is also open access to a wide range of
PHP frameworks, such as Laravel and Symfony. This feature is also appealing to

14
companies as it helps control the costs of web development. One of the major
benefits of PHP is that it is platform independent, meaning it can be used on Mac
OS, Windows, Linux and supports most web browsers. It also supports all the
major web servers, making it easy to deploy on different systems and platforms
at minimal additional cost. As a veteran scripting language that is widely used,
PHP now has a large and loyal community base to support it. There are tons of
tutorials, FAQs, and tips to help new PHP developers and to continue pushing the
boundaries of what the language can achieve through regular updates.

Two things that every organization wants their website or application to be are
fast and secure. PHP uses its own memory and competes well on speed, especially
when using the new version, there have been questions in the past about PHP
security, though it is important to note that it is not inherently more or less secure
than other programming languages. One important benefit is that because of its
widespread use and community support there are now many tools, frameworks
and best practices to help fix vulnerabilities and protect against
cyberattacks. PHP makes it easy to connect securely with almost any kind of
database. This gives developers more freedom when choosing which database is
best suited for the application being built. One major benefit of being around for
a quarter century is that PHP code has been put to the test in all kinds of real-life
environments. The main bugs have been found and fixed, making the language
more stable and trusted by developers. Moreover, many frameworks and tools
have been built over time, helping to make PHP web development more secure,
efficient and effective. OK, this isn’t really a benefit of using PHP in itself, but
when so many existing websites have been written with PHP it becomes an
important consideration. Put simply, it is usually easier to make updates in the
same language rather than try to rewrite everything in another. This helps PHP
endure even when some younger developers may have a personal preference for
another language.
15
The Hyper Text Markup Language (HTML) is the standard markup language for
documents designed to be displayed in a web browser. It can be assisted by
technologies such as Cascading Style Sheet (CSS) and scripting language such
as JavaScript. Web browser receive HTML documents from a Web server or
from local storage and render the documents into multimedia web pages. HTML
describes the structure of a web page semantically and originally included cues
for the appearance of the document.

HTML can embed programs written in a scripting language such as JavaScript,


which affects the behavior and content of web pages. Inclusion of CSS defines
the look and layout of content. The World Wide Web Consortium (W3C), former
maintainer of the HTML and current maintainer of the CSS standards, has
encouraged the use of CSS over explicit presentational HTML since 1997. A form
of HTML, known as HTML5, is used to display video and audio, primarily using
the <canvas> element, in collaboration with JavaScript.

Bootstrap is a powerful toolkit with a collection of HTML, CSS, and JavaScript


tools for creating and building web pages and web applications. It is a free and
open-source project, hosted on GitHub, and originally created by (and
for) Twitter. After its open-source release in 2011, Bootstrap became popular
very quickly, and not without reason. Web designers and web developers like
Bootstrap because it is flexible and easy to work with. Its main advantages are
that it is responsive by design, it maintains wide browser compatibility, it offers
consistent design by using reusable components, and it is very easy to use and
quick to learn. It offers rich extensibility using JavaScript, coming with built-in
support for jQuery plugins and a programmatic JavaScript API.

16
JavaScript (JS), is a programming language that is one of the core technologies
of the World Wide Web, alongside HTML and CSS. Over 97% of websites use
JavaScript on the client side for web page behavior, often incorporating third-
party libraries. All major web browsers have a dedicated JavaScript engine to
execute the code on users' devices. JavaScript is a high-level, often just-in-time
compiled language that conforms to the ECMAScript standard. It has dynamic
typing, prototype-based object-orientation, and first-class functions. It is multi-
paradigm, supporting event-driven, functional, and imperative programming
styles. It has application programming interfaces (APIs) for working with text,
dates, regular expressions, standard data structures, and the Document Object
Model (DOM).

The ECMAScript standard does not include any input/output (I/O), such
as networking, storage, or graphics facilities. In practice, the web browser or
other runtime system provides JavaScript APIs for I/O. JavaScript engines were
originally used only in web browsers, but are now core components of
some servers and a variety of applications. The most popular runtime system for
this usage is Node.js. Although Java and JavaScript are similar in name, syntax,
and respective standard libraries, the two languages are distinct and differ greatly
in design.

17
PROJECT DESCRIPTION

18
5. PROJECT DESCRIPTION

The project for developed Doctor Appointment System is for solve the purpose
for disallow the problems, which are not in the current system. This Doctor
Appointment System is assume to remove the hardships, which will be available
in the current appointment system. But by using electronics equipment like
computer and by using this devices we can stored valuable information which
we can stored under this appointment system. This Online Doctor Appointment
system is show as the fast, error free and secured system with fast management
of data. With the help of this Doctor Appointment System which show the good
for use of resources and stored records in central location of database. This
system we can also called Online Patient Scheduling or also known as Online
Appointment booking system and it has optimized phase of medical services to
increase patient healthcare experience in hospitals or in clinics. This system has
been build by motivating to see the increasing popularity of online appointment
booking system.we have add doctor scheduling model also which has been takes
into accounts when patient would like to seen this feature. Now a days it is
rational to established the issue that a very less hospitals has provide online
appointment booking system. So solve this all problem we have build this
Doctor Online Appointment booking system.

This Online Doctor Appointment Booking System in PHP is a easy project


developed using PHP script, MySQL database. Under this project there are three
sides. One at Admin side, second is doctor side and third is patient side. Under
this Doctor Appointment System Admin can manage whole system data like
doctor data, patient data, doctor schedule data and appointment data. At the
Doctor side, doctor can schedule their available time details under this system,
Doctor can view appointment data. And at patient side, they can view doctor
availability data and based on that data they can book appointment under this
system.

19
MODULE DESCRIPTION

MAIN MODULES:

Main modules of these systems are given below:

• Admin Module
• User Module
• Login Module
• Signup Module

ADMIN MODULE:
• Add Doctor:
Administrator can add a doctor by filling out required fields.
• Doctor registration
Administrator can add doctor and assign them duty times and schedules.
• Update Doctor profile:
Administrator can update a doctor profile.
• Remove a User:
Administrator can remove users profile.
• Add a new user:
Administrator can add a new user by filling out requires fields

USER MODULE:
• User Signup - Signup the user by the details that include Patient First
Name, Last Name, IC Number, Password, Email, DOB, Gender.
• Profile - User can edit and update their profile including their password.
• Doctor available - User can view the doctor available time to make an
appointment

20
• Make appointment - User view select the corresponding doctors scheduled
time and they need fill relevant list like appid, patinetic, schedulesid,
appsymptom, appcomment, to make an appointment
LOGIN MODULE:
Doctor and admin can login into the web page
SIGN UP MODULE:
User can register to get a appointment

SUB MODULES:

• Dashboard of admin
• Doctor schedule module
• Patient list module

DASHBOARD OF ADMIN: Admin can view an appointment list.

DOCTOR SCHEDULE MODULE: Administrator can schedule the doctor


appointment

PATIENT LIST MODULE: Administrator can view a patients list

21
SYSTEM DESIGN

22
6. SYSTEM DESIGN

SYSTEM FLOW DIAGRAM

Click to
Login

Add
Sign up patient
info
Admin Patient

Already
have an
account

Doctor
login

Login

Schedule
the time

Make
appoint
ment
Doctor
profile

Get
Update acknowl
the edgemen
profile t

23
DATA FLOW DIAGRAM

A data flow diagram can also be used for the visualization of Data
Processing. It is common practice for a designer to draw a context-level DFD first
which shows the interaction between the system and outside entities. This
context-level DFD is then "exploded" to show more detail of the system being
modeled.

A DFD represents flow of data through a system. Data flow diagrams are
commonly used during problem analysis. It views a system as a function that
transforms the input into desired output. A DFD shows movement of data through
the different transformations or processes in the system.

Dataflow diagrams can be used to provide the end user with a physical idea
of where the data they input ultimately has an effect upon the structure of the
whole system from order to dispatch to restock how any system is developed can
be determined through a dataflow diagram.

Data Flow Diagram Notation

Function

File/Database

Input/Output

Flow

24
Login

Get Username and Check


Password from User username
and
password Login

Load Main page

Sign Up

Already have an
account
no yes

Get information
Login
from user

Save user
informati
on

Sign up

25
Doctor details:

Admin

Login

Doctor Doctor
dashboard schedule Patient list

Doctor profile

Update the
profile

Logout

26
Patient details:

Click to login

Already have an
Sign up account

Make
Add patient info appointment

Get an
acknowledgement
database

Input design

Input design is the process of converting a user – oriented description of


the inputs to a computer-based business system into a programmer – oriented
specification. The goal of designing input data is to make data entry as easy,
logical and free from errors as possible. Input design is a part of the overall system
design, which requires careful attention. If the data going into system is incorrect,
then the processing and output will magnify these errors. The proposed system
satisfies the following input design objectives:

• A cost-effective method of input


• The highest possible level of accuracy

27
• The input is acceptable to and understand by the use staff
Several activities done in the input stages are:
• Data recording – collection of data as its sources
• Data transcription – transcription of data to an input form
• Data conversion – conversion of the input data to a computer acceptable
medium
• Data verification - checking the conversion
• Data control – checking the accuracy and controlling the flow of the data
to the computer
• Data transmission -transmitting or transporting, the data to the computer
• Data validation & correction – checking & correcting the errors the input
data by program when it enter the computer system.

OUTPUT DESIGN

The output from an information system should accomplish one or more of


the following objectives:

• Convey information about past activities, current status or projections in


future.
• Signal important events, opportunities, problem or warnings.
• Trigger an action
• Confirm the action

28
DATABASE DESIGN

29
7. DATABASE DESIGN

MySQL is a fast, easy-to-use RDBMS being used for many small and big
businesses. MySQL is developed, marketed and supported by MySQL AB, which
is a Swedish company. MySQL is becoming so popular because of many good
reasons –

• MySQL is released under an open-source license. So, you have nothing to pay
to use it.

• MySQL is a very powerful program in its own right. It handles a large subset of
the functionality of the most expensive and powerful database packages.

• MySQL uses a standard form of the well-known SQL data language.

• MySQL works on many operating systems and with many languages including
PYTHON, PHP, PERL, C, C++, JAVA, etc.

• MySQL works very quickly and works well even with large data sets.

• MySQL supports large databases, up to 50 million rows or more in a table. The


default file size limit for a table is 4GB, but you can increase this (if your
operating system can handle it) to a theoretical limit of 8 million terabytes (TB).

• MySQL is customizable. The open-source GPL license allows programmers to


modify the MySQL software to fit their own specific environments.

Administrative MySQL command:

Here is the list of the important MySQL commands, which you will use
time to time to work with MySQL database –

• USE Database name − this will be used to select a database in the MySQLwork
area.

30
• SHOW DATABASES − Lists out the databases that are accessible by the
MySQL DBMS.

• SHOW TABLES − Shows the tables in the database once a database has been
selected with the use command.

• SHOW COLUMNS FROM table name: Shows the attributes, types of attributes,
key information, whether NULL is permitted, defaults, and other information for
a table.

• SHOW INDEX FROM table name – Presents the details of all indexes on the
table, including the PRIMARY KEY.

• SHOW TABLE STATUS LIKE table name – Reports details of the MySQL
DBMS performance and statistics.

MySQL is offered under two different editions: the open source MySQL
Community Server[77] and the proprietary Enterprise Server. MySQL Enterprise
Server is differentiated by a series of proprietary extensions which install as
server plugins, but otherwise shares the version numbering system and is built
from the same code base. Oracle MySQL offers a high availability solution with
a mix of tools including the MySQL router and the MySQL shell. They are based
on Group Replication, open-source tools. MariaDB offers a similar offer in terms
of products

Relational models have remained popular for several reasons. They empower
users with intuitive, declarative programming languages — essentially telling
the database what result is wanted in language akin to, or at least
comprehensible as, written English, instead of meticulously coding up each step
of the procedure leading to that result. This moves a lot of the work into the
RDBMS and SQL engines, better enforcing logical rules and saving valuable
resources and manpower.

31
TABLE NAME: Doctor
DESCRIPTION: To create a doctor’s profile.

opDoctor Varchar(45)

Password Varchar(45)

doctorId Varchar(45)

doctorFistName Varchar(45)

doctorLastName Varchar(45)

doctorAddress Varchar(45)

doctorPhone Varchar(45)

doctorEmail Varchar(45)

doctorDOB Varchar(45)

32
TABLE NAME: Patient

DESCRIPTION: To create a patient’s profile.

idPatient Varchar(45)

Password Varchar(45)

patientFirstName Varchar(45)

patientLastName Varchar(45)

patientMaritialStatus Varchar(45)

patientDOB Varchar(45)

patientGender Varchar(45)

patientAddress Varchar(45)

patientPhone Varchar(45)

patientEmail Varchar(45)

33
TABLE NAME: Doctorschedule

DESCRIPTION: To create a schedule for the doctor.

scheduledId Varchar(45)

scheduledDate Varchar(45)

scheduleDay Varchar(45)

startTime Varchar(45)

endTime Varchar(45)

bookAvail Varchar(45)

TABLE NAME: Appointment

DESCRIPTION: To get a doctor’s appointment.

appId Varchar(45)

patientIc Varchar(45)

scheduledId Varchar(45)

appSymptom Varchar(45)

appCommend Varchar(45)

Status Varchar(45)

34
SOURCE CODE

35
8. SOURCE CODE

addShedule.php
<?php
session_start();
include_once '../assets/conn/dbconnect.php';
// include_once 'connection/server.php';
if(!isset($_SESSION['doctorSession']))
{
header("Location: ../index.php");
}
$usersession = $_SESSION['doctorSession'];
$res=mysqli_query($con,"SELECT * FROM doctor WHERE
doctorId=".$usersession);
$userRow=mysqli_fetch_array($res,MYSQLI_ASSOC);
// insert

if (isset($_POST['submit'])) {
$date = mysqli_real_escape_string($con,$_POST['date']);
$scheduleday = mysqli_real_escape_string($con,$_POST['scheduleday']);
$starttime = mysqli_real_escape_string($con,$_POST['starttime']);
$endtime = mysqli_real_escape_string($con,$_POST['endtime']);
$bookavail = mysqli_real_escape_string($con,$_POST['bookavail']);

//INSERT
$query = " INSERT INTO doctorschedule ( scheduleDate, scheduleDay,
startTime, endTime, bookAvail)
VALUES ( '$date', '$scheduleday', '$starttime', '$endtime', '$bookavail' ) ";

$result = mysqli_query($con, $query);


// echo $result;
if( $result )
{
?>
<script type="text/javascript">
alert('Schedule added successfully.');
</script>
<?php
}
else
{

36
?>
<script type="text/javascript">
alert('Added fail. Please try again.');
</script>
<?php
}

}
?>

?>
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="">
<meta name="author" content="">
<title>Welcome Dr <?php echo $userRow['doctorFirstName'];?> <?php
echo $userRow['doctorLastName'];?></title>
<!-- Bootstrap Core CSS -->
<!-- <link href="assets/css/bootstrap.css" rel="stylesheet"> -->
<link href="assets/css/material.css" rel="stylesheet">
<!-- Custom CSS -->
<link href="assets/css/sb-admin.css" rel="stylesheet">
<!-- Custom Fonts -->
</head>
<body>
<div id="wrapper">

<!-- Navigation -->


<nav class="navbar navbar-inverse navbar-fixed-top"
role="navigation">
<!-- Brand and toggle get grouped for better mobile display -->
<div class="navbar-header">
<button type="button" class="navbar-toggle" data-
toggle="collapse" data-target=".navbar-ex1-collapse">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>

37
<a class="navbar-brand" href="doctordashboard.php">Welcome Dr
<?php echo $userRow['doctorFirstName'];?> <?php echo
$userRow['doctorLastName'];?></a>
</div>
<!-- Top Menu Items -->
<ul class="nav navbar-right top-nav">

<li class="dropdown">
<a href="#" class="dropdown-toggle" data-
toggle="dropdown"><i class="fa fa-user"></i> <?php echo
$userRow['doctorFirstName']; ?> <?php echo $userRow['doctorLastName'];
?><b class="caret"></b></a>
<ul class="dropdown-menu">
<li>
<a href="doctorprofile.php"><i class="fa fa-fw fa-
user"></i> Profile</a>
</li>

<li class="divider"></li>
<li>
<a href="logout.php?logout"><i class="fa fa-fw fa-power-
off"></i> Log Out</a>
</li>
</ul>
</li>
</ul>
<!-- Sidebar Menu Items - These collapse to the responsive navigation
menu on small screens -->
<div class="collapse navbar-collapse navbar-ex1-collapse">
<ul class="nav navbar-nav side-nav">
<li>
<a href="doctordashboard.php"><i class="fa fa-fw fa-
dashboard"></i> Dashboard</a>
</li>
<li class="active">
<a href="addschedule.php"><i class="fa fa-fw fa-table"></i>
Doctor Schedule</a>
</li>
<li>
<a href="patientlist.php"><i class="fa fa-fw fa-edit"></i>
Patient List</a>
</li>

38
</ul>
</div>
<!-- /.navbar-collapse -->
</nav>
<!-- navigation end -->

<div id="page-wrapper">
<div class="container-fluid">

<!-- Page Heading -->


<div class="row">
<div class="col-lg-12">
<h2 class="page-header">
Doctor Schedule
</h2>
<ol class="breadcrumb">
<li class="active">
<i class="fa fa-calendar"></i> Schedule
</li>
</ol>
</div>
</div>
<!-- Page Heading end-->

<!-- panel start -->


<div class="panel panel-primary">

<!-- panel heading starat -->


<div class="panel-heading">
<h3 class="panel-title">Add Schedule</h3>
</div>
<!-- panel heading end -->

<div class="panel-body">
<!-- panel content start -->
<div class="bootstrap-iso">
<div class="container-fluid">
<div class="row">
<div class="col-md-12 col-sm-12 col-xs-12">
<form class="form-horizontal" method="post">
<div class="form-group form-group-lg">
<label class="control-label col-sm-2 requiredField"
for="date">

39
Date
<span class="asteriskField">
*
</span>
</label>
<div class="col-sm-10">
<div class="input-group">
<div class="input-group-addon">
<i class="fa fa-calendar">
</i>
</div>
<input class="form-control" id="date" name="date"
type="text" required/>
</div>
</div>
</div>
<div class="form-group form-group-lg">
<label class="control-label col-sm-2 requiredField"
for="scheduleday">
Day
<span class="asteriskField">
*
</span>
</label>
<div class="col-sm-10">
<select class="select form-control" id="scheduleday"
name="scheduleday" required>
<option value="Monday">
Monday
</option>
<option value="Tuesday">
Tuesday
</option>
<option value="Wednesday">
Wednesday
</option>
<option value="Thursday">
Thursday
</option>
<option value="Friday">
Friday
</option>
<option value="Saturday">

40
Saturday
</option>
<option value="Sunday">
Sunday
</option>
</select>
</div>
</div>
<div class="form-group form-group-lg">
<label class="control-label col-sm-2 requiredField"
for="starttime">
Start Time
<span class="asteriskField">
*
</span>
</label>

<div class="col-sm-10">
<div class="input-group clockpicker" data-align="top"
data-autoclose="true">
<div class="input-group-addon">
<i class="fa fa-clock-o">
</i>
</div>
<input class="form-control" id="starttime"
name="starttime" type="text" required/>
</div>
</div>
</div>
<div class="form-group form-group-lg">
<label class="control-label col-sm-2 requiredField"
for="endtime">
End Time
<span class="asteriskField">
*
</span>
</label>
<div class="col-sm-10">
<div class="input-group clockpicker" data-align="top"
data-autoclose="true">
<div class="input-group-addon">
<i class="fa fa-clock-o">
</i>

41
</div>
<input class="form-control" id="endtime"
name="endtime" type="text" required/>
</div>
</div>
</div>
<div class="form-group form-group-lg">
<label class="control-label col-sm-2 requiredField"
for="bookavail">
Availabilty
<span class="asteriskField">
*
</span>
</label>
<div class="col-sm-10">
<select class="select form-control" id="bookavail"
name="bookavail" required>
<option value="available">
available
</option>
<option value="notavail">
notavail
</option>
</select>
</div>
</div>
<div class="form-group">
<div class="col-sm-10 col-sm-offset-2">
<button class="btn btn-primary " name="submit"
type="submit">
Submit
</button>
</div>
</div>
</form>
</div>
</div>
</div>
</div>
<!-- panel content end -->
<!-- panel end -->
</div>
</div>

42
<!-- panel start -->

<!-- panel start -->


<div class="panel panel-primary filterable">

<!-- panel heading starat -->


<div class="panel-heading">
<h3 class="panel-title">List of Patients</h3>
<div class="pull-right">
<button class="btn btn-default btn-xs btn-filter"><span
class="fa fa-filter"></span> Filter</button>
</div>
</div>
<!-- panel heading end -->

<div class="panel-body">
<!-- panel content start -->
<!-- Table -->
<table class="table table-hover table-bordered">
<thead>
<tr class="filters">
<th><input type="text" class="form-control"
placeholder="scheduleId" disabled></th>
<th><input type="text" class="form-control"
placeholder="scheduleDate" disabled></th>
<th><input type="text" class="form-control"
placeholder="scheduleDay" disabled></th>
<th><input type="text" class="form-control"
placeholder="startTime." disabled></th>
<th><input type="text" class="form-control"
placeholder="endTime" disabled></th>
<th><input type="text" class="form-control"
placeholder="bookAvail" disabled></th>
</tr>
</thead>

<?php
$result=mysqli_query($con,"SELECT * FROM
doctorschedule");

while ($doctorschedule=mysqli_fetch_array($result)) {

43
echo "<tbody>";
echo "<tr>";
echo "<td>" . $doctorschedule['scheduleId'] . "</td>";
echo "<td>" . $doctorschedule['scheduleDate'] . "</td>";
echo "<td>" . $doctorschedule['scheduleDay'] . "</td>";
echo "<td>" . $doctorschedule['startTime'] . "</td>";
echo "<td>" . $doctorschedule['endTime'] . "</td>";
echo "<td>" . $doctorschedule['bookAvail'] . "</td>";
echo "<form method='POST'>";
echo "<td class='text-center'><a href='#'
id='".$doctorschedule['scheduleId']."' class='delete'><span class='glyphicon
glyphicon-trash' aria-hidden='true'></span></a>
</td>";

}
echo "</tr>";
echo "</tbody>";
echo "</table>";
echo "<div class='panel panel-default'>";
echo "<div class='col-md-offset-3 pull-right'>";
echo "<button class='btn btn-primary' type='submit'
value='Submit' name='submit'>Update</button>";
echo "</div>";
echo "</div>";
?>
<!-- panel content end -->
<!-- panel end -->
</div>
</div>
<!-- panel start -->
</div>
</div>
<!-- /#wrapper -->
<script src="assets/js/bootstrap-clockpicker.js"></script>
<script>
$(document).ready(function(){
var date_input=$('input[name="date"]'); //our date input has the name
"date"
var container=$('.bootstrap-iso form').length>0 ? $('.bootstrap-iso
form').parent() : "body";
date_input.datepicker({

44
format: 'yyyy/mm/dd',
container: container,
todayHighlight: true,
autoclose: true,
})
})
</script>
<script type="text/javascript">
$('.clockpicker').clockpicker();
</script>
<script type="text/javascript">
$(function() {
$(".delete").click(function(){
var element = $(this);
var id = element.attr("id");
var info = 'id=' + id;
if(confirm("Are you sure you want to delete this?"))
{
$.ajax({
type: "POST",
url: "deleteschedule.php",
data: info,
success: function(){
}
});
$(this).parent().parent().fadeOut(300, function(){ $(this).remove();});
}
return false;
});
});
</script>
<script type="text/javascript">
$(document).ready(function(){
$('.filterable .btn-filter').click(function(){
var $panel = $(this).parents('.filterable'),
$filters = $panel.find('.filters input'),
$tbody = $panel.find('.table tbody');
if ($filters.prop('disabled') == true) {
$filters.prop('disabled', false);
$filters.first().focus();
} else {
$filters.val('').prop('disabled', true);
$tbody.find('.no-result').remove();

45
$tbody.find('tr').show();
}
});

$('.filterable .filters input').keyup(function(e){


/* Ignore tab key */
var code = e.keyCode || e.which;
if (code == '9') return;
/* Useful DOM data and selectors */
var $input = $(this),
inputContent = $input.val().toLowerCase(),
$panel = $input.parents('.filterable'),
column = $panel.find('.filters th').index($input.parents('th')),
$table = $panel.find('.table'),
$rows = $table.find('tbody tr');
/* Dirtiest filter function ever ;) */
var $filteredRows = $rows.filter(function(){
var value = $(this).find('td').eq(column).text().toLowerCase();
return value.indexOf(inputContent) === -1;
});
/* Clean previous no-result if exist */
$table.find('tbody .no-result').remove();
/* Show all rows, hide filtered ones (never do that outside of a
demo ! xD) */
$rows.show();
$filteredRows.hide();
/* Prepend no-result row if all rows are filtered */
if ($filteredRows.length === $rows.length) {
$table.find('tbody').prepend($('<tr class="no-result text-
center"><td colspan="'+ $table.find('.filters th').length +'">No result
found</td></tr>'));
}
});
});
</script>

</body>
</html>
?>

Logout.php
<?php

46
session_start();

if(!isset($_SESSION['doctorSession']))
{
header("Location: doctordashboard.php");
}
else if(isset($_SESSION['doctorSession'])!="")
{
header("Location: ../index.php");
}

if(isset($_GET['logout']))
{
session_destroy();
unset($_SESSION['doctorSession']);
header("Location: ../user.php");
}
?>
Getshedule.php
<?php
session_start();
include_once '../assets/conn/dbconnect.php';
$q = $_GET['q'];
$res = mysqli_query($con,"SELECT * FROM doctorschedule WHERE
scheduleDate='$q'");
if (!$res) {
die("Error running $sql: " . mysqli_error());
}
?>
<!DOCTYPE html>
<html lang="en">
<head>
<link href="assets/css/bootstrap.min.css" rel="stylesheet">
</head>
<body>
<?php
if (mysqli_num_rows($res)==0) {
echo "<div class='alert alert-danger' role='alert'>Doctor is not available at
the moment. Please try again later.</div>";

} else {
echo " <table class='table table-hover'>";
echo " <thead>";

47
echo " <tr>";
echo " <th>App Id</th>";
echo " <th>Day</th>";
echo " <th>Date</th>";
echo " <th>Start Time</th>";
echo " <th>End Time</th>";
echo " <th>Availability</th>";
echo " <th>Book Now!</th>";
echo " </tr>";
echo " </thead>";
echo " <tbody>";
while($row = mysqli_fetch_array($res)) {
?>
<tr>
<?php
// $avail=null;
// $btnclick="";
if ($row['bookAvail']!='available') {
$avail="danger";
$btnstate="disabled";
$btnclick="danger";
} else {
$avail="primary";
$btnstate="";
$btnclick="primary";
}

// if ($rowapp['bookAvail']!="available") {
// $btnstate="disabled";
// } else {
// $btnstate="";
// }
echo "<td>" . $row['scheduleId'] . "</td>";
echo "<td>" . $row['scheduleDay'] . "</td>";
echo "<td>" . $row['scheduleDate'] . "</td>";
echo "<td>" . $row['startTime'] . "</td>";
echo "<td>" . $row['endTime'] . "</td>";
echo "<td> <span class='label label-".$avail."'>". $row['bookAvail']
."</span></td>";
echo "<td><a href='appointment.php?&appid=" .
$row['scheduleId'] . "&scheduleDate=".$q."' class='btn btn-".$btnclick." btn-xs'
role='button' ".$btnstate.">Book Now</a></td>";

48
// echo "<td><a href='appointment.php?&appid=" .
$row['scheduleId'] . "&scheduleDate=".$q."'>Book</a></td>";
// <td><button type='button' class='btn btn-primary btn-xs' data-
toggle='modal' data-target='#exampleModal'>Book Now</button></td>";
//triggered when modal is about to be shown
?>

</script>
<!-- ?> -->
</tr>

<?php
}
}
?>
</tbody>
<!-- modal start -->

</body>
</html>
Invoice.php
<?php
session_start();
include_once '../assets/conn/dbconnect.php';
if (isset($_GET['appid'])) {
$appid=$_GET['appid'];
}
$res=mysqli_query($con, "SELECT a.*, b.*,c.* FROM patient a
JOIN appointment b
On a.icPatient = b.patientIc
JOIN doctorschedule c
On b.scheduleId=c.scheduleId
WHERE b.appId =".$appid);

$userRow=mysqli_fetch_array($res,MYSQLI_ASSOC);
?>
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>A simple, clean, and responsive HTML invoice template</title>

<link rel="stylesheet" type="text/css" href="assets/css/invoice.css">

49
</head>
<body>
<div class="invoice-box">
<table cellpadding="0" cellspacing="0">
<tr class="top">
<td colspan="2">
<table>
<tr>
<td class="title">
<img src="assets/img/logo.jpg" style="width:100%; max-
width:300px;">
</td>

<td>
Invoice #: <?php echo $userRow['appId'];?><br>
Created: <?php echo date("d-m-Y");?><br>
</td>
</tr>
</table>
</td>
</tr>

<tr class="information">
<td colspan="2">
<table>
<tr>
<td>
<?php echo $userRow['patientAddress'];?>
</td>

<td><?php echo $userRow['patientIc'];?><br>


<?php echo $userRow['patientFirstName'];?> <?php echo
$userRow['patientLastName'];?><br>
<?php echo $userRow['patientEmail'];?>
</td>
</tr>
</table>
</td>
</tr>

<tr class="heading">

50
<td>
Appointment Details
</td>

<td>
#
</td>
</tr>

<tr class="item">
<td>
Appointment ID
</td>

<td>
<?php echo $userRow['appId'];?>
</td>
</tr>

<tr class="item">
<td>
Schedule ID
</td>

<td>
<?php echo $userRow['scheduleId'];?>
</td>
</tr>

<tr class="item">
<td>
Appointment Day
</td>
<td>
<?php echo $userRow['scheduleDay'];?>
</td>
</tr>
<tr class="item">
<td>
Appointment Date
</td>
<td>
<?php echo $userRow['scheduleDate'];?>

51
</td>
</tr>
<tr class="item">
<td>
Appointment Time
</td>
<td>
<?php echo $userRow['startTime'];?> untill <?php echo
$userRow['endTime'];?>
</td>
</tr>
<tr class="item">
<td>
Patient Symptom
</td>

<td>
<?php echo $userRow['appSymptom'];?>
</td>
</tr>

</table>
</div>
<div class="print">
<button onclick="myFunction()">Print this page</button>
</div>
<script>
function myFunction() {
window.print();
}
</script>
</body>
</html>

52
SAMPLE SCREEN

53
9. SAMPLE SCREEN

Main page:

54
Doctor login:

Doctor Dashboard:

55
Doctor Schedule:

Schedule page:

56
Schedule confirmation:

Patient list:

57
Scheduled main page:

Booking page:

58
Patient sign up:

fill the patient information:

59
Patient login:

login require field:

60
Patient profile:

Updating the patient profile:

61
Updated profile:

Main page for booking appointment:

62
fill the require field to make appointment:

Acknowledgement:

63
Print page:

64
SYSTEM TESTING

65
10. SYSTEM TESTING

a) TEST CASE REPORTS

The purpose of testing is to discover errors. Testing is the process of trying


to discover every conceivable fault or weakness in a work product. It provides a
way to check the functionality of components, sub-assemblies, assemblies and/or
a finished product. It is the process of exercising software with the intent of
ensuring that the Software system meets its requirements and user expectations
and does not fail in an unacceptable manner. There are various types of tests. Each
test type addresses a specific testing requirement.

b) TYPES OF TESTS

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.

Integration testing

Integration tests are designed to test integrated software components to


determine if they actually run as one program. Testing is event driven and is more
concerned with the basic outcome of screens or fields. Integration tests
demonstrate that although the components were individually satisfaction, as

66
shown by successfully unit testing, the combination of components is correct and
consistent. Integration testing is specifically aimed at exposing the problems that
arise from the combination of components.

Functional test

Functional tests provide systematic demonstrations that functions tested


are available as specified by the business and technical requirements, system
documentation, and user manuals. Functional testing is centered on the following
items:

Valid Input: identified classes of valid input must be accepted.

Invalid Input: identified classes of invalid input must be rejected.

Functions: identified functions must be exercised.

Output: identified classes of application outputs must be exercised.


Systems/Procedures: interfacing systems or procedures must be invoked.

Organization and preparation of functional tests is focused on requirements, key


functions, or special test cases. In addition, systematic coverage pertaining to
identify Business process flows; data fields, predefined processes, and successive
processes must be considered for testing. Before functional testing is complete,
additional tests are identified and the effective value of current tests is
determined.

System Test

System testing ensures that the entire integrated software system meets
requirements. It tests a configuration to ensure known and predictable results. An
example of system testing is the configuration-oriented system integration test.

67
System testing is based on process descriptions and flows, emphasizing predriven
process links and integration points.

White Box Testing

White Box Testing is a testing in which in which the software tester has
knowledge of the inner workings, structure and language of the software, or at
least its purpose. It is purpose. It is used to test areas that cannot be reached from
a black box level.

Black Box Testing

Black Box Testing is testing the software without any knowledge of the
inner workings, structure or language of the module being tested. Black box tests,
as most other kinds of tests, must be written from a definitive source document,
such as specification or requirements document, such as specification or
requirements document. It is a testing in which the software under test is treated,
as a black box. You cannot “see” into it. The test provides inputs and responds to
outputs without considering how the software works.

Unit Testing

Unit testing is usually conducted as part of a combined code and unit test
phase of the software lifecycle, although it is not uncommon for coding and unit
testing to be conducted as two distinct phases.

Test strategy and approach

Field testing will be performed manually and functional tests will be


written in detail.

Test objectives

✓ All field entries must work properly.


68
✓ Pages must be activated from the identified link.

✓ The entry screen, messages and responses must not be delayed.

Features to be tested

✓ Verify that the entries are of the correct format

✓ No duplicate entries should be allowed

✓ All links should take the user to the correct page.

Integration Testing

Software integration testing is the incremental integration testing of two or


more integrated software components on a single platform to produce failures
caused by interface defects.

The task of the integration test is to check that components or software


applications, e.g., components in a software system or one step up software
applications at the company level – interact without error.

Acceptance Testing

User Acceptance Testing is a critical phase of any project and requires


significant participation by the end user. It also ensures that the system meets the
functional requirements

69
CONCLUSION

70
11. CONCLUSION

This system aims to build an effective to make a appointment using doctor


appointment system. The proposed system will be able to get appointment via
online appointment system. Once the administrator has added the doctor and
patient can book their appointment by visiting the system. No need of third
person to process the request. The proposed system is efficient and has friendly
user interface. Addition of the admin and doctor modules in the web page are
included future work. That would help the doctor to register on the web page
and perform all the task on the app. The admin would be able to use the app for
managing the details of the patients and the doctor instead of using the web
page. Compared to the usual queuing method, the web-based appointment
system could significantly increase patient's satisfaction with registration and
reduce total waiting time effectively. However, further improvements are
needed for broad use of the system.

71
FUTURE ENHANCEMENT

72
12. FUTURE ENHANCEMENT

Online system is always a changeable system. It develops day by day, getting


better and better to easier for peoples. This could be a revolutionary web
application that may help bonding between doctor and patient. We believe we
can make this system more advanced in future. Advance features and User
interface will be updated in future. Our system is already user friendly but we
will try to make this system more user friendly in future.

73
13. BIBLIOGRAPHY
[1] https://qdoc.tips/php-and-mysql-project-on-doctor-appointment-system-pdf-
free.html

[2] https://ilide.info/doc-viewer

[3] https://www.academia.edu/32409989/Clinic_Appointment_System

[4]https://www.researchgate.net/publication/281643505_Impact_of_using_appo
intment_system_on_patients'_satisfaction

74

You might also like