Chen Chew Choong F
Chen Chew Choong F
EShipping Management
By
ACADEMIC YEAR
2012/2013
EShipping Management
EShipping Management
By
2012/2013
ii
EShipping Management Declaration
Declaration
The project submitted herewith is a result of my own efforts in totality and in every
aspect of the project works. All information that has been obtained from other
sources had been fully acknowledged. I understand that any plagiarism, cheating or
collusion or any sorts constitutes a breach of College rules and regulations and would
be subjected to disciplinary actions.
__________________________
iii
EShipping Management Abstract
Abstract
The main purpose of carving this project is a fulfillment of requirement for Bachelor
of Science. In the mean while, it also provided me a chance to learn on develop a
complete system with a complete processes. So I would like to take this as a challenge
to develop a logistics website system called EShipping Management. This system is
developed to sell the logistics services on web.
The system include front end and back end modules. Front end modules are
responsible on handle customer transaction such as making order, make payment and
etc. While for the back end module, it is responsible on maintenance and
administrator part in the system. EShipping Management contains 7 modules to
operate the business. Those modules are Authentication Access, Member Information
Maintenance, Booking, Payment, Data Maintenance, Report and Backend module. All
of this module can help the system to function smoothly and completely to meet the
business rules and business requirement.
For the methodology part, this project was implemented by using Microsoft Visual
Studio 2010 in .NET framework. The system is developed in Object Oriented
Approach. This Object Oriented Approach provides us a easy way to understand and
maintain the system.
For the development process, this project was using the System Development Life-
Cycle (SDLC) to implement the entire system. This SDLC include 5 phrases, there
are system planning, system analysis, system design, system testing and system
implementation phrase.
For the entire system it considered a very complete system as it meet all the function
which should have to include in the system. The strength in this system, such as we
have included Paypal Sandbox in the system, this brings lot of convenience to
customer on the payment part. Besides that EShipping system reduce lots of workload
of admin staff, like example, shipment scheduling and warehouse rental management.
As a conclusion, after implement this system, I had learnt lots of knowledge such as
the programming skill, familiar with C# language and SQL and get more familiar in
the logistics business flow.
iv
EShipping Management Acknowledgement
Acknowledgement
The author wishes to express his sincere gratitude to project supervisor, Ms.
YeohKarPeng, for his guidance, constant support and encouragement
throughout the completion of this final year project. The author would also
like to convey his heartfelt appreciation to Mr. Chong for contributing his
ideas and in-depth knowledge in mathematic field.
Last, but not least, the author wishes to acknowledge the unwavering support
shown by Ms. YeohKarPeng, and other Computer Division lecturers,
Mathematics Division lecturer Mr. Chong.
v
EShipping Management Table Content
Table of Contents
Declaration ................................................................................................................... iii
Abstract ......................................................................................................................... iv
Acknowledgement ......................................................................................................... v
1. System Planning ..................................................................................................... 2
1.1 Project Aims and Objectives ........................................................................... 3
1.2 Company Background ..................................................................................... 4
1.3 Project Scope ................................................................................................... 5
1.4 Project Scheduling......................................................................................... 10
1.5 Outline of approach/Methodology Used ....................................................... 11
1.6 Development Environment and Operational Environment ........................... 12
2. Requirements Analysis ......................................................................................... 14
2.1 Fact Finding................................................................................................... 14
2.2 System Requirement Specification ............................................................... 15
3. System Design ...................................................................................................... 24
3.1 Class Diagram ............................................................................................... 24
3.2 Activity Diagram ........................................................................................... 25
3.3 Use Case Diagram ......................................................................................... 46
3.4 Use Case Description .................................................................................... 50
3.5 Sequence Diagram......................................................................................... 60
3.6 Collaboration Diagram .................................................................................. 70
3.7 Entity Relationship Diagram (ERD) ............................................................. 74
3.8 User Interface ................................................................................................ 75
4. Programming ........................................................................................................ 90
4.1 Programming Approach ................................................................................ 90
4.2 Programming tools ........................................................................................ 92
4.3 Programming Demonstration ........................................................................ 93
5. Software Testing ................................................................................................. 108
5.1 Selected Testing Methods ........................................................................... 108
5.2 Testing Results ............................................................................................ 109
6. Conclusion .......................................................................................................... 114
6.1 Development Tools, Techniques and Technology used.............................. 114
vi
EShipping Management Table Content
vii
EShipping Management Chapter 1: System Planning
Chapter 1
System Planning
1
EShipping Management Chapter 1: System Planning
1. System Planning
Introduction
2
EShipping Management Chapter 1: System Planning
3
EShipping Management Chapter 1: System Planning
Besides that, lots of logistic companies their customer is just focus from some
small company, area and etc. This system is also allowing helping them to
enlarge their business because this system is run in the web site. In order to
focus some company, there is also possible to focus customer from others area.
With this system aid, they also can improve their customer services that take
orders in the web site and process all the orders. Comparing with the manual
system, this system will be faster to handle and accept all the orders, because
manual system just using paper work and phone call to handle and accept
orders but this computerized system is using online order transaction.
Our E-Shipping management system can be used by all logistics company. But
currently, we are focusing on Malaysia’s area.
Target User
1. Staff of E-Shipping
Admin staff can use the system for handle the shipment scheduling,
warehouse rental management. Manager can use this system to
view the many types of the reports created by the system, for
example sales analysis report and shipment delay report.
4
EShipping Management Chapter 1: System Planning
5
EShipping Management Chapter 1: System Planning
Functional Requirements
1. Authentication Access
a. Member login:
‐ The member login to the system to modify the information and
make booking transaction.
b. Admin login
‐ The admin staff can login to the system to view the report,
maintain the data and view shipment scheduling and warehouse
rental management.
c. Add Admin
‐ The high level admin staff can add the new admin staff to the
system. When add the new admin staff, the high level admin
staff need to key in the information of the new admin staff.
d. Forget Password
‐ When staff admin or members forget their password, system
will use this function to help them reset their password.
e. Change Password
‐ Manage the member or staff admin to change their password
f. Password Encryption
‐ All the user’s password will be encrypt before storing into
database
6
EShipping Management Chapter 1: System Planning
7
EShipping Management Chapter 1: System Planning
3. Payment
a. Display Invoice
‐ This function allows members to view the summarize of the
booking details and total payment in details for the transaction
that he/she had been made, such as the service type (door to
door delivery/moving house/warehouse rental), discount price,
shipment distance price, rack price and etc.
b. Make Payment
‐ When the transaction was successfully made, member can
make payment by using their credit card.
c. Send Order Confirmation
‐ When the payment was successfully made, the system will send
the order confirmation message to member’s email.
4. Shipment Scheduling (Backend Subsystem)
a. List Unprocessed Shipment
‐ This function allows admin staff to view the previous date of
all unprocessed shipment transaction. Thus assign all those
unprocessed shipment transaction to driver by click on the
allocate task to driver button and the system will assign
automatically.
b. Assign Task
‐ This function allows admin staff to assign the unprocessed
shipment to the available driver and store the information into
system database call task table.
c. List Today Task
‐ This function allows admin staff to view all today task list, and
allow admin staff to update the task if the task is completed or
done by the driver.
8
EShipping Management Chapter 1: System Planning
5. Report
a. Report Generator
‐ Sales Analysis Report
‐ The purpose of having this report is to let the highest
level admin staff to make decision whether to give
promotion to the particular customer by analysis his/her
total amount of transaction made from certain date to
certain date.
‐ Shipment Delay Report
‐ The purpose of having this report is to let the highest
level admin staff to take any appropriate action for the
particular driver if the particular driver keeps delay
finish the task that had been assigned by the system.
‐ Shipment Rate Analysis Report
‐ The purpose of having this report is to let the highest
level admin staff to take any action whether to increase
or decrease the shipment distance price. For example, if
the particular state having highest order of shipment
then the distance price should be decrease and attract
more customers to order the shipment transaction from
EShipping.
9
EShipping Management Chapter 1: System Planning
10
EShipping Management Chapter 1: System Planning
Besides that, all the system design will draw the UML diagram, which
includes class diagram, activity diagram, use case diagram, sequence diagram
and also collaboration diagram to design the flow of the system.
While for the coding part, C# programming language will be the main
language used to develop this EShipping Management System. HTML, Java
Script, JQuery, CSS code will be responsible for the design part.
11
EShipping Management Chapter 1: System Planning
Operational Environment
12
EShipping Management Chapter 2: Requirements Analysis
Chapter 2
Requirements Analysis
13
EShipping Management Chapter 2: Requirements Analysis
2. Requirements Analysis
This phrase is to find out the requirement should be include in the system
before implementation. Developer can find out the information by research,
interview, questionnaire, observation or others fact finding tools to gather
information before go to the implementation phrase. In short, in this phrase
will help developer implements the system to meet the requirement smoothly.
14
EShipping Management Chapter 2: Requirements Analysis
EShipping Management is a logistics web site that uses another way to doing
the business transaction by taking down the shipment or warehouse rental
services order by customer via internet. Thus, it enlarger their business scope
from local area to whole area of Malaysia. The website was selling the
cheapest shipment and warehouse rental services to customer over the internet
and which to encourage the customer to do more business with EShipping by
providing the reward point features. This reward point when reach certain
point it will convert as a discount price to the customer compare to the real life
ordering of logistics services in market it does not consist of this features. In
order to enjoy this reward point features, customer must register as a member
of EShipping and make order from EShipping to collect points.
15
EShipping Management Chapter 2: Requirements Analysis
In last, EShipping Management System able to generate the useful report to let
the highest level admin staff to make decision in future such as sales analysis
report, shipment delay report and etc.
16
EShipping Management Chapter 2: Requirements Analysis
17
EShipping Management Chapter 2: Requirements Analysis
General Constraint
1. Time frame
All the part of the website must be complete within the time frame
that has set it System Planning Stage. Any delay will affect the
project time frame and at the end the system cannot develop within
the period.
2. Development cost
This development cost is depending of the complexity of the
system, because more complexity it take more time to develop and
high cost occur. However, this system must be implementing
within the budget that provide by the company. The development
cost includes labor cost, and purchase software license and etc.
3. Operation Cost
This operation cost has to make it as low as affordable by company,
as the operation cost mainly is the web server cost, because in
order to hosting this system on web, it need its own web server.
Others than this, the operation cost also include the maintenance
cost, which maintenance able to make the system run more
smoothly from time to time.
4. Platform
This system is platform independently, as it does not relying on any
platform either Linux based OS or Window based OS. As long as
the user’s OS platform support for the web browser and this system
able to run perfectly.
5. Testing
Before this system to be go life, it must proceed to the testing
phrase as to fix all the bugs and error. Testing is to make sure in
future there is no any error or any problem for the system.
6. Training
After the system has completely implemented, we need to provide
a user guideline and also training for all the users. This training
might take 1 or 2 weeks in order to get familiar used for this system.
18
EShipping Management Chapter 2: Requirements Analysis
User Interface
1. Resolution
The standard resolution is 1200 × 800
2. Window layout
In this system, every window is in consistency design with the
same header, menu and footer.
3. Message
A response message will always prompt out to the user. The
messages may be error message, warning message or confirm
message.
4. Print
All scheduling and report and printable, by click on the print button
5. Report Design
All reports are creating in consistent look with the same header and
also footer.
Hardware Interface
1. Monitor screen
The system user interface will display the information to the user
through monitor screen, and provide communication between the
user and the system.
2. Mouse
It is an input device that allows all the users input from drop down
list, check box by using this pointing device.
3. Keyboard
It is an input device that allows the users used to interact with the
system by using the keystrokes on the keyboard. All the input data
will communicate with the system database.
4. Printer
It is an output device that uses to print out the entire document
required such as report and shipment schedule.
19
EShipping Management Chapter 2: Requirements Analysis
Software Interface
1. Operating System
This system does not relying in any OS. As long as the OS support
the web browsers the system can run perfectly.
2. Software
The main software which is the web browsers for supporting this
system, user may use Internet Explorer, Mozilla Firefox, Opera ,
Chrome and etc.
3. Database
This system operating with the SQL Server to store all the related
data into database. All the data in this database must be up to date
from time to time to make sure the system information is accurate.
20
EShipping Management Chapter 2: Requirements Analysis
Non-functional requirement
1. Product requirement
a. Reliability
The system need to be high reliable which to make sure the
overall failure rate is low. Thus, during the testing phrase,
developer must test properly for every single section.
System must able to prompt meaning error message to users
about the error.
b. Portability
The system must portable enough as it can run in any
platform. In short EShipping must be run in any where any
time with the available of internet network.
c. Usability
The system must have consistency in user interface design.
This is to make sure it is user friendly enough. System must
able to communicate with the user by prompt out
meaningful message.
d. Efficiency
The system response time must be fast, every time users
request, it must able to response within few second. Others
than that, EShipping also must able to capture input
correctly by users and fast to pass back it to the server to
process it.
2. Organizational requirement
a. Implementation
EShipping should implement in object oriented approach.
All the components of EShipping must able to reuse to help
to save jobs on the development. Thus, EShipping must be
implementing in C# programming.
b. Delivery
All the stage of development EShipping must be deliver
before end of year 2012. Each stage must be fully complete
within the time given before proceed to the next stage.
21
EShipping Management Chapter 2: Requirements Analysis
3. External requirement
a. Ethical
The system must be design according to admin person
requirement. The design must be in proper way that can be
accepted by either admin person or customer.
b. Legislative
Every development stages have to complete in a proper way
that within the scope of law in Malaysia. Besides that,
EShipping must operate in the way which fit in the laws
and regulations of Cyber Law and Malaysia Law.
22
EShipping Management Chapter 3: System Design
Chapter 3
System Design
23
EShipping Management Chapter 3: System Design
3. System Design
24
EShipping Management Chapter 3: System Design
25
EShipping Management Chapter 3: System Design
b) Admin Login
26
EShipping Management Chapter 3: System Design
c) Add Admin
27
EShipping Management Chapter 3: System Design
d) Forget Password
28
EShipping Management Chapter 3: System Design
1) Reset Password
29
EShipping Management Chapter 3: System Design
e) Change Password
30
EShipping Management Chapter 3: System Design
a) Member Registration
31
EShipping Management Chapter 3: System Design
1) Member Activation
32
EShipping Management Chapter 3: System Design
33
EShipping Management Chapter 3: System Design
34
EShipping Management Chapter 3: System Design
35
EShipping Management Chapter 3: System Design
36
EShipping Management Chapter 3: System Design
3. Payment
a) Display Invoice
37
EShipping Management Chapter 3: System Design
38
EShipping Management Chapter 3: System Design
b) Make Payment
39
EShipping Management Chapter 3: System Design
40
EShipping Management Chapter 3: System Design
41
EShipping Management Chapter 3: System Design
42
EShipping Management Chapter 3: System Design
b) Assign Task
43
EShipping Management Chapter 3: System Design
44
EShipping Management Chapter 3: System Design
5. Report
a) Report Generator
45
EShipping Management Chapter 3: System Design
46
EShipping Management Chapter 3: System Design
2. Authentication Access
47
EShipping Management Chapter 3: System Design
4. Payment
5. Shipment Scheduling
48
EShipping Management Chapter 3: System Design
6. Report
49
EShipping Management Chapter 3: System Design
Brief Description: The use case allows registered members to login to the
system
Actor: Customers
Main Flow:
3. Enter the correct login id and 4. Match the details with the
password. Click “Login” database, and log users into the
system.
Alternate Flow:
A1. Step 3 – if login id and password, or either one is not filled in, the
following steps will not be preceded.
A2. Step 4 – if the login id and password do not match with the database, the
user will be prompted with error message, and need to enter login id and
password again.
Post Condition:
50
EShipping Management Chapter 3: System Design
Brief Description: The use case allows admin staff to login to the system
Actor: administrators
Main Flow:
3. Enter the correct login id and 4. Match the details with the
password. Click “Login” database, and log users into the
system.
Alternate Flow:
A1. Step 3 – if login id and password, or either one is not filled in, the
following steps will not be preceded.
A2. Step 4 – if the login id and password do not match with the database, the
user will be prompted with error message, and need to enter login id and
password again.
Post Condition:
51
EShipping Management Chapter 3: System Design
Brief Description: The use case allows the administrator to add new
administrator into the system.
Actor: Administrator
Main Flow:
1. User goes to ‘Add Admin’ page 2. Display the add admin page with
form to be filled in.
3. Fill in the form with correct 4. Store the information into the
information database.
Alternate Flow:
A1. Step 3 – if the information entered is invalid or not correct, users will be
prompted error message.
Post Condition:
52
EShipping Management Chapter 3: System Design
Brief Description: The use case allows the members and administrator to
reset their forgotten password.
Main Flow:
Alternate Flow:
A1. Step 3 – if the login id is not filled, the following steps will not be
preceded.
Post Condition:
53
EShipping Management Chapter 3: System Design
Brief Description: The use case allows the customers to register themselves
as member of the EShipping website.
Actor: Customers
Main Flow:
3. Fill in the form with correct 4. Store the information into the
information, Click “Submit” database
6. Receive email
Alternate Flow:
Post Condition:
54
EShipping Management Chapter 3: System Design
Brief Description: The use case allows the member to edit their personal
details.
Actor: Customers
Main Flow:
3. Click “Update” and edit the 4. Store the information into the
personal details. database
Post Condition:
55
EShipping Management Chapter 3: System Design
3. Payment
Brief Description: The use case allows the member to make payment.
Actor: Customers
Main Flow:
1. User goes to the make payment 2. Display the make payment page
page.
3. Fill in the form with correct 4. Store the information into the
information, Click “Pay” database
Alternate Flow:
A1. Step 3 – if the information entered is invalid, users will be prompted with
error message.
Post Condition:
56
EShipping Management Chapter 3: System Design
4. Shipment Scheduling
Brief Description: The use case allows the administrator to view previous day
booked shipment list by customer.
Actor: Administrator
Main Flow:
Alternate Flow:
A1. Step 3 – if shipment payment status is unpaid discard the shipment and
loop the next shipment.
57
EShipping Management Chapter 3: System Design
Brief Description: The use case allows the administrator to assign task to
driver.
Actor: Administrator
Main Flow:
Alternate Flow:
A2. Step 5 – if the users click cancel, it will redirect to the admin main page
58
EShipping Management Chapter 3: System Design
Brief Description: The use case allows the administrator to view today task
list.
Actor: Administrator
Main Flow:
Alternate Flow:
A1. Step 5 – if the users click cancel, it will redirect to the admin main page
59
EShipping Management Chapter 3: System Design
a. Member Login
60
EShipping Management Chapter 3: System Design
b. Admin Login
61
EShipping Management Chapter 3: System Design
c. Add Admin
62
EShipping Management Chapter 3: System Design
d. Forget Password
63
EShipping Management Chapter 3: System Design
e. Change Password
64
EShipping Management Chapter 3: System Design
2. Payment
a. Display Invoice
65
EShipping Management Chapter 3: System Design
b. Make Payment
66
EShipping Management Chapter 3: System Design
3. Shipment Scheduling
67
EShipping Management Chapter 3: System Design
b. Assign Task
68
EShipping Management Chapter 3: System Design
69
EShipping Management Chapter 3: System Design
a. Member Registration
70
EShipping Management Chapter 3: System Design
71
EShipping Management Chapter 3: System Design
72
EShipping Management Chapter 3: System Design
2. Report
a. Report Generator
73
EShipping Management Chapter 3: System Design
74
EShipping Management Chapter 3: System Design
a. Member Login
b. Admin Login
75
EShipping Management Chapter 3: System Design
c. Add Admin
d. Forget Password
76
EShipping Management Chapter 3: System Design
1) Reset Password
e. Change Password
77
EShipping Management Chapter 3: System Design
a. Member Registration
1) Member Activation
78
EShipping Management Chapter 3: System Design
79
EShipping Management Chapter 3: System Design
80
EShipping Management Chapter 3: System Design
3. Payment
a. Display Invoice
81
EShipping Management Chapter 3: System Design
b. Make Payment
82
EShipping Management Chapter 3: System Design
4. Shipment Scheduling
83
EShipping Management Chapter 3: System Design
84
EShipping Management Chapter 3: System Design
5. Report
a. Report Generator
85
EShipping Management Chapter 3: System Design
86
EShipping Management Chapter 3: System Design
87
EShipping Management Chapter 3: System Design
88
EShipping Management Chapter 4: Programming
Chapter 4
Programming
89
EShipping Management Chapter 4: Programming
4. Programming
This programming chapter is discussing about the programming part in the
project. The issues are included the proposed programming approach,
development programming tools, and demonstration of the code used in the
project
For the visual portion (the ASPX file) contain the static HTML markup, and
also the declarative server control markup. Whereas for the code behind (the
ASPX.CS file) it contains the user interface logic for the page, it contains all
the logic code and event handlers.
Web Forms are the heart and soul of ASP.NET which it are the User Interface
(UI) elements that make the Web application look and feel nice. Besides that
Web Forms are similar to Windows Forms in that they provide properties,
methods, and events for the controls that are placed onto them. However, these
UI elements render themselves in the appropriate markup language required
by the request.
The purpose of web forms and ASP.NET were created is to overcome some of
the limitation of ASP.
90
EShipping Management Chapter 4: Programming
2. A rich set of server-side controls that can detect the browser and
send out appropriate markup language such as HTML
3. Less code to write due to the data binding capabilities of the new
server-side .NET controls, the example for data binding in
EShipping Management are ShipmentSchedule.aspx
91
EShipping Management Chapter 4: Programming
Visual Studio 2010 also supports the web service architecture. This feature
brings advantages for implementing Paypal in EShipping Management system
as Paypal is to enable customer to make payment via online.
92
EShipping Management Chapter 4: Programming
1. <%@PageTitle="ES
Express:Login"Language="C#"MasterPageFile="MainSite2.Master"AutoEventWireup="
true"CodeBehind="Login.aspx.cs"Inherits="EShipping.Login"%>
2. <asp:ContentID="Content1"ContentPlaceHolderID="ContentPlaceHolder1"runat="ser
ver">
3. <divalign="center">
4. <tablewidth="950">
5. <thead>
6. <tr>
7. <tdcolspan="4">
8. <imgsrc="Pictures/logistics-banner (1).png"width="950"/>
9. </td>
10. </tr>
11. <tr>
12. <tdcolspan="4">
13. <divstyle="background-color: #6699FF; text-align: left;"><strongstyle="color:
#FFFF00">Login</strong></div>
14. </td>
15. </tr>
16. </thead>
17. <tbody>
18. <tr>
19. <tdwidth="180"class="style2"style="text-align: left">
20. User ID
21. </td>
22. <tdclass="style2"style="text-align: left">
23. :
24. </td>
25. <tdclass="style2"style="width: 72px; text-align: left;">
26. <asp:TextBoxID="TextBoxLD"runat="server"MaxLength="15"Width="180px"
27. ToolTip="Enter Your User ID to Login"></asp:TextBox>
28. </td>
29. <tdclass="style2"style="text-align: left">
30. <asp:RequiredFieldValidatorID="RequiredFieldValidator1"runat="server"
31. ControlToValidate="TextBoxLD"ErrorMessage="Please Enter User ID"
32. ForeColor="Red"style="font-size: xx-small; text-align:
left"></asp:RequiredFieldValidator>
33. <br/>
34. </td>
35. </tr>
36. <tr>
37. <tdcolspan="4"class="style2"style="text-align: left"></td>
38. </tr>
39. <tr>
40. <tdclass="style2"style="text-align: left">
41. Password
42. </td>
43. <tdclass="style2"style="text-align: left">
44. :
93
EShipping Management Chapter 4: Programming
45. </td>
46. <tdclass="style2"style="width: 72px; text-align: left;">
47. <asp:TextBoxID="TextBoxPass"runat="server"Width="180px"TextMode="Password"
48. ToolTip="Enter Your Password"MaxLength="8"></asp:TextBox>
49. </td>
50. <tdclass="style2"style="text-align: left">
51.
52. <asp:RequiredFieldValidatorID="RequiredFieldValidator2"runat="server"
53. ControlToValidate="TextBoxPass"ErrorMessage="Please Enter Password"
54. ForeColor="Red"style="font-size: xx-small"></asp:RequiredFieldValidator>
55.
56. <br/>
57. </td>
58. </tr>
59.
60. <tr>
61. <tdcolspan="4"class="style2"style="text-align: left"></td>
62. </tr>
63. <tr>
64. <tdcolspan="4"class="style2"style="text-align: left">
65. <asp:ButtonID="ButtonLogin"runat="server"Text="Login"onclick="ButtonLogin_Cli
ck"
66. Width="100px"/>
67. </td>
68. </tr>
69. <tr>
70. <tdcolspan="3"></td>
71. <tdcolspan="1"style="text-align: right">
72. <asp:HyperLinkID="HyperLink2"runat="server"
73. NavigateUrl="~/ForgetPassword.aspx"style="font-size: small">Forget
Password</asp:HyperLink>
74. <asp:HyperLinkID="HyperLink1"runat="server"
75. NavigateUrl="~/Registration.aspx"style="font-size: small">New User Register
Here</asp:HyperLink></td>
76. </tr>
77. </tbody>
78. </table>
79. </div>
80. </asp:Content>
Overall we can see that, this ASPX file contain static HTML markup, like
example from line 4 to line 78 it start by <table> tag and close tag </table> as
know as we drag the table form into the web forms. Besides that, all the control
contains runat=”server” and it know as server-side control in ASP.NET. Based
on the above code, at the line 1, it specifies its own code behind which is
“Login.aspx.cs”. This code behind contain the user interface logic for the page,
it contain all the logic code and event handlers, like example at the line 65, the
server-side control button, “ButtonLogin” which are calling the event handler
and the event function name “ButtonLogin_Click”. This event handler will
implement in the “Login.aspx.cs” file.
94
EShipping Management Chapter 4: Programming
1. using System;
2. usingSystem.Collections.Generic;
3. usingSystem.Linq;
4. usingSystem.Web;
5. usingSystem.Web.UI;
6. usingSystem.Web.UI.WebControls;
7. usingSystem.Data.SqlClient;
8. usingSystem.Configuration;
9.
10. namespaceEShipping
11. {
12. publicpartialclassLogin : System.Web.UI.Page
13. {
14. protectedvoidPage_Load(object sender, EventArgs e){}
15.
16. protectedvoidButtonLogin_Click(object sender, EventArgs e)
17. {
18. SqlConnection con =
newSqlConnection(ConfigurationManager.ConnectionStrings["ESExpressConnectionS
tring"].ConnectionString);
19. con.Open();
20. stringstrCheckUser = "Select Count(*) From Login Where LoginID =
'"+TextBoxLD.Text+"'";
21. SqlCommandcmdCheckUser = newSqlCommand(strCheckUser, con);
22. int temp = Convert.ToInt32(cmdCheckUser.ExecuteScalar().ToString());
23. if (temp == 1)
24. {
25. stringstrCheckUserAC = "Select activated From Login Where LoginID = '" +
TextBoxLD.Text + "'";
26. SqlCommandcmdCheckUserAC = newSqlCommand(strCheckUserAC, con);
27. stringactivatedStatus = cmdCheckUserAC.ExecuteScalar().ToString();
28. con.Close();
29. if (activatedStatus.Equals("true"))//account already activated
30. {
31. con.Open();
32. stringstrCheckPass = "Select Password From Login Where LoginID = '" +
TextBoxLD.Text + "'";
33. SqlCommandcmdCheckPass = newSqlCommand(strCheckPass, con);
34. stringuserPass = cmdCheckPass.ExecuteScalar().ToString();
35. con.Close();
36. if (userPass.Equals(Encryption.encryption(TextBoxPass.Text)))
37. {
38. con.Open();
39. stringstrSelectRole = "Select Role From Login Where LoginID='" +
TextBoxLD.Text + "'";
40. SqlCommandcmdSelectRole = newSqlCommand(strSelectRole, con);
41. string role = cmdSelectRole.ExecuteScalar().ToString();
42. con.Close();
43. Session["User"] = TextBoxLD.Text;
44. Session["role"] = role;
45. Response.Redirect("MyES.aspx");
46. }
47. else
95
EShipping Management Chapter 4: Programming
48. {
49. Response.Write("<script>window.alert('Invalid Password')</script>");
50. }
51. }
52. else
53. {
54. Response.Write("<script>window.alert('Please activate your account before
login to ES Express')</script>");
55. Server.Transfer("RegistrationActivation.aspx");
56. }
57. }
58. else
59. {
60. Response.Write("<script>window.alert('Invalid Login ID')</script>");
61. }
62.
63. }
64. }
65. }
Based on the above code, at the line 16, it implements the event function
“ButtonLogin_Click” that is calling in the front end of member login page,
“Login.aspx”. When member enter the loginID and password and click for the
login button and the server will trigger this event by get the loginID and
password from the “Login.aspx”, if the loginID is exist in the EShipping
database and account of the member is activated and the password is valid, then
the server will redirect the member to member main page , “MyES.aspx”. All
those checking are implementing and handling in this ASPX.CS file as we can
see and read it clearly on the above demonstration code.
96
EShipping Management Chapter 4: Programming
97
EShipping Management Chapter 4: Programming
98
EShipping Management Chapter 4: Programming
Based on the above code, it is the cs file of password encryption, from the
beginning, it will get the password from the parameter passing by the user, and I
use for loop do the encryption process, every time I will get 1 character from the
particular password and I convert the character into integer, after that I adding
the key which in here the key is 8 and minus 20, after finished this process I
convert back it to character and concatenate it to string name enPassword and
finish the looping then will return the enPassword to user, this enPassword as
know as cipher text.
99
EShipping Management Chapter 4: Programming
1. publicstaticstringgenerateActivateCode()
2. {
3. string x = "1234567890abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ";
4. Randomrandom = newRandom();
5. string code = "";
6. while (code.Length != 6)
7. {
8. int a = random.Next(0, 61);
9. code += x.Substring(a, 1);
10. }
11. return code;
12. }
Based on the above code, it is the cs file of generateActivateCode for member
during registration time, this instruction use Math.Random to generate the
random index between 0 and 61 (Because index of “string x” start from 0 and
end at 61), each time get the random index and will concatenate it in the “string
code” and form a random activation code with the length of 6.
100
EShipping Management Chapter 4: Programming
5. Code of Paypal
a. Constant
1. using System;
2. usingSystem.Collections.Generic;
3. usingSystem.Linq;
4. usingSystem.Web;
5.
6. namespaceEShipping.PayPal
7. {
8. publicclassConstants
9. {
10. publicconststring ENVIRONMENT = "sandbox";
11. publicconststring PAYPAL_URL = "https://www.sandbox.paypal.com";
12. publicconststring ECURLLOGIN = "https://developer.paypal.com";
13. publicconststring SUBJECT = "";
14.
15. publicconststring PROFILE_KEY = "Profile";
16. publicconststring PAYMENT_ACTION_PARAM = "paymentAction";
17. publicconststring PAYMENT_TYPE_PARAM = "paymentType";
18.
19. publicconststring STANDARD_EMAIL_ADDRESS =
"eshipp_1350739744_biz@hotmail.com";
20.
21. publicconststring WEBSCR_URL = PAYPAL_URL + "/cgi-bin/webscr";
22.
23. //sandbox 3t credentials
24. publicconststring PRIVATE_KEY_PASSWORD = "";
25.
26. publicconststring API_USERNAME = "eshipp_1350739744_biz_api1.hotmail.com";
27. publicconststring API_PASSWORD = "1350739785";
28. publicconststring API_SIGNATURE = "An5ns1Kso7MWUdW4ErQKJJJ4qi4-
AI.WehZTrssXxDqBSO3uOSXdccK9";
29. publicconststring CERTIFICATE = "";
30.
31. publicconststring OAUTH_SIGNATURE = "";
32. publicconststring OAUTH_TOKEN = "";
33. publicconststring OAUTH_TIMESTAMP = "";
34.
35. }
36. }
Based on the code above, it demonstrate to calling the web services of paypal,
this constant is to set all the attribute that will need to call in the set profile to set
up the paypal API account, and enable customer to make payment to EShipping
through this payment gateway.
101
EShipping Management Chapter 4: Programming
b. Set Profile
1. using System;
2. usingSystem.Collections.Generic;
3. usingSystem.Linq;
4. usingSystem.Web;
5. usingcom.paypal.sdk.util;
6. usingcom.paypal.sdk.profiles;
7.
8. namespaceEShipping.PayPal
9. {
10. publicclassSetProfile
11. {
12. publicstaticIAPIProfileCreateAPIProfile(stringapiUsername, stringapiPassword,
string signature, stringCertificateFile_Cer, stringPrivateKeyPassword_Cer,
String stage, string subject, stringoauth_Signature, stringoauth_Token,
stringoauth_Timestamp)
13. {
14. IAPIProfile profile = ProfileFactory.createSignatureAPIProfile();
15. profile.APIUsername = apiUsername;
16. profile.APIPassword = apiPassword;
17. profile.Environment = stage;
18. profile.Subject = subject;
19. profile.APISignature = signature;
20. return profile;
21. }
22. }
23. }
Based on this code, it demonstrate how to set up the paypal profile
c. Util
1. usingSystem.Web;
2. usingcom.paypal.sdk.util;
3.
4. namespaceEShipping.PayPal
5. {
6. publicclassUtil
7. {
8. publicstaticstringBuildResponse(object response, string header1, string
header2)
9. {
10. if (response != null)
11. {
12. NVPCodec decoder = newNVPCodec();
13. decoder = (NVPCodec)response;
14. string res = "<center>";
15.
16. if (header1 != null)
17. res = res + "<font size=2 color=black face=Verdana><b>" +
header1 + "</b></font>";
18.
19. res = res + "<br>";
20. res = res + "<br>";
102
EShipping Management Chapter 4: Programming
21.
22. if (header2 != null)
23. res = res + "<b>" + header2 + "</b><br>";
24.
25. res = res + "<br>";
26. res = res + "<table width=400>";
27.
28. for (int i = 0; i <decoder.Keys.Count; i++)
29. {
30. res = res + "<tr><td> " + decoder.Keys[i].ToString() +
":</td>";
31. res = res + "<td>" + decoder.GetValues(i)[0] + "</td>";
32. res = res + "</tr>";
33. res = res + "<tr>";
34. }
35. res = res + "</table>";
36. res = res + "</center>";
37. return res;
38. }
39. else
40. {
41. return"Requested action not allowed";
42. }
43. }
44. }
45. }
Based on this code, it demonstrates the paypal how to encode and decode the
payment security information by customer and send through over the internet.
103
EShipping Management Chapter 4: Programming
104
EShipping Management Chapter 4: Programming
105
EShipping Management Chapter 4: Programming
106
EShipping Management Chapter 5: Software Testing
Chapter 5
Software Testing
107
EShipping Management Chapter 5: Software Testing
5. Software Testing
This software testing chapter is to evaluate the system compliance with its
specified requirements. Besides that, software testing is to find out the
reliability, completeness, security, and quality of the system by go through the
process of finding bugs and defects of the system.
1. Unit Testing
Unit Testing refers to the procedure used to validate the individual units
of source code are working properly. The goal of unit testing is to
separate each part of the program and show that the individual parts are
correct. In short, testing on individual part of the system from one to
another will be easier way to integrate the function to become the whole
system.
2. Integration Testing
108
EShipping Management Chapter 5: Software Testing
2. Check Login ID Availability System will check the login id enter Pass
by user during register time and
display error message if the login id
exist in the system.
3. Check password and confirm After system prompt user to enter Pass
password are match password, system will prompt user
to reenter the same password again
and will validate whether both
password are match if not display
the error message to user.
5. Click on the Submit button System will do the validation for Pass
the input format for the data entered
(Member Registration)
by user. If the input format correct
then system will save the
information into database, generate
activation code, send activation
code to user’s email, else display
the error message to user
109
EShipping Management Chapter 5: Software Testing
8. Click on resend activate code Create a new activate code and Pass
send to member’s email address
(Resend Activation Code)
10. Click on Edit Profile System will display the member Pass
personal details and allow the
member to edit their personal
details
11. Click on Update button on System will do the validation for Pass
(Edit Member Information) the input format for the data entered
by the user, if input is invalid,
display error message, else update
member information into database
110
EShipping Management Chapter 5: Software Testing
2. Payment Transaction
5. Give discount price System will get the reward point Pass
from member during payment
(Display Invoice)
time, and allow the point to
calculate discount rate.
7. Check Credit Card System will validate the card type, Pass
card number and card verification
number, certain card type got
certain length of card verification
number, example American
Express card verification number
length is 4 digit whereas Master
Card, Visa, Discover is 3 digit
111
EShipping Management Chapter 5: Software Testing
10. Update Reward Point System will update the member’s Pass
reward point by after the payment
(Make Payment)
is successful
112
EShipping Management Chapter 6: Conclusion
Chapter 6
Conclusion
113
EShipping Management Chapter 6: Conclusion
6. Conclusion
For the programming language part, I have using C# language as the main
language to develop the system. C# programming language is to use to
develop the server side function.
114
EShipping Management Chapter 6: Conclusion
1000
5
Where,
DR = Discount Rate
DP = Discount Price
Each time the member wishes to make transaction with EShipping, the system
will use this formula to calculate the Discount Rate and Discount Price and
use this Discount Price on the Total Payment, thus member able to enjoy the
discount moment during transaction.
115
EShipping Management Chapter 6: Conclusion
This project also provides the better management for the staff to manage the
business transaction and reduce lots of paper work, such as shipment
scheduling and warehouse rank management is computerize by the system but
not manually by staff. Besides that, the system also able to generate some
useful report as the staff or top management able to view the sales analysis
report easily. Thus, the company can saves up the cost to hired large amount
of staff to operate for the business.
116
EShipping Management Chapter 6: Conclusion
We faced some difficulties in determining our project scope as the scope large
is wide and we cannot deciding which scope falls on which modules. But after
doing some research on the internet and research some logistics company
standard and seeking for opinion from project supervisor, finally we managed
to solve this problem.
While during the system coding part, I faced a lot of problems in the payment
gateway, because in order to make this project go life, it must able to receive
payment from customer. But after doing some research and extra reading on
the Paypal, I manage to call the Do Direct Payment API and managed to solve
this problem.
117
EShipping Management Chapter 6: Conclusion
Furthermore, for the payment part it is not very convenience to the customer,
because the payment gateway just accept the credit card, in order to make it
flexible, the system can be enhance by allow customer to make payment
through online bank-in, thus this function will bring advantages to the
customer that does not hold any credit card.
Besides that, this system is not flexible enough as it lots of redundancy code or
instruction and turn the performance of system become slow. The system can
be enhance by change the technique from ASP.NET Web Forms to three-tier
architecture, as this architecture can develop the system more systematic way
and increase the performance time and easy to maintain as it separate to three
layer, presentation, business logic, data access layer. Others than that, it also
allow the code reusable as all the redundancy code or instruction put it in the
same layer which is business logic layer.
118
EShipping Management Chapter 6: Conclusion
119
EShipping Management Chapter 6: Conclusion
Last but not least, I had learnt about the importance of teamwork. In
developing this system, my partner and I always helped each other out when
we faced any problem. When we encountered bugs during the running of the
system, we will research together and solve out the problem.
120
EShipping Management Chapter 7: Appendices
7. Appendices
Example of famous logistics websites visited (site visits)
DHL (http://www.dhl.com.my/en.html )
121
EShipping Management Chapter 7: Appendices
122
EShipping Management Chapter 8: User Guide
8. User Guide
1. Member
a. Member Registration
2
3
1. Enter Login ID
- The login id must not use by others members
2. Enter Password
- The password will use as login password
- The length of password must non-black space between 6 or 8
character
5. Click the Submit button will check login id availability, password and
retype password must match, and validate the email and thus register
as member
123
EShipping Management Chapter 8: User Guide
i. Member Activation
1
2
3
4
1. Enter Login ID
- The login id must exists in system
3. Click the Activate button will check the exists of login id and correct
of activation code that match with the system and thus if all is valid
then system will activate the member account
124
EShipping Management Chapter 8: User Guide
1
1. Enter Login ID
- The login id must exists in system
2. Click on the Submit button system will generate another new activation
code and send to the member’s email
125
EShipping Management Chapter 8: User Guide
b. Member Login
3
1. Enter User ID
- The user id must exists in system
2. Enter Password
- The password must correct by compare with the password store in the
system
3. Click on the login button system will validate the input, if it is valid then
redirect to the member main page
126
EShipping Management Chapter 8: User Guide
2. Click the Update Profile button after finish edit personal information, if
input format invalid, system will display error message
127
EShipping Management Chapter 8: User Guide
d. Display invoice
1 2
1. Click the Make Payment button system will redirect to the make payment
page
2. Click the Cancel button system will cancel the transaction had been made
and redirect to the member main page
128
EShipping Management Chapter 8: User Guide
e. Make Payment
4 5
5. Click on the submit button, system will valid the input field, if correct will
send the money from member’s credit card into EShipping’sPaypal
account.
129
EShipping Management Chapter 8: User Guide
2. Admin
a. Admin Login
1. Enter User ID
- The user id must exists in system
2. Enter Password
- The password must correct by compare with the password store in the
system
3. Click on the login button system will validate the input, if it is valid then
redirect to the admin main page
130
EShipping Management Chapter 8: User Guide
b. Add Admin
2 3
1. Enter User ID
- Check user id availability in the system
2. Select Role
- Role can be admin or super admin
3. Click on the add button and the system will validate the input field, if it is
valid then system will generate the default password to the particular staff
and add the staff into system.
131
EShipping Management Chapter 8: User Guide
c. Shipment Scheduling
i. List Unprocessed Shipment
132
EShipping Management Chapter 8: User Guide
1 2
1. Click on the View Today Task button, system will redirect to the List
Today Task Page.
2. Click on the Print button, system will display the print wizard for print out
this task list.
133
EShipping Management Chapter 8: User Guide
1. Tick the Task Send Checked Box if the particular task is sends and
complete.
2. Click the Update button, system will update the entire tick task’s status
from pending into completed.
134