arreglar-funcionalidad #84

Merged
alex merged 14 commits from arreglar-funcionalidad into main 2024-11-28 02:52:23 +00:00
Showing only changes of commit fe517735ad - Show all commits

View File

@ -48,7 +48,7 @@ public class EmployeesListView extends BaseView {
StreamResource excelResource = new StreamResource("employees.xlsx", this::generateExcel); StreamResource excelResource = new StreamResource("employees.xlsx", this::generateExcel);
Anchor downloadLink = new Anchor(excelResource, "Export Employees"); Anchor downloadLink = new Anchor(excelResource, "Export Employees");
downloadLink.getElement().setAttribute("download", true); // Forzar descarga downloadLink.getElement().setAttribute("download", true); // Forzar descarga
return new Button("Export to Excel", e -> getCurrentPageLayout().add(downloadLink)); return new Button("Exportar como Excel", e -> getCurrentPageLayout().add(downloadLink));
} }
private ByteArrayInputStream generateExcel() { private ByteArrayInputStream generateExcel() {