use of org.hisp.dhis.scheduling.parameters.DataIntegrityJobParameters.DataIntegrityReportType in project dhis2-core by dhis2.
the class DataIntegrityJob method execute.
@Override
public void execute(JobConfiguration config, JobProgress progress) {
DataIntegrityJobParameters parameters = (DataIntegrityJobParameters) config.getJobParameters();
Set<String> checks = parameters == null ? Set.of() : parameters.getChecks();
DataIntegrityReportType type = parameters == null ? null : parameters.getType();
if (type == null || type == DataIntegrityReportType.REPORT) {
runReport(config, progress, checks);
} else if (type == DataIntegrityReportType.SUMMARY) {
dataIntegrityService.runSummaryChecks(checks, progress);
} else {
dataIntegrityService.runDetailsChecks(checks, progress);
}
}
Aggregations