Disable outline information on node types not enabled for book outlines

This commit is contained in:
Manuel Cillero 2017-07-26 08:45:10 +02:00
parent 8bc400de2a
commit 07fc14091e
2 changed files with 15 additions and 2 deletions

View file

@ -27,6 +27,15 @@ function book_admin_overview() {
*/
function book_admin_settings() {
$types = node_get_types('names');
// Patch http://drupal.org/node/502430:
$form['book_restrict_to_types'] = array(
'#type' => 'checkbox',
'#title' => t('Enforce Allowed Types Restrictions'),
'#description' => t('Restrict outline capabilities to only the enabled content types below, even with "administer book outlines" permission.'),
'#default_value' => variable_get('book_restrict_to_types', false),
);
$form['book_allowed_types'] = array(
'#type' => 'checkboxes',
'#title' => t('Allowed book outline types'),