CE-881 - Refactoring exports & reports

- add some fields together into ReportDestination class
- pass more data into export streamers (views) and add preRun method
- Add queryHint POTENTIALLY_LARGE_NUMBER_OF_RESULTS
- add pivot views
- optionally take in full ReportMetaData object instead of a name (e.g., for a user-defined/saved report)
This commit is contained in:
2024-03-27 19:50:06 -05:00
parent 05f31d0722
commit e078015732
17 changed files with 421 additions and 165 deletions

View File

@ -49,6 +49,7 @@ import com.kingsrook.qqq.backend.core.model.actions.metadata.MetaDataInput;
import com.kingsrook.qqq.backend.core.model.actions.metadata.MetaDataOutput;
import com.kingsrook.qqq.backend.core.model.actions.reporting.ExportInput;
import com.kingsrook.qqq.backend.core.model.actions.reporting.ExportOutput;
import com.kingsrook.qqq.backend.core.model.actions.reporting.ReportDestination;
import com.kingsrook.qqq.backend.core.model.actions.reporting.ReportFormat;
import com.kingsrook.qqq.backend.core.model.actions.tables.get.GetInput;
import com.kingsrook.qqq.backend.core.model.actions.tables.get.GetOutput;
@ -429,8 +430,11 @@ public class QSlackImplementation
ExportInput exportInput = new ExportInput();
exportInput.setLimit(1000);
exportInput.setTableName(tableName);
exportInput.setReportFormat(ReportFormat.valueOf(format));
exportInput.setReportOutputStream(baos);
exportInput.setReportDestination(new ReportDestination()
.withReportFormat(ReportFormat.valueOf(format))
.withReportOutputStream(baos));
setupSession(context, exportInput);
ExportOutput output = new ExportAction().execute(exportInput);