You are here

function commerce_product_line_item_types in Commerce Core 7

Returns an array of product line item types.

18 calls to commerce_product_line_item_types()
CommerceCartTestCaseMultiProducts::testCommerceCartOrder in modules/cart/tests/commerce_cart.test
Test if the product is present in the order stored in db.
CommerceCartTestCaseSimpleProduct::testCommerceCartOrder in modules/cart/tests/commerce_cart.test
Test if the product is present in the order stored in db.
commerce_cart_block_view in modules/cart/commerce_cart.module
Implements hook_block_view().
commerce_cart_checkout_router in modules/cart/includes/commerce_cart.pages.inc
Redirects invalid checkout attempts or displays the checkout form if valid.
commerce_cart_field_formatter_settings_form in modules/cart/commerce_cart.module
Implements hook_field_formatter_settings_form().

... See full list

File

modules/product_reference/commerce_product_reference.module, line 1458
Defines a field type for referencing products from other entities.

Code

function commerce_product_line_item_types() {
  $types = array();
  foreach (commerce_line_item_types() as $type => $line_item_type) {
    if (!empty($line_item_type['product'])) {
      $types[] = $type;
    }
  }
  return $types;
}