85 $this->
ui = $DIC->ui();
113 require_once
'Modules/TestQuestionPool/classes/questions/class.ilAssOrderingElementList.php';
124 $elementList->completeContentsFromElementList(
125 $question->getOrderingElementList()
134 return parent::getInstanceId();
263 $icon_name =
'icon_not_ok.svg';
264 $label = $this->
lng->txt(
"answer_is_wrong");
265 if ($correctness ===
'correct') {
266 $icon_name =
'icon_ok.svg';
267 $label = $this->
lng->txt(
"answer_is_right");
270 $icon = $this->
ui->factory()->symbol()->icon()->custom(
274 return $this->
ui->renderer()->render($icon);
282 return new ilTemplate(
'tpl.prop_ass_nested_order_elem.html',
true,
true,
'Modules/TestQuestionPool');
309 protected function getItemHtml($element, $identifier, $position, $itemSubFieldPostVar, $itemSubFieldId): string
317 $tpl->setCurrentBlock(
'item_text');
319 $tpl->parseCurrentBlock();
325 $tpl->setCurrentBlock(
'item_image');
328 $tpl->parseCurrentBlock();
333 $correctness =
'not_correct';
335 $correctness =
'correct';
337 $tpl->setCurrentBlock(
'correctness_icon');
340 $tpl->parseCurrentBlock();
343 $tpl->setCurrentBlock(
'item');
344 $tpl->setVariable(
"ITEM_ID", $itemSubFieldId);
345 $tpl->setVariable(
"ITEM_POSTVAR", $itemSubFieldPostVar);
347 $tpl->parseCurrentBlock();
359 if (!isset($elementValues[$elementCounter])) {
363 return $elementValues[$elementCounter][
'ordering_indentation'];
373 if (!isset($elementValues[$elementCounter + 1])) {
377 return $elementValues[$elementCounter + 1][
'ordering_indentation'];
382 if (!is_array(
$data)) {
Abstract basic class which is to be extended by the concrete assessment question type classes...
static getImagePath(string $img, string $module_path="", string $mode="output", bool $offline=false)
get image path (for images located in a template directory)
static buildInstance(int $question_id, array $elements=[])
Provides fluid interface to RBAC services.
getRandomIdentifierIndexedElements()
__construct(Container $dic, ilPlugin $plugin)
if($DIC->http() ->request() ->getMethod()=="GET" &&isset($DIC->http() ->request() ->getQueryParams()['tex'])) $tpl