Jump to content

[Jaspersoft BI 6.4.2] How to update value of parameters by clicking in HTML 5 charts


albert.wang

Recommended Posts

Hi all

I am trying to create an interactive dashboard or report by using Jaspersoft BI 6.4.2 commercial edition.

Requirement

Let's say I have two charts in the same dashboard/report, one is a pie chart and another one is a table. I want to change the content of the table by clicking a slice in the pie chart. For example, the pie chart shows customer's names and their total orders. The table shows order details of some customers. If I click customer Tom in the pie chart, I want to see Tom's orders details.

One extra requirement is that I do not want to refresh the whole dashboard/report.

What I have tried

By using a Jaspersoft Studio report

I created a report with two datasets and two charts. I created a parameter and used it in the SQL query in the table chart dataset so changing the parameter could change the content of the table. But then I don't know how to make the pie chart and the table chart connected. Or how to add a click event or hyperlink in the pie chart to update the parameter and refresh the table chart.

By using a JasperReports Server dashboard

I created a dashboard with two dashlets (two Jaspersoft Studio reports). In the table report I created a parameter and used it in the SQL query in the table chart dataset so changing the parameter could change the content of the table. But then I don't know how to make the pie dashlet and the table dashlet connected. Or how to add a click event or hyperlink in the pie dashlet to update the parameter and refresh the table dashlet.

So my question is: How to update value of parameters by clicking in HTML 5 charts (might via Hyperlink).

Thank yuou.

Link to comment
Share on other sites

  • Replies 2
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

Hi Albert,

From the "Parameter mapping dialog" (Jasper Server) on the dashboard desinger page (it's a crooked icon at the top :)), you can set the follwing properties for each dashlet (source dashlet is already set though),

 Filter/ParameterDashlet AffectedFilter/Parameter Affected

 

Please make sure both reports have at least one common parameter and if you have that already, linking them up is fairly simple. Once this bit is done, you would see that clicking on the chart would reload the table with relevant data. On a side note, you cannot do it from table -> chart since Jasper Server does not handle hyperlinks on tables (possible only in Studio). Hope this helps.

Thanks.

Link to comment
Share on other sites

  • 8 months later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...