private void setLastSavedRoleIntoSearchCriteria(AppRoleRefVo role) { if (role == null) throw new CodingRuntimeException("role cannot be null in method setLastSavedRoleIntoSearchCriteria"); for(int i=0;i<form.cmbRole().getValues().size(); i++) { AppRoleLiteVo voAppRole = (AppRoleLiteVo) form.cmbRole().getValues().get(i); if(voAppRole.getID_AppRole().equals(role.getID_AppRole())) { form.cmbRole().setValue(voAppRole); form.getLocalContext().setLastSelectedRole(voAppRole); break; } } }
public void initialize() throws FormOpenException { SecurityLevelLiteVoCollection voCollSecurity = domain.listSecurityLevel(); if(voCollSecurity == null || voCollSecurity.size() == 0) throw new FormOpenException("Security Level Configuration is mandatory"); form.getLocalContext().setSecurityLevels(voCollSecurity); form.getLocalContext().setRoles(domain.listActiveAppRole()); //load roles into search combo for(AppRoleLiteVo voRole : form.getLocalContext().getRoles()) form.cmbRole().newRow(voRole, voRole.getName()); form.getLocalContext().setOCSServices(domain.listActiveServiceByOCSCategories()); }
private void loadUnusedRolesIntoCombo() { form.cmbRoleDetail().clear(); AppRoleLiteVoCollection voCollRole = domain.listRolesNotUsedInRoleDisciplineSecurityLevel(); for(AppRoleLiteVo voRole : voCollRole) { form.cmbRoleDetail().newRow(voRole, voRole.getName()); } }