Example #1
0
  public Collection<CustomerFavHeader> getAvailableFavorites() {
    String customerId = getCustomerId();

    if (StringUtils.isBlank(customerId)
        || !isViewingShared()
        || StringUtils.equals(customerId, getCustomerProfile().getCustomer().getPrincipalName())) {
      customerId = getCustomerProfile().getCustomer().getPrincipalName();
      setViewingShared(false);
    }

    return ShopCartServiceLocator.getShopCartFavoriteService()
        .getFavoritesByCustomerId(customerId, isViewingShared());
  }
Example #2
0
 public ShopCartHomeForm() {
   setPunchOutCatalogs(
       ShopCartServiceLocator.getShopCartCatalogService()
           .getAvailableCatalogsPunchOut(getCustomerProfile()));
 }