Академический Документы
Профессиональный Документы
Культура Документы
By
Angriawan Ikhromy
001200900009
A Thesis
Submitted to the Faculty of Computing
President University
In Partial Fulfillment of the Requirements
For the Degree of Bachelor of Science
In Information Technology
VALLEY FIRST
By:
Angriawan Ikhromy
Approved:
_________________________________ _________________________________
Rikip Ginanjar, M. Sc Nur Hadisukmana, M.Sc
Thesis Advisor Program Head of Information Technology
_________________________________
Rila Mandala, Ph.D
Dean of Faculty of Computing
Declaration of Originality
I hereby certify that I am the sole author of this thesis and that no part of this
I certify that, to the best of my knowledge, my thesis does not infringe upon
anyones copyright nor violate any proprietary rights and that any ideas, techniques,
quotations, or any other material from the work of other people included in my thesis,
referencing practices.
I declare that this is a true copy of my thesis, including any final revisions, as
approved by my thesis committee, and that this thesis has not been submitted for a
(Angriawan Ikhromy)
ABSTRACT
difficult to meet due to specific reasons. Such miscalculations are: unstable market
complete the previously stated needs. In other words, some people do not have the
capabilities to manage their finances, which in fact can be solved, if their purchase
a daily basis. The uniqueness of this program is accessible to everyone, anywhere and
anytime via the internet. Not only managing the income statement, but it is also
designed to get the prices from the database and calculate the result, assisting the users
(Expenses > Income), the system calculates the data and generates the first result as a
real value based on users input. The second value will be generated as a suggestion
i
DEDICATION
constant source of inspiration and always giving the support to finish this thesis on time.
They have given me the motivation and discipline to tackle any task with enthusiasm
and determination. Without their love and support this project would not have been
made possible.
ii
ACKNOWLEDGEMENT
First of all, thanks to Allah SWT for His Mercy, Whose blessing gives me the
Apart from the efforts from me, the success of my project depends largely on
the encouragement and guidelines of many people. I take this opportunity to express
my gratitude to the people who have been instrumental in the successful completion of
Suheriyanto, MSi, for their support, courage, spirit and love. I can't say thank
you enough for their tremendous support and help. I feel motivated and
encouraged every time I go back to home and do this thesis at there. Without
his encouragement and guidance this project would not have materialized.
2. My Thesis Advisor, Mr. Rikip Ginanjar, for his support, patience, and guidance
3. All of my friends the Computing Family batch 2009, the guidance and support
who are contributing to this project, was vital for the success of the project. I
Angriawan Ikhromy
iii
TABLE OF CONTENTS
ABSTRACT .................................................................................................................... i
DEDICATION ...............................................................................................................ii
ACKNOWLEDGEMENT ........................................................................................... iii
TABLE OF CONTENTS .............................................................................................. iv
LIST OF TABLE .........................................................................................................vii
LIST OF FIGURES ................................................................................................... viii
CHAPTER I INTRODUCTION .................................................................................... 1
1.1 Background& Motivation ...............................................................................1
iv
2.8.2 Managing your expenses........................................................................18
v
CHAPTER V SYSTEM DEVELOPMENT ................................................................ 67
5.1 Code & Implementation ................................................................................67
vi
LIST OF TABLE
TABLE Page
Table 3.1 Use Case Narrative - Send Email ................................................................ 24
Table 3.2: Use Case Narrative for Register Account ................................................... 25
Table 3.3: Use Case Narrative for Login ..................................................................... 26
Table 3.4: Use Case Narrative for Budgetting Proccess .............................................. 27
Table 3.5 Use Case Narrative for View Admin Unlock User ID ................................ 28
Table 3.6 Use Case Narrative for View Admin Unblock User ID .............................. 29
Table 3.7 Use Case Narrative for View Admin Block User ID................................... 30
Table 4.1 Table ACCOUNT ........................................................................................ 51
Table 4.2 Table CAR ................................................................................................... 51
Table 4.3 Table ELECTRICITY.................................................................................. 52
Table 4.4 Table ELECTRICITY_TYPE...................................................................... 52
Table 4.5 Table FUEL ................................................................................................. 52
Table 4.6 Table MOTORCYCLE ................................................................................ 53
Table 4.7 Table SCHOOL ........................................................................................... 53
Table 4.8 Table RULE ................................................................................................. 53
Table 4.9 List of Model Class with All Methods and Description .............................. 59
Table 6.1 Testing Scenario Positive Test.................................................................. 97
Table 6.2 Testing Scenario Negative Test .............................................................. 102
vii
LIST OF FIGURES
FIGURE Page
Figure 1.1: Comparison of Traditional and RAD Methodology.................................... 4
Figure 2.1: Struts Framework ...................................................................................... 11
Figure 2.2: Forward Chaingin Tree ............................................................................. 16
Figure 2.3: Q&A Interface ........................................................................................... 16
Figure 3.1: System Overview ...................................................................................... 21
Figure 3.2 Use-case Diagram ....................................................................................... 23
Figure 3.3 Activity Diagram - User Regiter Page........................................................ 32
Figure 3.4 Activity Diagram - Send Email .................................................................. 33
Figure 3.5 Activity Diagram - Login as User or Admin .............................................. 34
Figure 3.6 Activity Diagram for Budgetting Proccess................................................. 35
Figure 3.7 Activity Diagram for Admin Authority - UnLock ID ................................ 36
Figure 3.8 Activity Diagram for Admin Authority - UnBlock ID ............................... 37
Figure 3.9 Activity Diagram for Admin Authority - Block ID.................................... 38
Figure 4.1 Login Page Interface................................................................................... 42
Figure 4.2 Register Page Interface ............................................................................... 43
Figure 4.3 Main Page Interface .................................................................................... 45
Figure 4.4 Main Menu Interface .................................................................................. 45
Figure 4.5 Email Menu Feature Interface .................................................................... 46
Figure 4.6 Database Design ......................................................................................... 55
Figure 4.7 Class Diagram ............................................................................................ 56
Figure 4.8 Class Controller Part I ................................................................................ 57
Figure 4.9 Class Controller Part II ............................................................................... 58
Figure 5.1: HTML Wrap Project - Controller Structure .............................................. 68
Figure 5.2: Online Expert Money Manager Project - Controller Structure ................. 69
Figure 5.3: Online Expert Money Manager Project - View Structure ......................... 70
Figure 5.4: Online Expert Money Manager Project - View Structure ......................... 71
Figure 5.5 Register Page .............................................................................................. 72
Figure 5.6 Register Page Email Validation............................................................... 73
Figure 5.7 Register Page Email Validation Java Script Code .................................. 74
Figure 5.8 Register Page Saving Account to Database Code ................................... 75
viii
Figure 5.9 Login Page .................................................................................................. 76
Figure 5.10 Login Page Login Action Code ............................................................. 77
Figure 5.11 Admin Page .............................................................................................. 78
Figure 5.12 Admin Page - Block User ID Error Message ........................................... 79
Figure 5.13 Admin Page - UnBlock User ID ............................................................... 80
Figure 5.14 Admin Page - UnLock User ID ................................................................ 81
Figure 5.15 Admin Page - Block User ID.................................................................... 82
Figure 5.16 Main Menu Page....................................................................................... 83
Figure 5.17 Main Menu Scrapping Data................................................................... 84
Figure 5.18 Main Menu Calculate the Data .............................................................. 85
Figure 5.19 Main Menu Deduct Quantity ................................................................. 86
Figure 5.20 Main Menu Do While Logic Code ........................................................ 86
Figure 5.21 Main Menu Inside Do While Logic Code ............................................ 88
Figure 5.22 Main Menu Inquiry the Data ................................................................. 89
Figure 5.23 Main Menu Hibernate Utils ................................................................... 89
Figure 5.24 Result Page ............................................................................................... 90
Figure 5.25 Email Area ................................................................................................ 91
Figure 5.26 Email Area ................................................................................................ 92
Figure 5.27 Struts Configuration ................................................................................. 93
ix
CHAPTER I
INTRODUCTION
There are two kinds of people in respect of the way they manage their financial
condition. The first is people who balance their income and expenses by means of
keeping a detailed purchase history. Meanwhile, some other people oversee their
financial condition by carefully analyzing their record of financial spending, and match
the compiled data with their monthly expense to determine their purchasing capability.
Nothing is bad or good from these two behaviors - each has their own advantages and
disadvantages. The best method is what suits you. The most important aspect of the two
described behaviors is how people can manage their finances so that everything can be
fulfilled accordingly.
1
2
purchases which in turn, damages the overall financial condition. Normally, expenses
should be recorded so that the income earned from work is sufficient to fulfill needs by
to balance the expense with the income. Proper spending of the money they earned to
be more beneficial, is necessary to manage the familys financial condition and helps
Online Expert Money Manager by Valley First, wealth management should not be a
huge obstacle. Moreover, the system will be able to generate a recommended value
based on specific criteria to be set as a benchmark if the first recommended value is less
than 10%.
People can access this application through the internet. This application includes
features that are lightweight and easy to understand such as sending an email.
3
The objective of this thesis is to provide users with the information and
knowledge they need to support decisions and to understand the financial implications
of decisions before they are made. It also enables users to monitor their decisions for
any potential financial implications and for lessons to be learned from experience, and
The thesis focuses in developing two types of wealth manager, designated for
software will develop another type of money manager, for instance company salary.
The application will give the information about the type, and the description of
the item in the global market. Because of the time limit of the thesis project, it will give
only specific data, such as the car type, motorcycle type, fuel type, school fee, etc.
Therefore, this application will not display all types of goods in the global market.
The application can only receive input from either keyboard or mouse and then
it will show the field that the user have to fill in the mandatory field and optional field,
and the system will take care of the rest. This system will calculate the data from the
user input and it will show the message that your income is enough for your needs or
not.
will be based on Java Language and implementing Data Access Object (DAO), Spring,
Struts, and also Hibernate. Since this application is accessible via internet (for now,
localhost) it will also utilize Java Server Page (JSP) to generate HTML which is already
1.5 Methodology
information and knowledge of the Hibernate, Spring Framework, and JavaEE (Java
engineering.
Development), thus prototypes of the system will be produced converging to the final
working system. In this way, even in a short time-range in system analysis it will result
another prototype until it reaches the final working system matching the thesis
objective.
Many prototypes covering one or more features of the ideal working system will
system, they are actually converging to a point: a complete working system. In short,
the system analysis and system design will have many prototypes converging to final
outline.
about Hibernate, Spring Framework, which is used for achieving the thesis
objectives.
requirements.
coding of the system. This part will be described relatively to each prototype
6. CHAPTER VI SYSTEM TESTING is the part that evaluates and tests the
system in order to encounter any limitation of the system. The system testing
will cover mostly final working system and some prototypes that are critical
conclusion obtained from the thesis, testing results, and possible future
works.
CHAPTER II
LITERATURE STUDY
make a decision - a choice from the available alternatives. Most decisions are made in
analyzes business data and presents it so that users can make business decisions more
easily [1].
demandingness, we can find common principles and tools for making better decisions.
Any manager can use the following techniques to overcome the barriers to effective
decision making:
Increase knowledge. A lack of experience with the problem at hand can cause
6
7
experience.
Dont overstress the finality of the decision. Very few decisions are forever;
Make sure the timing is right. Managers should not let their decisions be swayed
by passing moods.
There are several benefits by using DSS which is; improves personal efficiency,
used platform for programming in the Java language. It is the Java Platform used to
deploy portable applications for general use. In practical terms, Java SE consists of
a virtual machine, which must be used to run Java programs, together with a set
of libraries (or "packages") needed to allow the use of file systems, networks, graphical
includes all of the classes in Java SE, plus a number which are more useful to programs
enterprise Java computing platform. The platform provides an API and runtime
including network and web services, and other large-scale, multi-tiered, scalable,
reliable, and secure network applications. Java EE extends the Java Platform,
distributed and multi-tier architectures, and web services [3]. The platform
server. Software for Java EE is primarily developed in the Java programming language
Hibernate is free software that is distributed under the GNU Lesser General
Public License. Hibernates primary feature is mapping from Java classes to database
tables (and from Java data types to SQL data types). Hibernate also provides data query
and retrieval facilities. It also generates the SQL calls and attempts to relieve the
developer from manual result set handling and object conversion and keep the
application portable to all supported SQL databases with little performance overhead.
configuration of an XML file or by using Java Annotations. When using an XML file,
Hibernate can generate skeletal source code for the persistence classes. This is
unnecessary when annotations are used. Hibernate can use the XML file or the
can also manage reflexive associations where an object has a one-to-many relationship
Hibernate supports the mapping of custom value types. This makes the following
scenarios possible:
Overriding the default SQL type that Hibernate chooses when mapping a column
to a property.
Hibernate provides transparent persistence for Plain Old Java Objects (POJOs).
The only strict requirement for a persistent class is a no-argument constructor, not
10
necessarily public. Proper behavior in some applications also requires special attention
Collections of data objects are typically stored in Java collection objects such as
Set and List. Java generics, introduced in Java 5, are supported. Hibernate can be
Hibernate 3. Related objects can be configured to cascade operations from one to the
other. For example, a parent such as an Album object can be configured to cascade its
save and/or delete operation to its child Track objects. This can reduce development
time and ensure referential integrity. A dirty checking feature avoids unnecessary
database write actions by performing SQL updates only on the modified fields of
persistent objects.
Language (HQL) which allows SQL-like queries to be written against Hibernates data
Open source
file, struts-config.xml
The Struts Framework, itself, only fills in the View and Controller layers. The Model
All incoming requests are intercepted by the Struts servlet controller. The Struts
controller receives the request, looks up the mapping for this request, and forward it to
an action. The action turn calls a Model layer (Business layer) service or function.
12
After the call to and underlying function or service returns to the action class,
the action forwards to a resource in the View layer and a page is displayed in a web
browser.
The Controller
This receives all incoming requests. Its primary function is the mapping of a
request URI to an action class selecting the proper application module. It's provided by
the framework.
This file contains all of the routing and configuration information for the Struts
application. This XML file needs to be in the WEB-INF directory of the application.
Action Classes
It's the developer's responsibility to create these classes. They act as bridges
between user-invoked URIs and business services. Actions process a request and return
an ActionForward object that identifies the next component to invoke. They're part of
Action Forms
These greatly simplify user form validation by capturing user data from the
HTTP request. They act as a "firewall" between forms (Web pages) and the application
(actions). These components allow the validation of user input before proceeding to an
An expert system is a computer program that can simulate the judgment and
specific field in order to help problem solving or decision-making process [7]. The
system contains a knowledge base that consists of accumulated experience and a set of
rules for applying the knowledge base to each particular situation that is described in
the program. So, the reason why this system is called expert system is caused by the
similarities of its function and role with the human consultant that allows their user or
In general use, the system is intended to help common people to solve their
problem from the simple until the complex problems without even the direct help from
In addition, the expert system can also become the assistant for the human expertise
when doing their daily task. However, there are some factors that need to be fulfilled to
5. Knowledge restructure
Based on the main purpose, an expert system can be categorized into ten
different types:
Diagnose; diagnose the caused or the reason why a system fails in a complex
situation based on the symptom occurs.
Planning; organize a way that should be done in order to achieve a goal from
certain starting points.
Eye Disease Diagnose is a kind of expert system application that can diagnose
eye disease. The application will help common people to know what type of eye disease
that they had by checking the symptoms. The knowledge base is constructed from the
medical literature book and eye specialist doctor, and it will be constructed on the set
of IF-THEN rule.
The inference machine uses the forward chaining method that will associate the
facts with the existing rule and generate a conclusion from the facts. In this application,
the knowledge base is also constructed as a tree form where the left part of the tree
shows the symptom of the eye diseases while the right part of the tree is the list of the
disease. As shown in Figure 2.2, the entire existing symptom will be grouped into set
of rules based on the same goals. The existing rules on the knowledge base will be
asked to the user and continue after taking the answer response from the user. After
comes into a solution, the system will generate a conclusion that state what kind of Eye
Disease that the user had. Here is the interface of Question and Answer section as shown
in Figure 2.3.
16
Columbia, Canada. Founded in Penticton in 1947 as the Penticton and District Credit
Union, Valley First was established in 1983 following a period of expansion through
the Okanagan and Similkameen valleys. Valley First continued its growth into the
Kelowna market throughout the 1990s, before amalgamating with the Armstrong
Spallumcheen Savings and Credit Union and buying the KCP Credit Union in
Kamloops in 2001. In 2008, Valley First entered into discussions with Langley-
based Envision Financial to merge with one another and develop a new financial
services organization for Western Canada. In September 2009, members at both credit
unions voted in favour of the merger proposal, and on Jan. 1, 2010, Envision Financial
and Valley First merged to become First West Credit Union. In 2013, Enderby &
District Credit Union joined First West Credit Union, followed by Island Savings Credit
Key person of this Industry Financial Services is Paulette Rennie, she has more
than 30 years of financial industry experience. She started her career with Toronto
Dominion Bank where, over a 15-year period, she held various positions throughout
British Columbia.
This Industry Financial Services has financial management advice that can be a
method for this application, such as Managing your income, Managing your
When budgeting, make sure youre working with your net income figure (the
amount you take home after taxes) versus your gross income. Know your income
cycleif youre a seasonal employee, this will impact your cash flow throughout the
year and youll need to budget accordingly. Create a balance sheet which outlines all
your assets (savings/investments/things you own) and all your liabilities (debts). That
way, youll have a good idea what your current financial situation isthis is a great
starting point.
After determining how much money you or your household is bringing in each
week, it is essential to identify where it is going. By making a list of all your expenses,
you can get a good idea of what you are spending your money on. Record fixed
expenses which are typically the same each month, such as rent or mortgage, car
Reduce the totals of some of your variable expense categories, rather than
Consider commuting and share a gas bill, or use public transportation systems.
CHAPTER III
SYSTEM ANALYSIS
The display will be handled by Struts and Spring algorithm model, utilizing the
JSP which already supported by Java. Web page wont use HTML or PHP directly, but
will use JavaScript (JS) instead as a web controller, supported also by generic Java
codes.
The main workflow is simple. First, user have to open browser and go to the
Online Expert Money Manager by Valley First Website. The user will see interface that
consist of field at the web. Next, they will see the interface that consists of several fields
The user are free to fill out all of that field according to his/her needs. User has
to know that every field that is filled will show another field in next page with relation
to the field before. I will make this software as specifically as I can do.
After the user has finished filling in all of the text box, automatically this
program will calculate the total money that the user will spend later in that month
according user input before. The main algorithm of this software is to manipulate the
19
20
so it will stay updated, wont be missing, and is available to inquiry at all time. Another
main point is how to coordinate many components of Java language, which is Java
code, JSP, JS, Database, Spring framework, Struts, Hibernate, and DAO.
In order to achieve its main objective, the system must be able to cover the
1. The expert systems should be able to give brief explanations related to its
4. Users can see the detail and type of the goods that is generated by the expert
system.
5. Users should be able to fill all of the text field based on the user needs.
6. The web apps should provide two main interfaces for the user section and
7. User can type the input in the web forms such as text field, checkbox, radio
the system:
3. Netbeans or Eclipse IDE (with Java SDK and JRE version at least 1_5_0_17)
6. Internet browser
Figure 3.1 System Overview. The system overview diagram can help to identify
the flow of this system web application. As shown in figure 3.1, the system has to
perform data processing based on user input. After the data has been retrieved by the
22
system, it will send the data and querying into database, then the database give the result
based on queried data, and then the system will calculate again to give the last result.
case diagram descriptions will show the system behavioral upon interactions in the use-
case narratives.
the system. In here, more views of the system will be shown, starting from the structure
until the behavior. In addition, there will be use case diagram, use case narrative, and
activity diagram shown in this section. A Use Case is a series of related interactions
between a user (more generally an actor) and a system that enables the users to
achieve a goal [6]. Use Case Diagram is a view of the system boundaries that identifies
the use case, which defined to support the solution. The Use Case diagram shows which
actors and admin interact with each use case, as defined in Figure 3.2 Use Case
Diagrams.
The Administrator has a special authority than the user. The Administrator has
authority levels UnLock ID, UnBlock ID, and Block ID, which have granted in the
Admin Page. User cant access the Admin Page because the type of ID, the programmer
has already classified when the user create an account, the type of the account will be
automatically become the user ID. The Main Page only can be access by logging first
and using ID that already registered in Register Page, but Send Email Page can be
features that come as the solution. This are made to define the core elements and
processes of the system and it explains about the whole system from user point of view.
The key elements are termed as actors and the processes are termed as use cases. The
Use Case diagram shows which actors interact with each use case, as defined in Figure
In order to describe the use-case diagram shown in Figure 3.2, the following
Priority: Medium
Primary Business
User
Actor:
Primary System
Application
Actor:
Other Participating
-
Actors:
Descriptions: This use case describes the user wants to send a message to the Admin
Trigger:
Conclusion: This use case shows the User send Email to the Admin
Post Condition:
Business Rules: None
Implementation
Constraints and None
Specifications:
25
Priority: High
UserRegister Use Case
Source:
Model Diagram
Primary Business
User
Actor:
Primary System Actor: System
Other Participating
-
Actors:
Descriptions: This use case describes the user want to register a new account.
Trigger:
Actor Action System Response
Step 1: User open Step 2: The system will shows the login
application. form.
Step 3: User click Step 4: The system will shows the
register new account Register Page.
Typical Course of
Events: Step 5: User input all of Step 6: The system validate the data from
the textfield the user input
Step 7: The system will store into
database the user detail
Conclusion: This use case shows the user/Admin how to login the application.
Login will be success if the data is correct and valid, the system will
Business Rules:
check the data to database, and redirect into Application.
Implementation
Constraints and None
Specifications:
27
Step 1:User select the menu Step 2: The system will redirect the
"Salary Management" user into salary management page
Step 3: The system will update the
database by scrapping from website
Typical Course of
Events: Step 4: The User input all of
Step 5: The system will validate the
the mandatory field and click
data and calculate it.
"Calculate my Budget"
Step 6: The system will check the
condition, if Expenses > Income, the
system will calculate for suggestion
result.
Step 7: The system will show the
result page.
Alternate Courses: None
This use case shows the steps of how a user calculate their monthly
Conclusion:
salary.
Post Condition: None
Business Rules: Calculation will be success if the user follow the rule of each field.
Implementation
Constraints and None
Specifications:
28
Table 3.5 Use Case Narrative for View Admin Unlock User ID
This use case describes the admin wants to do unlock the ID that
Descriptions:
already registered in database
Trigger:
Actor Action System Response
Step 1: Admin go to login page Step 2: The system will display all
and login as admin of the admin authority
Conclusion: This use case shows the Admin authority in this application.
Business Rules: The result status will depend of the Admin authority type and the input.
Implementation
Constraints and None
Specifications:
29
Table 3.6 Use Case Narrative for View Admin Unblock User ID
This use case describes the admin wants to do unblock the ID that
Descriptions:
already registered in database
Trigger:
Actor Action System Response
Step 1: Admin go to login page Step 2: The system will display all
and login as admin of the admin authority
Step 4: Admin click the Step 5: The system will execute the
unblock button. admin order.
Business Rules: The result status will depend of the Admin authority type and the input.
Implementation
Constraints and None
Specifications:
30
Table 3.7 Use Case Narrative for View Admin Block User ID
Trigger:
Actor Action System Response
Step 1: Admin go to login page Step 2: The system will display all
and login as admin of the admin authority
Step 4: Admin click the block Step 5: The system will execute the
button. admin order.
Conclusion: This use case shows the Admin authority in this application.
Business Rules: The result status will depend of the Admin authority type and the input.
Implementation
Constraints and None
Specifications:
31
activities and actions with support for choice, iteration, and concurrency. Activity
diagram is basically a flow chart to represent the flow from one activity to other. The
activity can be described as an operation of the system. So the control flow is drawn
from one operation to another. This flow can be sequential, branched or concurrent.
Activity diagrams deals with all type of flow control by using different elements like
fork, join and others. This diagrams model the actions or behaviors performed by the
The following figures will represent each possible interaction between actor and
system in such a way so that the interaction can be traced in a better significance.
Furthermore, each activity diagram will represent one full interaction in scope of the
system functionality.
Figure 3.3 Activity Diagram User Register, it will be used during the first time
when the user wants to login into the application. Without this process, the user cant
access the main page. In the user register page there will be some required field that
needs to be filled in order to proceed with the process. Each field has its own validation
password field must be same with password field, the format of the email must be
correct, etc. The data that user has provided will be stored into database. Regarding the
password and confirmation password, they will be encrypted by the system first and
then stored into database. From within the database we cant see the real password from
user input.
32
Figure 3.3 Activity Diagram User Register Page is used for create a
new account for this application. When the user clicks the "Create my Account"
button, the system will verify the data, whether username or email is exist on the
database or not. All of the user that is register through this page will have the
Figure 3.4 Activity Diagram - Send Email, it will be used for all user
without do create a new account in the registration page. The programmer create
this menu is used if the user wants to give a suggestion, need help or complaining
about the application. This feature is one of the ways to communicate with the
administrator. The administrator will replay the message to the email address that
and user to access their own page. In general, the administrator or user has to fill
in username and password, but the system will check about the type of ID. If
identified as user, the system will redirect the user into user page. Likewise as in
of the budgetting proccess for user. In this proccess, the user have to input all of
the mandatory field and then the system will validate all of the data. After the user
clicks "Calculate my Budget" button, the system will calculate all of the data based
on user input.
than income, this condition named as "Meet the condition", and another one is
income bigger than expenses, named as "Doesnt meets the condition". When the
36
condition "Doesnt meets the condition", the system only calculate the data one
time, and give the result based on user input in the result page. In other case, when
the condition is "Meets the condition", the system will calculate again the first
result based on user input to make the suggestion result, so there will be two result
Figure 3.7 Activity Diagram Admin Authority - UnLock ID, it will used
for admin to unlock ID that is already registered in the database. Administrator has
to choose the type of the action, which is unlock all ID or unlock by ID.
Figure 3.7 Activity Diagram Admin Authority - UnLock ID, is used for the
admin wants to unLock the user ID that is locked by the system. The User ID that
admin wants to unlock has to registered in the database. The administrator has to
choose the type of the UnLock ID, which is UnLock all ID or UnLock by ID.
the admin to unblock the user ID that is already registered in the database. In
38
general, this proccess is same as the "UnLock ID" proccess, the admin has to
choose the type of the UnBlock ID, which is unblock all ID or unblock by ID.
Figure 3.9 Activity Diagram Admin Authority - Block ID, is used for
the admin wants to block some ID that already registered in the database. This case
will happened because that ID has a problem with the administrator, or with the
SYSTEM DESIGN
This chapter will describe the design phase, which includes the concept design
of the system, start from User Interface Design and Class Diagram. The design of the
system is related with the Chapter 3 which is system analysis. The design is based on
architecture of the system. The difference between this phase and the previous one is
that system analysis emphasizes functional requirement while system design concerns
The design of this expert system is divided into three main steps. Each of these
1. Create account is used for login into the system, this step is the first thing that
3. Login into the system by using Account that already registered in register page.
4. In the main program, the user have to input all mandatory field and the program
39
40
Create account is the basic step for this program, if the user dont have account,
user cant access the main menu of this system. Create account consist of two important
things which is user name and password. User name and password is very important
because both are used for security purpose .if the user have important data in our system
than any person can have steal data from your system.so in that situation the user must
4.1.2 Validations
Almost all field there is validation, in here validation is ensuring that data
inserted into an application satisfies defined formats and other input criteria. The system
4.1.3 Login
In this step, the user have to input the user name and password in the login page.
The system will check the data into database. If the data is valid, the user can access
the main menu page, but if the data is wrong, the system will check the user name, if
the user name is correct but the password is wrong, the system will add login status
become 1, and it will increase by1 if the user doing the same case. In this case, if login
status reach 3, the user name will automatically blocked by the system.
The process is started by taking the answer value that comes from the user after
all of the questions have been answered. After that the system will validate all of the
The next process is the Rule Checking." In this step, every rule will be checked
if there is a premise on this rule with "Yes" or No value. Available text field will
41
show up based on every text field that user input. And then the data will send by the
system and querying to database to get the value for calculating budget process.
Before the result page comes up, the system always check the condition in the
last stage, comparing between income and total expenses, if the total expenses is bigger
than income, so the system will calculating again to reduce the expenses by change the
type of items like fuel type from Pertamax to Premium, or reduce the total of some
variable like utilization of household power electricity rather than eliminating it.
User interface is created to receive input from a user to send some instructions
and information to application and show the output process from the system to the user.
User interface is a way for a system user to interact with the application and hardware.
In order to give the illustration of the being developed expert system; there will
be some illustration layout interface that can be used as the guidance during the
implementation process. All of the pages created will be developed using JSP (Java
Server Page)to generate HTML which already integrated by Java codes.All of the
elements will use struts 2, <s:textbox>, <s:textfield>,and so on. The usage of the
elements can make the interface design become easier because in each of the elements,
there are also some properties that can be set according to the user preference.
The interface design consists of some main parts such as: Register Page that is
used to create account before do login in the login page. Login Page that is used to
access the main menu and there will be two mandatory text field which is username and
password field. Home or Main Page that is used on the first display. The Main Page
that is used to display the general question and get the first answer from the user, and
42
then the system will check the answer by querying into database and it will show the
next question that related with the question before. The Result Page is used to display
the total calculation total of your income, expenses, and the rest of your income.
As shown in Figure 4.1, the interface consists of four different sections. The
first section is the site name. The second section is two text fields, User Name and
Password, this section is the important section, because this two fields is needed for
querying into database to get the information that ID can access the main page or not.
The third section is button submits, the button is used for access to the main
menu and there will be some validation on there. In this button, the system will
differentiate between the user ID and the administrator ID, because it has the different
The other one is feature area. There will be some function and feature at there,
like register is used for create an account before do login and email is used for
Register Page is the important thing in this program, because without this page,
user cant access the main page to do the main section at there.
As shown in Figure 4.2, the interface consists of four different sections. The
first section is title page. There are some text fields in the second section, which is User
Every text field has its own validation, like email, user have to input a valid
email. If the user input invalid format email, it will show alert Invalid email format,
the minimum length of user name is 4 characters, the confirmation password must be
44
same with password field, etc. Gender Selection is used to differentiate what page will
be load in the main page, which is male salary management or female salary
management.
The Main Page section consists of some parts which is welcome text to greet
the users when they are login into the application and some menu below the greetings
When the user click main menu, the system will automatically to get the useful
data from internet to update the data in database by scrapping. So, the user input in the
main menu will be calculated with the actual data right now. There is no data based on
developer opinion. Hopefully the result data can make the user manage their monthly
In the content of menu there will be some question about what will be spend
later, and the system will give the result based on user answer, so the user can know
As shown in Figure 4.4, the main content of the page consists of several text
field which are used user to input the data that they need to calculate. The Main Page
main section consists of some parts: two radio button to be used during the multiple
choice question session. In addition it also used in the question display itself.
Email Page is used for send email to the Admin. If the users have some
suggestion or problem with the program, they can send email by using this feature that
provided by the system at the login page. User can access this page without login first.
As shown in Figure 4.5, the main content of the page consists of several text
fields which are used for give some information to Admin. Your Email is the
47
important text field, because it is the only information where the admin have to replay
the message.
Actually there are 7 tables, which is Account Table, Car Table, Electricity
Table, Electricity Type Table, Fuel Table, Motorcycle Table, and School Table. The
database of this expert system consists of two main sections Account Table and the rest
table is used to keep temporarily data. Every user click the one of the main menu in the
main page, the database will be updated automatically. All of the tables are stored under
SQL Server with "MoneyManager" as the database name. Here is the list of the tables
a) Table Account (ACCOUNT), it is used to store the detail of each user personal data
PASSWORD; store the user password that the input in the register page. The password
will automatically encrypt by the system after the user click Create Account button.
prevent the user input the wrong password in the password text field as they want
before.
YOUR_EMAIL; store the email as the user address. This is the only one admin can
GENDER; store the type of user gender, is used for differentiate what budget will be
IS_LOGIN; store the login status, if the user already login, another user cant login
STATUS; store the user name status, every user do login and put the correct user name
but wrong password, the status will automatically increase (+1), but if user successfully
CREATED_DATE; store the date for admin information when the ID is registered.
TYPE; store the information that type of ID, which Admin or User ID.
b) Table Car (CAR), it is used to store the detail of each car type, fuel consumption inside
CAR_TYPE; as primary key and also store any information about car name.
INSIDE_TOWN; store any information about car fuel consumption inside town.
OUTSIDE_TOWN; store any information about car fuel consumption inside town.
CREATED_DATE; store the date for the information when the database is updated by
the system.
VA; as primary key and also store any information about type of electricity house in
VA (Volt Ampere)
KWH; store any information about type of electricity in KWH (kil watt/hour)
PRICE; store any information about price of electricity bills based on VA.
49
CREATED_DATE; store the date for the information when the database is updated by
the system.
information about the power used by each home application, both the normal watt and
NAME; as primary key and also store any information about the home application
voltage;
NORMAL_WATT; store any information about normal watt of each home application.
STARTUP_WATT; store any information about startup watt of each home application,
but not all of the home application have startup watt, only several application that have
2 type of voltage.
CREATED_DATE; store the date for the information when the database is updated by
the system.
e) Table Fuel (FUEL), it is used to store fuel type and prices of each name.
NAME; as primary key and also store any information about the fuel name in Indonesia.
COMPANY; store any information about company name, because every fuel type has
CREATED_DATE; store the date for the information when the database is updated by
the system.
consumption.
NAME; as primary key and also store any information about motorcycle name.
COMPANY; store any information about company name, because every motorcycle
CREATED_DATE; store the date for the information when the database is updated by
the system.
SCHOOL_NAME; as primary key and also store any information about school name.
SCHOOL_TYPE; store any information about school type like Elementary School,
SCHOOL_FEE_TYPE; .store any information about school fee type like High Class,
Medium Class, or Low Class. In here, the main point that differentiate between Cheap
or Expensive.
CREATED_DATE; store the date for the information when the database is updated by
the system.
h) Table Rule (RULE), it is used to store information about Rule based on fact. This table
QUESTION_NAME; as primary key and also store any information about the question.
VALUE; .store any information about question that will be shown based on premise
.
51
The table structure for the previous eight table description is shown in the Table 4.1,
Table 4.2, Table 4.3, Table 4.4, Table 4.5, Table 4.6, Table 4.7, and Table 4.8.
PASSWORD Varchar(200)
CONFIRMATION_PASSWORD Varchar(200)
YOUR_EMAIL Varchar(100)
GENDER Varchar(10)
STATUS Number(38,0)
CREATED_DATE Date
CREATED_DATE Date
The Table 4.3 used to store electricity type and price information.
KWH Number(38,0)
CREATED_DATE Date
CREATED_DATE Date
The Table 4.5 used to store fuel type and price information.
CREATED_DATE Date
CREATED_DATE Date
The Table 4.7 used to store school name and price information.
CREATED_DATE Date
54
All of the tables are located under the database of MoneyManager that is
created using Microsoft SQL Server 2008 R2. Every table has primary key that
positioning in the first column and created date as the information when the data is
updated by the system. There is no relationship between one table and another table,
because this application only saving data from website when the system do scrapping
action, so the data in database it is the actual data from the website, there is no data that
given by the programmer opinion. When the application wants to get some data, they
just querying from database. Almost all of the data type in every table using varchar
that represent string in the java programming, it can ease the programmer get the data,
in the calculation, the programmer can parse string into another type as they want.
In this section, the database schema of Online Expert Money Manager by Valley
database design of Online Expert Money Manager by Valley First is not complex. There
is no relationship between one table with another table. All the tables in database stand
alone. This kind of database design in possible due to unique characteristic and
Online Expert Money Manager by Valley First Project doesnt need to make
database with relationship. Because the system when do scrapping data from internet,
56
it will automatically save the data into database. So all tables in this database project is
stand alone.
Class diagram presents the applications class overview that will be developed.
The overview is including class name, instance, and its attribute. Figure 4.7 shows the
System
<<import>>
View Controller Model
The class diagram of the Online Expert Money Manager by Valley First is
generated using plugins in the eclipse class diagram. The class diagram shows any field,
property, operations, and also their relationships among classes. Because of there are
more than ten classes in total than the display of the class diagram will be divided into
several parts.
57
Based on Figure 4.7 Class Diagram, class user controller becomes the main
subject from the system, all the activities such as calculate the budget, send email, user
register, login, logout, etc. are done by users and will be recorded to database. The more
The detail explanations of each method are described in Table 4.8. The
explanations include the activity done by the controller, correlation with model or view
class, etc.
59
Table 4.9 List of Model Class with All Methods and Description
administrator
by the system or by
administrator
the ID
salaryManagement( ) page
on user input
method "calculateMale"
one.
droplist, etc
application
page
doSaveDataRegister() requirement
database
64
internet connection.
code
database
database
SYSTEM DEVELOPMENT
Designing. Here the previously designed system will be implemented as form of codes
application is using Eclipse Java EE IDE for Web Developers. The system needs some
external libraries which are Spring and Hibernate to manage the database connection.
Using these libraries could make the development of the application much faster by
providing a rich set of libraries function, as well as a fast and reliable database
connection.
The expert system application will use four main structures, which are Data
Access, Business Object, Business Logic, and Main Code. In Data Access part, the code
will be related to query string, stored procedure, and all other things which are related
67
68
As shown in Figure 4.7, in this Project I only create one package which is for
testing to scrapping data from website, the result will come out from its console.
htmlWrap.java is the important class for developer, because in this class is the first step
when the developer want to scrapping data from a website, the programmer have to
extract the HTML file and find the way to get the useful information from that, if the
code is work on this class, the programmer will copy the code into the main class. The
programmer create this class is for testing what the programmer can get from that
HTML, check the type. The programmer can do trial and error by only run this class
without run the main program. All of the data from scrapping will be store into database.
The project implements the MVC (Model View Controller) structure which
separates the entity model, graphical user interface and the controller of each interface.
Online Expert Money Manager by Valley First project consists of 4 packages, 10 JSP
(Java Server Page) view for the GUI like access_menu.jsp, admin_page.jsp,, and 15
project extends to that class, and this class extends with MoneyManagerActionForm as
For the JSP section, when the programmer start created the file .jsp, they have
to import taglib (uri=/struts-tags). If the programmer didnt import the taglib, they
cant use all the tag in struts 2. Another important thing is the programmer have to set
all the tags like <s:label>, <s:textfield>, <s:submit>, inside <s:form>..</s:form> tags
as shown in figure 5.4, if not, all of value that user already input in the interface will be
User will access the registration page when doing the registration phase.
Register page is a page that is required before the user can do login in the login page.
The users have to Create Account in the Register Page. To access Register Page, the
hyperlink will be provided by the system, exactly below of button login in the login
page. Here is the display of the Register Page as shown in Figure 5.5:
72
As shown in Figure 5.5, this register page consist of some field that user have
to input. Every text field have different validation, like the minimum of username is 5
character, password must be 6 digit or more, confirmation password must be same with
After the user input all mandatory fields, the system will check the validation of
each field. If there is some error such as User Name is already exist, the system will
throw error and return to this page and show error message in the bottom page.
Another important text field is Your Email. This is the only information for
admin to replay the user message if there is update feature/something problem about
the website. So the user has to put the correct email. The Java Script will validate all of
your input, even when the user move from field to field, or click the button Create My
Account.
As shown in Figure 5.6, this validation will show up even the user move from
Your Email text field to the Gender Selection or click the button Create My
Account.
74
function validateThisPage(){
var selectedId = document.getElementById('yourEmailId').value;
// alert(selectedId);
if (!validateEmail(selectedId)) {
alert("Invalid Email Format");
return;
}
}
function validateEmail(email) {
var a = false;
var res = false;
if (typeof(RegExp) == 'function') {
var b = new RegExp('abc');
if(b.test('abc') == true)
a = true;
}
if (a == true) {
reg = new RegExp('^([a-zA-Z0-9\\-\\.\\_]+)' + '(\\@)([a-zA-Z0-9\\-
\\.]+)' + '(\\.)([a-zA-Z]{2,4})$');
res = (reg.test(email));
} else {
res = (email.search('@') >= 1 &&
email.lastIndexOf('.') > email.search('@') &&
email.lastIndexOf('.') >= email.length-5)
}
As shown in Figure 5.7, this is the code for email validation in java script. The
validation will be divided into three parts which is header as the front part, split as
the middle part, and last word as the last part. For example the email is
alphabet, number or combine both of them (a-z or 0-9), the middle part is split, for
example (@), and last part email have to contains dot (.). While the user input the valid
email that never been used by another user, they also have to input the correct format,
if the user violeting the validation, it will pop up alert message Invalid Email as
As shown in Figure 5.8, this is the code for email saving account into database,
before the system save the data into database; it will validated the data like checking
user name and password for minimum and maximum length. After that, the system
querying into database for checking available email, because email is important thing
When the system saved the data into database, it will encrypt the password and
confirmation password. The programmers have to set a large number on the data type
length in the database. Because the password string is encrypted from original content,
Login page is a page that is required before the user can access another page in
the system. This page will store much information that can be used to be analyzing
factors such how many times the user has access the page, and so on. There are two
buttons and two textboxes elements that are used in this page, in the end of the text box
there is a button login to redirect us into main page. Here are the main components of
After the user input user name and password, the system will validate, and
querying to database. And then, if the data is valid, the user can access the menu based
on their gender when they choose gender selection in register page before. But for now
on, the system only show the male salary management page.
77
//check login
List getData = checkData(getId(), session,
Encryption.encrypt(getPassword()));
if(!getData.isEmpty()){
Account queryResult = (Account) getData.get(0);
In this code, login section will differentiate between admin and user. If the result
of query is User, so the system will redirect the user into main page, and set the status
isLogin become Y, it means the username is still login in the system. If there is
another user trying to login by using the same username, they will automatically throw
into login page again, and the system will show up the error message Your ID is still
login. But in other case, if the user put the right user name, but input the wrong
password, the system will automatically set the status in database increase by1. When
the number of status in the database reach three, the system will automatically block
your ID, and it will show the error message Your ID is blocked by Administrator.
78
There is also Admin in this application to maintain the system, when Admin
login in the application, the system will redirect into Admin Area without set the
isLogin and status in the database. Admin ID has different condition between
common user ID, they can't be locked, blocked by something, so the administrator don't
In this admin page, Administrator has some authority to the user like UnBlock
user ID, UnLock User ID, and Block User ID. Administrator have to login as admin in
the login page. The system will automatically redirect admin into this page. Here is the
The Administrator has to choose the type of action by choosing radio button
between action to all user ID or one ID. First step, the system will check the type of
action that administrator chooses, and then the system will validate the data by querying
into database. The user ID that admin wants to UnBlock / UnLock / Block has to
registered in the database, if the user is not registered in database, the system will
automatically show the error message in the bottom of page as shown in Figure 5.12:.
UnBlock User ID: it is used to open the ID that already blocked by the system in the
login page or by the Admin authority. In this part, there are two types of unblock user
ID, which is unblock the user by ID (one ID) or unblock all the user ID. The
administrator has to choose the radio button, which is unblock all or unblock user by
ID. If the admin choose unblock all user ID, the system will automatically querying
into database to set all of the ID with the type is "user" will be unblocked. If the admin
choose unblock user by ID, they have to input the correct ID that already registered into
database. The system will querying into database and check the user ID is exist in
database or not. Here is the Snippet of the code to unblock user ID as shown in Figure
5.12:
80
try{
if("1".equals(getUnblockUser())){
//Open Connection Query
HibernateUtils.getSessionfactory();
Session session =
HibernateUtils.getSessionfactory().getCurrentSession();
session.beginTransaction();
session.getTransaction().commit();
}
//check Data
session.getTransaction().commit();
UnLock User ID: it is used to open the ID that already locked by the system or by the
Admin authority. When the users do login in the login page, and then they forget to
logout, they just closed the browser, this situation make the ID will be locked because
the system still read the user name is still login. In this part, there are two type of unlock
user ID, which is unlock the user by ID or unlock all the user. Here is the Snippet of
//UnLock User
public String unlockUser() throws IOException{
try{
if("1".equals(getUnlockUser())){
//Open Connection Query
HibernateUtils.getSessionfactory();
Session session =
HibernateUtils.getSessionfactory().getCurrentSession
();
session.beginTransaction();
}
session.getTransaction().commit();
}
addActionMessage("Unlock All User is success");
return SUCCESS;
}
Block User ID: it is used to block the ID that Admin want to block, maybe it will
happen because the illegal ID or that ID doing some violation to the application. In this
part, there are two type of block user ID, which is block the user by ID or block all the
82
user instantly. Here is the Snippet of the code to unlock user ID as shown in Figure
5.15:
//Block User
public String blockUser() throws IOException{
try{
if("1".equals(getBlockUser())){
//check Data
List getData = checkData(getBlockID(), session);
if(!getData.isEmpty()){
Account queryResult = (Account) getData.get(0);
queryResult.setStatus(3);
//Update IS_Login
session.update(queryResult);
session.getTransaction().commit();
setGreetings(REGISTER_ID);
addActionMessage("Block User "+getBlockID()+" is success");
return SUCCESS;
}
In this main menu page, when the user click the menu, for example Salary
Management, the system automatically update the database, do scrapping from web to
web that already code by the programmer. Every area like Child Area, Car Area,
each of them has their own website. The system will automatically open the website,
The field will be automatically enabled when the user input the correct data and
match with the validation of each field. The system will automatically validate the user
input in java script, and also enabling another field that related with the user input at
that time.
84
resultSource = openConnectionForDataScrapping(SHELL_PRICE);
//extracting data
if(!resultSource.equals("") ){
shellName = extractShellName(resultSource);
shellPrice = extractShellPrice(resultSource);
for(int i = 0 ; i<shellName.size() ; i++){
saveFuelNameAndPrice(shellName.get(i).toString(),
shellPrice.get(i).toString());
}
}
Figure 5.17 is the first part of ProcessHTMLData, which is to read a file and
determine which part of the file will be processed next. Since the pattern from the source
site is the same, the program can easily recognize which part to take to be processed
later. The part the program will take is the part that contains useful information.
85
After the program take the useful information, the data will be filtered by
removing unused tags retain the needed information from that part, as the shown in
figure 5.17.
if("true".equals(getAcCheckBox())){
//Open Connection Query
HibernateUtils.getSessionfactory();
Session session2 =
HibernateUtils.getSessionfactory().getCurrentSession();
session2.beginTransaction();
if(isFirstTime){
System.out.println(acCalculate);
setAcTextFieldResultCal(nf.format(acCalculate));
}else{
setAcTextFieldResultSuggest(nf.format(acCalculate));
if(acUnit||acHour){
setAcTextFieldResultSuggestFlag("We Reduce your AC
Electricity Bills");
}
Here is the example of calculation in main menu page. The system will get the
user input in store into String. Almost of the value in this program is String, because
it easier the programmer to process the data. If the system want to change the value
type, they just parse it into a new value that they want.
86
//deduct quantity
if(isFirstTime == false){
int [] priorityInt = new int[]{3,2,1};
for (int priority : priorityInt) {
if(priority <= getPriority(getAcPriority())){
int i = Integer.parseInt(getAcTextField());
int j = 1;
int realHour =
Integer.parseInt(getAcTextField2());
int maxHour = 8;
if(realHour>maxHour){
int x = realHour - 1;
setAcTextField2(String.valueOf(x));
acHour = true;
}
if("Low".equals(getAcPriority())){
j = 0;
}
if(i>j){
int x = i - 1;
setAcTextField(String.valueOf(x));
acUnit = true;
break;
}
}
As shown in Figure 5.19, this code is about how to deduct quantity of each
component in this application. When the system calculating all data from user input to
get the result, at the end of calculation, there are code that will check the condition of
do{
...
...
...
}while(saveMoney.compareTo(theRestOfYourBudgetMaleTemp2)>0);
return SUCCESS;
The programmer create the logic that user have to save 10% of their monthly
salary for unpredictable condition, such as sick, buy some goods important, etc. As
shown in Figure 5.19, that picture is about do while logic when the system checks the
condition at the end of calculation. The programmers declare saveMoney as the value
income, so they cant save 10% of their monthly salary, so the system will calculate
again to get suggestion result for the user. The programmers already do some research
about the ideal of power consumption every household appliance, like the ideal of air
conditioner is 8 hour per day, AC can be turn on when someone wants to sleep, user
dont need turn on 24 hours per day, it just increase the expenses in a month. And also
the programmer will reduce based on priority that already provided in the main menu
screen.
There are three types of priority, which is high, medium, and low. Low priority
means that tool is not very important for the user, the system will decrease it first in the
second calculation. Each time the system decrease a quantity of goods, it will calculate
from top of calculation until reach the minimum quantity of that priority. Medium
88
priority means that tools is more important than low priority, the system will decrease
the quantity after the low priority reach the minimum value. High priority means that
tool is very important for the user, so the system will decrease that tool in the last
calculation, when the medium and low priority reaches the minimum value.
if(isFirstTime){
if(getFuelTypeCar2()!=null && !"".equals(getFuelTypeCar2())){
fuelTypeCarString2 = getFuelTypeCar2();
setFuelTypeCar2Result(getFuelTypeCar2());
}else{
setFuelTypeCar2Result("-");
}
}else{
if(getFuelTypeCar2()!=null && !"".equals(getFuelTypeCar2())){
setFuelTypeCar2Suggest(getFuelTypeCar2());
if(fuelCar2){
setFuelTypeCar2SuggestFlag("We change your fuel
type car, before is :"+fuelTypeCarString2);
}
}else{
setFuelTypeCar2Suggest("-");
setFuelTypeCar2SuggestFlag("-");
}
}
As shown in Figure 5.21, this code is differentiating the system when they have
to set the first result and suggestion result. Value of Boolean isFirstTime = true as a
symbol that value must be set for the real result, and when isFirstTime = false as a
session for each transaction. In this class, the code must specifically define what class
that has an annotated variable / class. If the class is not configured here, the class cant
In the result page, the system will display result data after calculation by the
system. The result page will show all fields even the user didnt input any data in the
In this page, is possible to get two result, because when the system calculate all
of the from user input, it will check the rest of user budget, if the rest budget is less than
10% of user total income, so the system will calculate again for the suggestion result,
and try to give the solution to the user what will be reduce in the user expenses in a
month.
91
Figure 5.25 is the process of Sending Email. This page is the one of the way to
communicate with the administrator. This feature is very useful if the user has some
problem, suggestion, or complaining about the application. Admin will receive the
message in the inbox mail, and replay to the Your Email Address as user input before
The user has to input Your Email Address because that field as the
information for Admin, where the admin have to replay the message, so the format of
user email must be in correct format. The user dont need to worry about the validation,
because when the user move from Your Email Address field to another field or when
clicking the Send Email button, there will be email validation on there.
92
//Send Email
public String sendEmailOutside() throws IOException{
try {
String host = "smtp.gmail.com";
String from = "thesisonlinemoneymanager2@gmail.com";
String pass = "cimb1234";
Properties props = System.getProperties();
props.put("mail.smtp.starttls.enable", "true"); // added
this line
props.put("mail.smtp.host", host);
props.put("mail.smtp.user", from);
props.put("mail.smtp.password", pass);
props.put("mail.smtp.port", "587");
props.put("mail.smtp.auth", "true");
String[] to = {"thesisonlinemoneymanager@gmail.com"}; //
added this
framework to build mail and messaging applications. The JavaMail API is available as
an optional package for use with Java SE platform and is also included in the Java EE
platform. The JavaMail 1.4.5 release contains several bug fixes and enhancements.
93
<action name="index">
<result>/index.jsp</result>
</action>
<action name="doLogin"
class="thesis.money.manager.action.LoginAction" method="checkLogin">
<result name="success">/access_menu.jsp</result>
<result name="error">/index.jsp</result>
<result name="input">/index.jsp</result>
<result name="login">/admin_page.jsp</result>
</action>
<action name="doCalculateSalaryManagementMale"
class="thesis.money.manager.action.MoneyManagerAction"
method="calculateMale">
<result
name="success">/salary_management_male_result.jsp</result>
<result
name="error">/salary_management_male.jsp</result>
</action>
<action name="doLogout"
class="thesis.money.manager.action.MoneyManagerAction"
method="logout">
<result name="success">/index.jsp</result>
</action>
<action name="doBackLoginPage"
class="thesis.money.manager.action.RegisterAction"
method="backToLoginPage">
<result name="success">/index.jsp</result>
</action>
<action name="doRegister"
class="thesis.money.manager.action.RegisterAction" method="register">
<result name="success">/register_page.jsp</result>
</action>
<action name="doSavingDataRegister"
class="thesis.money.manager.action.RegisterAction"
method="doSaveDataRegister">
<result name="error">/register_page.jsp</result>
<result name="success">/index.jsp</result>
</action>
Figure 5.27 Struts Configuration
no IDE assistance when creating such files. The important point in this file is the Action
tag. The <action> has several parameters. The tag <action> itself defines the flow of
For example, the tag <action name=doLogin> will be called every time the
.jsp link with struts (example: <s:url action='doLogin'/> will search the action with
After they found the matching action, the controller will pass the flow into the
corresponding action. As depicted above, the action named doLogin have the class
class with particular method specified. The method is also specified in method
parameter. For doLogin action, the method is login. The result is when the user
clicks the link, the system will go to LoginAction.Java and find login() method and run
it.
After the system run the execute() method, the method itself will return a value.
For example, the return value of method execute() is success, then struts will look for
that particular word in the tag <result> with matching name. When found, the system
will continue the flow to the particular .jsp file pointed by the tag result. For this case,
it is access_menu.jsp.
CHAPTER VI
EVALUATION
The objectives of system testing phase are to assess and make sure the
The system testing phase will be accommodated based on several scenarios. In order to
ensure the whole system accomplish the requirements, there are some scopes and
viewed on the Internet Explorer and Google Chrome browser. In addition, the
application should also guarantee that multiple users can access the application in
almost the same time. Therefore, the tests need to refer to systems functional
the system testing requires the latest version of web browsers that support HTML 5
The tests are based on the following hardware and software specifications:
95
96
2. MySQL Database
3. Core i5 Processor
4. 4 GB RAM
The testing scenario aims to demonstrate that the web application meets its
requirements. There are several policies inside the testing scenario such as all functions
accessed through menus will be tested, all functions will be tested with correct and
incorrect input. Then successful tests will show that the web application operates as
The interface evaluation will measure two main points of the application, which
are the cross browser interface and Interactivity level. After the test, it is proven that
the application can be shown in the Google Chrome and Internet Explorer with
compatibility mode.
In general, the whole interface can be said as the user friendly application
because it does not require complex interaction from and to the user. Unfortunately, the
design is not really attractive or maybe should be improved by more pictures or flash
animations.
97
The general evaluation distributed into two types, the positive and the negative
scenario. The positive scenario provides the correct input while the negative scenario
provides the incorrect input. Table 6.1 shows the positive scenarios, and Table 6.2
The negative testing scenario provides the system with the incorrect input. In
order to determines whether the application does what it is supposed to do based on its
Module
Scenario Expected Result
Name
Login - Leave username field System shows error message,
blank. User Name & Password is
- Leave password field mandatory
blank.
- Clicked on login
button.
Login - Filled in correct Three expected results:
username field System shows error message,
- Filled in incorrect Password is Mandatory
password field If the username is correct, the
- Clicked on login system will increase the status
button. by1.
If the username status reach
three, the system shows error
message, Your ID is already
blocked by Administrator,
Please contact us to get some
information by email at
romy10010001@yahoo.com
Login - Filled in correct If the username is locked
username field (because of the user didnt do
103
CONCLUSION
7.2 Conclusion
Developing Online Expert Money Manager by Valley First application can help
people to manage their own monthly salary. This thesis proves that it is possible to
create software needed by many people through simple approach. The application itself
is built as a web application under struts 2 Framework. It provides managers with the
understand the financial implications of decisions before they are made. It also enables
managers to monitor their decisions for any potential financial implications and for
At the end of this application, it will show final result based on user input and
combine with the data from internet, so the programmer hopefully the final result of
this application can satisfying the user even not 100% accurate, because each website
has its own opinion about household appliance, but still there is some information that
107
108
There are also some suggestions that may be done with the development of the
system in the future, so the system can fulfill more satisfaction for the user. Here is the
suggestions list:
1. Application Interface.
In the current condition, The Online Expert Money Manager by Valley First
management can made the company have some trouble when managing their
own company financial. It will very useful for every company if the programmer
The differences between Male and Female needs in daily life give an opinion in
the programmer minds that Salary Management have to divided into two types
which is female and male. In the current condition the application only provide
http://en.wikipedia.org/wiki/Java_Platform,_Standard_Edition
http://en.wikipedia.org/wiki/Java_Platform,_Enterprise_Edition
http://en.wikipedia.org/wiki/Hibernate_(Java)
http://struts.apache.org/primer.html
http://www.accompa.com/product-management-blog/2009/09/19/use-cases-
definition-requirements-management-basics/.
http://searchcio-midmarket.techtarget.com/definition/expert-system
http:// informatika-unkris.ac.id/img/buku/sistem-pagookar-5.pdf
https://en.wikipedia.org/wiki/Valley_First
109
110
APPENDINCES
Here are the lists of the rule that is used during the Process:
IF haveChild = YES
THEN showExpertFieldChildQ
ELSE hideExpertFieldChildQ
IF haveHouse = YES
THEN showExpertFieldHouseQ
ELSE showCustomFieldHouseQ
IF haveMotorCycle = YES
THEN showExpertFieldMotorQ
ELSE showCustomFieldMotorQ
IF haveCar = YES
THEN showExpertFieldCarQ
ELSE showCustomFieldCarQ
IF savingMoney = YES
THEN showExpertMoneyQ
ELSE hideExpertMoneyQ