Namespace: exports

bcdui.component. exports

Export package is the API to the WYSIWYG and detail exports of BCD-UI WYSIWYG can be pdf, excel or image

Methods

staticbcdui.component.exports.detailExport(args)

component/exports/exportsPackage.js, line 460
Uses SylkServlet, CsvServlet or ExcelExportServlet export servlets to provide the data of a WrsRequest, the response opens asynchronously in an extra window
Name Type Description
args Object The argument map with the following properties
Name Type Default Description
wrq string | bcdui.core.DataProvider Model containing the wrs request according to XSD http://www.businesscode.de/schema/bcdui/wrs-request-1.0.0
type string slk optional Can be "slk" or "csv" or "xlsx". slk is efficient as csv and preserves numbers, use "xlsx" to preserve non-latin characters in addition
fileName string export_(timestamp).(csv|xls) optional Name of the response file, depending on type, can also be provided via /wrq:WrsRequest/@bcdFileName from within the request
vfsFilename string optional when using vfs stored export lists, you can define a vfs path name here, if not, it is generated out of url/user information
exportMode string full optional full - using the wrq as it is, show - always showing a column selector, silent - use stored column information (at least 1 column specified) if available, otherwise full
allowSave boolean false optional ability to save to vfs, ensure that vfs binding and user rights are available when turned on
allDeselected boolean false optional for the column picjer, all columns are initially selected by default and you can deselect some. Settings this flag to true, you inverse this behaviour
wrqModify function optional function to do post wrq processing just before sending the request

staticbcdui.component.exports.exportToExcelTemplate(args)

component/exports/exportsPackage.js, line 578
Uses ExcelExportServlet to export Wrs(s) into XLSX template
Name Type Description
args Object The argument map with the following properties
Name Type Default Description
inputModel bcdui.core.DataProvider containing wrs:WrsContainer with 1..n wrs:Wrs or wrq:WrsRequest elements, containing wrs:Header or rnd:Wrs2Excel defining target sheets
fileName string excelExport.xlsx optional URL name used as suffix, must end with .xlsx

staticbcdui.component.exports.exportWysiwygAsExcel(args)

component/exports/exportsPackage.js, line 199
Produces a WYSIWYG Excel export of a windows.document subtree
Name Type Description
args Object The parameter map contains the following properties:
Name Type Default Description
rootElement string | HtmlElement The id of or the root element itself
fileName string export(_timestamp).xsl optional The name of the returned Excel document

staticbcdui.component.exports.exportWysiwygAsImage(args, format)

component/exports/exportsPackage.js, line 259
Produces a WYSIWYG image export of a windows.document subtree, needs pdf extension, part of EnterpriseEdition
Name Type Default Description
args Object The parameter map contains the following properties:
Name Type Default Description
rootElement string | HtmlElement The id of or the root element itself
fileName string report.format optional The name of the returned image
format string png optional Image format, supported are 'jpg', 'png', 'bmp' or 'gif'
args.css Array.<string> | string optional An array or space separated list of URLs containing CSS files to be used, relative the the current page. This allows using different styling on export than on the page. You can also use an bcdPdfStyle for inline style only to be applied on export. Absolute paths starting with '/' are relative to the context path. Use more specific rule precedence. (css precedence based on later declaration is not supported). Local css are being cached.
args.orientationLandscape boolean false optional Set this flag to true to make the PDF appear in landscape page orientation
args.dimension string A4 optional Physical dimension of the output like 'A5' or 'LETTER', default is A4.
Example
bcdui.component.exports.exportWysiwygAsImage( { rootElement: "myReportDiv, format: "gif" } );

staticbcdui.component.exports.exportWysiwygAsPdf(args)

component/exports/exportsPackage.js, line 164
Produces a WYSIWYG pdf export of a windows.document subtree, needs pdf extension, part of EnterpriseEdition
Name Type Description
args Object The parameter map contains the following properties:
Name Type Default Description
rootElement string | HtmlElement The id of or the root element itself
fileName string report.pdf optional The name of the returned pdf
css Array.<string> | string optional An array or space separated list of URLs containing CSS files to be used, relative the the current page. This allows using different styling on export than on the page. You can also use an bcdPdfStyle for inline style only to be applied on export. Absolute paths starting with '/' are relative to the context path. Use more specific rule precedence. (css precedence based on later declaration is not supported). Local css are being cached.
orientationLandscape boolean false optional Set this flag to true to make the PDF appear in landscape page orientation
dimension string A4 optional Physical dimension of the output like 'A5' or 'LETTER', default is A4.
Example
bcdui.component.exports.exportWysiwygAsPdf( { rootElement: "myReportDiv", css: ["/bcdui/theme/css/allStyles.css", "my.css"] } );