function page_manager_term_view_admin_settings

Provide a setting to the Panels administrative form.

1 call to page_manager_term_view_admin_settings()
page_manager_term_view_settings in page_manager/plugins/tasks/term_view.inc
Settings page for this item.
1 string reference to 'page_manager_term_view_admin_settings'
page_manager_term_view_page_manager_tasks in page_manager/plugins/tasks/term_view.inc
Specialized implementation of hook_page_manager_task_tasks(). See api-task.html for more information.

File

page_manager/plugins/tasks/term_view.inc, line 256

Code

function page_manager_term_view_admin_settings($form, $settings = array()) {
    if (empty($settings)) {
        $settings = array(
            'page_manager_term_view_type' => page_manager_term_view_get_type(),
            'page_manager_taxonomy_breadcrumb' => variable_get('page_manager_taxonomy_breadcrumb', TRUE),
        );
    }
    $form['page_manager_term_view_type'] = array(
        '#type' => 'radios',
        '#title' => t('Allow multiple terms on taxonomy/term/%term'),
        '#options' => array(
            'single' => t('Single term'),
            'multiple' => t('Multiple terms'),
        ),
        '#description' => t('By default, Drupal allows multiple terms as an argument by separating them with commas or plus signs. If you set this to single, that feature will be disabled.') . ' ' . t('This feature does not currently work and is disabled.'),
        '#default_value' => $settings['page_manager_term_view_type'],
        // @todo -- fix this
'#disabled' => TRUE,
    );
    $form['page_manager_taxonomy_breadcrumb'] = array(
        '#title' => t('Inject hierarchy of first term into breadcrumb trail'),
        '#type' => 'checkbox',
        '#default_value' => $settings['page_manager_taxonomy_breadcrumb'],
        '#description' => t('If checked, taxonomy term parents will appear in the breadcrumb trail.'),
    );
    return $form;
}