4 include_once
"./Modules/Test/classes/inc.AssessmentConstants.php";
54 $this->
ilObject($a_id,$a_call_by_reference);
95 if (!parent::update())
108 include_once
"./Services/MetaData/classes/class.ilMD.php";
110 $md_gen =& $md->getGeneral();
111 if ($md_gen ==
false)
113 include_once
"./Services/MetaData/classes/class.ilMDCreator.php";
115 $md_creator->setTitle($this->
getTitle());
116 $md_creator->setTitleLanguage($ilUser->getPref(
'language'));
117 $md_creator->create();
127 function read($a_force_db =
false)
143 if (!parent::delete())
161 if (count($questions))
163 foreach ($questions as $question_id)
170 include_once
"./Services/Utilities/classes/class.ilUtil.php";
172 $directory = $qpl_data_dir.
"/qpl_".$this->
getId();
173 if (is_dir($directory))
175 include_once
"./Services/Utilities/classes/class.ilUtil.php";
194 function notify($a_event,$a_ref_id,$a_parent_non_rbac_id,$a_node_id,$a_params = 0)
234 if ($a_node_id==
$_GET[
"ref_id"])
236 $parent_obj =& $this->ilias->obj_factory->getInstanceByRefId($a_node_id);
237 $parent_type = $parent_obj->getType();
238 if($parent_type == $this->
getType())
240 $a_node_id = (int) $tree->getParentId($a_node_id);
244 parent::notify($a_event,$a_ref_id,$a_parent_non_rbac_id,$a_node_id,$a_params);
255 include_once
"./Modules/Test/classes/class.ilObjTest.php";
256 include_once
"./Modules/TestQuestionPool/classes/class.assQuestion.php";
260 $question->delete($question_id);
285 $result = $ilDB->queryF(
"SELECT * FROM qpl_questionpool WHERE obj_fi = %s",
287 array($this->
getId())
307 $result = $ilDB->queryF(
"SELECT id_questionpool FROM qpl_questionpool WHERE obj_fi = %s",
309 array($this->
getId())
314 $result = $ilDB->update(
'qpl_questionpool',
316 'isonline' => array(
'text', $this->
getOnline()),
319 'tstamp' => array(
'integer', time())
322 'obj_fi' => array(
'integer', $this->
getId())
328 $next_id = $ilDB->nextId(
'qpl_questionpool');
330 $result = $ilDB->insert(
'qpl_questionpool', array(
331 'id_questionpool' => array(
'integer', $next_id),
332 'isonline' => array(
'text', $this->
getOnline()),
335 'tstamp' => array(
'integer', time()),
336 'obj_fi' => array(
'integer', $this->
getId())
352 if ($question_id < 1)
357 $result = $ilDB->queryF(
"SELECT qpl_qst_type.type_tag FROM qpl_questions, qpl_qst_type WHERE qpl_questions.question_type_fi = qpl_qst_type.question_type_id AND qpl_questions.question_id = %s",
363 $data = $ilDB->fetchAssoc(
$result);
364 return $data[
"type_tag"];
419 $result = $ilDB->queryF(
"SELECT COUNT(solution_id) solution_count FROM tst_solutions WHERE question_fi = %s",
424 return $row[
"solution_count"];
429 include_once
"./Modules/TestQuestionPool/classes/class.assQuestion.php";
432 $question_type_gui = $question_type .
"GUI";
433 $question_gui =&
new $question_type_gui();
434 return $question_gui;
446 $newtitle = $question->object->getTitle();
447 if ($question->object->questionTitleExists($this->getId(), $question->object->getTitle()))
450 while ($question->object->questionTitleExists($this->getId(), $question->object->getTitle() .
" ($counter)"))
454 $newtitle = $question->object->getTitle() .
" ($counter)";
456 $new_id = $question->object->duplicate(
false, $newtitle);
472 if ($question_gui->object->getObjId() == $questionpool_to)
480 $newtitle = $question_gui->object->getTitle();
481 if ($question_gui->object->questionTitleExists($this->getId(), $question_gui->object->getTitle()))
484 while ($question_gui->object->questionTitleExists($this->getId(), $question_gui->object->getTitle() .
" ($counter)"))
488 $newtitle = $question_gui->object->getTitle() .
" ($counter)";
490 return $question_gui->object->copyObject($this->
getId(), $newtitle);
503 $query_result = $ilDB->queryF(
"SELECT qpl_questions.*, qpl_qst_type.type_tag, qpl_qst_type.plugin, qpl_questions.tstamp updated FROM qpl_questions, qpl_qst_type WHERE qpl_questions.original_id IS NULL AND qpl_questions.tstamp > 0 AND qpl_questions.question_type_fi = qpl_qst_type.question_type_id AND qpl_questions.obj_fi = %s",
505 array($this->
getId())
509 if ($query_result->numRows())
511 while (
$row = $ilDB->fetchAssoc($query_result))
513 $row[
'ttype'] = $types[
$row[
'type_tag']];
518 array_push($rows, $row);
523 array_push($rows, $row);
536 function exportPagesXML(&$a_xml_writer, $a_inst, $a_target_dir, &$expLog, $questions)
540 $this->mob_ids = array();
541 $this->file_ids = array();
544 $attrs[
"Type"] =
"Questionpool_Test";
545 $a_xml_writer->xmlStartTag(
"ContentObject", $attrs);
551 $expLog->write(date(
"[y-m-d H:i:s] ").
"Start Export Page Objects");
552 $ilBench->start(
"ContentObjectExport",
"exportPageObjects");
554 $ilBench->stop(
"ContentObjectExport",
"exportPageObjects");
555 $expLog->write(date(
"[y-m-d H:i:s] ").
"Finished Export Page Objects");
558 $expLog->write(date(
"[y-m-d H:i:s] ").
"Start Export Media Objects");
559 $ilBench->start(
"ContentObjectExport",
"exportMediaObjects");
561 $ilBench->stop(
"ContentObjectExport",
"exportMediaObjects");
562 $expLog->write(date(
"[y-m-d H:i:s] ").
"Finished Export Media Objects");
565 $expLog->write(date(
"[y-m-d H:i:s] ").
"Start Export File Items");
566 $ilBench->start(
"ContentObjectExport",
"exportFileItems");
568 $ilBench->stop(
"ContentObjectExport",
"exportFileItems");
569 $expLog->write(date(
"[y-m-d H:i:s] ").
"Finished Export File Items");
571 $a_xml_writer->xmlEndTag(
"ContentObject");
582 include_once(
"Services/MetaData/classes/class.ilMD2XML.php");
584 $md2xml->setExportMode(
true);
585 $md2xml->startExport();
586 $a_xml_writer->appendXML($md2xml->getXML());
591 if ($a_tag ==
"Identifier" && $a_param ==
"Entry")
593 include_once
"./Services/Utilities/classes/class.ilUtil.php";
611 include_once
"./Modules/LearningModule/classes/class.ilLMPageObject.php";
613 foreach ($questions as $question_id)
615 $ilBench->start(
"ContentObjectExport",
"exportPageObject");
616 $expLog->write(date(
"[y-m-d H:i:s] ").
"Page Object ".$question_id);
619 $a_xml_writer->xmlStartTag(
"PageObject", $attrs);
623 $ilBench->start(
"ContentObjectExport",
"exportPageObject_XML");
624 include_once(
"./Modules/TestQuestionPool/classes/class.ilAssQuestionPage.php");
626 $page_object->buildDom();
627 $page_object->insertInstIntoIDs($a_inst);
628 $mob_ids = $page_object->collectMediaObjects(
false);
629 require_once
'Services/COPage/classes/class.ilPCFileList.php';
631 $xml = $page_object->getXMLFromDom(
false,
false,
false,
"",
true);
632 $xml = str_replace(
"&",
"&", $xml);
633 $a_xml_writer->appendXML($xml);
634 $page_object->freeDom();
635 unset ($page_object);
637 $ilBench->stop(
"ContentObjectExport",
"exportPageObject_XML");
640 $ilBench->start(
"ContentObjectExport",
"exportPageObject_CollectMedia");
642 foreach($mob_ids as $mob_id)
644 $this->mob_ids[$mob_id] = $mob_id;
646 $ilBench->stop(
"ContentObjectExport",
"exportPageObject_CollectMedia");
649 $ilBench->start(
"ContentObjectExport",
"exportPageObject_CollectFileItems");
651 foreach($file_ids as $file_id)
653 $this->file_ids[$file_id] = $file_id;
655 $ilBench->stop(
"ContentObjectExport",
"exportPageObject_CollectFileItems");
657 $a_xml_writer->xmlEndTag(
"PageObject");
660 $ilBench->stop(
"ContentObjectExport",
"exportPageObject");
674 include_once(
"./Services/MediaObjects/classes/class.ilObjMediaObject.php");
676 foreach ($this->mob_ids as $mob_id)
678 $expLog->write(date(
"[y-m-d H:i:s] ").
"Media Object ".$mob_id);
682 $media_obj->exportXML($a_xml_writer, $a_inst);
683 $media_obj->exportFiles($a_target_dir);
695 include_once(
"./Modules/File/classes/class.ilObjFile.php");
697 foreach ($this->file_ids as $file_id)
699 $expLog->write(date(
"[y-m-d H:i:s] ").
"File Item ".$file_id);
700 $file_obj =
new ilObjFile($file_id,
false);
701 $file_obj->export($a_target_dir);
713 include_once
"./Services/Utilities/classes/class.ilUtil.php";
716 if(!is_writable($qpl_data_dir))
718 $this->ilias->raiseError(
"Questionpool Data Directory (".$qpl_data_dir
719 .
") not writeable.",$this->ilias->error_obj->FATAL);
723 $qpl_dir = $qpl_data_dir.
"/qpl_".$this->
getId();
725 if(!@is_dir($qpl_dir))
727 $this->ilias->raiseError(
"Creation of Questionpool Directory failed.",$this->ilias->error_obj->FATAL);
733 $this->ilias->raiseError(
"Creation of Export Directory failed.",$this->ilias->error_obj->FATAL);
738 $this->ilias->raiseError(
"Creation of Export Directory failed.",$this->ilias->error_obj->FATAL);
747 include_once
"./Services/Utilities/classes/class.ilUtil.php";
752 $export_dir =
ilUtil::getDataDir().
"/qpl_data".
"/qpl_".$this->getId().
"/export_$type";
770 include_once
"./Services/Utilities/classes/class.ilUtil.php";
774 if(!is_writable($qpl_data_dir))
776 $ilias->raiseError(
"Questionpool Data Directory (".$qpl_data_dir
777 .
") not writeable.",$ilias->error_obj->FATAL);
781 $qpl_dir = $qpl_data_dir.
"/qpl_import";
783 if(!@is_dir($qpl_dir))
785 $ilias->raiseError(
"Creation of Questionpool Directory failed.",$ilias->error_obj->FATAL);
795 if (strlen($a_import_dir))
797 $_SESSION[
"qpl_import_dir"] = $a_import_dir;
831 $result = $ilDB->queryF(
"SELECT question_id FROM qpl_questions WHERE obj_fi = %s AND qpl_questions.tstamp > 0 AND original_id IS NULL",
833 array($this->
getId())
835 $questions = array();
838 array_push($questions,
$row[
"question_id"]);
847 $query_result = $ilDB->queryF(
"SELECT question_id, qpl_qst_type.type_tag, qpl_qst_type.plugin FROM qpl_questions, qpl_qst_type WHERE original_id IS NULL AND qpl_questions.tstamp > 0 AND obj_fi = %s AND complete = %s AND qpl_questions.question_type_fi = qpl_qst_type.question_type_id",
848 array(
'integer',
'text'),
849 array($this->
getId(), 1)
851 $questions = array();
852 if ($query_result->numRows())
854 while (
$row = $ilDB->fetchAssoc($query_result))
860 array_push($questions,
$row[
"question_id"]);
865 array_push($questions,
$row[
"question_id"]);
878 if (!is_array($this->import_mapping))
884 return $this->import_mapping;
899 if (count($questions) > 0)
901 foreach ($questions as $key => $value)
904 $xml .= $question->object->toXML();
906 if (count($questions) > 1)
908 $xml = preg_replace(
"/<\/questestinterop>\s*<.xml.*?>\s*<questestinterop>/",
"", $xml);
911 $xml = preg_replace(
"/(<\?xml[^>]*?>)/",
"\\1" .
"<!DOCTYPE questestinterop SYSTEM \"ims_qtiasiv1p2p1.dtd\">", $xml);
926 if ($complete_questions_only)
928 $result = $ilDB->queryF(
"SELECT COUNT(question_id) question_count FROM qpl_questions WHERE obj_fi = %s AND qpl_questions.tstamp > 0 AND original_id IS NULL AND complete = %s",
929 array(
'integer',
'text'),
930 array($questionpool_id, 1)
935 $result = $ilDB->queryF(
"SELECT COUNT(question_id) question_count FROM qpl_questions WHERE obj_fi = %s AND qpl_questions.tstamp > 0 AND original_id IS NULL",
937 array($questionpool_id)
941 return $row[
"question_count"];
953 switch ($a_online_status)
957 $this->online = $a_online_status;
967 if (strcmp($this->online,
"") == 0) $this->online =
"0";
1002 $result = $ilDB->queryF(
"SELECT qpl_questionpool.isonline FROM qpl_questionpool,object_reference WHERE object_reference.ref_id = %s AND object_reference.obj_id = qpl_questionpool.obj_fi",
1009 $result = $ilDB->queryF(
"SELECT isonline FROM qpl_questionpool WHERE obj_fi = %s",
1017 return $row[
"isonline"];
1034 $result = $ilDB->queryF(
"SELECT count(DISTINCT qpl_questions.points) equal_points FROM qpl_questions, object_reference WHERE object_reference.ref_id = %s AND qpl_questions.tstamp > 0 AND object_reference.obj_id = qpl_questions.obj_fi AND qpl_questions.original_id IS NULL",
1041 $result = $ilDB->queryF(
"SELECT count(DISTINCT points) equal_points FROM qpl_questions WHERE obj_fi = %s AND qpl_questions.tstamp > 0 AND qpl_questions.original_id IS NULL",
1049 if (
$row[
"equal_points"] == 1)
1071 if (array_key_exists(
"qpl_clipboard",
$_SESSION))
1074 foreach (
$_SESSION[
"qpl_clipboard"] as $question_object)
1076 if (strcmp($question_object[
"action"],
"move") == 0)
1078 $result = $ilDB->queryF(
"SELECT obj_fi FROM qpl_questions WHERE question_id = %s",
1080 array($question_object[
"question_id"])
1085 $source_questionpool =
$row[
"obj_fi"];
1087 $affectedRows = $ilDB->manipulateF(
"UPDATE qpl_questions SET obj_fi = %s WHERE question_id = %s",
1088 array(
'integer',
'integer'),
1089 array($this->
getId(), $question_object[
"question_id"])
1097 $source_path = CLIENT_WEB_DIR .
"/assessment/" . $source_questionpool .
"/" . $question_object[
"question_id"] .
"/";
1098 if (@is_dir($source_path))
1100 $target_path = CLIENT_WEB_DIR .
"/assessment/" . $this->
getId() .
"/";
1101 if (!@is_dir($target_path))
1103 include_once
"./Services/Utilities/classes/class.ilUtil.php";
1106 @rename($source_path, $target_path . $question_object[
"question_id"]);
1114 $new_question_id = $this->
copyQuestion($question_object[
"question_id"], $this->
getId());
1115 if(!$new_question_id)
1137 if (!array_key_exists(
"qpl_clipboard",
$_SESSION))
1141 $_SESSION[
"qpl_clipboard"][$question_id] = array(
"question_id" => $question_id,
"action" =>
"copy");
1152 if (!array_key_exists(
"qpl_clipboard",
$_SESSION))
1156 $_SESSION[
"qpl_clipboard"][$question_id] = array(
"question_id" => $question_id,
"action" =>
"move");
1161 if( !isset(
$_SESSION[
'qpl_clipboard']) )
1166 if( !isset(
$_SESSION[
'qpl_clipboard'][$deletedQuestionId]) )
1171 unset(
$_SESSION[
'qpl_clipboard'][$deletedQuestionId]);
1173 if( !count(
$_SESSION[
'qpl_clipboard']) )
1190 include_once
"./Services/Object/classes/class.ilObject.php";
1217 $query_result = $ilDB->query(
"SELECT qpl_questions.*, qpl_qst_type.type_tag FROM qpl_questions, qpl_qst_type WHERE qpl_questions.question_type_fi = qpl_qst_type.question_type_id AND " . $ilDB->in(
'qpl_questions.question_id', $question_ids,
false,
'integer') .
" ORDER BY qpl_questions.title");
1218 if ($query_result->numRows())
1220 while (
$row = $ilDB->fetchAssoc($query_result))
1241 $query_result = $ilDB->query(
"SELECT qpl_questions.*, qpl_qst_type.type_tag FROM qpl_questions, qpl_qst_type WHERE qpl_questions.question_type_fi = qpl_qst_type.question_type_id AND " . $ilDB->in(
'qpl_questions.question_id', $question_ids,
false,
'integer') .
" ORDER BY qpl_questions.title");
1242 if ($query_result->numRows())
1244 include_once
"./Modules/TestQuestionPool/classes/class.assQuestion.php";
1245 while (
$row = $ilDB->fetchAssoc($query_result))
1260 $duplicate_id = $question->object->duplicate(
true);
1261 if ($duplicate_id > 0)
1264 $affectedRows = $ilDB->manipulateF(
"UPDATE tst_solutions SET question_fi = %s WHERE question_fi = %s",
1265 array(
'integer',
'integer'),
1266 array($duplicate_id,
$row[
"question_id"])
1270 $affectedRows = $ilDB->manipulateF(
"UPDATE tst_test_rnd_qst SET question_fi = %s WHERE question_fi = %s",
1271 array(
'integer',
'integer'),
1272 array($duplicate_id,
$row[
"question_id"])
1276 $affectedRows = $ilDB->manipulateF(
"UPDATE tst_test_result SET question_fi = %s WHERE question_fi = %s",
1277 array(
'integer',
'integer'),
1278 array($duplicate_id,
$row[
"question_id"])
1282 $affectedRows = $ilDB->manipulateF(
"UPDATE ass_log SET question_fi = %s WHERE question_fi = %s",
1283 array(
'integer',
'integer'),
1284 array($duplicate_id,
$row[
"question_id"])
1308 foreach (
$path as $item)
1310 if (($counter > 0) && ($counter < count(
$path)-1))
1312 array_push($items, $item[
"title"]);
1316 $fullpath = join(
" > ", $items);
1317 include_once
"./Services/Utilities/classes/class.ilStr.php";
1318 if (strlen($fullpath) > 60)
1331 function &
_getAvailableQuestionpools($use_object_id = FALSE, $equal_points = FALSE, $could_be_offline = FALSE, $showPath = FALSE, $with_questioncount = FALSE, $permission =
"read", $usr_id =
"")
1335 $result_array = array();
1336 $permission = (strlen($permission) == 0) ?
"read" : $permission;
1345 if (count($obj_ids))
1347 $in = $ilDB->in(
'object_data.obj_id', $obj_ids,
false,
'integer');
1348 if ($could_be_offline)
1350 $result = $ilDB->query(
"SELECT qpl_questionpool.*, object_data.title FROM qpl_questionpool, object_data WHERE ".
1351 "qpl_questionpool.obj_fi = object_data.obj_id AND $in ORDER BY object_data.title");
1355 $result = $ilDB->queryF(
"SELECT qpl_questionpool.*, object_data.title FROM qpl_questionpool, object_data WHERE ".
1356 "qpl_questionpool.obj_fi = object_data.obj_id AND $in AND qpl_questionpool.isonline = %s ".
1357 "ORDER BY object_data.title",
1374 $ref_id = array_search(
$row[
"obj_fi"], $obj_ids);
1375 $title = (($showPath) ? $titles[$ref_id] :
$row[
"title"]);
1376 if ($with_questioncount)
1378 $title .=
" [" . $row[
"questioncount"] .
" " . ($row[
"questioncount"] == 1 ? $lng->txt(
"ass_question") : $lng->txt(
"assQuestions")) .
"]";
1383 $result_array[$row[
"obj_fi"]] = array(
1384 'qpl_id' => $row[
'obj_fi'],
1385 'qpl_title' => $row[
'title'],
1387 "count" => $row[
"questioncount"]
1392 $result_array[
$ref_id] = array(
1393 'qpl_id' => $row[
'obj_fi'],
1394 'qpl_title' => $row[
'title'],
1396 "count" => $row[
"questioncount"]
1402 return $result_array;
1409 $questions = array();
1410 $result = $ilDB->queryF(
"SELECT qpl_questions.question_id FROM qpl_questions WHERE qpl_questions.original_id IS NULL AND qpl_questions.tstamp > 0 AND qpl_questions.obj_fi = %s",
1412 array($this->
getId())
1416 array_push($questions,
$row[
"question_id"]);
1435 if(!$cp_options->isRootNode($this->getRefId()))
1441 $newObj->saveToDb();
1445 $questionIdsMap = array();
1446 foreach ($questions as $question_id)
1448 $newQuestionId = $newObj->copyQuestion($question_id, $newObj->getId());
1449 $questionIdsMap[$question_id] = $newQuestionId;
1453 include_once
"./Services/MetaData/classes/class.ilMD.php";
1455 $new_md =& $md->cloneMD($newObj->getId(),0,$newObj->getType());
1458 $newObj->updateMetaData();
1460 require_once
'Modules/TestQuestionPool/classes/class.ilQuestionPoolTaxonomiesDuplicator.php';
1462 $duplicator->setSourceObjId($this->
getId());
1463 $duplicator->setSourceObjType($this->
getType());
1464 $duplicator->setTargetObjId($newObj->getId());
1465 $duplicator->setTargetObjType($newObj->getType());
1466 $duplicator->setQuestionIdMapping($questionIdsMap);
1467 $duplicator->duplicate();
1469 $duplicatedTaxKeyMap = $duplicator->getDuplicatedTaxonomiesKeysMap();
1470 $newObj->setNavTaxonomyId($duplicatedTaxKeyMap->getMappedTaxonomyId($this->getNavTaxonomyId()));
1471 $newObj->saveToDb();
1486 include_once
"./Modules/Test/classes/class.ilObjAssessmentFolder.php";
1488 $lng->loadLanguageModule(
"assessment");
1489 $result = $ilDB->query(
"SELECT * FROM qpl_qst_type");
1493 if ($all_tags || (!in_array(
$row[
"question_type_id"], $forbidden_types)))
1497 if (
$row[
"plugin"] == 0)
1499 $types[$lng->txt(
$row[
"type_tag"])] =
$row;
1503 global $ilPluginAdmin;
1504 $pl_names = $ilPluginAdmin->getActivePluginsForSlot(
IL_COMP_MODULE,
"TestQuestionPool",
"qst");
1505 foreach ($pl_names as $pl_name)
1508 if (strcmp($pl->getQuestionType(),
$row[
"type_tag"]) == 0)
1510 $types[$pl->getQuestionTypeTranslation()] =
$row;
1517 require_once
'Modules/TestQuestionPool/classes/class.ilAssQuestionTypeOrderer.php';
1520 $types = $orderer->getOrderedTypes();
1527 $query =
"SELECT type_tag FROM qpl_qst_type WHERE question_type_id = %s";
1528 $types = array(
'integer');
1529 $values = array($type_id);
1532 return $row[
'type_tag'];
1541 global $ilPluginAdmin;
1543 $lng->loadLanguageModule(
"assessment");
1544 $result = $ilDB->query(
"SELECT * FROM qpl_qst_type");
1548 if (
$row[
"plugin"] == 0)
1550 $types[
$row[
'type_tag']] = $lng->txt($row[
"type_tag"]);
1554 $pl_names = $ilPluginAdmin->getActivePluginsForSlot(
IL_COMP_MODULE,
"TestQuestionPool",
"qst");
1555 foreach ($pl_names as $pl_name)
1558 if (strcmp($pl->getQuestionType(),
$row[
"type_tag"]) == 0)
1560 $types[
$row[
'type_tag']] = $pl->getQuestionTypeTranslation();
1588 $allowed_types = array(
1589 "assSingleChoice" => 1,
1590 "assMultipleChoice" => 2,
1591 "assKprimChoice" => 3,
1592 "assClozeTest" => 4,
1593 "assMatchingQuestion" => 5,
1594 "assOrderingQuestion" => 6,
1595 "assOrderingHorizontal" => 7,
1596 "assImagemapQuestion" => 8,
1597 "assTextSubset" => 9,
1598 "assErrorText" => 10
1602 foreach($qtypes as $k =>
$t)
1605 if (isset($allowed_types[
$t[
"type_tag"]]))
1607 $t[
"order"] = $allowed_types[$t[
"type_tag"]];
1619 $questions = array();
1620 $result = $ilDB->queryF(
"SELECT qpl_questions.*, qpl_qst_type.* FROM qpl_questions, qpl_qst_type WHERE qpl_questions.original_id IS NULL AND qpl_questions.obj_fi = %s AND qpl_questions.tstamp > 0 AND qpl_questions.question_type_fi = qpl_qst_type.question_type_id",
1622 array($this->
getId())
1626 array_push($questions,
$row);
1640 $result = $ilDB->manipulateF(
"UPDATE qpl_questionpool SET questioncount = %s, tstamp = %s WHERE obj_fi = %s",
1641 array(
'integer',
'integer',
'integer'),
1654 global $ilPluginAdmin;
1655 if ($ilPluginAdmin->isActive(
IL_COMP_MODULE,
"TestQuestionPool",
"qst", $a_pname))
1672 require_once
'Modules/TestQuestionPool/classes/class.ilAssIncompleteQuestionPurger.php';
1674 $incompleteQuestionPurger->setOwnerId($ilUser->getId());
1675 $incompleteQuestionPurger->purge();
1685 require_once
'Services/Taxonomy/classes/class.ilObjTaxonomy.php';