Пример #1
0
  public List<Product> getProductsToDisplayForTheme(String theme) {
    List<Product> products;

    if (!StringUtils.equalsIgnoreCase(theme, "ubs")) {
      Company provider = this.companyDAO.findProvider(theme);
      products = new LinkedList<Product>(provider.getProducts());
    } else {
      if (logger.isInfoEnabled()) {
        logger.info("ubs theme passed in.  returning all products.");
      }
      products = new LinkedList<Product>(this.productDAO.readAllProducts());
    }

    return products;
  }