public void initialize(Boolean isStatusSearchCriteriaVisible, Boolean areDistinctRecRetrieved) { showStatus(isStatusSearchCriteriaVisible); initialize(); form.grdGps().setVisible(isStatusSearchCriteriaVisible ); form.dynGrdGps().setVisible(!isStatusSearchCriteriaVisible); boolean isPracticeAndSurgeryColsVisible = ConfigFlag.UI.SHOW_SURGERY_WITH_PRACTICE_DETAILS.getValue(); if (!isStatusSearchCriteriaVisible) { initializeGPDynGrid(isPracticeAndSurgeryColsVisible); } form.cmbStatus().setValue(GPStatus.ACTIVE); form.getLocalContext().setSearchForDistinctRecords(areDistinctRecRetrieved); }
public GpShortVoCollection listGPsBySurname(String text) { if(text == null) throw new CodingRuntimeException("text is mandatory in method listGPsBySurname"); text = text.replaceAll("%", ""); String hql = "from Gp gp where gp.name.upperSurname like :surname and gp.status = :activeStatus order by gp.name.upperSurname"; return GpShortVoAssembler.createGpShortVoCollectionFromGp(getDomainFactory().find(hql, new String[] {"surname", "activeStatus"}, new Object[] {text.toUpperCase() + "%", getDomLookup(GPStatus.ACTIVE)})); }
private void newInstance() { form.getLocalContext().setGPVo(null); clearScreen(); form.setMode(FormMode.EDIT); form.ctnGPDetails().lyrGPDetails().showtabGPDetails(); if ((!form.getGlobalContext().NTPF.getTargetObjectIdIsNotNull()) && (engine.getFormName().equals(form.getForms().Admin.GPAdminDialog))) form.ctnGPDetails().lyrGPDetails().tabGPDetails().cmbGPStatus().setValue(GPStatus.TOBECODED); form.ctnGPDetails().lyrGPDetails().tabGPDetails().cmbTitle().setFocus(); }
private void listGpsAndPractices() { String gpQuery = "select gp from Gp as gp left join gp.status as status where (gp.isRIE is null or gp.isRIE = 0) and status.id <> " + GPStatus.INACTIVE.getID(); List<?> gpsList = getDomainFactory().find(gpQuery); assembleGps(gpsList); //String practiceQuery = "select org from Organisation as org left join org.type as orgType where (org.isRIE is null or org.isRIE = 0) and orgType.id = :OrganisationType"; //List<?> practicesList = getDomainFactory().find(practiceQuery, new String[]{"OrganisationType"}, new Object[] {OrganisationType.GPP.getID()}); //assemblePractices(practicesList); }
private GP updateGpStatus(GP gp) { if(gp!=null) { gp.setStatus(GPStatus.INACTIVE); String gMCCode = gp.getNationalCode(); if(gp.getPracticesIsNotNull()&&gp.getPractices().size()>0 &&gMCCode!=null) { for (GpToPracticesVo gpToPracticesVo : gp.getPractices()) { if(gpToPracticesVo.getPracticeIsNotNull()&&gpToPracticesVo.getPractice().getIsActive()!=null&&gpToPracticesVo.getPractice().getIsActive()) { if(gpToPracticesVo.getPractice().getLocationSitesIsNotNull()&&gpToPracticesVo.getPractice().getLocationSites().size()>0) { for (LocSiteVo surgery : gpToPracticesVo.getPractice().getLocationSites()) { if(surgery.getIsActiveIsNotNull() && surgery.getIsActive().equals(Boolean.TRUE)&& surgery.getPasCode()!=null&& gMCCode!=null&& gMCCode.trim()!=null&& surgery.getPasCode().toUpperCase().matches("\\S+_"+gMCCode.trim().toUpperCase()+"_\\S+")) //http://jira/browse/WDEV-15535 changed filter from PAS to GMC { gp.setStatus(GPStatus.ACTIVE); break; } } } } } } } return gp; }
private void clearControls() { super.clearScreen(); //setDefaultCodeType(); //WDEV-13987 form.cmbStatus().setValue(Boolean.TRUE.equals(form.cmbStatus().getVisible()) ? null : GPStatus.ACTIVE); form.grdGps().getRows().clear(); form.dynGrdGps().getRows().clear(); }
private void setDefaultCodeType() { form.cmbSearchCodeType().setValue(TaxonomyType.NAT_GP_CODE); form.cmbStatus().setValue(GPStatus.ACTIVE); }