当前位置: 首页>>代码示例>>PHP>>正文


PHP ilLMObject::_getAllLMObjectsOfLM方法代码示例

本文整理汇总了PHP中ilLMObject::_getAllLMObjectsOfLM方法的典型用法代码示例。如果您正苦于以下问题:PHP ilLMObject::_getAllLMObjectsOfLM方法的具体用法?PHP ilLMObject::_getAllLMObjectsOfLM怎么用?PHP ilLMObject::_getAllLMObjectsOfLM使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在ilLMObject的用法示例。


在下文中一共展示了ilLMObject::_getAllLMObjectsOfLM方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: __construct

 /**
  * Constructor
  *
  * @param object $a_parent_obj parent gui object
  * @param string $a_parent_cmd parent cmd
  * @param ilLMPresentationGUI $a_lm_pres learning module presentation gui object
  * @param string $a_lang language
  */
 function __construct($a_parent_obj, $a_parent_cmd, ilLMPresentationGUI $a_lm_pres, $a_lang = "-")
 {
     parent::__construct($a_parent_obj, $a_parent_cmd, $a_lm_pres, $a_lang);
     include_once "./Modules/LearningModule/classes/class.ilLMObject.php";
     $chaps = ilLMObject::_getAllLMObjectsOfLM($this->lm->getId(), $a_type = "st");
     foreach ($chaps as $c) {
         $this->setNodeOpen($c);
     }
 }
开发者ID:arlendotcn,项目名称:ilias,代码行数:17,代码来源:class.ilLMTableOfContentsExplorerGUI.php

示例2: loadLMTrackingData

 /**
  * Load LM tracking data. Loaded when needed.
  *
  * @param
  * @return
  */
 protected function loadLMTrackingData()
 {
     global $ilDB;
     // we must prevent loading tracking data multiple times during a request where possible
     // please note that the dirty flag works only to a certain limit
     // e.g. if questions are answered the flag is not set (yet)
     // or if pages/chapter are added/deleted the flag is not set
     if ($this->loaded_for_node === (int) $this->getCurrentPage() && !$this->dirty) {
         return;
     }
     $this->loaded_for_node = (int) $this->getCurrentPage();
     $this->dirty = false;
     // load lm tree in array
     $this->tree_arr = array();
     $nodes = $this->lm_tree->getSubTree($this->lm_tree->getNodeData($this->lm_tree->readRootId()));
     foreach ($nodes as $node) {
         $this->tree_arr["childs"][$node["parent"]][] = $node;
         $this->tree_arr["parent"][$node["child"]] = $node["parent"];
         $this->tree_arr["nodes"][$node["child"]] = $node;
     }
     // load all lm obj ids of learning module
     include_once "./Modules/LearningModule/classes/class.ilLMObject.php";
     $this->lm_obj_ids = ilLMObject::_getAllLMObjectsOfLM($this->lm_obj_id);
     // load read event data
     $this->re_arr = array();
     $set = $ilDB->query("SELECT * FROM lm_read_event " . " WHERE " . $ilDB->in("obj_id", $this->lm_obj_ids, false, "integer"));
     while ($rec = $ilDB->fetchAssoc($set)) {
         $this->re_arr[$rec["obj_id"]] = $rec;
     }
     // load question/pages information
     $this->page_questions = array();
     $this->all_questions = array();
     include_once "./Modules/LearningModule/classes/class.ilLMPageObject.php";
     $q = ilLMPageObject::queryQuestionsOfLearningModule($this->lm_obj_id, "", "", 0, 0);
     foreach ($q["set"] as $quest) {
         $this->page_questions[$quest["page_id"]][] = $quest["question_id"];
         $this->all_questions[] = $quest["question_id"];
     }
     // load question answer information
     include_once "./Services/COPage/classes/class.ilPageQuestionProcessor.php";
     $this->answer_status = ilPageQuestionProcessor::getAnswerStatus($this->all_questions, $this->user_id);
     $this->has_incorrect_answers = false;
     $has_pred_incorrect_answers = false;
     $has_pred_incorrect_not_unlocked_answers = false;
     $this->determineProgressStatus($this->lm_tree->readRootId(), $has_pred_incorrect_answers, $has_pred_incorrect_not_unlocked_answers);
     $this->has_incorrect_answers = $has_pred_incorrect_answers;
 }
开发者ID:bheyser,项目名称:qplskl,代码行数:53,代码来源:class.ilLMTracker.php


注:本文中的ilLMObject::_getAllLMObjectsOfLM方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。