function views_fetch_base_tables

Fetch a list of all base tables available.

Return value

array A keyed array of in the form of 'base_table' => 'Description'.

4 calls to views_fetch_base_tables()
views_ui::list_form in plugins/export_ui/views_ui.class.php
Create the filter/sort form at the top of a list of exports.
views_ui_edit_page_title in ./views_ui.module
Page title callback for the Edit View page.
views_ui_get_wizard in ./views_ui.module
Fetch metadata on a specific views ui wizard plugin.
views_ui_get_wizards in ./views_ui.module
Fetch metadata for all content_type plugins.

File

includes/admin.inc, line 5229

Code

function views_fetch_base_tables() {
    static $base_tables = array();
    if (empty($base_tables)) {
        $tables = array();
        $data = views_fetch_data();
        foreach ($data as $table => $info) {
            if (!empty($info['table']['base'])) {
                $tables[$table] = array(
                    'title' => $info['table']['base']['title'],
                    'description' => !empty($info['table']['base']['help']) ? $info['table']['base']['help'] : '',
                    'weight' => !empty($info['table']['base']['weight']) ? $info['table']['base']['weight'] : 0,
                );
            }
        }
        uasort($tables, '_views_weight_sort');
        $base_tables = $tables;
    }
    return $base_tables;
}