A report can be rendered from Python code and reacted to when rendering completes, via the onAfterRender event.

Load, render, and handle completion.
report = StiReport()
report.onAfterRender += 'afterRender'

if report.processRequest(request):
    return report.getFrameworkResponse()

report.loadFile(url_for('static', filename='reports/SimpleList.mrt'))
report.render()

js = report.javascript.getHtml()
html = report.getHtml()
return render_template('...html', reportJavaScript=js, reportHtml=html)

How it works. Python only generates the engine code; the report is built in the browser, and the event signals when it is ready.

By using this website, you agree to the use of cookies for analytics and personalized content. Cookies store useful information on your computer to help us improve efficiency and usability. For more information, please read the privacy policy and cookie policy.