Configure DOCX Export Command
Configure DOCX Export Command
Technologies > User Interface Add-Ins > Parts for Reports > Report with DOC, PDF, Excel, and Data Transfer Actions
The DOCX export command has the following attributes.
printRestriction="true|false"
Use
printRestriction
to include the client-side (soft) parsed restriction that is in effect at the top of the DOCX report.
<command type="exportPanel" outputType="docx" printRestriction="true"/>
View designers can also enable printing of the client-side restriction in the Java Script code.
Print out the client-side parsed restriction in Java Script:
var parameters = {};
if(panel.getParametersForRefresh){
parameters = panel.getParametersForRefresh();
}
parameters.printRestriction = true;
var restriction = new Ab.view.Restriction();
restriction.addClause('fl.bl_id', HQ', '=');
restriction.addClause('fl.fl_id', ['16', '17', '18'], 'IN');
var jobId = panel.callDOCXReportJob(panel.title, restriction, parameters);
Print out a client-side custom restriction in Java Script:
var console = this.chartConsole_console;
var bl_id = console.getFieldValue('bl.bl_id');
var city_id = console.getFieldValue('bl.city_id');
var printableRestriction = [];
if(city_id != null && city_id != ''){
printableRestriction.push({'title': 'Restricted by the city', 'value': city_id});
}
if(bl_id != null && bl_id != ''){
printableRestriction.push({'title': 'Restricted by the building', 'value': bl_id});
}
var panel = this.chartConsole_chart;
var parameters = {};
if(panel.getParametersForRefresh){
parameters = panel.getParametersForRefresh();
}
parameters. printRestriction = true;
parameters. printableRestriction = printableRestriction;
var jobId = panel.callDOCXReportJob(panel.title, panel.restriction, parameters);
Examples:
http://localhost:8080/archibus/schema/ab-products/solutions/parts/chart/ab-chart-console.axvw
http://localhost:8080/archibus/schema/ab-products/solutions/assemblies/find-manage/ab-ex-console.axvw
orientation="landscape|portrait"
Use the
orientation
attribute to output a DOCX report in landscape or portrait model. The default setting for a DOCX report is portrait.
<command type="exportPanel" outputType="docx" orientation="landscape"/>
Example:
http://localhost:8080/archibus/schema/ab-products/solutions/parts/grid/ab-ex-report-grid-export.axvw
pageSize="width;height"
Use the
pageSize
attribute to specify the page size in inches.
<command type="exportPanel" outputType="docx" orientation="landscape" pageSize="17;17"/>