Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
PUBLIC CLOUD
PRIVATE CLOUD
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Intelligence (Analytics)
JSAPI freeze problem
shariat
<p>We have JSAPI freeze problem in Chrome and Firefox on a simple report, across different OSes.The result is not consistent, but freezing happens most of the time.</p>
<p>Here is the link to the report: <a data-ipb='nomediaparse' href='
http://portal.cvst.ca/bixi_analytics.html'>http://portal.cvst.ca/bixi_analytics.html</a></p>
;
Find more posts tagged with
Comments
micajblock
<p>What version? Can you provide the source code of the page?</p>
shariat
<p>Please take a look at the html source code</p>
micajblock
<p>What version are you using?</p>
shariat
<p>We are using BIRT <span style="color:rgb(38,38,38);font-family:arial, sans-serif;font-size:13px;">iHub 3.1</span></p>
micajblock
<p>Change your init function to this:</p>
<div>
<pre class="_prettyXprint">
function init( ){
actuate.load("viewer");
actuate.load("parameter");
var reqOps = new actuate.RequestOptions( );
reqOps.setRepositoryType(actuate.RequestOptions.REPOSITORY_ENCYCLOPEDIA);
reqOps.setIServerUrl("http://142.150.208.245:8000");
reqOps.setVolumeProfile("Default Volume");
actuate.initialize( "http://142.150.208.245:8700/iportal", reqOps, "public", "", displayParams);
}</pre>
</div>
shariat
<p>I added this snippet (<a data-ipb='nomediaparse' href='
http://portal.cvst.ca/bixi_analytics.html'>http://portal.cvst.ca/bixi_analytics.html</a>)
but the problem is still there. The page freezes at <em>widget.js</em></p>
micajblock
<p>Last try. If this does not work I would contact support. My experience is that the include of the JSAPI is in the header. I also put all my scripts there (or better in a separate JS file) I have no idea what this line is for (never seen it)?</p>
<div>
<pre class="_prettyXprint">
<script type="text/javascript" language="JavaScript" src="http://142.150.208.245:8700/iportal/"></script>
<script type="text/javascript" language="JavaScript"></pre>
</div>
<p> </p>
<p>Try this:</p>
<div>
<pre class="_prettyXprint">
</pre>
<div><!DOCTYPE html></div>
<div><html></div>
<div><head></div>
<div><meta http-equiv="content-type" content="text/html; charset=utf-8" /></div>
<div><title>Viewer with Parameters Page</title></div>
<div><script type="text/javascript" language="JavaScript" src="<a data-ipb='nomediaparse' href='
http://142.150.208.245:8700/iportal/jsapi'>http://142.150.208.245:8700/iportal/jsapi"></script></a></div>
;
<div><script type="text/javascript" language="JavaScript"></div>
<div> </div>
<div>function init(){</div>
<div> actuate.load("viewer");</div>
<div> actuate.load("parameter");</div>
<div> var reqOps = new actuate.RequestOptions();</div>
<div> reqOps.setRepositoryType(actuate.RequestOptions.REPOSITORY_ENCYCLOPEDIA);</div>
<div> reqOps.setIServerUrl("<a data-ipb='nomediaparse' href='
http://142.150.208.245:8000'>http://142.150.208.245:8000");</a></div>
;
<div> reqOps.setVolumeProfile("Default Volume");</div>
<div> actuate.initialize( "<a data-ipb='nomediaparse' href='
http://142.150.208.245:8700/iportal'>http://142.150.208.245:8700/iportal",</a>reqOps
, "public", "", displayParams); </div>
<div>}</div>
<div>function displayParams(){</div>
<div> param = new actuate.Parameter("parampane");</div>
<div> param.setReportName("/Resources/FinalProjectPlus.rptdesign");</div>
<div> param.submit(function(){</div>
<div> document.getElementById("run").style.visibility = 'visible';</div>
<div> });</div>
<div>}</div>
<div>function processParameters(){</div>
<div> param.downloadParameterValues(runReport);</div>
<div>}</div>
<div> </div>
<div>function runReport(paramvalues) {</div>
<div> var viewer = new actuate.Viewer("viewerpane");</div>
<div> viewer.setReportName("/Resources/FinalProjectPlus.rptdesign");</div>
<div> viewer.setParameterValues(paramvalues);</div>
<div> var options = new actuate.viewer.UIOptions();</div>
<div> options.enableEditReport(false);</div>
<div> options.enableDataExtraction(false);</div>
<div> options.enableExportReport(false);</div>
<div> options.enableToolBar(false);</div>
<div> options.enableFilter(false);</div>
<div> options.enableDataAnalyzer(false);</div>
<div> options.enableCollapseExpand(false);</div>
<div> options.enableAdvancedSort(false);</div>
<div> options.enableAggregation(false);</div>
<div> options.enableCalculatedColumn(false);</div>
<div> options.enableChartProperty(false);</div>
<div> options.enableChartSubType(false);</div>
<div> options.enableFormat(false);</div>
<div> options.enableGroupEdit(false);</div>
<div> options.enableMainMenu(false);</div>
<div> options.enablePageNavigation(false);</div>
<div> options.enableShowToolTip(false);</div>
<div> options.enableSort(false);</div>
<div> options.enableTopBottomNFilter(false);</div>
<div> viewer.setUIOptions(options);</div>
<div> viewer.submit();</div>
<div>}</div>
<div></script></div>
<div> </div>
<div></head></div>
<div><body onload="init()"></div>
<div><div id="parampane"></div>
<div> </div>
<div> </div>
<div></div></div>
<div> </div>
<div><hr><br /></div>
<div><input type="button" class="btn" id="run" name="run" value="Run Report" onclick="processParameters()"></div>
<div> </div>
<div><div id="viewerpane"></div>
<div> </div>
<div> </div>
<div></div></div>
<div></body></div>
<div></html></div>
<p> </p>
</div>
shariat
<p>Thanks Mica,</p>
<p>I updated the code with HTML and Javascript best practices. Still it freezes in widget.js. </p>
micajblock
<p>Maybe a conflict somewhere, like I said support is your best bet at this point.</p>