Merge pull request 'Close an open ordering slide on "next" before moving on' (#116) from fix/order-next-reveals into main
CI / Deploy / PHP 8.4 (push) Successful in 1m14s
CI / Deploy / PHP 8.5 (push) Successful in 1m22s
CI / Deploy / test (push) Successful in 1s
CI / Deploy / deploy (push) Successful in 7s

Reviewed-on: #116
This commit was merged in pull request #116.
This commit is contained in:
gnilebein committed 2026-11-21 09:24:32 +01:00
commit cad09163d9
3 files changed
+27 -1

No files matched your search

+8 -1
View File
@@ -274,7 +274,8 @@ class AdminController extends AdminAppController
*
* On a Q&A slide that is being discussed, next/prev step through the questions
* first (like builds in presentation software); on a quiz, next starts it and then ends it
* before moving on, prev always goes to the previous slide. While paused, next/prev resume
* before moving on, on an open ordering slide next closes it (reveals the solution),
* prev always goes to the previous slide. While paused, next/prev resume
* the slide that was live before.
*
* Answers with the new state as JSON for XHR requests, otherwise redirects back.
@@ -308,6 +309,12 @@ class AdminController extends AdminAppController
}
}
// Same for an ordering slide: forward first closes the voting (reveals the solution).
if ($current !== null && $current->isOrder() && $action === 'next' && $current->isVotingOpen()) {
(new SlideControlService())->apply($current, 'close');
$action = 'none';
}
switch ($action) {
case 'none':
break;