You are here

function party_log_party_data_set_detach in Party 7

Implements hook_party_data_set_detach().

Store a message against the data set controller when an entity is detached.

File

modules/party_log/party_log.party.inc, line 31
Party General hook include.

Code

function party_log_party_data_set_detach($controller, $entity, $delta) {
  global $user;
  $entity_type = $controller
    ->getDataInfo('entity type');
  $data_set_name = $controller
    ->getDataInfo('name');
  $controller->party_log_messages[] = array(
    'message_type' => 'party_data_set_detach_' . $data_set_name,
    $entity_type => $entity,
    'timestamp' => time(),
    'account' => $user,
  );
}