Add two-step set test start form

This commit is contained in:
Wojtek
2026-10-15 18:12:53 +02:00
parent 54c4c56469
commit 463160c0c7
6 changed files with 40 additions and 6 deletions
@@ -13,6 +13,7 @@ class HtmlView extends BaseHtmlView
protected $items;
protected $sets;
protected $results;
protected $started;
public function display($tpl = null)
{
@@ -23,6 +24,10 @@ class HtmlView extends BaseHtmlView
$this->set = $this->get('Set');
$this->items = $this->get('Items');
$this->sets = $this->get('Sets');
$input = Factory::getApplication()->getInput();
$this->started = $input->getMethod() === 'POST'
&& $input->post->getString('participant_name', '') !== ''
&& $input->post->getInt('set_id', 0) > 0;
$this->results = $this->buildResults($this->items);
return parent::display($tpl);