You are here

function hook_references_dialog_search_attachables in References dialog 7

Return all 'attachables' that can be used together with views. An attachable is just a name that the views search reference plugin uses to know what to attach itself to. You can define your own attachables if you want to use the references dialog search functionality outside of the realm of fields.

Return value

An array keyed by entity and a unique name containing the following:

  • 'label': The label to use in views.

Related topics

1 function implements hook_references_dialog_search_attachables()

Note: this list is generated by pattern matching, so it may include some functions that are not actually implementations of this hook.

references_dialog_references_dialog_search_attachables in ./references_dialog.module
Implements hook_references_dialog_search_attachables().
2 invocations of hook_references_dialog_search_attachables()
references_dialog_get_attachable in ./references_dialog.module
Get an attachable by name.
references_dialog_get_search_view_attachables in ./references_dialog.module
Get instances appropriate for a search view on a particular entity type.

File

./references_dialog.api.php, line 93
This file contains documentation on hooks provided by this module.

Code

function hook_references_dialog_search_attachables() {

  // Return search views attachables for nodes.
  return array(
    'node' => array(
      'mysearchplugin' => array(
        'label' => t('A pretty label'),
      ),
    ),
  );
}