Adds the commerce shipment item to the database. Also notifies the appropriate model listeners.

@param commerceShipmentItem the commerce shipment item
@return the commerce shipment item that was added
352365
@Indexable(type = IndexableType.REINDEX)
	@Override
	public CommerceShipmentItem addCommerceShipmentItem(
		CommerceShipmentItem commerceShipmentItem) {
		commerceShipmentItem.setNew(true);

		return commerceShipmentItemPersistence.update(commerceShipmentItem);
	}
122009
public CommerceExtendedData addItem(Item item) throws JSONException {
		if (this.items == null) {
			this.items = new ArrayList<>();
		}
		items.add(item);
		return this;
	}
821747
@Override
	public com.liferay.commerce.model.CommerceShippingMethod createCommerceShippingMethod(
		long commerceShippingMethodId) {
		return _commerceShippingMethodLocalService.createCommerceShippingMethod(commerceShippingMethodId);
	}
1118474
@Indexable(type = IndexableType.REINDEX)
	@Override
	public CommerceWarehouseItem updateCommerceWarehouseItem(
		CommerceWarehouseItem commerceWarehouseItem) {
		return commerceWarehouseItemPersistence.update(commerceWarehouseItem);
	}
940807
@Indexable(type = IndexableType.REINDEX)
	@Override
	public CommerceWarehouseItem addCommerceWarehouseItem(
		CommerceWarehouseItem commerceWarehouseItem) {
		commerceWarehouseItem.setNew(true);

		return commerceWarehouseItemPersistence.update(commerceWarehouseItem);
	}
1151757
public static com.liferay.commerce.model.CommerceWarehouse addCommerceWarehouse(
		com.liferay.commerce.model.CommerceWarehouse commerceWarehouse) {
		return getService().addCommerceWarehouse(commerceWarehouse);
	}
411344
@Override
	public com.liferay.commerce.account.model.CommerceAccount addCommerceAccount(
		com.liferay.commerce.account.model.CommerceAccount commerceAccount) {
		return _commerceAccountLocalService.addCommerceAccount(commerceAccount);
	}
611205
private function _addShipmentToOrder($shipmentNumber)
    {
        print "Select an item to add to shipment #" . ($shipmentNumber + 1) . ":" . PHP_EOL;
        $items = $this->exampleClass->getItemNames();
        for ($i = 0; $i < count($items); $i++) {
            print " " . $i . " - " . $items[$i] . PHP_EOL;
        }

        do {
            print "Select the number of the item to add to this shipment:";
            $itemToAdd = trim(fgets(STDIN));
        } while (!is_numeric($itemToAdd));
        
        print PHP_EOL;
        
        $this->exampleClass->addShipmentToOrder($itemToAdd);
    }
741877
@Indexable(type = IndexableType.REINDEX)
	@Override
	public CommerceShipmentItem updateCommerceShipmentItem(
		CommerceShipmentItem commerceShipmentItem) {
		return commerceShipmentItemPersistence.update(commerceShipmentItem);
	}
168878
@Override
	public void cacheResult(CommerceShipment commerceShipment) {
		entityCache.putResult(CommerceShipmentModelImpl.ENTITY_CACHE_ENABLED,
			CommerceShipmentImpl.class, commerceShipment.getPrimaryKey(),
			commerceShipment);

		commerceShipment.resetOriginalValues();
	}
808316
@Override
	public void cacheResult(List<CommerceShipmentItem> commerceShipmentItems) {
		for (CommerceShipmentItem commerceShipmentItem : commerceShipmentItems) {
			if (entityCache.getResult(
						CommerceShipmentItemModelImpl.ENTITY_CACHE_ENABLED,
						CommerceShipmentItemImpl.class,
						commerceShipmentItem.getPrimaryKey()) == null) {
				cacheResult(commerceShipmentItem);
			}
			else {
				commerceShipmentItem.resetOriginalValues();
			}
		}
	}
735462
@Override
	@Transactional(enabled = false)
	public CommerceShipment createCommerceShipment(long commerceShipmentId) {
		return commerceShipmentPersistence.create(commerceShipmentId);
	}
163020
@Override
	public com.liferay.commerce.model.CommerceShipment updateCommerceShipment(
		com.liferay.commerce.model.CommerceShipment commerceShipment) {
		return _commerceShipmentLocalService.updateCommerceShipment(commerceShipment);
	}
330582
@Indexable(type = IndexableType.REINDEX)
	@Override
	public CommerceShipment addCommerceShipment(
		CommerceShipment commerceShipment) {
		commerceShipment.setNew(true);

		return commerceShipmentPersistence.update(commerceShipment);
	}
232670
@Indexable(type = IndexableType.REINDEX)
	@Override
	public CommerceOrderNote addCommerceOrderNote(
		CommerceOrderNote commerceOrderNote) {
		commerceOrderNote.setNew(true);

		return commerceOrderNotePersistence.update(commerceOrderNote);
	}
1138203
@Override
	public int countByCommerceShippingMethodId(long commerceShippingMethodId) {
		FinderPath finderPath = FINDER_PATH_COUNT_BY_COMMERCESHIPPINGMETHODID;

		Object[] finderArgs = new Object[] { commerceShippingMethodId };

		Long count = (Long)finderCache.getResult(finderPath, finderArgs, this);

		if (count == null) {
			StringBundler query = new StringBundler(2);

			query.append(_SQL_COUNT_COMMERCESHIPPINGFIXEDOPTION_WHERE);

			query.append(_FINDER_COLUMN_COMMERCESHIPPINGMETHODID_COMMERCESHIPPINGMETHODID_2);

			String sql = query.toString();

			Session session = null;

			try {
				session = openSession();

				Query q = session.createQuery(sql);

				QueryPos qPos = QueryPos.getInstance(q);

				qPos.add(commerceShippingMethodId);

				count = (Long)q.uniqueResult();

				finderCache.putResult(finderPath, finderArgs, count);
			}
			catch (Exception e) {
				finderCache.removeResult(finderPath, finderArgs);

				throw processException(e);
			}
			finally {
				closeSession(session);
			}
		}

		return count.intValue();
	}
637748
@Indexable(type = IndexableType.REINDEX)
	@Override
	public CommerceOrderPayment addCommerceOrderPayment(
		CommerceOrderPayment commerceOrderPayment) {
		commerceOrderPayment.setNew(true);

		return commerceOrderPaymentPersistence.update(commerceOrderPayment);
	}