Пример #1
0
 private void performDestroy() {
   try {
     getFacade().remove(current);
     JsfUtil.addSuccessMessage(
         ResourceBundle.getBundle("/com/sigolf/Bundle").getString("InfoEfectoDeleted"));
   } catch (Exception e) {
     JsfUtil.addErrorMessage(
         e, ResourceBundle.getBundle("/com/sigolf/Bundle").getString("PersistenceErrorOccured"));
   }
 }
Пример #2
0
 public String create() {
   try {
     getFacade().create(current);
     JsfUtil.addSuccessMessage(
         ResourceBundle.getBundle("/com/sigolf/Bundle").getString("InfoEfectoCreated"));
     return prepareCreate();
   } catch (Exception e) {
     JsfUtil.addErrorMessage(
         e, ResourceBundle.getBundle("/com/sigolf/Bundle").getString("PersistenceErrorOccured"));
     return null;
   }
 }
Пример #3
0
 public SelectItem[] getItemsAvailableSelectOne() {
   return JsfUtil.getSelectItems(ejbFacade.findAll(), true);
 }
Пример #4
0
 public SelectItem[] getItemsAvailableSelectMany() {
   return JsfUtil.getSelectItems(ejbFacade.findAll(), false);
 }