Apertura floatingPane gwHtmlReport
La gwHtmlReport è una particolare tipologia di floatingPane del tutto simile alla scheda descritta qui.
openGwHtmlReportFloatingPane()
Per aprire questa tipologia di tab è esposta l'apposita function openGwHtmlReportFloatingPane(). (Dalla versione 4.4.18 in poi)
Parametri
- reportUrl String, required path to the .jasper file, 'WEB/template/' excluded (ex: 'path/To/file_name.jasper')
- options Object, optional, default null. Additional parameters.
- gwHtmlReport specific:
- reportParameters: Object, optional, default null. This map contains the parameter that will be available inside the report
- gwClassName: String, optional, default null. If omitted the eventual gwClass scope will not to be applied
- updateOnChangeInGwClassNameListString: String, optional, default null. Comma separated (',') gwClassNames. This parameter decides to which gwClass publish events will cause a gwHtmlReport tab refresh (insert/update/delete) So when user modifies a gwClassDetail of a specific gwClass, if updateOnChangeInGwClassNameListString contains the specific gwClassName, he tab will automatically refresh itself.
- floatingPane commons:
- floatingPaneId: String, optional, default null. When provided is used as fp id. Configuring it allow to open report on the already opened fp when needed, basing on fp id check
- title: String, optional, default ''
- modal: Boolean, optional, default false
- useCookie: Boolean, optional, default true
- dimensions: Object, optional, default {w: 1000, h: 800}
@Deprecated
- className: String, optional, default null. Like gwClassName. (Deprecated from 4.4.18), but still supported.
Esempi
Codice minimale dalla 4.4.18
- example.js
var reportUrl = 'path/To/file_name.jasper'; var gwHtmlReportFloatingPane = openGwHtmlReportFloatingPane(reportUrl, options);
Esempio con utilizzo di tutti i parametri, anche opzionali dalla 4.4.18:
- example.js
var reportUrl = 'path/To/file_name.jasper'; var options = { reportParameters: { date: new Date(), project: 'P01' }, updateOnChangeInGwClassNameListString: 'class_name_1', floatingPaneId: 'floatingPaneId', modal: false, useCookie: true dimensions: {w: 1000, h: 800} title: 'title', gwClassName: 'scoped_class_name' }; var gwHtmlReportFloatingPane = openGwHtmlReportFloatingPane(reportUrl, options);