Template Print Model Copies on Business Objects
A new feature allows creating a copy of a template print model for a specific business object.
To use this feature:
-
Add a many-to-one field
templatePrintModelon your business object domain:<many-to-one name="templatePrintModel" title="Template print model" ref="com.axelor.template.db.TemplatePrintModel"/> -
Add the field to your XML view:
<field name="templatePrintModel" domain="self.uploadStatus = 'ok' AND self.original = NULL"/> -
Add a button to create the copy:
<button name="createCopyBtn" title="Copy" onClick="action-template-print-model-group-copy-template"/> -
Add the studio panel dashlet:
<panel-dashlet colSpan="12" height="800" action="action.template.print.model.view.generic.studio"/>
The field name must be templatePrintModel. Names, titles, and component sizes can be customized as needed.
|