You are here

function commerce_customer_profile_delete_multiple in Commerce Core 7

Deletes multiple customer profiles by ID.

Parameters

$profile_ids: An array of customer profile IDs to delete.

$entity_context: An optional entity context array that specifies the entity through whose customer profile reference field the given profiles are being deleted:

  • entity_type: The type of entity.
  • entity_id: The unique ID of the entity.

Return value

TRUE on success, FALSE otherwise.

2 calls to commerce_customer_profile_delete_multiple()
CommerceCustomerUITest::testCommerceCustomerDeleteProfilesWithOrderReference in modules/customer/tests/commerce_customer_ui.test
Delete multiple profiles with and without orders attached.
commerce_customer_profile_delete in modules/customer/commerce_customer.module
Deletes a customer profile by ID.

File

modules/customer/commerce_customer.module, line 687
Defines the customer profile entity and API functions to manage customers and interact with them.

Code

function commerce_customer_profile_delete_multiple($profile_ids, $entity_context = array()) {
  return entity_get_controller('commerce_customer_profile')
    ->delete($profile_ids, NULL, $entity_context);
}