Ejemplo n.º 1
0
 /**
  * DAO转BO
  *
  * @param ladderDAO
  * @return
  */
 public static LadderBO convertDAOTOBO(LadderDAO ladderDAO) {
   LadderBO ladderBO = new LadderBO();
   if (ladderDAO == null) {
     return ladderBO;
   }
   ladderBO.setId(ladderDAO.getId());
   ladderBO.setNumPercent(ladderDAO.getNumPercent());
   ladderBO.setPriceDiscount(ladderDAO.getPriceDiscount());
   ladderBO.setType(ladderDAO.getType());
   ladderBO.setYn(ladderDAO.getYn());
   return ladderBO;
 }
Ejemplo n.º 2
0
 /**
  * DAOList转BOList
  *
  * @param ladderDAO
  * @return
  */
 public static List<LadderBO> convertDAOTOBOList(List<LadderDAO> ladderDAOList) {
   List<LadderBO> ladderBOList = new ArrayList<LadderBO>();
   if (CollectionUtils.isEmpty(ladderDAOList)) {
     return ladderBOList;
   }
   for (LadderDAO ladderDAO : ladderDAOList) {
     LadderBO ladderBO = new LadderBO();
     ladderBO.setId(ladderDAO.getId());
     ladderBO.setNumPercent(ladderDAO.getNumPercent());
     ladderBO.setPriceDiscount(ladderDAO.getPriceDiscount());
     ladderBO.setType(ladderDAO.getType());
     ladderBO.setYn(ladderDAO.getYn());
     ladderBOList.add(ladderBO);
   }
   return ladderBOList;
 }