You are here

function media_acquiadam_schema_alter in Media: Acquia DAM 7

Implements hook_schema_alter().

File

./media_acquiadam.module, line 206

Code

function media_acquiadam_schema_alter(&$schema) {

  // Add an asset_id property to the file_managed table so we can easily find
  // related cache without having to parse/manipulate strings.
  $file_managed =& $schema['file_managed'];
  $file_managed['fields']['acquiadam_id'] = [
    'description' => st('The Acquia DAM asset identifier.'),
    'type' => 'int',
    'unsigned' => TRUE,
    'not null' => FALSE,
  ];
  $file_managed['indexes']['acquiadam_id'] = [
    'acquiadam_id',
  ];
  $file_managed['indexes']['fid_acquiadam_id'] = [
    'fid',
    'acquiadam_id',
  ];
}