ReportBro Designer Configuration Options

Options can affect the user interface of the report designer and allow to enable, disable and customize features. You can set options when initializing ReportBro with the $().reportBro() constructor as shown in the example below:

    $("#reportbro").reportBro({
        menuSidebar: true // use vertical menu in sidebar instead of horizontal on top
    });
    
Option Type Default Description
adminMode boolean
true
If false no parameters can be added, deleted or modified. This can be used when existing reports can be adapted by your web application users. Since parameters are more complex and reference server data, it is usually not recommended for normal users to change them.
fonts array of array containing name (string) and value (string)
[
  { name: 'Courier', value: 'courier' },
  { name: 'Helvetica', value: 'helvetica' },
  { name: 'Times New Roman', value: 'times' }
]
Fonts that are available in font drop down within the text style section. Each font entry contains an array with name and value, where name is displayed in the drop down and value is used to identify the font in ReportBro Designer and ReportBro Lib.
additionalFonts array of array containing name (string) and value (string)
[]
These fonts will be added to fonts. In case additional fonts are added they must be made available with a font-face css defintion, e.g.
@font-face {
    font-family: "myfont";
    src: url("fonts/myfont.ttf");
}
The font-family must match the value from the font entry. See ReportBro Lib how to configure additional fonts on the server.
enableSpreadsheet boolean
true
If false the spreadsheet section for various elements (text, image, table, barcode) is hidden. Further no xlsx download link is shown in the preview tab.
localStorageReportKey string
null
If set and saveCallback is not set this key is used to store the report in the Browser's local storage when the save method is called. Further it is used in the method loadLocalReport to load the report from local storage.
menuShowButtonLabels boolean
false
If true labels are shown next to the icon for action buttons (save, undo/redo, preview).
menuSidebar boolean
false
Display report designer menu bar as vertical sidebar instead of horizontal menu on top.
patternCurrencySymbol string
"$"
The default pattern currency symbol in the document properties. This is only used for a new report, otherwise it is overriden from loaded report. The pattern currency symbol is inserted when a number is formatted with a pattern containing the currency symbol.
patternLocale string
"en"
The default pattern locale in the document properties. This is only used for a new report, otherwise it is overriden from loaded report. The pattern locale is used when a date or number is formatted with a pattern. Allowed values are 'de', 'en', 'es', 'fr' and 'it'.
patternDates array of array containing name (string) and description (string)
[
  { name: 'd.M.yyyy', description: 'patternDate1' },
  { name: 'd.M.yy, H:mm', description: 'patternDate2' },
  { name: 'd/MMM/yyyy', description: 'patternDate3' },
  { name: 'MM/dd/yyyy', description: 'patternDate4' }
]
The patterns are shown in a popup window when a date pattern input is selected. Each pattern entry contains an array with name and description. The name must be a valid date pattern. See Date Pattern Syntax for further details.
patternNumbers array of array containing name (string) and description (string)
[
  { name:'#,##0',description:'patternNumber1' },
  { name:'0.000',description:'patternNumber2' },
  { name:'0.00##',description:'patternNumber3' },
  { name:'#,##0.00',description:'patternNumber4' },
  { name:'$ #,##0.00',description:'patternNumber5' }
]
The patterns are shown in a popup window when a number pattern input is selected. Each pattern entry contains an array with name and description. The name must be a valid number pattern. See Number Pattern Syntax for further details.
patternAdditionalDates array of array containing name (string) and description (string)
[]
These date patterns will be added to patternDates.
patternAdditionalNumbers array of array containing name (string) and description (string)
[]
These number patterns will be added to patternNumbers.
reportServerTimeout string
20000
Timeout (in msec) for the report preview ajax request.
reportServerUrl string
"https://www.reportbro.com/report/run"
The url which is used in the preview method to generate the report. Replace this url with your endpoint in case you are running your own server to generate reports. Initially a 'PUT' request is sent to the server to verify the report and upload report definition in case the report is valid. A uuid key is returned for this request which uniquely identifies the report. This key is used in the following 'GET' request in the url for pdf preview and when downloading the xlsx file.
saveCallback function
null
Function which is called when save button is clicked. This can be used to get the report (see getReport) and make an ajax call to your web app to save the report in your application. If the report was saved successfully you should set the modified flag to false (see setModified) so the save button gets disabled.
showGrid boolean
true
If true the grid for the document content will be initially shown.