Updates the commerce wish list item in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners.

@param commerceWishListItem the commerce wish list item
@return the commerce wish list item that was updated
160
public static com.liferay.commerce.wish.list.model.CommerceWishListItem updateCommerceWishListItem(
		com.liferay.commerce.wish.list.model.CommerceWishListItem commerceWishListItem) {
		return getService().updateCommerceWishListItem(commerceWishListItem);
	}
459933
@Indexable(type = IndexableType.REINDEX)
	@Override
	public CommerceOrderNote updateCommerceOrderNote(
		CommerceOrderNote commerceOrderNote) {
		return commerceOrderNotePersistence.update(commerceOrderNote);
	}
784045
@Override
	public com.liferay.commerce.discount.model.CommerceDiscount updateCommerceDiscount(
		com.liferay.commerce.discount.model.CommerceDiscount commerceDiscount) {
		return _commerceDiscountLocalService.updateCommerceDiscount(commerceDiscount);
	}
234306
public static com.liferay.commerce.price.list.model.CommercePriceEntry updateCommercePriceEntry(
		com.liferay.commerce.price.list.model.CommercePriceEntry commercePriceEntry) {
		return getService().updateCommercePriceEntry(commercePriceEntry);
	}
221515
public static com.liferay.commerce.discount.model.CommerceDiscount updateCommerceDiscount(
		com.liferay.commerce.discount.model.CommerceDiscount commerceDiscount) {
		return getService().updateCommerceDiscount(commerceDiscount);
	}
864313
@Indexable(type = IndexableType.DELETE)
	@Override
	public CommerceWishList deleteCommerceWishList(
		CommerceWishList commerceWishList) {
		return commerceWishListPersistence.remove(commerceWishList);
	}
424788
protected function _updateWishlist($aArticleList, $oUser)
    {

        foreach ($aArticleList as $oContent) {
            if (($sWishId = $oContent->getWishId())) {
                // checking which wishlist user uses ..
                if ($sWishId == $oUser->getId()) {
                    $oUserBasket = $oUser->getBasket('wishlist');
                } else {
                    $aWhere = ['oxuserbaskets.oxuserid' => $sWishId, 'oxuserbaskets.oxtitle' => 'wishlist'];
                    $oUserBasket = oxNew(\OxidEsales\Eshop\Application\Model\UserBasket::class);
                    $oUserBasket->assignRecord($oUserBasket->buildSelectString($aWhere));
                }

                // updating users wish list
                if ($oUserBasket) {
                    if (!($sProdId = $oContent->getWishArticleId())) {
                        $sProdId = $oContent->getProductId();
                    }
                    $oUserBasketItem = $oUserBasket->getItem($sProdId, $oContent->getSelList());
                    $dNewAmount = $oUserBasketItem->oxuserbasketitems__oxamount->value - $oContent->getAmount();
                    if ($dNewAmount < 0) {
                        $dNewAmount = 0;
                    }
                    $oUserBasket->addItemToBasket($sProdId, $dNewAmount, $oContent->getSelList(), true);
                }
            }
        }
    }
620226
public static com.liferay.commerce.model.CommerceOrder updateCommerceOrder(
		com.liferay.commerce.model.CommerceOrder commerceOrder) {
		return getService().updateCommerceOrder(commerceOrder);
	}
188129
public static com.liferay.commerce.price.list.model.CommercePriceList addCommercePriceList(
		com.liferay.commerce.price.list.model.CommercePriceList commercePriceList) {
		return getService().addCommercePriceList(commercePriceList);
	}
1339546
@Override
	public void clearCache() {
		entityCache.clearCache(CommerceWishListImpl.class);

		finderCache.clearCache(FINDER_CLASS_NAME_ENTITY);
		finderCache.clearCache(FINDER_CLASS_NAME_LIST_WITH_PAGINATION);
		finderCache.clearCache(FINDER_CLASS_NAME_LIST_WITHOUT_PAGINATION);
	}
543257
@Override
	public com.liferay.commerce.wish.list.model.CommerceWishList createCommerceWishList(
		long commerceWishListId) {
		return _commerceWishListLocalService.createCommerceWishList(commerceWishListId);
	}
403278
@Override
	public List<CommerceWishListItem> findByCommerceWishListId(
		long commerceWishListId) {
		return findByCommerceWishListId(commerceWishListId, QueryUtil.ALL_POS,
			QueryUtil.ALL_POS, null);
	}
66553
@Indexable(type = IndexableType.REINDEX)
	@Override
	public CommerceOrderPayment updateCommerceOrderPayment(
		CommerceOrderPayment commerceOrderPayment) {
		return commerceOrderPaymentPersistence.update(commerceOrderPayment);
	}
352365
@Indexable(type = IndexableType.REINDEX)
	@Override
	public CommerceShipmentItem addCommerceShipmentItem(
		CommerceShipmentItem commerceShipmentItem) {
		commerceShipmentItem.setNew(true);

		return commerceShipmentItemPersistence.update(commerceShipmentItem);
	}
976963
@Override
	public List<CommerceWishList> findAll() {
		return findAll(QueryUtil.ALL_POS, QueryUtil.ALL_POS, null);
	}
1263673
@Override
	@Transactional(enabled = false)
	public CommercePriceList createCommercePriceList(long commercePriceListId) {
		return commercePriceListPersistence.create(commercePriceListId);
	}
1031545
@Override
	public List<CommerceWishList> getCommerceWishListsByUuidAndCompanyId(
		String uuid, long companyId) {
		return commerceWishListPersistence.findByUuid_C(uuid, companyId);
	}