public DischargeSummaryScheduleVoCollection getJobs() { DomainFactory factory = getDomainFactory(); String sql = "from DischargeSummarySchedule"; List jobs = factory.find(sql); if (jobs.size() > 0) { return DischargeSummaryScheduleVoAssembler.createDischargeSummaryScheduleVoCollectionFromDischargeSummarySchedule(jobs); } return null; }
private void populateGrid() { form.grdJob().getRows().clear(); DischargeSummaryScheduleVoCollection voCol = domain.getJobs(); DischargeSummaryScheduleVo summaryScheduleVo = null; for (int j = 0 ; voCol != null && j < voCol.size() ; j++) { summaryScheduleVo = voCol.get(j); grdJobRow row = form.grdJob().getRows().newRow(); row.setValue(summaryScheduleVo); if (summaryScheduleVo.getCreationDateIsNotNull()) row.setcolCreatedOn(summaryScheduleVo.getCreationDate()); if (summaryScheduleVo.getTriggerFrequencyIsNotNull()) row.setcolFrequency(summaryScheduleVo.getTriggerFrequency()); if (summaryScheduleVo.getLastRunIsNotNull()) row.setcolLastRun(summaryScheduleVo.getLastRun().toString()); if (summaryScheduleVo.getNextRunIsNotNull()) row.setcolNextRun(summaryScheduleVo.getNextRun().toString()); if (summaryScheduleVo.getPrintedLettersNoIsNotNull()) row.setcolNumberLettersPrinted(summaryScheduleVo.getPrintedLettersNo()); if (summaryScheduleVo.getGeneratedLeettersNoIsNotNull()) row.setcolNumberLettersGenerated(summaryScheduleVo.getGeneratedLeettersNo()); if (summaryScheduleVo.getSuccessfulEmailsNoIsNotNull()) row.setcolSuccessfulSentEmail(summaryScheduleVo.getSuccessfulEmailsNo()); if (summaryScheduleVo.getFailedEmailsNoIsNotNull()) row.setcolFailedSentEmail(summaryScheduleVo.getFailedEmailsNo()); row.setcolJob("Print Report"); row.setValue(summaryScheduleVo); if (summaryScheduleVo.getJobTypeIsNotNull()) { row.setcolType(summaryScheduleVo.getJobType().toString()); form.cmbJobType().removeRow(summaryScheduleVo.getJobType()); } } updateControlState(); }
private void populateGrid() { form.grdJob().getRows().clear(); DischargeSummaryScheduleVoCollection voCol = domain.getJobs(); DischargeSummaryScheduleVo summaryScheduleVo = null; for (int j = 0 ; voCol != null && j < voCol.size() ; j++) { summaryScheduleVo = voCol.get(j); grdJobRow row = form.grdJob().getRows().newRow(); row.setValue(summaryScheduleVo); if (summaryScheduleVo.getCreationDateIsNotNull()) row.setcolCreatedOn(summaryScheduleVo.getCreationDate()); if (summaryScheduleVo.getTriggerFrequencyIsNotNull()) row.setcolFrequency(summaryScheduleVo.getTriggerFrequency()); if (summaryScheduleVo.getLastRunIsNotNull()) row.setcolLastRun(summaryScheduleVo.getLastRun().toString()); if (summaryScheduleVo.getNextRunIsNotNull()) row.setcolNextRun(summaryScheduleVo.getNextRun().toString()); if (summaryScheduleVo.getPrintedLettersNoIsNotNull()) row.setcolNumberLettersPrinted(summaryScheduleVo.getPrintedLettersNo()); if (summaryScheduleVo.getGeneratedLeettersNoIsNotNull()) row.setcolNumberLettersGenerated(summaryScheduleVo.getGeneratedLeettersNo()); if (summaryScheduleVo.getSuccessfulEmailsNoIsNotNull()) row.setcolSuccessfulSentEmail(summaryScheduleVo.getSuccessfulEmailsNo()); if (summaryScheduleVo.getFailedEmailsNoIsNotNull()) row.setcolFailedSentEmail(summaryScheduleVo.getFailedEmailsNo()); if (summaryScheduleVo.getSealedEnvelopePatientsNo() != null) row.setcolSealedEnvelops(summaryScheduleVo.getSealedEnvelopePatientsNo()); row.setcolJob("Print Report"); row.setValue(summaryScheduleVo); if (summaryScheduleVo.getJobTypeIsNotNull()) { row.setcolType(summaryScheduleVo.getJobType().toString()); form.cmbJobType().removeRow(summaryScheduleVo.getJobType()); } } updateControlState(); }