use of org.isisaddons.module.excel.dom.WorksheetSpec in project estatio by estatio.
the class KeyItemImportExportManager method export.
// region > export (action)
@Action(semantics = SemanticsOf.SAFE)
@ActionLayout(cssClassFa = "fa-download")
@MemberOrder(name = "keyItems", sequence = "1")
public Blob export() {
final String fileName = withExtension(getFileName(), ".xlsx");
WorksheetSpec spec = new WorksheetSpec(KeyItemImportExportLineItem.class, "keyItems");
WorksheetContent worksheetContent = new WorksheetContent(getKeyItems(), spec);
return excelService.toExcel(worksheetContent, fileName);
}
use of org.isisaddons.module.excel.dom.WorksheetSpec in project estatio by estatio.
the class InvoiceImportManager method downloadTemplate.
@Action(semantics = SemanticsOf.SAFE)
@ActionLayout(cssClassFa = "fa-download")
public Blob downloadTemplate() {
final String fileName = "template.xlsx";
WorksheetSpec spec = new WorksheetSpec(InvoiceImportLine.class, "invoiceImportLine");
WorksheetContent worksheetContent = new WorksheetContent(getLines(), spec);
return excelService.toExcel(worksheetContent, fileName);
}
Aggregations