settings.php 1.58 KB
Newer Older
1
<?php
2
// This file is part of Moodle - http://moodle.org/
Petr Skoda's avatar
Petr Skoda committed
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
//
// Moodle is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// (at your option) any later version.
//
// Moodle is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with Moodle.  If not, see <http://www.gnu.org/licenses/>.

/**
 * Book plugin settings
 *
20
21
 * @package    mod_book
 * @copyright  2004-2011 Petr Skoda {@link http://skodak.org}
Petr Skoda's avatar
Petr Skoda committed
22
23
 * @license    http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
 */
24

Petr Skoda's avatar
Petr Skoda committed
25
defined('MOODLE_INTERNAL') || die;
26

Petr Skoda's avatar
Petr Skoda committed
27
if ($ADMIN->fulltree) {
28
    require_once(__DIR__.'/lib.php');
29

30
    // General settings
Petr Skoda's avatar
Petr Skoda committed
31

32
33
34
    $options = book_get_numbering_types();

    $settings->add(new admin_setting_configmultiselect('book/numberingoptions',
35
        get_string('numberingoptions', 'mod_book'), get_string('numberingoptions_desc', 'mod_book'),
36
        array_keys($options), $options));
37

38
39
    // Modedit defaults.

40
41
    $settings->add(new admin_setting_heading('bookmodeditdefaults',
        get_string('modeditdefaults', 'admin'), get_string('condifmodeditdefaults', 'admin')));
Petr Skoda's avatar
Petr Skoda committed
42
43
44
45

    $settings->add(new admin_setting_configselect('book/numbering',
        get_string('numbering', 'mod_book'), '', BOOK_NUM_NUMBERS, $options));

46
}