Package org.zkoss.zul

Examples of org.zkoss.zul.Comboitem


  }

  private void setupCombos() {
    List<Organization> orgs=organizationManager.findAll();
    for(Organization organisation : orgs){
      Comboitem item=new Comboitem(organisation.getName());
      ccombo.appendChild(item);
    }
   
  }
View Full Code Here


  }
 
  private void setupCombos(){
    List<Division> divisions=dmanager.findAll();
    for (Division division : divisions) {
      Comboitem item=new Comboitem(division.getCode());
      divisionCombo.appendChild(item);
     
    }
  }
View Full Code Here

  }

  private void setupCombos(){
    List<Company> companies=companyManager.findAll();
    for (Company company : companies) {
      Comboitem item=new Comboitem(company.getName());
      companiesCombo.appendChild(item);
    }
  }
View Full Code Here

        nameBox.setDisabled(true);

       
        List<Warehouse> replacements=manager.findAll();
        for (Warehouse replacement : replacements) {
          Comboitem item=new Comboitem(replacement.getName());
          warehousesCombo.appendChild(item);
        }


        Button okButton=new Button("OK");
View Full Code Here

  private void manageOption(String string) {
    nameBox.setDisabled(false);     
   
    List<Warehouse> replacements=manager.findAll();
    for (Warehouse replacement : replacements) {
      Comboitem item=new Comboitem(replacement.getName());
      warehousesCombo.appendChild(item);
    }
    Button okButton=new Button("OK");
    okButton.addEventListener("onClick", new EventListener(){
      public void onEvent(Event event) throws Exception {
View Full Code Here

                else {
                    lastName = groups.get(size - 1)
                    .getConceptName();
                }

                Comboitem item = new Comboitem();
                item.setLabel(firstName.substring(0, 1) + " - " + lastName.substring(0, 1));
                item.setDescription(firstName + " - " + lastName);
                item.setValue(position);
                filterByNameCombo.appendChild(item);
                position = newPosition;
            }
        }

        Comboitem lastItem = new Comboitem();
        lastItem.setLabel(_("All"));
        lastItem.setDescription(_("Show all elements"));
        lastItem.setValue(new Integer(-1));
        filterByNameCombo.appendChild(lastItem);

        filterByNameCombo.setSelectedIndex(0);
        refreshNameFilter = false;
    }
View Full Code Here

        }
        return result;
    }

    private Resource getSelectedResource() {
        Comboitem itemSelected = filterResource.getSelectedItem();
        if ((itemSelected != null)
                && (((Resource) itemSelected.getValue()) != null)) {
            return (Resource) itemSelected.getValue();
        }
        return null;
    }
View Full Code Here

        }
        return null;
    }

    private TypeOfWorkHours getSelectedHoursType() {
        Comboitem itemSelected = filterHoursType.getSelectedItem();
        if ((itemSelected != null)
                && (((TypeOfWorkHours) itemSelected.getValue()) != null)) {
            return (TypeOfWorkHours) itemSelected.getValue();
        }
        return null;
    }
View Full Code Here

    }

    private void createCalendar() {
        Combobox combobox = (Combobox) getCurrentWindow().getFellow(
                "createDerivedCalendar");
        Comboitem selectedItem = combobox.getSelectedItem();
        if (selectedItem == null) {
            throw new WrongValueException(combobox,
                    "You should select one calendar");
        }
        BaseCalendar parentCalendar = (BaseCalendar) combobox.getSelectedItem()
View Full Code Here

            throw new WrongValueException(buttonCreateAndAssign,
                    _("you do not have permissions to create new labels"));
        }

        // Check LabelType is not null
        final Comboitem comboitem = cbLabelType.getSelectedItem();
        if (comboitem == null || comboitem.getValue() == null) {
            throw new WrongValueException(cbLabelType,
                    _("please, select an item"));
        }

        // Check Label is not null or empty
        final String labelName = txtLabelName.getValue();
        if (labelName == null || labelName.isEmpty()) {
            throw new WrongValueException(txtLabelName,
                    _("cannot be empty"));
        }

        // Label does not exist, create
        final LabelType labelType = (LabelType) comboitem.getValue();
        Label label = getModel().findLabelByNameAndType(
                labelName, labelType);
        if (label == null) {
            label = addLabel(labelName, labelType);
        } else {
View Full Code Here

TOP

Related Classes of org.zkoss.zul.Comboitem

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.