1 views_ui.module | views_ui_get_wizards() |
Fetch metadata for all content_type plugins.
Return value
An array of arrays with information about all available views wizards.:
File
- core/
modules/ views_ui/ views_ui.module, line 563 - Provide structure for the administrative interface to Views.
Code
function views_ui_get_wizards() {
$wizard_plugins = module_invoke_all('views_ui_wizards');
$defaults = views_ui_views_wizard_defaults();
foreach ($wizard_plugins as $key => $plugin) {
$wizard_plugins[$key] += $defaults;
}
$wizard_tables = array();
foreach ($wizard_plugins as $name => $info) {
$wizard_tables[$info['base_table']] = TRUE;
}
$base_tables = views_fetch_base_tables();
// Find base tables with no wizard.
// @todo - handle this via an alter hook for plugins?
foreach ($base_tables as $table => $info) {
if (!isset($wizard_tables[$table])) {
$wizard = $defaults;
$wizard['title'] = $info['title'];
$wizard['base_table'] = $table;
$wizard_plugins[$table] = $wizard;
}
}
return $wizard_plugins;
}