Search in sources :

Example 1 with XlsFormBuilder

use of org.activityinfo.io.xlsform.XlsFormBuilder in project activityinfo by bedatadriven.

the class FormResource method getXlsForm.

@GET
@NoCache
@Path("form.xls")
@Operation(summary = "Get a form's schema as an XLSForm")
public Response getXlsForm() {
    assertVisible(formId);
    final XlsFormBuilder xlsForm = new XlsFormBuilder(backend.getStorage());
    xlsForm.build(formId);
    StreamingOutput output = xlsForm::write;
    return Response.ok(output, "application/vnd.ms-excel").build();
}
Also used : XlsFormBuilder(org.activityinfo.io.xlsform.XlsFormBuilder) Operation(io.swagger.v3.oas.annotations.Operation)

Aggregations

Operation (io.swagger.v3.oas.annotations.Operation)1 XlsFormBuilder (org.activityinfo.io.xlsform.XlsFormBuilder)1