Skip to content

Commit

Permalink
Exercise: set vertical for default orientation for sequence ordering …
Browse files Browse the repository at this point in the history
…questions for better management of all use case -refs BT20587
  • Loading branch information
NicoDucou committed Mar 10, 2023
1 parent 2f9b171 commit 2650f0e
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions main/exercise/Draggable.php
Expand Up @@ -51,7 +51,7 @@ public function createAnswersForm($form)
$nb_options++;
}
} elseif (!empty($this->iid)) {
$defaults['orientation'] = in_array($this->extra, ['h', 'v']) ? $this->extra : 'h';
$defaults['orientation'] = in_array($this->extra, ['h', 'v']) ? $this->extra : 'v';

$answer = new Answer($this->iid);
$answer->read();
Expand All @@ -77,7 +77,7 @@ public function createAnswersForm($form)
$defaults['matches[2]'] = '2';
$defaults['option[1]'] = get_lang('DefaultMatchingOptA');
$defaults['option[2]'] = get_lang('DefaultMatchingOptB');
$defaults['orientation'] = 'h';
$defaults['orientation'] = 'v';
}

for ($i = 1; $i <= $nb_matches; $i++) {
Expand All @@ -90,7 +90,7 @@ public function createAnswersForm($form)
$form->addRadio(
'orientation',
get_lang('ChooseOrientation'),
['h' => get_lang('Horizontal'), 'v' => get_lang('Vertical')]
['v' => get_lang('Vertical'), 'h' => get_lang('Horizontal')]
);

// DISPLAY MATCHES
Expand Down Expand Up @@ -157,7 +157,7 @@ public function createAnswersForm($form)
if (!empty($this->iid)) {
$form->setDefaults($defaults);
} else {
$form->setDefaults(['orientation' => 'h']);
$form->setDefaults(['orientation' => 'v']);

if (1 == $this->isContent) {
$form->setDefaults($defaults);
Expand Down

0 comments on commit 2650f0e

Please sign in to comment.