function media_acquiadam_schema in Media: Acquia DAM 7
Same name and namespace in other branches
- 8 media_acquiadam.install \media_acquiadam_schema()
Implements hook_schema().
File
- ./
media_acquiadam.install, line 51 - Drupal install related hooks.
Code
function media_acquiadam_schema() {
$schema = [];
$schema['acquiadam_asset_cache'] = [
'description' => st('Locally cached Acquia DAM asset information.'),
'fields' => [
'asset_id' => [
'description' => st('The Acquia DAM asset identifier.'),
'type' => 'int',
'unsigned' => TRUE,
'not null' => TRUE,
],
'type' => [
'description' => st('The machine name of the asset type.'),
'type' => 'varchar',
'length' => 32,
'not null' => TRUE,
'default' => '',
],
'data' => [
'type' => 'blob',
'size' => 'big',
'not null' => TRUE,
'description' => 'Serialized data containing the asset properties that do not warrant a dedicated column.',
],
'created' => [
'description' => 'The Unix timestamp when the asset was created.',
'type' => 'int',
'not null' => TRUE,
'default' => 0,
'unsigned' => TRUE,
],
'changed' => [
'description' => 'The Unix timestamp when the asset was most recently saved.',
'type' => 'int',
'not null' => TRUE,
'default' => 0,
'unsigned' => TRUE,
],
'expiration' => [
'description' => 'The Unix timestamp when the asset is set to expire.',
'type' => 'int',
'not null' => FALSE,
'default' => NULL,
'unsigned' => TRUE,
],
],
'indexes' => [
'created' => [
'created',
],
'changed' => [
'changed',
],
'expiration' => [
'expiration',
],
],
'unique keys' => [],
'primary key' => [
'asset_id',
],
];
return $schema;
}