Table of Contents
Part 1: Introduction and Functional SpecsPart 2: Java classes
Part 3: Jasper layout with iReport
Part 4: HTML and jqGrid
Part 5: XML configuration
Part 6: Running the Application
Dependencies
- Spring core 3.1.0.RELEASE
- Spring Data JPA 1.1.0.M1
- jQuery 1.6.4
- jqGrid 4.3.1
- Jasper Reports 4.5.0
- See pom.xml for details
Github
To access the source code, please visit the project's Github repository (click here)
Functional Specs
Before we start, let's define our application's specs as follows:- Display reports in an interactive table
- Downloadable reports in PDF and Excel formats
- Use AJAX to avoid page refresh
- Users have roles. They are either admin or regular (default)
- A username is assumed to be unique
Here's our Use Case diagram:
Database
Our database contains two tables: user and role tables.User table
The user table contains personal information of each user. Notice the password values are hashed using Md5.Role table
The role table contains role values of each user. We define a role value of 1 as an admin, while a role value of 2 as a regular user.Screenshots
Before we start with the actual development, let's preview how our application will look like. This is also a good way to clarify further the application's specs.Entry page
The entry page is the primary page that users will see. It contains an interactive table where users can view and download records.
Pdf document
This is the downloadable Pdf document whenever the user clicks on the Pdf button.
Excel document
This is the downloadable Excel document whenever the user clicks on the Excel button. When using Excel format, the document's appearance varies depending on the application, i.e Microsoft Excel, Google Docs, Open Office.
Progress dialog
When a user clicks on any of the download buttons (Pdf or Excel), a progress dialog will appear and disappears once the download starts.
Next
In the next section, we will discuss the project's structure and write the Java classes. Click here to proceed.
Share the joy:
|
Subscribe by reader Subscribe by email Share