ILIAS  release_7 Revision v7.30-3-g800a261c036
class.ilStudyProgrammeIndividualPlanProgressListGUI.php
Go to the documentation of this file.
1<?php
2
3/* Copyright (c) 2015 Richard Klees <richard.klees@concepts-and-training.de> Extended GPL, see docs/LICENSE */
4
12require_once("Modules/StudyProgramme/classes/class.ilStudyProgrammeExpandableProgressListGUI.php");
13
15{
16 protected function showMyProgress()
17 {
18 // expand tree completely on start
19 return $this->progress->isRelevant();
20 }
21
23 {
24 return true;
25 }
26
27 public function newSubItem(ilStudyProgrammeProgress $a_progress)
28 {
30 }
31
32 protected function getTitleForItem(ilObjStudyProgramme $a_programme)
33 {
34 $title = $a_programme->getTitle();
35 if (!$this->progress->isRelevant()
37 ) {
38 return "<s>" . $title . "</s>";
39 }
40 return $title;
41 }
42
43 protected function buildProgressStatus(ilStudyProgrammeProgress $a_progress)
44 {
45 $programme = ilObjStudyProgramme::getInstanceByObjId($a_progress->getNodeId());
46 $can_be_completed = $programme->canBeCompleted($a_progress);
47
48 $points = parent::buildProgressStatus($a_progress);
49 if (!$can_be_completed && !$a_progress->isSuccessful()) {
50 return "<img src='" . ilUtil::getImagePath("icon_alert.svg") . "' alt='" . $this->il_lng->txt("warning") . "'>" . $points;
51 } else {
52 return $points;
53 }
54 }
55
56 protected function configureItemGUI(ilStudyProgrammeCourseListGUI $a_item_gui)
57 {
58 $a_item_gui->enableComments(false);
59 $a_item_gui->enableTags(false);
60 $a_item_gui->enableIcon(true);
61 $a_item_gui->enableDelete(false);
62 $a_item_gui->enableCut(false);
63 $a_item_gui->enableCopy(false);
64 $a_item_gui->enableLink(false);
65 $a_item_gui->enableInfoScreen(false);
66 $a_item_gui->enableSubscribe(false);
67 $a_item_gui->enableCheckbox(false);
68 $a_item_gui->enableDescription(true);
69 $a_item_gui->enableProperties(false);
70 $a_item_gui->enablePreconditions(false);
71 $a_item_gui->enableNoticeProperties(false);
72 $a_item_gui->enableCommands(false, true);
73 $a_item_gui->enableProgressInfo(false);
74 $a_item_gui->setIndent($this->getIndent() + 2);
75 }
76}
An exception for terminatinating execution or to throw for unit testing.
enableDescription($a_status)
En/disable description.
enableCommands($a_status, $a_std_only=false)
En/disable commands.
enableProperties($a_status)
En/disable properties.
enableLink($a_status)
En/disable link.
enableCheckbox($a_status)
En/Dis-able checkboxes.
enableNoticeProperties($a_status)
En/disable notices.
enableIcon($a_status)
En/Dis-able icons.
enableCopy($a_status)
En/disable copy.
enablePreconditions($a_status)
En/disable preconditions.
enableTags($a_value)
Toogle tags action status.
enableCut($a_status)
En/disable cut.
enableProgressInfo($a_status)
enable progress info
enableSubscribe($a_status)
En/disable subscribe.
enableComments($a_value, $a_enable_comments_settings=true)
Toogle comments action status.
enableInfoScreen($a_info_screen)
En/disable path.
enableDelete($a_status)
En/disable delete.
getTitle()
get object title @access public
Class ilStudyProgrammeCourseListGUI.
Class ilStudyProgrammeProgress.
getNodeId()
Get the obj_id of the program node this progress belongs to.
static getImagePath($img, $module_path="", $mode="output", $offline=false)
get image path (for images located in a template directory)