For my project I built a Application service provider payroll system. Application Service Providers (ASPs) are companies that provide computer services online such as accounting or CAD. The software is run on the ASPs computers and the client companies link to it via an internet connection. The advantage of such services to the client company is that they can spend less money on computers software and IT staff allowing them to concentrate more on key business areas. There are disadvantages the main one being security. By using these remote computers they are effectively extending their networks into areas beyond their control.
I chose to use java partly because it was ideal for the project and partly because I already had experience in using it from units in my first and second year and wanted to further improve.
Examination of the Problem Domain.
The project includes the core payroll processing section which deals with tax, National Insurance Contributions(NIC), Statutory Sick Pay (SSP), Statutory Maternity Pay(SMP), Student Loan Deductions(SLD) and Tax Credits(TC). The system should allow for the entry and removal of companies and employees details on the system and a method of altering this data should it change or be updated. The tax boundaries and NIC boundaries need to be adjustable so as to cope with the annual tax and NIC alterations. A section that allows monthly returns and end of the year procedures to be carried out online needs to be designed.
The application needed The application can be broken into two main sections one section is for the client companies the other section is for the administrator allowing him to administrate the database remotely.
An important part of the application is the start up process carried out automatically when the server is started up. The start up process carries out two important first it initialises a custome built database connectionpool then it takes values used in the payroll process such as the rates of taxation from the database and places them into varible within the application.
security In order for businesses to use the application it needs to be secure to do this password and login names are required. The application has to levels of passwords for the clients. One level allows the users rights to enter data and run the payroll but does not allow them to access account information. A third level is for the administrator. When the user logs in the password and login name are sent to a table in the database containing all the passwords and login names is checked to see if the combination exists if it does not the user is told to re enter their password and login name combination. If the combination is found the company name and the permission level for the combination is returned and placed into the session object.
The lines below are used to check if a user has the correct level of permission to enter a page. The first line takes the permission level for the session from the session object. The second line checks to see if the permission is at the correct level if it is not the user is forwarded to a page a separate page telling them that they do not have rights to enter that section of the application from there they can return to the main menu.
String permission = (String)session.getAttribute("Permission"); if(permission.equals("1")) { %>Once the user has logged into the application they are taken to the main menu page. In the main menu the user clicks on buttons to move to the different parts of the application. These include a section to add new employees a section to remove employees from the payroll and a section to check on past payroll data. If the user has logged in as an administrator a button is displayed which takes them to a page from where they can directly edit the database using SQL statements.
The client companies enter the payroll section of the application from the main menu.The payroll process part of the application is the largest most complicated part consisting of many different JSPs and Classes. The diagram below demonstrates the various JSPs and classes that make up the payroll section of the program. When payroll is carried out it operates as a loop going though each employee taking there past payroll data which is needed for the calculation from the database. This data is placed into an EmployeeObject used to hold the various variable connected to an individual employee.
The hours worked Sick pay etc are then entered for each employee via a jsp page this data is stored in the employee object. The employee objects are then looped through one at a time and the NIC tax is calculated on each. This involves the calculation of gross pay the calculation of tax for the relevant tax code and the NIC calculation. The data is sent to a bank class which formats the data into a text file in the format specified by the Royal Bank of Scotland for Banks Automated Clearing System (BACS) transaction. If this application were to be used by an application several different bank classes would be required allowing the string to be formatted to other banks specifications. Finally the results of the payroll process are displayed to the user. Most of the application was completed but some parts such as the end of year process classes to allow the return of forms to the Inland Revenue were not created due to limited time. This was my first attempt at creating an actual application it was ambitious as in the past I had created only small programs it has been of great benefit and been a massive learning experience.
The project has made clear to me the importance of clearly understanding the system your application is for. Although during the creation of my application I did talk to people about payroll and study notes on the payroll process I did not really get a full understanding until I was well into the programming stage. If I were to tackle a similar application again I would find it easier partly because I have a better understanding of the design process and partly because my programming skills have been greatly improved in the proccess