mirror of
https://github.com/moodle/moodle.git
synced 2025-08-10 19:36:41 +02:00
Merge branch 'MDL-73313_master' of https://github.com/tasosb/moodle
This commit is contained in:
commit
af7a0ed1a1
6 changed files with 28 additions and 5 deletions
|
@ -797,6 +797,9 @@ EOF;
|
|||
*/
|
||||
public function get_welcome_message(): string {
|
||||
$welcomestring = $this->get_instance_var('welcome');
|
||||
if (!config::get('welcome_editable') || empty($welcomestring)) {
|
||||
$welcomestring = config::get('welcome_default');
|
||||
}
|
||||
if (empty($welcomestring)) {
|
||||
$welcomestring = get_string('mod_form_field_welcome_default', 'bigbluebuttonbn');
|
||||
}
|
||||
|
|
|
@ -224,6 +224,7 @@ class config {
|
|||
'lockonjoinconfigurable_editable' => self::get('lockonjoinconfigurable_editable'),
|
||||
'lockonjoinconfigurable_default' => self::get('lockonjoinconfigurable_default'),
|
||||
'welcome_default' => self::get('welcome_default'),
|
||||
'welcome_editable' => self::get('welcome_editable'),
|
||||
];
|
||||
}
|
||||
|
||||
|
|
|
@ -193,6 +193,18 @@ class settings {
|
|||
$item,
|
||||
$settingsgeneral
|
||||
);
|
||||
$settingsgeneral->add($item);
|
||||
$item = new admin_setting_configcheckbox(
|
||||
'bigbluebuttonbn_welcome_editable',
|
||||
get_string('config_welcome_editable', 'bigbluebuttonbn'),
|
||||
get_string('config_welcome_editable_description', 'bigbluebuttonbn'),
|
||||
1,
|
||||
);
|
||||
$this->add_conditional_element(
|
||||
'welcome_editable',
|
||||
$item,
|
||||
$settingsgeneral
|
||||
);
|
||||
}
|
||||
return $settingsgeneral;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue