function views_ui_get_wizards
Fetch metadata for all content_type plugins.
Return value
array An array of arrays with information about all available views wizards.
1 call to views_ui_get_wizards()
- views_ui_add_form in includes/
admin.inc - Form builder for the "add new view" page.
File
-
./
views_ui.module, line 636
Code
function views_ui_get_wizards() {
ctools_include('plugins');
$wizard_plugins = ctools_get_plugins('views_ui', 'views_wizard');
$wizard_tables = array();
foreach ($wizard_plugins as $info) {
$wizard_tables[$info['base_table']] = TRUE;
}
$base_tables = views_fetch_base_tables();
$default_wizard = views_ui_views_wizard_defaults();
// 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 = $default_wizard;
$wizard['title'] = $info['title'];
$wizard['base_table'] = $table;
$wizard_plugins[$table] = $wizard;
}
}
return $wizard_plugins;
}