r3154 - in trunk/lima-business/src/main/java/org/chorem/lima/business: ejb ejbinterface
Author: vsalaun Date: 2011-06-01 12:25:17 +0200 (Wed, 01 Jun 2011) New Revision: 3154 Url: http://chorem.org/repositories/revision/lima/3154 Log: ajout d'une fonction pour obtenir la liste des comptes a partir d'une de ses proprietes Modified: trunk/lima-business/src/main/java/org/chorem/lima/business/ejb/AccountServiceImpl.java trunk/lima-business/src/main/java/org/chorem/lima/business/ejbinterface/AccountService.java Modified: trunk/lima-business/src/main/java/org/chorem/lima/business/ejb/AccountServiceImpl.java =================================================================== --- trunk/lima-business/src/main/java/org/chorem/lima/business/ejb/AccountServiceImpl.java 2011-05-30 12:40:22 UTC (rev 3153) +++ trunk/lima-business/src/main/java/org/chorem/lima/business/ejb/AccountServiceImpl.java 2011-06-01 10:25:17 UTC (rev 3154) @@ -208,6 +208,31 @@ } } + + /** + * Permer d'obtenir la liste des comptes à partir d'une de ses propriétés + */ + @Override + public List<Account> getAllAccountByProperty(String propertyName, String value) throws LimaException { + List<Account> account = null; + + TopiaContext transaction = null; + try { + transaction = beginTransaction(); + + AccountDAO accountDAO = + LimaCallaoDAOHelper.getAccountDAO(transaction); + account = accountDAO.findAllByProperty(propertyName, value); + } + catch (TopiaException ex) { + doCatch(transaction, ex, log); + } + finally { + doFinally(transaction, log); + } + + return account; + } /** Modified: trunk/lima-business/src/main/java/org/chorem/lima/business/ejbinterface/AccountService.java =================================================================== --- trunk/lima-business/src/main/java/org/chorem/lima/business/ejbinterface/AccountService.java 2011-05-30 12:40:22 UTC (rev 3153) +++ trunk/lima-business/src/main/java/org/chorem/lima/business/ejbinterface/AccountService.java 2011-06-01 10:25:17 UTC (rev 3154) @@ -42,6 +42,8 @@ @Remote public interface AccountService { + + List<Account> getAllAccountByProperty(String propertyName, String value) throws LimaException; List<Account> getAllAccounts() throws LimaException;
participants (1)
-
vsalaun@users.chorem.org