Skip to content

Commit

Permalink
Merge pull request #587 from armccoy/fix/settings-section-headers
Browse files Browse the repository at this point in the history
Make section headers unique; set initial expanded sections
  • Loading branch information
jrchamp authored Apr 15, 2024
2 parents ad99325 + e59ddc4 commit 5f7a1ce
Showing 1 changed file with 9 additions and 5 deletions.
14 changes: 9 additions & 5 deletions mod_form.php
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,8 @@ public function definition() {
$this->standard_intro_elements();

// Adding the "schedule" fieldset, where all settings relating to date and time are shown.
$mform->addElement('header', 'general', get_string('schedule', 'mod_zoom'));
$mform->addElement('header', 'schedule', get_string('schedule', 'mod_zoom'));
$mform->setExpanded('schedule');

// Add date/time. Validation in validation().
$starttimeoptions = [
Expand Down Expand Up @@ -465,7 +466,8 @@ public function definition() {
$mform->setType('roomsgroups', PARAM_RAW);

// Adding the "security" fieldset, where all settings relating to securing and protecting the meeting are shown.
$mform->addElement('header', 'general', get_string('security', 'mod_zoom'));
$mform->addElement('header', 'security', get_string('security', 'mod_zoom'));
$mform->setExpanded('security');

// Deals with password manager issues.
if (isset($this->current->password)) {
Expand Down Expand Up @@ -603,7 +605,8 @@ public function definition() {
$mform->addHelpButton('show_security', 'showsecurity', 'zoom');

// Adding the "media" fieldset, where all settings relating to media streams in the meeting are shown.
$mform->addElement('header', 'general', get_string('media', 'mod_zoom'));
$mform->addElement('header', 'media', get_string('media', 'mod_zoom'));
$mform->setExpanded('media');

// Add host/participants video options.
$mform->addGroup([
Expand Down Expand Up @@ -695,7 +698,8 @@ public function definition() {
$showalternativehosts = ($config->showalternativehosts != ZOOM_ALTERNATIVEHOSTS_DISABLE);
if ($showschedulingprivilege || $showalternativehosts) {
// Adding the "host" fieldset, where all settings relating to defining the meeting host are shown.
$mform->addElement('header', 'general', get_string('host', 'mod_zoom'));
$mform->addElement('header', 'host', get_string('host', 'mod_zoom'));
$mform->setExpanded('host');

// Supplementary feature: Alternative hosts.
// Only show if the admin did not disable this feature completely.
Expand Down Expand Up @@ -774,7 +778,7 @@ public function definition() {

// Adding option for Recording Visiblity by default.
if (!empty($config->viewrecordings)) {
$mform->addElement('header', 'general', get_string('recording', 'mod_zoom'));
$mform->addElement('header', 'recording', get_string('recording', 'mod_zoom'));
$mform->addElement(
'advcheckbox',
'recordings_visible_default',
Expand Down

0 comments on commit 5f7a1ce

Please sign in to comment.