コード例 #1
0
ファイル: Fasteign.java プロジェクト: idega/is.fmr.landskra
 public String getNafn() {
   if (nafn != null) {
     return nafn;
   } else {
     Gata gata = getGata();
     if (gata != null) {
       String gotuheiti = gata.getNafn();
       gotuheiti = gotuheiti + " " + getGotuNumer();
       return gotuheiti;
     }
   }
   return null;
 }
コード例 #2
0
  public List getGotuListiSelects() {

    ArrayList selects = new ArrayList();
    if (postnumer == null || postnumer.equals("")) {
      SelectItem item = new SelectItem();
      item.setLabel("Veldu póstnúmer fyrst");
      item.setValue("");
      selects.add(item);
    } else {
      SelectItem item0 = new SelectItem();
      item0.setLabel("- Engin gata til staðar");
      item0.setValue("none");
      selects.add(item0);
      List gotuListi = InitialData.getInitialData().getGotuListiByPostnumer(postnumer);
      for (Iterator iter = gotuListi.iterator(); iter.hasNext(); ) {
        Gata gata = (Gata) iter.next();
        SelectItem item = new SelectItem();
        item.setLabel(gata.getNafn());
        item.setValue(gata.getNafn());
        selects.add(item);
      }
    }
    return selects;
  }