Add ordering slide type
CI / Deploy / test (push) Successful in 50s
CI / Deploy / deploy (push) Skipped

Participants bring shuffled items into the correct order and submit it
once. The admin enters the items in the correct order and can reorder
them by drag & drop or arrow keys. Closing the voting reveals the
solution: how many got it completely right and how often each item was
placed correctly; participants see whether their order was right.

The drag & drop mechanics of the slide list are extracted into a
reusable makeSortable() helper.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
gnilebeinandClaude Opus 5.5 committed 2026-11-07 16:47:37 +01:00
1 parent 4eed568a64
commit 918e077734
17 files changed
+922 -95

No files matched your search

+3 -2
View File
@@ -85,9 +85,10 @@ class ParticipateController extends AppController
$poll = $this->loadPoll($code);
$stateService = new PollStateService();
$slide = $poll->is_active ? $stateService->currentSlide($poll) : null;
$state = $stateService->forParticipant($poll, $this->participantHash($poll));
$participantHash = $this->participantHash($poll);
$state = $stateService->forParticipant($poll, $participantHash);
$this->set(compact('poll', 'slide', 'state'));
$this->set(compact('poll', 'slide', 'state', 'participantHash'));
$this->set('pollIntervalMs', (int)Configure::read('Plenario.pollIntervalMs', 2000));
}