Professional Documents
Culture Documents
PROJECT FILE
(SESSION 2016 2017)
AIRLINE RESERVATION
SYSTEM
Page 2
Page 3
Page 4
Page 5
Page 6
Ubuntu 9.10:
Processor: 600 MHZ Intel Pentium IV or equivalent
Memory : 512 MB
Disk Space: 250MB of free disk space
Page 7
and distance .
present
Page 8
Page 9
Page
10
START
Accept
YES
If choice
= login
choice
No
If choice
= signup
OPEN
USER LOGIN
FORM
No
OPEN
ADMIN LOGIN
FORM
No
Accept
Information
(If correct)
If choice
=admin
OPEN
Signup
form
No
Accept
login
details
No
Accept
login
details
(If correct)
Stores Information
OPEN
Validation
form
Store Data
Page
11
OPEN BOOKING
SYSTEM FORM
ACCEPT
FLIGHT
DETAILS
If choice =
Domestic
If choice =
International
ACCEPT
FLIGHT
ACCEPT
FLIGHT
B
Page
12
Accept
passengers
Accept
class
If choice =
First
If choice =
Economy
OPEN
PAYMENT WINDOW
C
Page
13
ACCEPT
CHOICE
If choice =
VisaCard
If choice
= Paypal
RESERVE FLIGHT
STOP
Page
14
If choice =
MasterCard
1.
Main Form
2.
Login Form
3.
Signup Form
4.
5.
6.
7.
Reservation Form
8.
9.
Page
15
FORM SUMMARY :The above form is the main window of the application
which provides every user with three choices.
The person can login into the system by registering
himself by clicking SIGNUP and then LOGIN anytime from
anywhere he/she desires.
NOTE :- The idea of ADMIN is to refer to the regular validation of the flights
and other required information that needs to be kept fresh that can be done by
administrators . It is not meant for normal users.
Page
16
Page
17
FORM SUMMARY :This is the window that opens when the user clicks on
login button . the user is prompted to enter his/her
username and password which on being correct prompts
the user to further window which is the Booking Form.
Page
18
Page
19
Form Summary:This is the form/window which opens when the user clicks
on the SIGNUP window on the main form. This form accepts
all essential information from the user and stores them in
the database thereby registering the user in the system.
Page
20
{
JOptionPane.showMessageDialog(this,"Information incomplete");
}
else if(mobile.length()!=10)
{
JOptionPane.showMessageDialog(this,"wrong mobile no.");
}
else if(jCheckBox1.isSelected()!= true)
{
JOptionPane.showMessageDialog(this,"Please agree to our terms and conditions ");
}
else
{
try
{
Class.forName("java.sql.DriverManager");
Connection con = (Connection)
DriverManager.getConnection("jdbc:mysql://localhost:3306/mysql", "root","");
Statement stmt = (Statement) con.createStatement();
Statement st = (Statement) con.createStatement();
String query="INSERT INTO skyline_users VALUES
('"+name+"','"+email+"','"+password+"','"+date+"','"+cor+"','"+mobile+"','"+mn+"');";
stmt.executeUpdate(query);
}
catch (Exception e)
{
JOptionPane.showMessageDialog (this, e.getMessage());
}
}
Page
22
Figure-1
Figure-2
Page
23
Form Summary:This form on the click of next accepts the regions the person
wants to travel between and further after sorting suitable
flights view all the flights in a table under VIEW FLIGHT
DETAILS tab as can be seen in the preview above.
Page
24
}
private void jButton2ActionPerformed(java.awt.event.ActionEvent evt) {
try {
new mai().setVisible(true);
} catch (SQLException ex) {
Logger.getLogger(MANAGING_SOFTWARE.class.getName()).log(Level.SEVERE, null, ex);
}
dispose();
Page
25
Form Summary:This form represented above receives command from the previous selection
that the user did i.e. selecting the origin and end of the journey. The action
promotes the database to be searched through and thereby displaying all the
flights following the tour. The user can easily select the flight by simply
clicking on the flight suiting him/her.
NOTE:- The above window is just the continuation of the previous form
which are sub-contained in the same form but under different tabs just like
web-browser style.
Page
26
Page
27
Page
29
Page
30
l = l2.getSelectedIndices().length;
if(l>n)
{
JOptionPane.showMessageDialog(this,"PLEASE DONT SELECT EXTRA SEATS");
}
else if(l<n)
{
JOptionPane.showMessageDialog(this,"PLEASE SELECT MORE SEATS");
}
else{
new class1().setVisible(true);
dispose();
class1.l3.setListData(l2.getSelectedValues());
int s1=0;
for(int j=0;j<=n-1;j++)
{
String i = (String)l3.getModel().getElementAt(j);
String s= i.substring(20);
s1 = Integer.parseInt(s)+s1;
}
int t = Integer.parseInt(jTextField5.getText())*z1;
class1.jTextField3.setText(Integer.toString(t+s1));
class1.jTextField1.setText("FIRST");
class1.jTextField4.setText(AIR_RESERVATION_SYSTEM.name);
class1.jTextField5.setText(AIR_RESERVATION_SYSTEM.mob);
}
}
if(jRadioButton1.isSelected()==false && jRadioButton2.isSelected()==false )
{
JOptionPane.showMessageDialog(this,"SELECT CLASS");
}
}
else
{
JOptionPane.showMessageDialog(this,"PLEASE ENTER NUMBER OF PASSENGERS");
}
Page
31
FORM SUMMARY :This form receives the essential information from the
previous inputs and results and asks for the payment
through the three ways possible shown i.e. VisaCard,
Paypal, MasterCard.
Note:The image might look tilted in the figure above. It is just because of effects used
while editing .
Page
32
Page
33
Form Summary :This form finally shows the details essential for reservation
and after the user have confirmed these he/she presses
reserve which stores the flight record in the database that
Can be tracked later using the UNIQUE CODE provided.
Page
34
Page
35
The user enter his/her unique number and gets the flight
record displayed accordingly.
Page
36
Page
37
Page
38
FORM SUMMARY:This form can easily modify the flight schedule with the
help of buttons INSERT, DELETE which can add as well as
delete a particular desired row from the database.
Page
39
}
private void jButton2ActionPerformed(java.awt.event.ActionEvent evt) {
try {
rs2 =st1.executeQuery("Select * from flights");
} catch (SQLException ex) {
Logger.getLogger(addschedule.class.getName()).log(Level.SEVERE, null, ex);
}
jTable1.setModel(DbUtils.resultSetToTableModel(rs2));
}
private void jButton3ActionPerformed(java.awt.event.ActionEvent evt) {
int row = jTable1.getSelectedRow();
if(row>=0)
{
try {
rs3 =st1.executeQuery("select * from flights LIMIT 1 OFFSET "+row+" ");
while(rs3.next())
{
String s = rs3.getString("FN");
String query = " delete from flights where FN = '"+s+"' ";
Page
40
st2.executeUpdate(query);
}}
catch(Exception e ){}
}
If you observe the preview image and the above and below
one you will observe that the row with primary key 101 has
been removed and with 1001 has been added. Such is
obtained by the action of delete and insert button.
Page
41
Page
42