function ldap_query_schema in Lightweight Directory Access Protocol (LDAP) 8.2
Same name and namespace in other branches
- 7.2 ldap_query/ldap_query.install \ldap_query_schema()
- 7 ldap_query/ldap_query.install \ldap_query_schema()
Implements hook_schema().
1 call to ldap_query_schema()
- ldap_servers_update_7201 in ldap_servers/
ldap_servers.install - upgrade as much as feasible for 7.1 to 7.2 branch
File
- ldap_query/
ldap_query.install, line 30 - Install, update and uninstall functions for the LDAP API module.
Code
function ldap_query_schema() {
$schema['ldap_query'] = array(
'export' => array(
'key' => 'qid',
'key name' => 'Query Name',
'identifier' => 'qid',
'primary key' => 'query_numeric_id',
'api' => array(
'owner' => 'ldap_query',
'api' => 'ldap_query',
'minimum_version' => 1,
'current_version' => 1,
),
),
'description' => "LDAP Query Data leveraged by other LDAP Modules",
'primary key' => array(
'query_numeric_id',
),
'foreign keys' => array(
'sid' => array(
'table' => 'ldap_servers',
'columns' => array(
'sid' => 'sid',
),
),
),
);
module_load_include('module', 'ldap_servers');
ldap_servers_module_load_include('php', 'ldap_query', 'LdapQuery.class');
$fields = LdapQuery::fields();
foreach ($fields as $field_id => $field) {
if (isset($field['schema'])) {
$schema['ldap_query']['fields'][$field_id] = $field['schema'];
}
}
return $schema;
}