ILIAS  Release_4_4_x_branch Revision 61816
 All Data Structures Namespaces Files Functions Variables Groups Pages
ilSurveySkillThresholdsGUI Class Reference

Survey skill thresholds GUI class. More...

+ Collaboration diagram for ilSurveySkillThresholdsGUI:

Public Member Functions

 __construct (ilObjSurvey $a_survey)
 Constructor.
 executeCommand ()
 Execute command.
 listCompetences ()
 List competences.
 listSkillThresholds ()
 List skill thresholds.
 selectSkill ()
 Select skill.
 saveThresholds ()
 Save Thresholds.

Detailed Description

Survey skill thresholds GUI class.

Author
Alex Killing alex..nosp@m.kill.nosp@m.ing@g.nosp@m.mx.d.nosp@m.e
Version
$Id$ ilSurveySkillThresholdsGUI:

Definition at line 13 of file class.ilSurveySkillThresholdsGUI.php.

Constructor & Destructor Documentation

ilSurveySkillThresholdsGUI::__construct ( ilObjSurvey  $a_survey)

Constructor.

Parameters
object$a_survey

Definition at line 20 of file class.ilSurveySkillThresholdsGUI.php.

{
$this->survey = $a_survey;
}

Member Function Documentation

ilSurveySkillThresholdsGUI::executeCommand ( )

Execute command.

Definition at line 28 of file class.ilSurveySkillThresholdsGUI.php.

References $cmd, and $ilCtrl.

{
global $ilCtrl;
$cmd = $ilCtrl->getCmd();
$ilCtrl->saveParameter($this, array("sk_id", "tref_id"));
if (in_array($cmd, array("listCompetences", "listSkillThresholds", "selectSkill",
"saveThresholds")))
{
$this->$cmd();
}
}
ilSurveySkillThresholdsGUI::listCompetences ( )

List competences.

Parameters
@return

Definition at line 49 of file class.ilSurveySkillThresholdsGUI.php.

References $tab, and $tpl.

{
global $tpl;
include_once("./Modules/Survey/classes/class.ilSurveySkillTableGUI.php");
$tab = new ilSurveySkillTableGUI($this, "listCompetences", $this->survey);
$tpl->setContent($tab->getHTML());
}
ilSurveySkillThresholdsGUI::listSkillThresholds ( )

List skill thresholds.

Definition at line 62 of file class.ilSurveySkillThresholdsGUI.php.

References $_GET, $ilCtrl, $lng, $tab, and $tpl.

{
global $tpl, $ilToolbar, $lng, $ilCtrl, $ilTabs;
$ilTabs->clearTargets();
$ilTabs->setBackTarget($lng->txt("svy_back"),
$ilCtrl->getLinkTarget($this, "listCompetences"));
include_once("./Modules/Survey/classes/class.ilSurveySkillThresholdsTableGUI.php");
$tab = new ilSurveySkillThresholdsTableGUI($this, "listSkillThresholds",
$this->survey, (int) $_GET["sk_id"], (int) $_GET["tref_id"]);
$tpl->setContent($tab->getHTML());
}
ilSurveySkillThresholdsGUI::saveThresholds ( )

Save Thresholds.

Parameters
@return

Definition at line 98 of file class.ilSurveySkillThresholdsGUI.php.

References $_GET, $_POST, $ilCtrl, $lng, $t, and ilUtil\sendSuccess().

{
global $ilCtrl, $lng;
include_once("./Modules/Survey/classes/class.ilSurveySkillThresholds.php");
$thres = new ilSurveySkillThresholds($this->survey);
if (is_array($_POST["threshold"]))
{
foreach ($_POST["threshold"] as $l => $t)
{
$thres->writeThreshold((int) $_GET["sk_id"],
(int) $_GET["tref_id"], (int) $l, (int) $t);
}
ilUtil::sendSuccess($lng->txt("msg_obj_modified"));
}
$ilCtrl->redirect($this, "listSkillThresholds");
}

+ Here is the call graph for this function:

ilSurveySkillThresholdsGUI::selectSkill ( )

Select skill.

Parameters
@return

Definition at line 82 of file class.ilSurveySkillThresholdsGUI.php.

References $_POST, and $ilCtrl.

{
global $ilCtrl;
$o = explode(":", $_POST["skill"]);
$ilCtrl->setParameter($this, "sk_id", (int) $o[0]);
$ilCtrl->setParameter($this, "tref_id", (int) $o[1]);
$ilCtrl->redirect($this, "listSkillThresholds");
}

The documentation for this class was generated from the following file: