custom parameter page jsp birt integration with Iserver
#1
Posted 05 November 2011 - 07:55 AM
I have a custom parameter page written in jsp for a Birt report
I want to publish the jsp page into our Iserver box along with the Birt report
Birt report is not a problem, but I don't know how to integrate the jsp page/
It is possible to do that?
I know how to do it in a tomcat servlet.
Thans a lot for your ideas
JulioC
#2
Posted 07 November 2011 - 10:05 AM
Information console is a struts based web application so it is possible to customize it to your liking. Here is a link to the latest developer guide that has more details:
http://www.birt-exch...-ipwebapps.html
Ashwini
#3
Posted 08 November 2011 - 09:03 AM
I have been looking into it, however I don't find how to achieve what I'm looking for.
I have a report that have some parameters,when I deploy it to my Iserver and run it, it shows the default screen for the parameters, what I want is to see the customize screen parameters .
How can I link the report in Iserver to look to my jsp page that has the parameters insted of the default one.
Thanks in advance for your time
#4
Posted 08 November 2011 - 02:54 PM
Ashwini
#5
Posted 15 November 2011 - 06:00 AM
averma, on 08 November 2011 - 03:54 PM, said:
Ashwini
Hi thanks for your reply
What we want to do is to have a jsp page that has the customize screen parameters for the rptdesign report.
We don't know how to accomplish that in the Iserver environment, as you know, once we have the report design, we publish it to the Iserver, put it into a specific folder, once is there just click on it and run it.So it shows the default screen parameters.(how we can ask the report to look my jsp page and not the default screen)
Thanks
#6
Posted 15 November 2011 - 10:30 AM
You can build you own custom jsp page using Actuate JSAPI and deploy it in any servlet container. BIRT iServer comes with an embedded servlet container that you could use. You will find it in the following folder:
[Install Dir]\iServer\servletcontainer.
Now you can create an html page that redirects to this jsp.
Here is an article on JSAPI to get you started.
http://www.birt-exch..._Javascript_API
There are serveral other example of JSAPI usage in product documentation:
http://www.birt-exch...using-jsapi.pdf
Hope this helps!
Ashwini
#7
Posted 02 February 2012 - 01:36 PM
averma, on 15 November 2011 - 10:30 AM, said:
You can build you own custom jsp page using Actuate JSAPI and deploy it in any servlet container. BIRT iServer comes with an embedded servlet container that you could use. You will find it in the following folder:
[Install Dir]\iServer\servletcontainer.
Now you can create an html page that redirects to this jsp.
Here is an article on JSAPI to get you started.
http://www.birt-exch..._Javascript_API
There are serveral other example of JSAPI usage in product documentation:
http://www.birt-exch...using-jsapi.pdf
Hope this helps!
Ashwininow
Hi thanks for your reply
I was off for a while , now I'm back
I just tried one of the examples in the link, partially is working
I have this code
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
"http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
<meta http-equiv="content-type" content="text/
html;charset=utf-8" />
<title>Viewer With Parameters Page</title>
</head>
<body onload="init( )">
<div id="parampane">
<script type="text/javascript" language="Javascript"
src="http://iserver.ls.cbn:8900/iportal/jsapi"></script>
<script type="text/javascript" language="Javascript">
function init( ){
actuate.load("viewer");
actuate.load("parameter");
actuate.initialize( "http://iserver.ls.cbn:8900/iportal", null,null, null, displayParams);
}
function displayParams( ) {
param = new actuate.Parameter("parampane");
param.setReportName("/Public/BIRT and BIRT Studio Examples/Customer Order History.rptdesign");
param.submit(
function ( ) {this.run.style.visibility = 'visible';}); (here is the error)
}
function processParameters( ) {
param.downloadParameterValues(runReport);
}
</script>
</div>
<hr><br />
<input type="button" class="btn" name="run"
value="Run Report" onclick="processParameters( )"
style="visibility: hidden">
<div id="viewerpane">
<script type="text/javascript" language="Javascript"
src="http://localhost:8700/iportal/jsapi"></script>
<script type="text/javascript" language="Javascript">
function runReport(paramvalues) {
var viewer = new actuate.Viewer("viewerpane");
viewer.setReportName("/Public/BIRT and BIRT Studio Examples/Customer Order History.rptdesign");
viewer.setParameterValues(paramvalues);
viewer.submit( );
}
</script>
and it is showing this error message
this.run.style is undefined
Do you have any idea?
Thanks
#8
Posted 06 February 2012 - 12:37 PM
document.getElementById("<run button id>").style.display = 'none';
You will need to give your html button an id.






MultiQuote




