Match set frontend to exam view

This commit is contained in:
Wojtek
2026-10-15 18:05:11 +02:00
parent b2ea519ff5
commit 54c4c56469
7 changed files with 37 additions and 2 deletions
@@ -3,6 +3,18 @@
defined('_JEXEC') or die;
?>
<div class="com-testquestions egzamin">
<form action="<?php echo htmlspecialchars($_SERVER['REQUEST_URI'], ENT_QUOTES, 'UTF-8'); ?>" method="get" class="mb-4">
<label for="test-set" class="form-label"><?php echo \Joomla\CMS\Language\Text::_('COM_TESTQUESTIONS_SELECT_SET'); ?></label>
<div class="input-group">
<select id="test-set" name="set_id" class="form-select egzamin" required>
<option value=""><?php echo \Joomla\CMS\Language\Text::_('COM_TESTQUESTIONS_SELECT_SET'); ?></option>
<?php foreach ($this->sets as $set) : ?>
<option value="<?php echo (int) $set->id; ?>" <?php echo $this->set && (int) $this->set->id === (int) $set->id ? 'selected' : ''; ?>><?php echo htmlspecialchars(($set->subject_title ? $set->subject_title . ' — ' : '') . $set->title, ENT_QUOTES, 'UTF-8'); ?></option>
<?php endforeach; ?>
</select>
<input type="submit" class="egzamin" value="<?php echo htmlspecialchars(\Joomla\CMS\Language\Text::_('COM_TESTQUESTIONS_SHOW_SET'), ENT_QUOTES, 'UTF-8'); ?>">
</div>
</form>
<?php if (!$this->set) : ?>
<div class="alert alert-info"><?php echo \Joomla\CMS\Language\Text::_('COM_TESTQUESTIONS_SET_NOT_FOUND'); ?></div>
<?php else : ?>