private void loadCombos() { //Status form.cmbStatus().clear(); PreActiveActiveInactiveStatusCollection statusColl = LookupHelper.getPreActiveActiveInactiveStatus(domain.getLookupService()); for(int i=0; statusColl != null && i<statusColl.size(); i++) { PreActiveActiveInactiveStatus status = statusColl.get(i); if(isNewQuestion()) { //When we have a new Question - Remove Inactive entry (cannot create a new Inactive Record) if(status.equals(PreActiveActiveInactiveStatus.INACTIVE)) continue; } else { //When record is active don't allow to Preactivate it if(isRecordActive() && status.equals(PreActiveActiveInactiveStatus.PREACTIVE)) continue; } form.cmbStatus().newRow(status, status.toString()); } }
private void removePreActiveActiveStatus() { PreActiveActiveInactiveStatus status = form.cmbStatus().getValue(); form.cmbStatus().clear(); PreActiveActiveInactiveStatusCollection lookupColl = ims.core.vo.lookups.LookupHelper.getPreActiveActiveInactiveStatus(domain.getLookupService()); for (int i = 0; lookupColl != null && i < lookupColl.size(); i++) { if (isStatusActive() && lookupColl.get(i).equals(PreActiveActiveInactiveStatus.PREACTIVE)) continue; if (isStatusInactive() && (lookupColl.get(i).equals(PreActiveActiveInactiveStatus.PREACTIVE) || lookupColl.get(i).equals(PreActiveActiveInactiveStatus.ACTIVE))) continue; form.cmbStatus().newRow(lookupColl.get(i), lookupColl.get(i).toString(), lookupColl.get(i).getImage(), lookupColl.get(i).getColor()); } form.cmbStatus().setValue(status); }
private void removeActiveOrPreactiveLookup() { PreActiveActiveInactiveStatus status = form.cmbActiveStatus().getValue(); form.cmbActiveStatus().clear(); PreActiveActiveInactiveStatusCollection lookupColl = LookupHelper.getPreActiveActiveInactiveStatus(domain.getLookupService()); for(int i=0; lookupColl != null && i<lookupColl.size(); i++) { if(isStatusActive() && lookupColl.get(i).equals(PreActiveActiveInactiveStatus.PREACTIVE)) continue; if(isStatusInactive() && (lookupColl.get(i).equals(PreActiveActiveInactiveStatus.PREACTIVE) || lookupColl.get(i).equals(PreActiveActiveInactiveStatus.ACTIVE))) continue; form.cmbActiveStatus().newRow(lookupColl.get(i), lookupColl.get(i).toString(), lookupColl.get(i).getImage(), lookupColl.get(i).getColor()); } form.cmbActiveStatus().setValue(status); }
private void removePreactiveOrActiveLookup() { PreActiveActiveInactiveStatus status = form.lyrFindings().tabView().cmbStatus().getValue(); form.lyrFindings().tabView().cmbStatus().clear(); PreActiveActiveInactiveStatusCollection lookupColl = LookupHelper.getPreActiveActiveInactiveStatus(domain.getLookupService()); for (int i = 0; lookupColl != null && i < lookupColl.size(); i++) { if(isStatusActive() && lookupColl.get(i).equals(PreActiveActiveInactiveStatus.PREACTIVE)) continue; if(isStatusInactive() && (lookupColl.get(i).equals(PreActiveActiveInactiveStatus.PREACTIVE) || lookupColl.get(i).equals(PreActiveActiveInactiveStatus.ACTIVE))) continue; form.lyrFindings().tabView().cmbStatus().newRow(lookupColl.get(i), lookupColl.get(i).toString(), lookupColl.get(i).getImage(), lookupColl.get(i).getColor()); } form.lyrFindings().tabView().cmbStatus().setValue(status); }
private void removePreactiveOrActiveLookup() { PreActiveActiveInactiveStatus status = form.cmbActiveStatus().getValue(); form.cmbActiveStatus().clear(); PreActiveActiveInactiveStatusCollection lookupColl = LookupHelper.getPreActiveActiveInactiveStatus(domain.getLookupService()); for(int i=0; lookupColl != null && i<lookupColl.size(); i++) { if(isStatusActive() && lookupColl.get(i).equals(PreActiveActiveInactiveStatus.PREACTIVE)) continue; if(isStatusInactive() && (lookupColl.get(i).equals(PreActiveActiveInactiveStatus.PREACTIVE) || lookupColl.get(i).equals(PreActiveActiveInactiveStatus.ACTIVE))) continue; form.cmbActiveStatus().newRow(lookupColl.get(i), lookupColl.get(i).toString(), lookupColl.get(i).getImage(), lookupColl.get(i).getColor()); } form.cmbActiveStatus().setValue(status); }
private void removePreactiveOrActiveLookup() { PreActiveActiveInactiveStatus status = form.ctnDetails().cmbStatus().getValue(); form.ctnDetails().cmbStatus().clear(); PreActiveActiveInactiveStatusCollection lookupColl = LookupHelper.getPreActiveActiveInactiveStatus(domain.getLookupService()); for (int i = 0; lookupColl != null && i < lookupColl.size(); i++) { if (isStatusActive() && lookupColl.get(i).equals(PreActiveActiveInactiveStatus.PREACTIVE)) continue; if (isStatusInactive() && (lookupColl.get(i).equals(PreActiveActiveInactiveStatus.PREACTIVE) || lookupColl.get(i).equals(PreActiveActiveInactiveStatus.ACTIVE))) continue; form.ctnDetails().cmbStatus().newRow(lookupColl.get(i), lookupColl.get(i).toString(), lookupColl.get(i).getImage(), lookupColl.get(i).getColor()); } form.ctnDetails().cmbStatus().setValue(status); }
private void removePreactiveOrActiveLookup() { PreActiveActiveInactiveStatus status = form.cmbStatus().getValue(); form.cmbStatus().clear(); PreActiveActiveInactiveStatusCollection lookupColl = LookupHelper.getPreActiveActiveInactiveStatus(domain.getLookupService()); for (int i = 0; lookupColl != null && i < lookupColl.size(); i++) { if (isStatusActive() && lookupColl.get(i).equals(PreActiveActiveInactiveStatus.PREACTIVE)) continue; if (isStatusInactive() && (lookupColl.get(i).equals(PreActiveActiveInactiveStatus.PREACTIVE) || lookupColl.get(i).equals(PreActiveActiveInactiveStatus.ACTIVE))) continue; //WDEV-17376 if ((form.getLocalContext().getSelectedTriageProtocol()==null || form.getLocalContext().getSelectedTriageProtocol() != null && form.getLocalContext().getSelectedTriageProtocol().getActiveStatusIsNotNull() && form.getLocalContext().getSelectedTriageProtocol().getActiveStatus().equals(PreActiveActiveInactiveStatus.PREACTIVE)) && lookupColl.get(i).equals(PreActiveActiveInactiveStatus.INACTIVE)) { continue; } form.cmbStatus().newRow(lookupColl.get(i), lookupColl.get(i).toString(), lookupColl.get(i).getImage(), lookupColl.get(i).getColor()); } form.cmbStatus().setValue(status); }
private void removePreactiveOrActiveLookup() { PreActiveActiveInactiveStatus status = form.lyrDrawing().tabImageSelect().cmbImageStatus().getValue(); form.lyrDrawing().tabImageSelect().cmbImageStatus().clear(); PreActiveActiveInactiveStatusCollection lookupColl = LookupHelper.getPreActiveActiveInactiveStatus(domain.getLookupService()); for (int i = 0; lookupColl != null && i < lookupColl.size(); i++) { if (isStatusActive() && lookupColl.get(i).equals(PreActiveActiveInactiveStatus.PREACTIVE)) continue; if (isStatusInactive() && (lookupColl.get(i).equals(PreActiveActiveInactiveStatus.PREACTIVE) || lookupColl.get(i).equals(PreActiveActiveInactiveStatus.ACTIVE))) continue; form.lyrDrawing().tabImageSelect().cmbImageStatus().newRow(lookupColl.get(i), lookupColl.get(i).toString(), lookupColl.get(i).getImage(), lookupColl.get(i).getColor()); } form.lyrDrawing().tabImageSelect().cmbImageStatus().setValue(status); }
private void populateStatusCell(DynamicGridCell cellStatus, PreActiveActiveInactiveStatus status) { cellStatus.getItems().clear(); cellStatus.setAutoPostBack(true); PreActiveActiveInactiveStatusCollection voColl = ims.core.vo.lookups.LookupHelper.getPreActiveActiveInactiveStatus(domain.getLookupService()); for(int i = 0; voColl != null && i < voColl.size(); i++) { if(voColl.get(i).getParent() == null) { if (status != null) { if (!voColl.get(i).equals(status)) cellStatus.getItems().newItem(voColl.get(i)); } else { cellStatus.getItems().newItem(voColl.get(i)); } } } }
private void removePreactiveOrActiveLookup() { PreActiveActiveInactiveStatus status = form.ctnDetails().cmbStatus().getValue(); form.ctnDetails().cmbStatus().clear(); PreActiveActiveInactiveStatusCollection lookupColl = ims.core.vo.lookups.LookupHelper.getPreActiveActiveInactiveStatus(domain.getLookupService()); for (int i = 0; lookupColl != null && i < lookupColl.size(); i++) { if (isStatusActive() && lookupColl.get(i).equals(PreActiveActiveInactiveStatus.PREACTIVE)) continue; if (isStatusInactive() && lookupColl.get(i).equals(PreActiveActiveInactiveStatus.PREACTIVE)) continue; form.ctnDetails().cmbStatus().newRow(lookupColl.get(i), lookupColl.get(i).toString(), lookupColl.get(i).getImage(), lookupColl.get(i).getColor()); } form.ctnDetails().cmbStatus().setValue(status); }
private void removePreactiveOrActiveLookup() { PreActiveActiveInactiveStatus status = form.ctnDetails().lyrPrimaryTumour().tabTumourDetails().cmbStatus().getValue(); form.ctnDetails().lyrPrimaryTumour().tabTumourDetails().cmbStatus().clear(); PreActiveActiveInactiveStatusCollection lookupColl = ims.core.vo.lookups.LookupHelper.getPreActiveActiveInactiveStatus(domain.getLookupService()); for (int i = 0; lookupColl != null && i < lookupColl.size(); i++) { if (isStatusActive() && lookupColl.get(i).equals(PreActiveActiveInactiveStatus.PREACTIVE)) continue; if (isStatusInactive() && (lookupColl.get(i).equals(PreActiveActiveInactiveStatus.PREACTIVE) || lookupColl.get(i).equals(PreActiveActiveInactiveStatus.ACTIVE))) continue; form.ctnDetails().lyrPrimaryTumour().tabTumourDetails().cmbStatus().newRow(lookupColl.get(i), lookupColl.get(i).toString(), lookupColl.get(i).getImage(), lookupColl.get(i).getColor()); } form.ctnDetails().lyrPrimaryTumour().tabTumourDetails().cmbStatus().setValue(status); }
private void populateStatusCell(DynamicGridCell statusCell) { statusCell.getItems().clear(); PreActiveActiveInactiveStatusCollection statusColl = LookupHelper.getPreActiveActiveInactiveStatus(domain.getLookupService()); if (form.cmbStatus().getValue().equals(PreActiveActiveInactiveStatus.PREACTIVE)) { statusColl.remove(PreActiveActiveInactiveStatus.INACTIVE); } if (form.cmbStatus().getValue().equals(PreActiveActiveInactiveStatus.ACTIVE)) { statusColl.remove(PreActiveActiveInactiveStatus.PREACTIVE); } for (int i = 0; i < statusColl.size(); i++) { DynamicGridCellItem item = statusCell.getItems().newItem(statusColl.get(i)); item.setIdentifier(statusColl.get(i).getIItemText()); item.setValue(statusColl.get(i)); } }
private void populateStatusComboBox(PreActiveActiveInactiveStatus value) { form.ctnScheduleConfiguration().cmbScheduleStatus().clear(); PreActiveActiveInactiveStatusCollection statusValues = LookupHelper.getPreActiveActiveInactiveStatus(this.domain.getLookupService()); for (int i = 0; i < statusValues.size(); i++) { if (statusValues.get(i) == null) continue; form.ctnScheduleConfiguration().cmbScheduleStatus().newRow(statusValues.get(i), statusValues.get(i).getText(), statusValues.get(i).getImage(), statusValues.get(i).getTextColor()); } if (PreActiveActiveInactiveStatus.ACTIVE.equals(value)) { form.ctnScheduleConfiguration().cmbScheduleStatus().removeRow(PreActiveActiveInactiveStatus.PREACTIVE); } else if (PreActiveActiveInactiveStatus.INACTIVE.equals(value)) { form.ctnScheduleConfiguration().cmbScheduleStatus().removeRow(PreActiveActiveInactiveStatus.PREACTIVE); form.ctnScheduleConfiguration().cmbScheduleStatus().removeRow(PreActiveActiveInactiveStatus.ACTIVE); } form.ctnScheduleConfiguration().cmbScheduleStatus().setValue(value); }
private void populateStatusComboBox(PreActiveActiveInactiveStatus value) { form.ctnBatchDetails().cmbStatus().clear(); PreActiveActiveInactiveStatusCollection statusValues = LookupHelper.getPreActiveActiveInactiveStatus(this.domain.getLookupService()); for (int i = 0; i < statusValues.size(); i++) { if (statusValues.get(i) == null) continue; form.ctnBatchDetails().cmbStatus().newRow(statusValues.get(i), statusValues.get(i).getText(), statusValues.get(i).getImage(), statusValues.get(i).getTextColor()); } if (PreActiveActiveInactiveStatus.ACTIVE.equals(value)) { form.ctnBatchDetails().cmbStatus().removeRow(PreActiveActiveInactiveStatus.PREACTIVE); } else if (PreActiveActiveInactiveStatus.INACTIVE.equals(value)) { form.ctnBatchDetails().cmbStatus().removeRow(PreActiveActiveInactiveStatus.PREACTIVE); //form.ctnBatchDetails().cmbStatus().removeRow(PreActiveActiveInactiveStatus.ACTIVE); } form.ctnBatchDetails().cmbStatus().setValue(value); }