ILIAS  release_5-3 Revision v5.3.23-19-g915713cf615
ilSurveyParticipantsGUI Class Reference

Class ilSurveyParticipantsGUI. More...

+ Collaboration diagram for ilSurveyParticipantsGUI:

Public Member Functions

 __construct (ilObjSurveyGUI $a_parent_gui, $a_has_write_access)
 
 executeCommand ()
 
 maintenanceObject ()
 Participants maintenance. More...
 
 setCodesSubtabs ()
 Set the tabs for the access codes section. More...
 
 disinviteUserGroupObject ()
 Disinvite users or groups from a survey. More...
 
 inviteUserGroupObject ($a_user_ids=array())
 Invite users or groups to a survey. More...
 
 saveInvitationStatusObject ()
 Saves the status of the invitation tab. More...
 
 inviteObject ()
 Creates the output for user/group invitation to a survey. More...
 
 deleteAllUserDataObject ()
 Creates a confirmation form for delete all user data. More...
 
 confirmDeleteAllUserDataObject ()
 Deletes all user data of the survey after confirmation. More...
 
 cancelDeleteAllUserDataObject ()
 Cancels delete of all user data in maintenance. More...
 
 confirmDeleteSelectedUserDataObject ()
 Deletes all user data for the test object. More...
 
 cancelDeleteSelectedUserDataObject ()
 Cancels the deletion of all user data for the test object. More...
 
 deleteSingleUserResultsObject ()
 Asks for a confirmation to delete selected user data of the test object. More...
 
 setCodeLanguageObject ()
 Change survey language for direct access URL's. More...
 
 codesObject ()
 Display the survey access codes tab. More...
 
 editCodesObject ()
 
 updateCodesObject ()
 
 deleteCodesConfirmObject ()
 
 deleteCodesObject ()
 Delete a list of survey codes. More...
 
 exportCodesObject ()
 Exports a list of survey codes. More...
 
 exportAllCodesObject ()
 Exports all survey codes. More...
 
 createSurveyCodesObject ()
 Create access codes for the survey. More...
 
 insertSavedMessageObject ()
 
 deleteSavedMessageObject ()
 
 mailCodesObject ()
 
 sendCodesMailObject ()
 
 importExternalRecipientsFromTextObject ()
 
 importExternalRecipientsFromFileObject ()
 
 importExternalMailRecipientsFromFileFormObject ()
 
 importExternalMailRecipientsFromTextFormObject ()
 
 listAppraiseesObject ()
 
 addAppraisee ($a_user_ids)
 
 confirmDeleteAppraiseesObject ()
 
 deleteAppraiseesObject ()
 
 handleRatersAccess ()
 
 editRatersObject ()
 
 addExternalRaterFormObject (ilPropertyFormGUI $a_form=null)
 
 addExternalRaterObject ()
 
 addRater ($a_user_ids)
 
 confirmDeleteRatersObject ()
 
 deleteRatersObject ()
 
 addSelfAppraiseeObject ()
 
 initMailRatersForm ($appr_id, array $rec_ids)
 
 mailRatersObject (ilPropertyFormGUI $a_form=null)
 
 mailRatersActionObject ()
 
 confirmAppraiseeCloseObject ()
 
 confirmAppraiseeCloseCancelObject ()
 
 appraiseeCloseObject ()
 
 confirmAdminAppraiseesCloseObject ()
 
 adminAppraiseesCloseObject ()
 
 getObject ()
 

Protected Member Functions

 handleWriteAccess ()
 
 isAnonymousListActive ()
 
 importAccessCodesObject ()
 Import codes from export codes file (upload form) More...
 
 importAccessCodesActionObject ()
 Import codes from export codes file. More...
 
 _convertCharset ($a_string, $a_from_charset="", $a_to_charset="UTF-8")
 
 removeUTF8Bom ($a_text)
 
 initExternalRaterForm ($appr_id)
 
 listParticipantsObject ()
 

Protected Attributes

 $ctrl
 
 $lng
 
 $tpl
 
 $tabs
 
 $toolbar
 
 $access
 
 $rbacsystem
 
 $user
 
 $log
 
 $parent_gui
 
 $object
 
 $ref_id
 
 $has_write
 

Detailed Description

Constructor & Destructor Documentation

◆ __construct()

ilSurveyParticipantsGUI::__construct ( ilObjSurveyGUI  $a_parent_gui,
  $a_has_write_access 
)

Definition at line 66 of file class.ilSurveyParticipantsGUI.php.

References $DIC, $ilCtrl, $lng, $tpl, and user().

67  {
68  global $DIC;
69 
70  $this->tabs = $DIC->tabs();
71  $this->toolbar = $DIC->toolbar();
72  $this->access = $DIC->access();
73  $this->rbacsystem = $DIC->rbac()->system();
74  $this->user = $DIC->user();
75  $this->log = $DIC["ilLog"];
76  $ilCtrl = $DIC->ctrl();
77  $lng = $DIC->language();
78  $tpl = $DIC["tpl"];
79 
80  $this->parent_gui = $a_parent_gui;
81  $this->object = $this->parent_gui->object;
82  $this->ref_id = $this->object->getRefId();
83  $this->has_write = (bool) $a_has_write_access;
84 
85  $this->ctrl = $ilCtrl;
86  $this->lng = $lng;
87  $this->tpl = $tpl;
88  }
global $DIC
Definition: saml.php:7
user()
Definition: user.php:4
global $ilCtrl
Definition: ilias.php:18
+ Here is the call graph for this function:

Member Function Documentation

◆ _convertCharset()

ilSurveyParticipantsGUI::_convertCharset (   $a_string,
  $a_from_charset = "",
  $a_to_charset = "UTF-8" 
)
protected

Definition at line 980 of file class.ilSurveyParticipantsGUI.php.

Referenced by importExternalRecipientsFromFileObject().

981  {
982  if (extension_loaded("mbstring")) {
983  if (!$a_from_charset) {
984  mb_detect_order("UTF-8, ISO-8859-1, Windows-1252, ASCII");
985  $a_from_charset = mb_detect_encoding($a_string);
986  }
987  if (strtoupper($a_from_charset) != $a_to_charset) {
988  return @mb_convert_encoding($a_string, $a_to_charset, $a_from_charset);
989  }
990  }
991  return $a_string;
992  }
+ Here is the caller graph for this function:

◆ addAppraisee()

ilSurveyParticipantsGUI::addAppraisee (   $a_user_ids)

Definition at line 1195 of file class.ilSurveyParticipantsGUI.php.

References ilUtil\sendSuccess().

1196  {
1197  if (sizeof($a_user_ids)) {
1198  // #13319
1199  foreach (array_unique($a_user_ids) as $user_id) {
1200  $this->object->addAppraisee($user_id);
1201  }
1202 
1203  ilUtil::sendSuccess($this->lng->txt("settings_saved"), true);
1204  }
1205  $this->ctrl->redirect($this, "listAppraisees");
1206  }
static sendSuccess($a_info="", $a_keep=false)
Send Success Message to Screen.
+ Here is the call graph for this function:

◆ addExternalRaterFormObject()

ilSurveyParticipantsGUI::addExternalRaterFormObject ( ilPropertyFormGUI  $a_form = null)

Definition at line 1339 of file class.ilSurveyParticipantsGUI.php.

References $access, $has_write, $tabs, handleRatersAccess(), and initExternalRaterForm().

Referenced by addExternalRaterObject().

1340  {
1341  $ilTabs = $this->tabs;
1342  $ilAccess = $this->access;
1343 
1344  $appr_id = $this->handleRatersAccess();
1345  $this->ctrl->setParameter($this, "appr_id", $appr_id);
1346 
1347  $has_write = $ilAccess->checkAccess("write", "", $this->ref_id);
1348  if ($has_write) {
1349  $ilTabs->clearTargets();
1350  $ilTabs->setBackTarget(
1351  $this->lng->txt("btn_back"),
1352  $this->ctrl->getLinkTarget($this, "editRaters")
1353  );
1354  }
1355 
1356  if (!$a_form) {
1357  $a_form = $this->initExternalRaterForm($appr_id);
1358  }
1359 
1360  $this->tpl->setContent($a_form->getHTML());
1361  }
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ addExternalRaterObject()

ilSurveyParticipantsGUI::addExternalRaterObject ( )

Definition at line 1390 of file class.ilSurveyParticipantsGUI.php.

References $data, $form, addExternalRaterFormObject(), array, initExternalRaterForm(), and ilUtil\sendSuccess().

1391  {
1392  $appr_id = $_REQUEST["appr_id"];
1393  if (!$appr_id) {
1394  $this->ctrl->redirect($this, "listAppraisees");
1395  }
1396 
1397  $this->ctrl->setParameter($this, "appr_id", $appr_id);
1398 
1399  $form = $this->initExternalRaterForm($appr_id);
1400  if ($form->checkInput()) {
1401  $data = array(
1402  "email" => $form->getInput("email"),
1403  "lastname" => $form->getInput("lname"),
1404  "firstname" => $form->getInput("fname")
1405  );
1406  $anonymous_id = $this->object->createSurveyCodesForExternalData(array($data));
1407  $anonymous_id = array_pop($anonymous_id);
1408 
1409  $this->object->addRater($appr_id, 0, $anonymous_id);
1410 
1411  ilUtil::sendSuccess($this->lng->txt("settings_saved"), true);
1412  $this->ctrl->setParameter($this, "appr_id", $appr_id);
1413  $this->ctrl->redirect($this, "editRaters");
1414  }
1415 
1416  $form->setValuesByPost();
1418  }
static sendSuccess($a_info="", $a_keep=false)
Send Success Message to Screen.
addExternalRaterFormObject(ilPropertyFormGUI $a_form=null)
if(isset($_POST['submit'])) $form
Create styles array
The data for the language used.
+ Here is the call graph for this function:

◆ addRater()

ilSurveyParticipantsGUI::addRater (   $a_user_ids)

Definition at line 1420 of file class.ilSurveyParticipantsGUI.php.

References $access, $ilUser, $user, handleRatersAccess(), ilUtil\sendFailure(), and ilUtil\sendSuccess().

1421  {
1422  $ilAccess = $this->access;
1423  $ilUser = $this->user;
1424 
1425  $appr_id = $this->handleRatersAccess();
1426 
1427  if (sizeof($a_user_ids)) {
1428  // #13319
1429  foreach (array_unique($a_user_ids) as $user_id) {
1430  if ($ilAccess->checkAccess("write", "", $this->ref_id) ||
1431  $this->object->get360SelfEvaluation() ||
1432  $user_id != $ilUser->getId()) {
1433  if ($appr_id != $user_id) {
1434  $this->object->addRater($appr_id, $user_id);
1435  ilUtil::sendSuccess($this->lng->txt("settings_saved"), true);
1436  } else {
1437  ilUtil::sendFailure($this->lng->txt("svy_appraisses_cannot_be_raters"), true);
1438  }
1439  }
1440  }
1441  }
1442 
1443  $this->ctrl->setParameter($this, "appr_id", $appr_id);
1444  $this->ctrl->redirect($this, "editRaters");
1445  }
static sendSuccess($a_info="", $a_keep=false)
Send Success Message to Screen.
$ilUser
Definition: imgupload.php:18
static sendFailure($a_info="", $a_keep=false)
Send Failure Message to Screen.
+ Here is the call graph for this function:

◆ addSelfAppraiseeObject()

ilSurveyParticipantsGUI::addSelfAppraiseeObject ( )

Definition at line 1512 of file class.ilSurveyParticipantsGUI.php.

References $ilUser, $user, and object.

1513  {
1514  $ilUser = $this->user;
1515 
1516  if ($this->object->get360SelfAppraisee() &&
1517  !$this->object->isAppraisee($ilUser->getId())) {
1518  $this->object->addAppraisee($ilUser->getId());
1519  }
1520 
1521  $this->ctrl->redirect($this->parent_gui, "infoScreen");
1522  }
$ilUser
Definition: imgupload.php:18
Create new PHPExcel object
obj_idprivate

◆ adminAppraiseesCloseObject()

ilSurveyParticipantsGUI::adminAppraiseesCloseObject ( )

Definition at line 1763 of file class.ilSurveyParticipantsGUI.php.

References $_POST, handleWriteAccess(), ilUtil\sendFailure(), and ilUtil\sendSuccess().

1764  {
1765  $this->handleWriteAccess();
1766 
1767  $appr_ids = $_POST["appr_id"];
1768 
1769  if (!sizeof($appr_ids)) {
1770  ilUtil::sendFailure($this->lng->txt("select_one"), true);
1771  $this->ctrl->redirect($this, "listAppraisees");
1772  }
1773 
1774  $appr_data = $this->object->getAppraiseesData();
1775  foreach ($appr_ids as $appr_id) {
1776  if (isset($appr_data[$appr_id]) && !$appr_data[$appr_id]["closed"]) {
1777  $this->object->closeAppraisee($appr_id);
1778  }
1779  }
1780 
1781  ilUtil::sendSuccess($this->lng->txt("survey_360_appraisee_close_action_success_admin"), true);
1782  $this->ctrl->redirect($this, "listAppraisees");
1783  }
static sendSuccess($a_info="", $a_keep=false)
Send Success Message to Screen.
static sendFailure($a_info="", $a_keep=false)
Send Failure Message to Screen.
$_POST["username"]
+ Here is the call graph for this function:

◆ appraiseeCloseObject()

ilSurveyParticipantsGUI::appraiseeCloseObject ( )

Definition at line 1721 of file class.ilSurveyParticipantsGUI.php.

References $ilUser, $user, object, and ilUtil\sendSuccess().

1722  {
1723  $ilUser = $this->user;
1724 
1725  if (!$this->object->isAppraisee($ilUser->getId())) {
1726  $this->ctrl->redirect($this->parent_gui, "infoScreen");
1727  }
1728 
1729  $this->object->closeAppraisee($ilUser->getId());
1730  ilUtil::sendSuccess($this->lng->txt("survey_360_appraisee_close_action_success"), true);
1731  $this->ctrl->redirect($this->parent_gui, "infoScreen");
1732  }
static sendSuccess($a_info="", $a_keep=false)
Send Success Message to Screen.
$ilUser
Definition: imgupload.php:18
Create new PHPExcel object
obj_idprivate
+ Here is the call graph for this function:

◆ cancelDeleteAllUserDataObject()

ilSurveyParticipantsGUI::cancelDeleteAllUserDataObject ( )

Cancels delete of all user data in maintenance.

Definition at line 470 of file class.ilSurveyParticipantsGUI.php.

471  {
472  $this->ctrl->redirect($this, "maintenance");
473  }

◆ cancelDeleteSelectedUserDataObject()

ilSurveyParticipantsGUI::cancelDeleteSelectedUserDataObject ( )

Cancels the deletion of all user data for the test object.

Definition at line 488 of file class.ilSurveyParticipantsGUI.php.

References ilUtil\sendInfo().

489  {
490  ilUtil::sendInfo($this->lng->txt('msg_cancel'), true);
491  $this->ctrl->redirect($this, "maintenance");
492  }
static sendInfo($a_info="", $a_keep=false)
Send Info Message to Screen.
+ Here is the call graph for this function:

◆ codesObject()

ilSurveyParticipantsGUI::codesObject ( )

Display the survey access codes tab.

Definition at line 542 of file class.ilSurveyParticipantsGUI.php.

References $ilUser, $lang, $options, $si, $toolbar, $user, array, ilSubmitButton\getInstance(), handleWriteAccess(), object, ilUtil\sendInfo(), and setCodesSubtabs().

543  {
545  $ilToolbar = $this->toolbar;
546 
547  $this->handleWriteAccess();
548  $this->setCodesSubtabs();
549 
550  if ($this->object->isAccessibleWithoutCode()) {
551  return ilUtil::sendInfo($this->lng->txt("survey_codes_no_anonymization"));
552  }
553 
554  $default_lang = $ilUser->getPref("survey_code_language");
555 
556  // creation buttons
557  $ilToolbar->setFormAction($this->ctrl->getFormAction($this));
558 
559  include_once("./Services/Form/classes/class.ilTextInputGUI.php");
560  $si = new ilTextInputGUI($this->lng->txt("new_survey_codes"), "nrOfCodes");
561  $si->setValue(1);
562  $si->setSize(3);
563  $ilToolbar->addInputItem($si, true);
564 
565  include_once "Services/UIComponent/Button/classes/class.ilSubmitButton.php";
566 
567  $button = ilSubmitButton::getInstance();
568  $button->setCaption("create");
569  $button->setCommand("createSurveyCodes");
570  $ilToolbar->addButtonInstance($button);
571 
572  $ilToolbar->addSeparator();
573 
574  $button = ilSubmitButton::getInstance();
575  $button->setCaption("import_from_file");
576  $button->setCommand("importExternalMailRecipientsFromFileForm");
577  $ilToolbar->addButtonInstance($button);
578 
579  $button = ilSubmitButton::getInstance();
580  $button->setCaption("import_from_text");
581  $button->setCommand("importExternalMailRecipientsFromTextForm");
582  $ilToolbar->addButtonInstance($button);
583 
584  $ilToolbar->addSeparator();
585 
586  $button = ilSubmitButton::getInstance();
587  $button->setCaption("svy_import_codes");
588  $button->setCommand("importAccessCodes");
589  $ilToolbar->addButtonInstance($button);
590 
591  $ilToolbar->addSeparator();
592 
593  $languages = $this->lng->getInstalledLanguages();
594  $options = array();
595  $this->lng->loadLanguageModule("meta");
596  foreach ($languages as $lang) {
597  $options[$lang] = $this->lng->txt("meta_l_" . $lang);
598  }
599  include_once("./Services/Form/classes/class.ilSelectInputGUI.php");
600  $si = new ilSelectInputGUI($this->lng->txt("survey_codes_lang"), "lang");
601  $si->setOptions($options);
602  $si->setValue($default_lang);
603  $ilToolbar->addInputItem($si, true);
604 
605  $button = ilSubmitButton::getInstance();
606  $button->setCaption("set");
607  $button->setCommand("setCodeLanguage");
608  $ilToolbar->addButtonInstance($button);
609 
610  include_once "./Modules/Survey/classes/tables/class.ilSurveyCodesTableGUI.php";
611  $table_gui = new ilSurveyCodesTableGUI($this, 'codes');
612  $survey_codes = $this->object->getSurveyCodesTableData(null, $default_lang);
613  $table_gui->setData($survey_codes);
614  $this->tpl->setContent($table_gui->getHTML());
615  }
This class represents a selection list property in a property form.
static sendInfo($a_info="", $a_keep=false)
Send Info Message to Screen.
This class represents a text property in a property form.
$ilUser
Definition: imgupload.php:18
Create styles array
The data for the language used.
Create new PHPExcel object
obj_idprivate
setCodesSubtabs()
Set the tabs for the access codes section.
if(!isset($_REQUEST['ReturnTo'])) if(!isset($_REQUEST['AuthId'])) $options
Definition: as_login.php:20
+ Here is the call graph for this function:

◆ confirmAdminAppraiseesCloseObject()

ilSurveyParticipantsGUI::confirmAdminAppraiseesCloseObject ( )

Definition at line 1734 of file class.ilSurveyParticipantsGUI.php.

References $_POST, $tpl, ilUserUtil\getNamePresentation(), handleWriteAccess(), and ilUtil\sendFailure().

1735  {
1736  $tpl = $this->tpl;
1737 
1738  $this->handleWriteAccess();
1739 
1740  $appr_ids = $_POST["appr_id"];
1741 
1742  if (!sizeof($appr_ids)) {
1743  ilUtil::sendFailure($this->lng->txt("select_one"), true);
1744  $this->ctrl->redirect($this, "listAppraisees");
1745  }
1746 
1747  include_once("./Services/Utilities/classes/class.ilConfirmationGUI.php");
1748  $cgui = new ilConfirmationGUI();
1749  $cgui->setHeaderText($this->lng->txt("survey_360_sure_appraisee_close_admin"));
1750 
1751  $cgui->setFormAction($this->ctrl->getFormAction($this, "adminAppraiseesClose"));
1752  $cgui->setCancel($this->lng->txt("cancel"), "listAppraisees");
1753  $cgui->setConfirm($this->lng->txt("confirm"), "adminAppraiseesClose");
1754 
1755  include_once "Services/User/classes/class.ilUserUtil.php";
1756  foreach ($appr_ids as $appr_id) {
1757  $cgui->addItem("appr_id[]", $appr_id, ilUserUtil::getNamePresentation($appr_id));
1758  }
1759 
1760  $tpl->setContent($cgui->getHTML());
1761  }
static getNamePresentation( $a_user_id, $a_user_image=false, $a_profile_link=false, $a_profile_back_link="", $a_force_first_lastname=false, $a_omit_login=false, $a_sortable=true, $a_return_data_array=false, $a_ctrl_path="ilpublicuserprofilegui")
Default behaviour is:
static sendFailure($a_info="", $a_keep=false)
Send Failure Message to Screen.
$_POST["username"]
Confirmation screen class.
+ Here is the call graph for this function:

◆ confirmAppraiseeCloseCancelObject()

ilSurveyParticipantsGUI::confirmAppraiseeCloseCancelObject ( )

Definition at line 1716 of file class.ilSurveyParticipantsGUI.php.

1717  {
1718  $this->ctrl->redirect($this->parent_gui, "infoScreen");
1719  }

◆ confirmAppraiseeCloseObject()

ilSurveyParticipantsGUI::confirmAppraiseeCloseObject ( )

Definition at line 1689 of file class.ilSurveyParticipantsGUI.php.

References $ilUser, $tabs, $tpl, $user, and object.

1690  {
1691  $ilUser = $this->user;
1692  $tpl = $this->tpl;
1693  $ilTabs = $this->tabs;
1694 
1695  $ilTabs->clearTargets();
1696  $ilTabs->setBackTarget(
1697  $this->lng->txt("menuback"),
1698  $this->ctrl->getLinkTarget($this->parent_gui, "infoScreen")
1699  );
1700 
1701  if (!$this->object->isAppraisee($ilUser->getId())) {
1702  $this->ctrl->redirect($this->parent_gui, "infoScreen");
1703  }
1704 
1705  include_once("./Services/Utilities/classes/class.ilConfirmationGUI.php");
1706  $cgui = new ilConfirmationGUI();
1707  $cgui->setHeaderText($this->lng->txt("survey_360_sure_appraisee_close"));
1708 
1709  $cgui->setFormAction($this->ctrl->getFormAction($this, "appraiseeClose"));
1710  $cgui->setCancel($this->lng->txt("cancel"), "confirmAppraiseeCloseCancel");
1711  $cgui->setConfirm($this->lng->txt("confirm"), "appraiseeClose");
1712 
1713  $tpl->setContent($cgui->getHTML());
1714  }
$ilUser
Definition: imgupload.php:18
Create new PHPExcel object
obj_idprivate
Confirmation screen class.

◆ confirmDeleteAllUserDataObject()

ilSurveyParticipantsGUI::confirmDeleteAllUserDataObject ( )

Deletes all user data of the survey after confirmation.

Definition at line 454 of file class.ilSurveyParticipantsGUI.php.

References object, and ilUtil\sendSuccess().

455  {
456  $this->object->deleteAllUserData();
457 
458  // #11558 - re-open closed appraisees
459  if ($this->object->get360Mode()) {
460  $this->object->openAllAppraisees();
461  }
462 
463  ilUtil::sendSuccess($this->lng->txt("svy_all_user_data_deleted"), true);
464  $this->ctrl->redirect($this, "maintenance");
465  }
static sendSuccess($a_info="", $a_keep=false)
Send Success Message to Screen.
Create new PHPExcel object
obj_idprivate
+ Here is the call graph for this function:

◆ confirmDeleteAppraiseesObject()

ilSurveyParticipantsGUI::confirmDeleteAppraiseesObject ( )

Definition at line 1208 of file class.ilSurveyParticipantsGUI.php.

References $_POST, $data, $id, $tabs, ilUserUtil\getNamePresentation(), and ilUtil\sendFailure().

1209  {
1210  $ilTabs = $this->tabs;
1211 
1212  if (!sizeof($_POST["appr_id"])) {
1213  ilUtil::sendFailure($this->lng->txt("select_one"), true);
1214  $this->ctrl->redirect($this, "listAppraisees");
1215  }
1216 
1217  $ilTabs->clearTargets();
1218  $ilTabs->setBackTarget(
1219  $this->lng->txt("btn_back"),
1220  $this->ctrl->getLinkTarget($this, "listAppraisees")
1221  );
1222 
1223  include_once("./Services/Utilities/classes/class.ilConfirmationGUI.php");
1224  $cgui = new ilConfirmationGUI();
1225  $cgui->setHeaderText($this->lng->txt("survey_360_sure_delete_appraises"));
1226 
1227  $cgui->setFormAction($this->ctrl->getFormAction($this, "deleteAppraisees"));
1228  $cgui->setCancel($this->lng->txt("cancel"), "listAppraisees");
1229  $cgui->setConfirm($this->lng->txt("confirm"), "deleteAppraisees");
1230 
1231  $data = $this->object->getAppraiseesData();
1232 
1233  $count = 0;
1234  include_once "Services/User/classes/class.ilUserUtil.php";
1235  foreach ($_POST["appr_id"] as $id) {
1236  if (isset($data[$id]) && !$data[$id]["closed"]) {
1237  $cgui->addItem("appr_id[]", $id, ilUserUtil::getNamePresentation($id));
1238  $count++;
1239  }
1240  }
1241 
1242  if (!$count) {
1243  ilUtil::sendFailure($this->lng->txt("select_one"), true);
1244  $this->ctrl->redirect($this, "listAppraisees");
1245  }
1246 
1247  $this->tpl->setContent($cgui->getHTML());
1248  }
if(!array_key_exists('StateId', $_REQUEST)) $id
static getNamePresentation( $a_user_id, $a_user_image=false, $a_profile_link=false, $a_profile_back_link="", $a_force_first_lastname=false, $a_omit_login=false, $a_sortable=true, $a_return_data_array=false, $a_ctrl_path="ilpublicuserprofilegui")
Default behaviour is:
static sendFailure($a_info="", $a_keep=false)
Send Failure Message to Screen.
$_POST["username"]
Confirmation screen class.
+ Here is the call graph for this function:

◆ confirmDeleteRatersObject()

ilSurveyParticipantsGUI::confirmDeleteRatersObject ( )

Definition at line 1447 of file class.ilSurveyParticipantsGUI.php.

References $_POST, $data, $id, $tabs, ilUserUtil\getNamePresentation(), handleRatersAccess(), and ilUtil\sendFailure().

1448  {
1449  $ilTabs = $this->tabs;
1450 
1451  $appr_id = $this->handleRatersAccess();
1452  $this->ctrl->setParameter($this, "appr_id", $appr_id);
1453  if (!sizeof($_POST["rtr_id"])) {
1454  ilUtil::sendFailure($this->lng->txt("select_one"), true);
1455  $this->ctrl->redirect($this, "editRaters");
1456  }
1457 
1458  $ilTabs->clearTargets();
1459  $ilTabs->setBackTarget(
1460  $this->lng->txt("btn_back"),
1461  $this->ctrl->getLinkTarget($this, "editRaters")
1462  );
1463 
1464  include_once "Services/User/classes/class.ilUserUtil.php";
1465  include_once("./Services/Utilities/classes/class.ilConfirmationGUI.php");
1466  $cgui = new ilConfirmationGUI();
1467  $cgui->setHeaderText(sprintf(
1468  $this->lng->txt("survey_360_sure_delete_raters"),
1470  ));
1471 
1472  $cgui->setFormAction($this->ctrl->getFormAction($this, "deleteRaters"));
1473  $cgui->setCancel($this->lng->txt("cancel"), "editRaters");
1474  $cgui->setConfirm($this->lng->txt("confirm"), "deleteRaters");
1475 
1476  $data = $this->object->getRatersData($appr_id);
1477 
1478  foreach ($_POST["rtr_id"] as $id) {
1479  if (isset($data[$id])) {
1480  $cgui->addItem("rtr_id[]", $id, $data[$id]["lastname"] . ", " .
1481  $data[$id]["firstname"] . " (" . $data[$id]["email"] . ")");
1482  }
1483  }
1484 
1485  $this->tpl->setContent($cgui->getHTML());
1486  }
if(!array_key_exists('StateId', $_REQUEST)) $id
static getNamePresentation( $a_user_id, $a_user_image=false, $a_profile_link=false, $a_profile_back_link="", $a_force_first_lastname=false, $a_omit_login=false, $a_sortable=true, $a_return_data_array=false, $a_ctrl_path="ilpublicuserprofilegui")
Default behaviour is:
static sendFailure($a_info="", $a_keep=false)
Send Failure Message to Screen.
$_POST["username"]
Confirmation screen class.
+ Here is the call graph for this function:

◆ confirmDeleteSelectedUserDataObject()

ilSurveyParticipantsGUI::confirmDeleteSelectedUserDataObject ( )

Deletes all user data for the test object.

Definition at line 478 of file class.ilSurveyParticipantsGUI.php.

References $_POST, and ilUtil\sendSuccess().

479  {
480  $this->object->removeSelectedSurveyResults($_POST["chbUser"]);
481  ilUtil::sendSuccess($this->lng->txt("svy_selected_user_data_deleted"), true);
482  $this->ctrl->redirect($this, "maintenance");
483  }
static sendSuccess($a_info="", $a_keep=false)
Send Success Message to Screen.
$_POST["username"]
+ Here is the call graph for this function:

◆ createSurveyCodesObject()

ilSurveyParticipantsGUI::createSurveyCodesObject ( )

Create access codes for the survey.

Definition at line 823 of file class.ilSurveyParticipantsGUI.php.

References $_POST, ilUtil\sendFailure(), and ilUtil\sendSuccess().

824  {
825  if (is_numeric($_POST["nrOfCodes"])) {
826  $ids = $this->object->createSurveyCodes($_POST["nrOfCodes"]);
827  ilUtil::sendSuccess($this->lng->txt('codes_created'), true);
828  $this->ctrl->setParameter($this, "new_ids", implode(";", $ids));
829  $this->ctrl->redirect($this, 'editCodes');
830  } else {
831  ilUtil::sendFailure($this->lng->txt("enter_valid_number_of_codes"), true);
832  $this->ctrl->redirect($this, 'codes');
833  }
834  }
static sendSuccess($a_info="", $a_keep=false)
Send Success Message to Screen.
static sendFailure($a_info="", $a_keep=false)
Send Failure Message to Screen.
$_POST["username"]
+ Here is the call graph for this function:

◆ deleteAllUserDataObject()

ilSurveyParticipantsGUI::deleteAllUserDataObject ( )

Creates a confirmation form for delete all user data.

Definition at line 440 of file class.ilSurveyParticipantsGUI.php.

441  {
442  include_once "Services/Utilities/classes/class.ilConfirmationGUI.php";
443  $cgui = new ilConfirmationGUI();
444  $cgui->setHeaderText($this->lng->txt("confirm_delete_all_user_data"));
445  $cgui->setFormAction($this->ctrl->getFormAction($this, "deleteAllUserData"));
446  $cgui->setCancel($this->lng->txt("cancel"), "cancelDeleteAllUserData");
447  $cgui->setConfirm($this->lng->txt("confirm"), "confirmDeleteAllUserData");
448  $this->tpl->setContent($cgui->getHTML());
449  }
Confirmation screen class.

◆ deleteAppraiseesObject()

ilSurveyParticipantsGUI::deleteAppraiseesObject ( )

Definition at line 1250 of file class.ilSurveyParticipantsGUI.php.

References $_POST, $data, $id, and ilUtil\sendSuccess().

1251  {
1252  if (sizeof($_POST["appr_id"])) {
1253  $data = $this->object->getAppraiseesData();
1254 
1255  foreach ($_POST["appr_id"] as $id) {
1256  // #11285
1257  if (isset($data[$id]) && !$data[$id]["closed"]) {
1258  $this->object->deleteAppraisee($id);
1259  }
1260  }
1261 
1262  ilUtil::sendSuccess($this->lng->txt("settings_saved"), true);
1263  }
1264 
1265  $this->ctrl->redirect($this, "listAppraisees");
1266  }
static sendSuccess($a_info="", $a_keep=false)
Send Success Message to Screen.
if(!array_key_exists('StateId', $_REQUEST)) $id
$_POST["username"]
+ Here is the call graph for this function:

◆ deleteCodesConfirmObject()

ilSurveyParticipantsGUI::deleteCodesConfirmObject ( )

Definition at line 669 of file class.ilSurveyParticipantsGUI.php.

References $_POST, $data, $title, array, and ilUtil\sendFailure().

670  {
671  if (is_array($_POST["chb_code"]) && (count($_POST["chb_code"]) > 0)) {
672  include_once("./Services/Utilities/classes/class.ilConfirmationGUI.php");
673  $cgui = new ilConfirmationGUI();
674  $cgui->setHeaderText($this->lng->txt("survey_code_delete_sure"));
675 
676  $cgui->setFormAction($this->ctrl->getFormAction($this));
677  $cgui->setCancel($this->lng->txt("cancel"), "codes");
678  $cgui->setConfirm($this->lng->txt("confirm"), "deleteCodes");
679 
680  $data = $this->object->getSurveyCodesTableData($_POST["chb_code"]);
681 
682  foreach ($data as $item) {
683  if ($item["used"]) {
684  continue;
685  }
686 
687  $title = array($item["code"]);
688  $item["email"] ? $title[] = $item["email"] : null;
689  $item["last_name"] ? $title[] = $item["last_name"] : null;
690  $item["first_name"] ? $title[] = $item["first_name"] : null;
691  $title = implode(", ", $title);
692 
693  $cgui->addItem("chb_code[]", $item["code"], $title);
694  }
695 
696  $this->tpl->setContent($cgui->getHTML());
697  } else {
698  ilUtil::sendFailure($this->lng->txt('no_checkbox'), true);
699  $this->ctrl->redirect($this, 'codes');
700  }
701  }
Create styles array
The data for the language used.
static sendFailure($a_info="", $a_keep=false)
Send Failure Message to Screen.
$_POST["username"]
Confirmation screen class.
+ Here is the call graph for this function:

◆ deleteCodesObject()

ilSurveyParticipantsGUI::deleteCodesObject ( )

Delete a list of survey codes.

Definition at line 706 of file class.ilSurveyParticipantsGUI.php.

References $_POST, ilUtil\sendInfo(), and ilUtil\sendSuccess().

707  {
708  if (is_array($_POST["chb_code"]) && (count($_POST["chb_code"]) > 0)) {
709  foreach ($_POST["chb_code"] as $survey_code) {
710  $this->object->deleteSurveyCode($survey_code);
711  }
712  ilUtil::sendSuccess($this->lng->txt('codes_deleted'), true);
713  } else {
714  ilUtil::sendInfo($this->lng->txt('no_checkbox'), true);
715  }
716  $this->ctrl->redirect($this, 'codes');
717  }
static sendSuccess($a_info="", $a_keep=false)
Send Success Message to Screen.
static sendInfo($a_info="", $a_keep=false)
Send Info Message to Screen.
$_POST["username"]
+ Here is the call graph for this function:

◆ deleteRatersObject()

ilSurveyParticipantsGUI::deleteRatersObject ( )

Definition at line 1488 of file class.ilSurveyParticipantsGUI.php.

References $_POST, $data, $id, handleRatersAccess(), and ilUtil\sendSuccess().

1489  {
1490  $appr_id = $this->handleRatersAccess();
1491  $this->ctrl->setParameter($this, "appr_id", $appr_id);
1492 
1493  if (sizeof($_POST["rtr_id"])) {
1494  $data = $this->object->getRatersData($appr_id);
1495 
1496  foreach ($_POST["rtr_id"] as $id) {
1497  if (isset($data[$id])) {
1498  if (substr($id, 0, 1) == "u") {
1499  $this->object->deleteRater($appr_id, substr($id, 1));
1500  } else {
1501  $this->object->deleteRater($appr_id, 0, substr($id, 1));
1502  }
1503  }
1504  }
1505 
1506  ilUtil::sendSuccess($this->lng->txt("settings_saved"), true);
1507  }
1508 
1509  $this->ctrl->redirect($this, "editRaters");
1510  }
static sendSuccess($a_info="", $a_keep=false)
Send Success Message to Screen.
if(!array_key_exists('StateId', $_REQUEST)) $id
$_POST["username"]
+ Here is the call graph for this function:

◆ deleteSavedMessageObject()

ilSurveyParticipantsGUI::deleteSavedMessageObject ( )

Definition at line 860 of file class.ilSurveyParticipantsGUI.php.

References $ilLog, $log, handleWriteAccess(), ilUtil\sendFailure(), ilUtil\sendSuccess(), and setCodesSubtabs().

861  {
862  $this->handleWriteAccess();
863  $this->setCodesSubtabs();
864 
865  include_once("./Modules/Survey/classes/forms/FormMailCodesGUI.php");
866  $form_gui = new FormMailCodesGUI($this);
867  $form_gui->setValuesByPost();
868  try {
869  if ($form_gui->getSavedMessages()->getValue() > 0) {
870  $this->object->deleteUserSettings($form_gui->getSavedMessages()->getValue());
871  $form_gui = new FormMailCodesGUI($this);
872  $form_gui->setValuesByPost();
873  ilUtil::sendSuccess($this->lng->txt('msg_message_deleted'));
874  } else {
875  ilUtil::sendFailure($this->lng->txt('msg_no_message_deleted'));
876  }
877  } catch (Exception $e) {
878  $ilLog = $this->log;
879  $ilLog->write('Error: ' + $e->getMessage());
880  }
881  $this->tpl->setVariable("ADM_CONTENT", $form_gui->getHTML());
882  }
static sendSuccess($a_info="", $a_keep=false)
Send Success Message to Screen.
static sendFailure($a_info="", $a_keep=false)
Send Failure Message to Screen.
Class FormMailCodesGUI.
setCodesSubtabs()
Set the tabs for the access codes section.
+ Here is the call graph for this function:

◆ deleteSingleUserResultsObject()

ilSurveyParticipantsGUI::deleteSingleUserResultsObject ( )

Asks for a confirmation to delete selected user data of the test object.

Definition at line 497 of file class.ilSurveyParticipantsGUI.php.

References $_POST, $data, $total, array, handleWriteAccess(), ilUtil\sendInfo(), and ilUtil\sendQuestion().

498  {
499  $this->handleWriteAccess();
500 
501  if (!is_array($_POST["chbUser"]) || count($_POST["chbUser"]) == 0) {
502  ilUtil::sendInfo($this->lng->txt('no_checkbox'), true);
503  $this->ctrl->redirect($this, "maintenance");
504  }
505 
506  ilUtil::sendQuestion($this->lng->txt("confirm_delete_single_user_data"));
507  include_once "./Modules/Survey/classes/tables/class.ilSurveyMaintenanceTableGUI.php";
508  $table_gui = new ilSurveyMaintenanceTableGUI($this, 'maintenance', true);
509  $total =&$this->object->getSurveyParticipants();
510  $data = array();
511  foreach ($total as $user_data) {
512  if (in_array($user_data['active_id'], $_POST['chbUser'])) {
513  $last_access = $this->object->getLastAccess($user_data["active_id"]);
514  array_push($data, array(
515  'id' => $user_data["active_id"],
516  'name' => $user_data["sortname"],
517  'login' => $user_data["login"],
518  'last_access' => $last_access
519  ));
520  }
521  }
522  $table_gui->setData($data);
523  $this->tpl->setVariable('ADM_CONTENT', $table_gui->getHTML());
524  }
$total
Definition: Utf8Test.php:87
static sendInfo($a_info="", $a_keep=false)
Send Info Message to Screen.
static sendQuestion($a_info="", $a_keep=false)
Send Question to Screen.
Create styles array
The data for the language used.
$_POST["username"]
+ Here is the call graph for this function:

◆ disinviteUserGroupObject()

ilSurveyParticipantsGUI::disinviteUserGroupObject ( )

Disinvite users or groups from a survey.

Definition at line 306 of file class.ilSurveyParticipantsGUI.php.

References $_POST, and ilUtil\sendSuccess().

307  {
308  // disinvite users
309  if (is_array($_POST["user_select"])) {
310  foreach ($_POST["user_select"] as $user_id) {
311  $this->object->disinviteUser($user_id);
312  }
313  }
314  ilUtil::sendSuccess($this->lng->txt('msg_users_disinvited'), true);
315  $this->ctrl->redirect($this, "invite");
316  }
static sendSuccess($a_info="", $a_keep=false)
Send Success Message to Screen.
$_POST["username"]
+ Here is the call graph for this function:

◆ editCodesObject()

ilSurveyParticipantsGUI::editCodesObject ( )

Definition at line 617 of file class.ilSurveyParticipantsGUI.php.

References $_GET, $_POST, array, handleWriteAccess(), object, ilUtil\sendFailure(), and setCodesSubtabs().

618  {
619  if (isset($_GET["new_ids"])) {
620  $ids = explode(";", $_GET["new_ids"]);
621  } else {
622  $ids = (array) $_POST["chb_code"];
623  }
624  if (!$ids) {
625  ilUtil::sendFailure($this->lng->txt('no_checkbox'), true);
626  $this->ctrl->redirect($this, 'codes');
627  }
628 
629  $this->handleWriteAccess();
630  $this->setCodesSubtabs();
631 
632  include_once "./Modules/Survey/classes/tables/class.ilSurveyCodesEditTableGUI.php";
633  $table_gui = new ilSurveyCodesEditTableGUI($this, 'editCodes');
634  $table_gui->setData($this->object->getSurveyCodesTableData($ids));
635  $this->tpl->setContent($table_gui->getHTML());
636  }
$_GET["client_id"]
Create styles array
The data for the language used.
static sendFailure($a_info="", $a_keep=false)
Send Failure Message to Screen.
Create new PHPExcel object
obj_idprivate
setCodesSubtabs()
Set the tabs for the access codes section.
$_POST["username"]
+ Here is the call graph for this function:

◆ editRatersObject()

ilSurveyParticipantsGUI::editRatersObject ( )

Definition at line 1288 of file class.ilSurveyParticipantsGUI.php.

References $access, $has_write, $ref_id, $tabs, $tbl, $toolbar, $url, ilLink\_getStaticLink(), array, ilRepositorySearchGUI\fillAutoCompleteToolbar(), handleRatersAccess(), and object.

1289  {
1290  $ilTabs = $this->tabs;
1291  $ilToolbar = $this->toolbar;
1292  $ilAccess = $this->access;
1293 
1294  $appr_id = $_REQUEST["appr_id"] = $this->handleRatersAccess();
1295 
1296  $has_write = $ilAccess->checkAccess("write", "", $this->ref_id);
1297  if ($has_write) {
1298  $ilTabs->clearTargets();
1299  $ilTabs->setBackTarget(
1300  $this->lng->txt("btn_back"),
1301  $this->ctrl->getLinkTarget($this, "listAppraisees")
1302  );
1303  }
1304 
1305  $this->ctrl->setParameter($this, "appr_id", $appr_id);
1306  $this->ctrl->setParameter($this, "rate360", 1);
1307 
1308  include_once './Services/Search/classes/class.ilRepositorySearchGUI.php';
1310  $this,
1311  $ilToolbar,
1312  array(
1313  'auto_complete_name' => $this->lng->txt('user'),
1314  'submit_name' => $this->lng->txt('add'),
1315  'add_search' => true,
1316  'add_from_container' => $this->ref_id
1317  )
1318  );
1319 
1320  $this->ctrl->setParameter($this, "rate360", "");
1321 
1322  $ilToolbar->addSeparator();
1323 
1324  $ilToolbar->addButton(
1325  $this->lng->txt("survey_360_add_external_rater"),
1326  $this->ctrl->getLinkTarget($this, "addExternalRaterForm")
1327  );
1328 
1329  // #13320
1330  require_once "Services/Link/classes/class.ilLink.php";
1331  $url = ilLink::_getStaticLink($this->object->getRefId());
1332 
1333  include_once "Modules/Survey/classes/tables/class.ilSurveyAppraiseesTableGUI.php";
1334  $tbl = new ilSurveyAppraiseesTableGUI($this, "editRaters", true, !$this->object->isAppraiseeClosed($appr_id), $url); // #11285
1335  $tbl->setData($this->object->getRatersData($appr_id));
1336  $this->tpl->setContent($tbl->getHTML());
1337  }
$tbl
Definition: example_048.php:81
Create styles array
The data for the language used.
Create new PHPExcel object
obj_idprivate
$url
static fillAutoCompleteToolbar($parent_object, ilToolbarGUI $toolbar=null, $a_options=array(), $a_sticky=false)
fill toolbar with
+ Here is the call graph for this function:

◆ executeCommand()

ilSurveyParticipantsGUI::executeCommand ( )

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

References $ctrl, $ilCtrl, $tabs, and array.

99  {
101  $ilTabs = $this->tabs;
102 
103  $cmd = $ilCtrl->getCmd("maintenance");
104  $next_class = $this->ctrl->getNextClass($this);
105 
106  switch ($next_class) {
107  case 'ilrepositorysearchgui':
108  include_once('./Services/Search/classes/class.ilRepositorySearchGUI.php');
109  $rep_search = new ilRepositorySearchGUI();
110 
111  if (!$_REQUEST["appr360"] && !$_REQUEST["rate360"]) {
112  $ilTabs->clearTargets();
113  $ilTabs->setBackTarget(
114  $this->lng->txt("btn_back"),
115  $this->ctrl->getLinkTarget($this, "invite")
116  );
117 
118  $rep_search->setCallback(
119  $this,
120  'inviteUserGroupObject',
121  array(
122  )
123  );
124 
125  // Set tabs
126  $this->ctrl->setReturn($this, 'invite');
127  $this->ctrl->forwardCommand($rep_search);
128  $ilTabs->setTabActive('invitation');
129  } elseif ($_REQUEST["rate360"]) {
130  $ilTabs->clearTargets();
131  $ilTabs->setBackTarget(
132  $this->lng->txt("btn_back"),
133  $this->ctrl->getLinkTarget($this, "listAppraisees")
134  );
135 
136  $this->ctrl->setParameter($this, "rate360", 1);
137  $this->ctrl->saveParameter($this, "appr_id");
138 
139  $rep_search->setCallback(
140  $this,
141  'addRater',
142  array(
143  )
144  );
145 
146  // Set tabs
147  $this->ctrl->setReturn($this, 'editRaters');
148  $this->ctrl->forwardCommand($rep_search);
149  } else {
150  $ilTabs->activateTab("survey_360_appraisees");
151  $this->ctrl->setParameter($this, "appr360", 1);
152 
153  $rep_search->setCallback(
154  $this,
155  'addAppraisee',
156  array(
157  )
158  );
159 
160  // Set tabs
161  $this->ctrl->setReturn($this, 'listAppraisees');
162  $this->ctrl->forwardCommand($rep_search);
163  }
164  break;
165 
166  default:
167  $cmd .= "Object";
168  $this->$cmd();
169  break;
170  }
171  }
global $ilCtrl
Definition: ilias.php:18
Create styles array
The data for the language used.

◆ exportAllCodesObject()

ilSurveyParticipantsGUI::exportAllCodesObject ( )

Exports all survey codes.

Definition at line 736 of file class.ilSurveyParticipantsGUI.php.

References ilUtil\deliverData(), ilUtil\getASCIIFilename(), and object.

737  {
738  $export = $this->object->getSurveyCodesForExport();
739  ilUtil::deliverData($export, ilUtil::getASCIIFilename($this->object->getTitle() . ".csv"));
740  }
static deliverData($a_data, $a_filename, $mime="application/octet-stream", $charset="")
deliver data for download via browser.
static getASCIIFilename($a_filename)
convert utf8 to ascii filename
Create new PHPExcel object
obj_idprivate
+ Here is the call graph for this function:

◆ exportCodesObject()

ilSurveyParticipantsGUI::exportCodesObject ( )

Exports a list of survey codes.

Definition at line 722 of file class.ilSurveyParticipantsGUI.php.

References $_POST, ilUtil\deliverData(), ilUtil\getASCIIFilename(), object, and ilUtil\sendFailure().

723  {
724  if (is_array($_POST["chb_code"]) && (count($_POST["chb_code"]) > 0)) {
725  $export = $this->object->getSurveyCodesForExport(null, $_POST["chb_code"]);
726  ilUtil::deliverData($export, ilUtil::getASCIIFilename($this->object->getTitle() . ".csv"));
727  } else {
728  ilUtil::sendFailure($this->lng->txt("no_checkbox"), true);
729  $this->ctrl->redirect($this, 'codes');
730  }
731  }
static deliverData($a_data, $a_filename, $mime="application/octet-stream", $charset="")
deliver data for download via browser.
static getASCIIFilename($a_filename)
convert utf8 to ascii filename
static sendFailure($a_info="", $a_keep=false)
Send Failure Message to Screen.
Create new PHPExcel object
obj_idprivate
$_POST["username"]
+ Here is the call graph for this function:

◆ getObject()

ilSurveyParticipantsGUI::getObject ( )

Definition at line 1808 of file class.ilSurveyParticipantsGUI.php.

References $object.

1809  {
1810  return $this->object;
1811  }

◆ handleRatersAccess()

ilSurveyParticipantsGUI::handleRatersAccess ( )

Definition at line 1268 of file class.ilSurveyParticipantsGUI.php.

References $access, $ilUser, $user, and object.

Referenced by addExternalRaterFormObject(), addRater(), confirmDeleteRatersObject(), deleteRatersObject(), editRatersObject(), mailRatersActionObject(), and mailRatersObject().

1269  {
1270  $ilAccess = $this->access;
1271  $ilUser = $this->user;
1272 
1273  if ($ilAccess->checkAccess("write", "", $this->ref_id)) {
1274  $appr_id = $_REQUEST["appr_id"];
1275  if (!$appr_id) {
1276  $this->ctrl->redirect($this, "listAppraisees");
1277  }
1278  return $appr_id;
1279  } elseif ($this->object->get360Mode() &&
1280  $this->object->get360SelfRaters() &&
1281  $this->object->isAppraisee($ilUser->getId()) &&
1282  !$this->object->isAppraiseeClosed($ilUser->getId())) {
1283  return $ilUser->getId();
1284  }
1285  $this->ctrl->redirect($this->parent_gui, "infoScreen");
1286  }
$ilUser
Definition: imgupload.php:18
Create new PHPExcel object
obj_idprivate
+ Here is the caller graph for this function:

◆ handleWriteAccess()

ilSurveyParticipantsGUI::handleWriteAccess ( )
protected

◆ importAccessCodesActionObject()

ilSurveyParticipantsGUI::importAccessCodesActionObject ( )
protected

Import codes from export codes file.

Definition at line 778 of file class.ilSurveyParticipantsGUI.php.

References $code, $email, $reader, $row, $url, array, IL_CAL_DATE, IL_CAL_DATETIME, IL_CAL_UNIX, object, and ilUtil\sendSuccess().

779  {
780  if (trim($_FILES['codes']['tmp_name'])) {
781  $existing = array();
782  foreach ($this->object->getSurveyCodesTableData() as $item) {
783  $existing[$item["code"]] = $item["id"];
784  }
785 
786  include_once "./Services/Utilities/classes/class.ilCSVReader.php";
787  $reader = new ilCSVReader();
788  $reader->open($_FILES['codes']['tmp_name']);
789  foreach ($reader->getDataArrayFromCSVFile() as $row) {
790  if (sizeof($row) == 8) {
791  // used/sent/url are not relevant when importing
792  list($code, $email, $last_name, $first_name, $created, $used, $sent, $url) = $row;
793 
794  // unique code?
795  if (!array_key_exists($code, $existing)) {
796  // could be date or datetime
797  if (strlen($created) == 10) {
798  $created = new ilDate($created, IL_CAL_DATE);
799  } else {
800  $created = new ilDateTime($created, IL_CAL_DATETIME);
801  }
802  $created = $created->get(IL_CAL_UNIX);
803 
804  $user_data = array(
805  "email" => $email
806  ,"lastname" => $last_name
807  ,"firstname" => $first_name
808  );
809  $this->object->importSurveyCode($code, $created, $user_data);
810  }
811  }
812  }
813 
814  ilUtil::sendSuccess($this->lng->txt('codes_created'), true);
815  }
816 
817  $this->ctrl->redirect($this, 'codes');
818  }
static sendSuccess($a_info="", $a_keep=false)
Send Success Message to Screen.
if($orgName !==null) if($spconfig->hasValue('contacts')) $email
Definition: metadata.php:193
const IL_CAL_DATETIME
$code
Definition: example_050.php:99
const IL_CAL_UNIX
Class for single dates.
Date and time handling
Create styles array
The data for the language used.
const IL_CAL_DATE
Create new PHPExcel object
obj_idprivate
$url
+ Here is the call graph for this function:

◆ importAccessCodesObject()

ilSurveyParticipantsGUI::importAccessCodesObject ( )
protected

Import codes from export codes file (upload form)

Definition at line 745 of file class.ilSurveyParticipantsGUI.php.

References array, handleWriteAccess(), setCodesSubtabs(), and ilFormPropertyGUI\setInfo().

746  {
747  $this->handleWriteAccess();
748  $this->setCodesSubtabs();
749 
750  include_once("./Services/Form/classes/class.ilPropertyFormGUI.php");
751  $form_import_file = new ilPropertyFormGUI();
752  $form_import_file->setFormAction($this->ctrl->getFormAction($this));
753  $form_import_file->setTableWidth("100%");
754  $form_import_file->setId("codes_import_file");
755 
756  $headerfile = new ilFormSectionHeaderGUI();
757  $headerfile->setTitle($this->lng->txt("svy_import_codes"));
758  $form_import_file->addItem($headerfile);
759 
760  $export_file = new ilFileInputGUI($this->lng->txt("codes"), "codes");
761  $export_file->setInfo(sprintf(
762  $this->lng->txt('svy_import_codes_info'),
763  $this->lng->txt("export_all_survey_codes")
764  ));
765  $export_file->setSuffixes(array("csv"));
766  $export_file->setRequired(true);
767  $form_import_file->addItem($export_file);
768 
769  $form_import_file->addCommandButton("importAccessCodesAction", $this->lng->txt("import"));
770  $form_import_file->addCommandButton("codes", $this->lng->txt("cancel"));
771 
772  $this->tpl->setContent($form_import_file->getHTML());
773  }
This class represents a property form user interface.
This class represents a section header in a property form.
This class represents a file property in a property form.
setInfo($a_info)
Set Information Text.
Create styles array
The data for the language used.
setCodesSubtabs()
Set the tabs for the access codes section.
+ Here is the call graph for this function:

◆ importExternalMailRecipientsFromFileFormObject()

ilSurveyParticipantsGUI::importExternalMailRecipientsFromFileFormObject ( )

Definition at line 1059 of file class.ilSurveyParticipantsGUI.php.

References $_GET, $access, handleWriteAccess(), setCodesSubtabs(), and ilFormPropertyGUI\setInfo().

1060  {
1061  $ilAccess = $this->access;
1062 
1063  $this->handleWriteAccess();
1064  $this->setCodesSubtabs();
1065 
1066  include_once("./Services/Form/classes/class.ilPropertyFormGUI.php");
1067  $form_import_file = new ilPropertyFormGUI();
1068  $form_import_file->setFormAction($this->ctrl->getFormAction($this));
1069  $form_import_file->setTableWidth("100%");
1070  $form_import_file->setId("codes_import_file");
1071 
1072  $headerfile = new ilFormSectionHeaderGUI();
1073  $headerfile->setTitle($this->lng->txt("import_from_file"));
1074  $form_import_file->addItem($headerfile);
1075 
1076  $externalmails = new ilFileInputGUI($this->lng->txt("externalmails"), "externalmails");
1077  $externalmails->setInfo($this->lng->txt('externalmails_info'));
1078  $externalmails->setRequired(true);
1079  $form_import_file->addItem($externalmails);
1080  if ($ilAccess->checkAccess("write", "", $_GET["ref_id"])) {
1081  $form_import_file->addCommandButton("importExternalRecipientsFromFile", $this->lng->txt("import"));
1082  }
1083  if ($ilAccess->checkAccess("write", "", $_GET["ref_id"])) {
1084  $form_import_file->addCommandButton("codes", $this->lng->txt("cancel"));
1085  }
1086 
1087  $this->tpl->setContent($form_import_file->getHTML());
1088  }
This class represents a property form user interface.
$_GET["client_id"]
This class represents a section header in a property form.
This class represents a file property in a property form.
setInfo($a_info)
Set Information Text.
setCodesSubtabs()
Set the tabs for the access codes section.
+ Here is the call graph for this function:

◆ importExternalMailRecipientsFromTextFormObject()

ilSurveyParticipantsGUI::importExternalMailRecipientsFromTextFormObject ( )

Definition at line 1090 of file class.ilSurveyParticipantsGUI.php.

References $_GET, $_SESSION, $access, handleWriteAccess(), setCodesSubtabs(), and ilTextAreaInputGUI\setValue().

1091  {
1092  $ilAccess = $this->access;
1093 
1094  $this->handleWriteAccess();
1095  $this->setCodesSubtabs();
1096 
1097  include_once("./Services/Form/classes/class.ilPropertyFormGUI.php");
1098  $form_import_text = new ilPropertyFormGUI();
1099  $form_import_text->setFormAction($this->ctrl->getFormAction($this));
1100  $form_import_text->setTableWidth("100%");
1101  $form_import_text->setId("codes_import_text");
1102 
1103  $headertext = new ilFormSectionHeaderGUI();
1104  $headertext->setTitle($this->lng->txt("import_from_text"));
1105  $form_import_text->addItem($headertext);
1106 
1107  $inp = new ilTextAreaInputGUI($this->lng->txt('externaltext'), 'externaltext');
1108  if (array_key_exists('externaltext', $_SESSION) && strlen($_SESSION['externaltext'])) {
1109  $inp->setValue($_SESSION['externaltext']);
1110  } else {
1111  // $this->lng->txt('mail_import_example1') #14897
1112  $inp->setValue("email;firstname;lastname\n" . $this->lng->txt('mail_import_example2') . "\n" . $this->lng->txt('mail_import_example3') . "\n");
1113  }
1114  $inp->setRequired(true);
1115  $inp->setCols(80);
1116  $inp->setRows(10);
1117  $inp->setInfo($this->lng->txt('externaltext_info'));
1118  $form_import_text->addItem($inp);
1119  unset($_SESSION['externaltext']);
1120 
1121  if ($ilAccess->checkAccess("write", "", $_GET["ref_id"])) {
1122  $form_import_text->addCommandButton("importExternalRecipientsFromText", $this->lng->txt("import"));
1123  }
1124  if ($ilAccess->checkAccess("write", "", $_GET["ref_id"])) {
1125  $form_import_text->addCommandButton("codes", $this->lng->txt("cancel"));
1126  }
1127 
1128  $this->tpl->setContent($form_import_text->getHTML());
1129  }
$_SESSION["AccountId"]
This class represents a property form user interface.
$_GET["client_id"]
This class represents a section header in a property form.
setValue($a_value)
Set Value.
This class represents a text area property in a property form.
setCodesSubtabs()
Set the tabs for the access codes section.
+ Here is the call graph for this function:

◆ importExternalRecipientsFromFileObject()

ilSurveyParticipantsGUI::importExternalRecipientsFromFileObject ( )

Definition at line 1000 of file class.ilSurveyParticipantsGUI.php.

References $data, $dataset, $key, $reader, $row, _convertCharset(), array, removeUTF8Bom(), ilUtil\sendFailure(), and ilUtil\sendSuccess().

1001  {
1002  if (trim($_FILES['externalmails']['tmp_name'])) {
1003  include_once "./Services/Utilities/classes/class.ilCSVReader.php";
1004  $reader = new ilCSVReader();
1005  $reader->open($_FILES['externalmails']['tmp_name']);
1006  $data = $reader->getDataArrayFromCSVFile();
1007  $fields = array_shift($data);
1008  foreach ($fields as $idx => $field) {
1009  $fields[$idx] = $this->removeUTF8Bom($field);
1010  }
1011  if (!in_array('email', $fields)) {
1012  $reader->close();
1013  ilUtil::sendFailure($this->lng->txt('err_external_rcp_no_email'), true);
1014  $this->ctrl->redirect($this, 'codes');
1015  }
1016  $existingdata = $this->object->getExternalCodeRecipients();
1017  $existingcolumns = array();
1018  if (count($existingdata)) {
1019  $first = array_shift($existingdata);
1020  foreach ($first as $key => $value) {
1021  array_push($existingcolumns, $key);
1022  }
1023  }
1024 
1025  include_once "Services/Utilities/classes/class.ilStr.php";
1026 
1027  $founddata = array();
1028  foreach ($data as $row) {
1029  if (count($row) == count($fields)) {
1030  $dataset = array();
1031  foreach ($fields as $idx => $fieldname) {
1032  // #14811
1033  $row[$idx] = $this->_convertCharset($row[$idx]);
1034 
1035  if (count($existingcolumns)) {
1036  if (array_key_exists($idx, $existingcolumns)) {
1037  $dataset[$fieldname] = $row[$idx];
1038  }
1039  } else {
1040  $dataset[$fieldname] = $row[$idx];
1041  }
1042  }
1043  if (strlen($dataset['email'])) {
1044  array_push($founddata, $dataset);
1045  }
1046  }
1047  }
1048  $reader->close();
1049 
1050  if (sizeof($founddata)) {
1051  $this->object->createSurveyCodesForExternalData($founddata);
1052  ilUtil::sendSuccess($this->lng->txt('external_recipients_imported'), true);
1053  }
1054  }
1055 
1056  $this->ctrl->redirect($this, 'codes');
1057  }
static sendSuccess($a_info="", $a_keep=false)
Send Success Message to Screen.
_convertCharset($a_string, $a_from_charset="", $a_to_charset="UTF-8")
$dataset
Definition: showstats.php:45
Create styles array
The data for the language used.
static sendFailure($a_info="", $a_keep=false)
Send Failure Message to Screen.
$key
Definition: croninfo.php:18
+ Here is the call graph for this function:

◆ importExternalRecipientsFromTextObject()

ilSurveyParticipantsGUI::importExternalRecipientsFromTextObject ( )

Definition at line 934 of file class.ilSurveyParticipantsGUI.php.

References $_POST, $_SESSION, $data, $dataset, $key, $row, array, ilUtil\sendFailure(), and ilUtil\sendSuccess().

935  {
936  if (trim($_POST['externaltext'])) {
937  $data = preg_split("/[\n\r]/", $_POST['externaltext']);
938  $fields = preg_split("/;/", array_shift($data));
939  if (!in_array('email', $fields)) {
940  $_SESSION['externaltext'] = $_POST['externaltext'];
941  ilUtil::sendFailure($this->lng->txt('err_external_rcp_no_email_column'), true);
942  $this->ctrl->redirect($this, 'importExternalMailRecipientsFromTextForm');
943  }
944  $existingdata = $this->object->getExternalCodeRecipients();
945  $existingcolumns = array();
946  if (count($existingdata)) {
947  $first = array_shift($existingdata);
948  foreach ($first as $key => $value) {
949  array_push($existingcolumns, $key);
950  }
951  }
952  $founddata = array();
953  foreach ($data as $datarow) {
954  $row = preg_split("/;/", $datarow);
955  if (count($row) == count($fields)) {
956  $dataset = array();
957  foreach ($fields as $idx => $fieldname) {
958  if (count($existingcolumns)) {
959  if (array_key_exists($idx, $existingcolumns)) {
960  $dataset[$fieldname] = $row[$idx];
961  }
962  } else {
963  $dataset[$fieldname] = $row[$idx];
964  }
965  }
966  if (strlen($dataset['email'])) {
967  array_push($founddata, $dataset);
968  }
969  }
970  }
971  $this->object->createSurveyCodesForExternalData($founddata);
972  ilUtil::sendSuccess($this->lng->txt('external_recipients_imported'), true);
973  $this->ctrl->redirect($this, 'codes');
974  }
975 
976  $this->ctrl->redirect($this, 'importExternalMailRecipientsFromTextForm');
977  }
static sendSuccess($a_info="", $a_keep=false)
Send Success Message to Screen.
$_SESSION["AccountId"]
$dataset
Definition: showstats.php:45
Create styles array
The data for the language used.
static sendFailure($a_info="", $a_keep=false)
Send Failure Message to Screen.
$key
Definition: croninfo.php:18
$_POST["username"]
+ Here is the call graph for this function:

◆ initExternalRaterForm()

ilSurveyParticipantsGUI::initExternalRaterForm (   $appr_id)
protected

Definition at line 1363 of file class.ilSurveyParticipantsGUI.php.

References $email, $form, ilUserUtil\getNamePresentation(), and ilTextInputGUI\setSize().

Referenced by addExternalRaterFormObject(), and addExternalRaterObject().

1364  {
1365  include_once "Services/User/classes/class.ilUserUtil.php";
1366  include_once("./Services/Form/classes/class.ilPropertyFormGUI.php");
1367  $form = new ilPropertyFormGUI();
1368  $form->setFormAction($this->ctrl->getFormAction($this, "addExternalRater"));
1369  $form->setTitle($this->lng->txt("survey_360_add_external_rater") .
1370  ": " . ilUserUtil::getNamePresentation($appr_id));
1371 
1372  $email = new ilEmailInputGUI($this->lng->txt("email"), "email");
1373  $email->setRequired(true);
1374  $form->addItem($email);
1375 
1376  $lname = new ilTextInputGUI($this->lng->txt("lastname"), "lname");
1377  $lname->setSize(30);
1378  $form->addItem($lname);
1379 
1380  $fname = new ilTextInputGUI($this->lng->txt("firstname"), "fname");
1381  $fname->setSize(30);
1382  $form->addItem($fname);
1383 
1384  $form->addCommandButton("addExternalRater", $this->lng->txt("save"));
1385  $form->addCommandButton("editRaters", $this->lng->txt("cancel"));
1386 
1387  return $form;
1388  }
if($orgName !==null) if($spconfig->hasValue('contacts')) $email
Definition: metadata.php:193
This class represents a property form user interface.
if(isset($_POST['submit'])) $form
setSize($a_size)
Set Size.
This class represents a text property in a property form.
static getNamePresentation( $a_user_id, $a_user_image=false, $a_profile_link=false, $a_profile_back_link="", $a_force_first_lastname=false, $a_omit_login=false, $a_sortable=true, $a_return_data_array=false, $a_ctrl_path="ilpublicuserprofilegui")
Default behaviour is:
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ initMailRatersForm()

ilSurveyParticipantsGUI::initMailRatersForm (   $appr_id,
array  $rec_ids 
)

Definition at line 1524 of file class.ilSurveyParticipantsGUI.php.

References $form, $key, array, ilFormPropertyGUI\setRequired(), and ilTextInputGUI\setSize().

Referenced by mailRatersActionObject(), and mailRatersObject().

1525  {
1526  include_once("./Services/Form/classes/class.ilPropertyFormGUI.php");
1527  $form = new ilPropertyFormGUI();
1528  $form->setFormAction($this->ctrl->getFormAction($this, "mailRatersAction"));
1529  $form->setTitle($this->lng->txt('compose'));
1530 
1531  $all_data = $this->object->getRatersData($appr_id);
1532  $rec_data = array();
1533  foreach ($rec_ids as $rec_id) {
1534  if (isset($all_data[$rec_id])) {
1535  $rec_data[] = $all_data[$rec_id]["lastname"] . ", " .
1536  $all_data[$rec_id]["firstname"] .
1537  " (" . $all_data[$rec_id]["email"] . ")";
1538  }
1539  }
1540  sort($rec_data);
1541  $rec = new ilCustomInputGUI($this->lng->txt('recipients'));
1542  $rec->setHTML(implode("<br />", $rec_data));
1543  $form->addItem($rec);
1544 
1545  $subject = new ilTextInputGUI($this->lng->txt('subject'), 'subject');
1546  $subject->setSize(50);
1547  $subject->setRequired(true);
1548  $form->addItem($subject);
1549 
1550  $existingdata = $this->object->getExternalCodeRecipients();
1551  $existingcolumns = array();
1552  if (count($existingdata)) {
1553  $first = array_shift($existingdata);
1554  foreach ($first as $key => $value) {
1555  if (strcmp($key, 'code') != 0 && strcmp($key, 'email') != 0 && strcmp($key, 'sent') != 0) {
1556  array_push($existingcolumns, '[' . $key . ']');
1557  }
1558  }
1559  }
1560 
1561  $mailmessage_u = new ilTextAreaInputGUI($this->lng->txt('survey_360_rater_message_content_registered'), 'message_u');
1562  $mailmessage_u->setRequired(true);
1563  $mailmessage_u->setCols(80);
1564  $mailmessage_u->setRows(10);
1565  $form->addItem($mailmessage_u);
1566 
1567  $mailmessage_a = new ilTextAreaInputGUI($this->lng->txt('survey_360_rater_message_content_anonymous'), 'message_a');
1568  $mailmessage_a->setRequired(true);
1569  $mailmessage_a->setCols(80);
1570  $mailmessage_a->setRows(10);
1571  $mailmessage_a->setInfo(sprintf($this->lng->txt('message_content_info'), join($existingcolumns, ', ')));
1572  $form->addItem($mailmessage_a);
1573 
1574  $recf = new ilHiddenInputGUI("rtr_id");
1575  $recf->setValue(implode(";", $rec_ids));
1576  $form->addItem($recf);
1577 
1578  $form->addCommandButton("mailRatersAction", $this->lng->txt("send"));
1579  $form->addCommandButton("editRaters", $this->lng->txt("cancel"));
1580 
1581  $subject->setValue(sprintf($this->lng->txt('survey_360_rater_subject_default'), $this->object->getTitle()));
1582  $mailmessage_u->setValue($this->lng->txt('survey_360_rater_message_content_registered_default'));
1583  $mailmessage_a->setValue($this->lng->txt('survey_360_rater_message_content_anonymous_default'));
1584 
1585  return $form;
1586  }
This class represents a property form user interface.
This class represents a hidden form property in a property form.
if(isset($_POST['submit'])) $form
setSize($a_size)
Set Size.
This class represents a text property in a property form.
Create styles array
The data for the language used.
This class represents a custom property in a property form.
This class represents a text area property in a property form.
$key
Definition: croninfo.php:18
setRequired($a_required)
Set Required.
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ insertSavedMessageObject()

ilSurveyParticipantsGUI::insertSavedMessageObject ( )

Definition at line 836 of file class.ilSurveyParticipantsGUI.php.

References $ilLog, $ilUser, $log, $user, handleWriteAccess(), ilUtil\sendFailure(), ilUtil\sendSuccess(), and setCodesSubtabs().

837  {
838  $this->handleWriteAccess();
839  $this->setCodesSubtabs();
840 
841  include_once("./Modules/Survey/classes/forms/FormMailCodesGUI.php");
842  $form_gui = new FormMailCodesGUI($this);
843  $form_gui->setValuesByPost();
844  try {
845  if ($form_gui->getSavedMessages()->getValue() > 0) {
847  $settings = $this->object->getUserSettings($ilUser->getId(), 'savemessage');
848  $form_gui->getMailMessage()->setValue($settings[$form_gui->getSavedMessages()->getValue()]['value']);
849  ilUtil::sendSuccess($this->lng->txt('msg_message_inserted'));
850  } else {
851  ilUtil::sendFailure($this->lng->txt('msg_no_message_inserted'));
852  }
853  } catch (Exception $e) {
854  $ilLog = $this->log;
855  $ilLog->write('Error: ' + $e->getMessage());
856  }
857  $this->tpl->setVariable("ADM_CONTENT", $form_gui->getHTML());
858  }
static sendSuccess($a_info="", $a_keep=false)
Send Success Message to Screen.
$ilUser
Definition: imgupload.php:18
static sendFailure($a_info="", $a_keep=false)
Send Failure Message to Screen.
Class FormMailCodesGUI.
setCodesSubtabs()
Set the tabs for the access codes section.
+ Here is the call graph for this function:

◆ inviteObject()

ilSurveyParticipantsGUI::inviteObject ( )

Creates the output for user/group invitation to a survey.

Definition at line 366 of file class.ilSurveyParticipantsGUI.php.

References $access, $form, $header, $lng, $rbacsystem, $toolbar, array, ilRepositorySearchGUI\fillAutoCompleteToolbar(), handleWriteAccess(), object, setCodesSubtabs(), and ilFormPropertyGUI\setInfo().

367  {
368  $ilAccess = $this->access;
370  $ilToolbar = $this->toolbar;
371  $lng = $this->lng;
372 
373  $this->handleWriteAccess();
374  $this->setCodesSubtabs();
375 
376  include_once("./Services/Form/classes/class.ilPropertyFormGUI.php");
377  $form = new ilPropertyFormGUI();
378  $form->setFormAction($this->ctrl->getFormAction($this));
379  $form->setTableWidth("500");
380  $form->setId("invite");
381 
382  // invitation
384  $header->setTitle($this->lng->txt("invitation"));
385  $form->addItem($header);
386 
387  // invitation mode
388  $invitation = new ilRadioGroupInputGUI($this->lng->txt('invitation_mode'), "invitation");
389  $invitation->setInfo($this->lng->txt('invitation_mode_desc'));
390  $invitation->addOption(new ilRadioOption($this->lng->txt("invitation_off"), 0, ''));
391  $surveySetting = new ilSetting("survey");
392  if ($surveySetting->get("unlimited_invitation")) {
393  $invitation->addOption(new ilRadioOption($this->lng->txt("unlimited_users"), 1, ''));
394  }
395  $invitation->addOption(new ilRadioOption($this->lng->txt("predefined_users"), 2, ''));
396  $inv = 0;
397  if ($this->object->getInvitation()) {
398  $inv = $this->object->getInvitationMode() + 1;
399  }
400  $invitation->setValue($inv);
401  $form->addItem($invitation);
402 
403  $form->addCommandButton("saveInvitationStatus", $this->lng->txt("save"));
404 
405  $this->tpl->addBlockFile("ADM_CONTENT", "adm_content", "tpl.il_svy_svy_invite.html", "Modules/Survey");
406  $this->tpl->setVariable("INVITATION_TABLE", $form->getHTML());
407 
408  if ($this->object->getInvitation() && $this->object->getInvitationMode() == 1) {
409  // search button
410  include_once './Services/Search/classes/class.ilRepositorySearchGUI.php';
412  $this,
413  $tb,
414  array(
415  'auto_complete_name' => $lng->txt('user'),
416  'submit_name' => $lng->txt('svy_invite_action')
417  )
418  );
419 
420  $ilToolbar->addSpacer();
421 
422  $ilToolbar->addButton(
423  $this->lng->txt("svy_search_users"),
424  $this->ctrl->getLinkTargetByClass('ilRepositorySearchGUI', '')
425  );
426 
427  $this->tpl->setVariable("ADM_CONTENT", $form->getHTML());
428 
429  $invited_users = $this->object->getUserData($this->object->getInvitedUsers());
430  include_once "./Modules/Survey/classes/tables/class.ilSurveyInvitedUsersTableGUI.php";
431  $table_gui = new ilSurveyInvitedUsersTableGUI($this, 'invite');
432  $table_gui->setData($invited_users);
433  $this->tpl->setVariable('TBL_INVITED_USERS', $table_gui->getHTML());
434  }
435  }
This class represents an option in a radio group.
This class represents a property form user interface.
This class represents a section header in a property form.
setInfo($a_info)
Set Information Text.
This class represents a property in a property form.
if(isset($_POST['submit'])) $form
Create styles array
The data for the language used.
Create new PHPExcel object
obj_idprivate
setCodesSubtabs()
Set the tabs for the access codes section.
static fillAutoCompleteToolbar($parent_object, ilToolbarGUI $toolbar=null, $a_options=array(), $a_sticky=false)
fill toolbar with
+ Here is the call graph for this function:

◆ inviteUserGroupObject()

ilSurveyParticipantsGUI::inviteUserGroupObject (   $a_user_ids = array())

Invite users or groups to a survey.

Definition at line 321 of file class.ilSurveyParticipantsGUI.php.

References ilUtil\sendFailure(), and ilUtil\sendSuccess().

322  {
323  $invited = 0;
324  // add users to invitation
325  if (is_array($a_user_ids)) {
326  foreach ($a_user_ids as $user_id) {
327  $this->object->inviteUser($user_id);
328  $invited++;
329  }
330  }
331  if ($invited == 0) {
332  ilUtil::sendFailure($this->lng->txt('no_user_invited'), true);
333  return false;
334  } else {
335  ilUtil::sendSuccess(sprintf($this->lng->txt('users_invited'), $invited), true);
336  return false;
337  }
338  $this->ctrl->redirect($this, "invite");
339  }
static sendSuccess($a_info="", $a_keep=false)
Send Success Message to Screen.
static sendFailure($a_info="", $a_keep=false)
Send Failure Message to Screen.
+ Here is the call graph for this function:

◆ isAnonymousListActive()

ilSurveyParticipantsGUI::isAnonymousListActive ( )
protected

Definition at line 216 of file class.ilSurveyParticipantsGUI.php.

References $end, $total, date, and object.

Referenced by listParticipantsObject(), and setCodesSubtabs().

217  {
218  $surveySetting = new ilSetting("survey");
219  if ($surveySetting->get("anonymous_participants", false)) {
220  if ($this->object->hasAnonymizedResults() &&
221  $this->object->hasAnonymousUserList()) {
222  $end = $this->object->getEndDate();
223  if ($end && $end < date("YmdHis")) {
224  $min = $surveySetting->get("anonymous_participants_min", 0);
225  $total = $this->object->getSurveyParticipants();
226  if (!$min || sizeof($total) >= $min) {
227  return true;
228  }
229  }
230  }
231  }
232  return false;
233  }
$end
Definition: saml1-acs.php:18
$total
Definition: Utf8Test.php:87
date( 'd-M-Y', $objPHPExcel->getProperties() ->getCreated())
Create new PHPExcel object
obj_idprivate
+ Here is the caller graph for this function:

◆ listAppraiseesObject()

ilSurveyParticipantsGUI::listAppraiseesObject ( )

Definition at line 1147 of file class.ilSurveyParticipantsGUI.php.

References $ctrl, $ilCtrl, $lng, $ref_id, $tbl, $toolbar, array, ilRepositorySearchGUI\fillAutoCompleteToolbar(), handleWriteAccess(), and object.

Referenced by maintenanceObject().

1148  {
1149  $ilToolbar = $this->toolbar;
1150  $lng = $this->lng;
1151  $ilCtrl = $this->ctrl;
1152 
1153  $this->handleWriteAccess();
1154 
1155  $this->ctrl->setParameter($this, "appr360", 1);
1156 
1157  include_once './Services/Search/classes/class.ilRepositorySearchGUI.php';
1159  $this,
1160  $ilToolbar,
1161  array(
1162  'auto_complete_name' => $this->lng->txt('user'),
1163  'submit_name' => $this->lng->txt('add'),
1164  'add_search' => true,
1165  'add_from_container' => $this->ref_id
1166  )
1167  );
1168 
1169  // competence calculations
1170  include_once("./Services/Skill/classes/class.ilSkillManagementSettings.php");
1171  $skmg_set = new ilSkillManagementSettings();
1172  if ($this->object->get360SkillService() && $skmg_set->isActivated()) {
1173  $ilToolbar->addSeparator();
1174  $ilToolbar->addButton(
1175  $lng->txt("survey_calc_skills"),
1176  $ilCtrl->getLinkTargetByClass("ilsurveyskilldeterminationgui"),
1177  ""
1178  );
1179  }
1180 
1181  $ilToolbar->addSeparator();
1182  $ilToolbar->addButton(
1183  $this->lng->txt('svy_delete_all_user_data'),
1184  $this->ctrl->getLinkTarget($this, 'deleteAllUserData')
1185  );
1186 
1187  $this->ctrl->setParameter($this, "appr360", "");
1188 
1189  include_once "Modules/Survey/classes/tables/class.ilSurveyAppraiseesTableGUI.php";
1190  $tbl = new ilSurveyAppraiseesTableGUI($this, "listAppraisees");
1191  $tbl->setData($this->object->getAppraiseesData());
1192  $this->tpl->setContent($tbl->getHTML());
1193  }
$tbl
Definition: example_048.php:81
global $ilCtrl
Definition: ilias.php:18
Create styles array
The data for the language used.
Create new PHPExcel object
obj_idprivate
static fillAutoCompleteToolbar($parent_object, ilToolbarGUI $toolbar=null, $a_options=array(), $a_sticky=false)
fill toolbar with
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ listParticipantsObject()

ilSurveyParticipantsGUI::listParticipantsObject ( )
protected

Definition at line 1785 of file class.ilSurveyParticipantsGUI.php.

References $tbl, $toolbar, ilLinkButton\getInstance(), handleWriteAccess(), isAnonymousListActive(), and setCodesSubtabs().

1786  {
1787  $ilToolbar = $this->toolbar;
1788 
1789  if (!$this->isAnonymousListActive()) {
1790  $this->ctrl->redirect($this, "maintenance");
1791  }
1792 
1793  $this->handleWriteAccess();
1794  $this->setCodesSubtabs();
1795 
1796  include_once "Services/UIComponent/Button/classes/class.ilLinkButton.php";
1797  $button = ilLinkButton::getInstance();
1798  $button->setCaption("print");
1799  $button->setOnClick("window.print(); return false;");
1800  $button->setOmitPreventDoubleSubmission(true);
1801  $ilToolbar->addButtonInstance($button);
1802 
1803  include_once "Modules/Survey/classes/tables/class.ilSurveyParticipantsTableGUI.php";
1804  $tbl = new ilSurveyParticipantsTableGUI($this, "listParticipants", $this->object);
1805  $this->tpl->setContent($tbl->getHTML());
1806  }
$tbl
Definition: example_048.php:81
setCodesSubtabs()
Set the tabs for the access codes section.
+ Here is the call graph for this function:

◆ mailCodesObject()

ilSurveyParticipantsGUI::mailCodesObject ( )

Definition at line 884 of file class.ilSurveyParticipantsGUI.php.

References $_POST, handleWriteAccess(), and setCodesSubtabs().

885  {
886  $this->handleWriteAccess();
887  $this->setCodesSubtabs();
888 
889  $mailData['m_subject'] = (array_key_exists('m_subject', $_POST)) ? $_POST['m_subject'] : sprintf($this->lng->txt('default_codes_mail_subject'), $this->object->getTitle());
890  $mailData['m_message'] = (array_key_exists('m_message', $_POST)) ? $_POST['m_message'] : $this->lng->txt('default_codes_mail_message');
891  $mailData['m_notsent'] = (array_key_exists('m_notsent', $_POST)) ? $_POST['m_notsent'] : '1';
892 
893  include_once("./Modules/Survey/classes/forms/FormMailCodesGUI.php");
894  $form_gui = new FormMailCodesGUI($this);
895  $form_gui->setValuesByArray($mailData);
896  $this->tpl->setVariable("ADM_CONTENT", $form_gui->getHTML());
897  }
Class FormMailCodesGUI.
setCodesSubtabs()
Set the tabs for the access codes section.
$_POST["username"]
+ Here is the call graph for this function:

◆ mailRatersActionObject()

ilSurveyParticipantsGUI::mailRatersActionObject ( )

Definition at line 1613 of file class.ilSurveyParticipantsGUI.php.

References $_POST, $form, $ilUser, $url, $user, ilLink\_getStaticLink(), array, handleRatersAccess(), initMailRatersForm(), mailRatersObject(), object, and ilUtil\sendSuccess().

1614  {
1615  $ilUser = $this->user;
1616 
1617  $appr_id = $this->handleRatersAccess();
1618  $this->ctrl->setParameter($this, "appr_id", $appr_id);
1619 
1620  $rec_ids = explode(";", $_POST["rtr_id"]);
1621  if (!sizeof($rec_ids)) {
1622  $this->ctrl->redirect($this, "editRaters");
1623  }
1624 
1625  $form = $this->initMailRatersForm($appr_id, $rec_ids);
1626  if ($form->checkInput()) {
1627  $txt_u = $form->getInput("message_u");
1628  $txt_a = $form->getInput("message_a");
1629  $subj = $form->getInput("subject");
1630 
1631  // #12743
1632  $sender_id = (trim($ilUser->getEmail()))
1633  ? $ilUser->getId()
1634  : ANONYMOUS_USER_ID;
1635 
1636  include_once "./Services/Mail/classes/class.ilMail.php";
1637 
1638  $all_data = $this->object->getRatersData($appr_id);
1639  foreach ($rec_ids as $rec_id) {
1640  if (isset($all_data[$rec_id])) {
1641  $user = $all_data[$rec_id];
1642 
1643  // anonymous
1644  if (substr($rec_id, 0, 1) == "a") {
1645  $mytxt = $txt_a;
1646  $url = $user["href"];
1647  $rcp = $user["email"];
1648  }
1649  // reg
1650  else {
1651  $mytxt = $txt_u;
1652  $user["code"] = $this->lng->txt("survey_code_mail_on_demand");
1653  $url = ilLink::_getStaticLink($this->object->getRefId());
1654  $rcp = $user["login"]; // #15141
1655  }
1656 
1657  $mytxt = str_replace("[lastname]", $user["lastname"], $mytxt);
1658  $mytxt = str_replace("[firstname]", $user["firstname"], $mytxt);
1659  $mytxt = str_replace("[url]", $url, $mytxt);
1660  $mytxt = str_replace("[code]", $user["code"], $mytxt);
1661 
1662  $mail = new ilMail($sender_id);
1663  $mail->sendMail(
1664  $rcp, // to
1665  "", // cc
1666  "", // bcc
1667  $subj, // subject
1668  $mytxt, // message
1669  array(), // attachments
1670  array('normal') // type
1671  );
1672 
1673  $this->object->set360RaterSent(
1674  $appr_id,
1675  (substr($rec_id, 0, 1) == "a") ? 0 : (int) substr($rec_id, 1),
1676  (substr($rec_id, 0, 1) == "u") ? 0 : (int) substr($rec_id, 1)
1677  );
1678  }
1679  }
1680 
1681  ilUtil::sendSuccess($this->lng->txt("mail_sent"), true);
1682  $this->ctrl->redirect($this, "editRaters");
1683  }
1684 
1685  $form->setValuesByPost();
1686  $this->mailRatersObject($form);
1687  }
static sendSuccess($a_info="", $a_keep=false)
Send Success Message to Screen.
initMailRatersForm($appr_id, array $rec_ids)
if(isset($_POST['submit'])) $form
This class handles base functions for mail handling.
$ilUser
Definition: imgupload.php:18
Create styles array
The data for the language used.
Create new PHPExcel object
obj_idprivate
$url
mailRatersObject(ilPropertyFormGUI $a_form=null)
$_POST["username"]
+ Here is the call graph for this function:

◆ mailRatersObject()

ilSurveyParticipantsGUI::mailRatersObject ( ilPropertyFormGUI  $a_form = null)

Definition at line 1588 of file class.ilSurveyParticipantsGUI.php.

References $_POST, $tabs, handleRatersAccess(), initMailRatersForm(), and ilUtil\sendFailure().

Referenced by mailRatersActionObject().

1589  {
1590  $ilTabs = $this->tabs;
1591 
1592  if (!$a_form) {
1593  $appr_id = $this->handleRatersAccess();
1594  $this->ctrl->setParameter($this, "appr_id", $appr_id);
1595 
1596  if (!sizeof($_POST["rtr_id"])) {
1597  ilUtil::sendFailure($this->lng->txt("select_one"), true);
1598  $this->ctrl->redirect($this, "editRaters");
1599  }
1600 
1601  $a_form = $this->initMailRatersForm($appr_id, $_POST["rtr_id"]);
1602  }
1603 
1604  $ilTabs->clearTargets();
1605  $ilTabs->setBackTarget(
1606  $this->lng->txt("btn_back"),
1607  $this->ctrl->getLinkTarget($this, "editRaters")
1608  );
1609 
1610  $this->tpl->setContent($a_form->getHTML());
1611  }
initMailRatersForm($appr_id, array $rec_ids)
static sendFailure($a_info="", $a_keep=false)
Send Failure Message to Screen.
$_POST["username"]
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ maintenanceObject()

ilSurveyParticipantsGUI::maintenanceObject ( )

Participants maintenance.

Definition at line 176 of file class.ilSurveyParticipantsGUI.php.

References $data, $toolbar, $total, array, handleWriteAccess(), listAppraiseesObject(), object, and setCodesSubtabs().

177  {
178  $ilToolbar = $this->toolbar;
179 
180  if ($this->object->get360Mode()) {
181  return $this->listAppraiseesObject();
182  }
183 
184  $this->handleWriteAccess();
185  $this->setCodesSubtabs();
186 
187  $ilToolbar->addButton(
188  $this->lng->txt('svy_delete_all_user_data'),
189  $this->ctrl->getLinkTarget($this, 'deleteAllUserData')
190  );
191 
192  include_once "./Modules/Survey/classes/tables/class.ilSurveyMaintenanceTableGUI.php";
193  $table_gui = new ilSurveyMaintenanceTableGUI($this, 'maintenance');
194  $total =&$this->object->getSurveyParticipants();
195  $data = array();
196  foreach ($total as $user_data) {
197  $finished = false;
198  if ((bool) $user_data["finished"]) {
199  $finished = $user_data["finished_tstamp"];
200  }
201  $wt = $this->object->getWorkingtimeForParticipant($user_data["active_id"]);
202  $last_access = $this->object->getLastAccess($user_data["active_id"]);
203  array_push($data, array(
204  'id' => $user_data["active_id"],
205  'name' => $user_data["sortname"],
206  'login' => $user_data["login"],
207  'last_access' => $last_access,
208  'workingtime' => $wt,
209  'finished' => $finished
210  ));
211  }
212  $table_gui->setData($data);
213  $this->tpl->setVariable('ADM_CONTENT', $table_gui->getHTML());
214  }
$total
Definition: Utf8Test.php:87
Create styles array
The data for the language used.
Create new PHPExcel object
obj_idprivate
setCodesSubtabs()
Set the tabs for the access codes section.
+ Here is the call graph for this function:

◆ removeUTF8Bom()

ilSurveyParticipantsGUI::removeUTF8Bom (   $a_text)
protected

Definition at line 994 of file class.ilSurveyParticipantsGUI.php.

Referenced by importExternalRecipientsFromFileObject().

995  {
996  $bom = pack('H*', 'EFBBBF');
997  return preg_replace('/^' . $bom . '/', '', $a_text);
998  }
+ Here is the caller graph for this function:

◆ saveInvitationStatusObject()

ilSurveyParticipantsGUI::saveInvitationStatusObject ( )

Saves the status of the invitation tab.

Definition at line 344 of file class.ilSurveyParticipantsGUI.php.

References $_POST, ilObjSurvey\INVITATION_OFF, ilObjSurvey\INVITATION_ON, ilObjSurvey\MODE_PREDEFINED_USERS, ilObjSurvey\MODE_UNLIMITED, and ilUtil\sendSuccess().

345  {
346  $mode = $_POST['invitation'];
347  switch ($mode) {
348  case 0:
349  $this->object->setInvitation(ilObjSurvey::INVITATION_OFF);
350  break;
351  case 1:
352  $this->object->setInvitationAndMode(ilObjSurvey::INVITATION_ON, ilObjSurvey::MODE_UNLIMITED);
353  break;
354  case 2:
355  $this->object->setInvitationAndMode(ilObjSurvey::INVITATION_ON, ilObjSurvey::MODE_PREDEFINED_USERS);
356  break;
357  }
358  $this->object->saveToDb();
359  ilUtil::sendSuccess($this->lng->txt('msg_obj_modified'), true);
360  $this->ctrl->redirect($this, "invite");
361  }
static sendSuccess($a_info="", $a_keep=false)
Send Success Message to Screen.
const MODE_PREDEFINED_USERS
$_POST["username"]
+ Here is the call graph for this function:

◆ sendCodesMailObject()

ilSurveyParticipantsGUI::sendCodesMailObject ( )

Definition at line 899 of file class.ilSurveyParticipantsGUI.php.

References $_POST, $ilUser, $lang, $title, $user, handleWriteAccess(), ilUtil\sendFailure(), ilUtil\sendSuccess(), and setCodesSubtabs().

900  {
902 
903  $this->handleWriteAccess();
904  $this->setCodesSubtabs();
905 
906  include_once("./Modules/Survey/classes/forms/FormMailCodesGUI.php");
907  $form_gui = new FormMailCodesGUI($this);
908  if ($form_gui->checkInput()) {
909  $url_exists = strpos($_POST['m_message'], '[url]') !== false;
910  if (!$url_exists) {
911  ilUtil::sendFailure($this->lng->txt('please_enter_mail_url'));
912  $form_gui->setValuesByPost();
913  } else {
914  if ($_POST['savemessage'] == 1) {
916  $title = (strlen($_POST['savemessagetitle'])) ? $_POST['savemessagetitle'] : ilStr::substr($_POST['m_message'], 0, 40) . '...';
917  $this->object->saveUserSettings($ilUser->getId(), 'savemessage', $title, $_POST['m_message']);
918  }
919 
920  $lang = $ilUser->getPref("survey_code_language");
921  if (!$lang) {
922  $lang = $this->lng->getDefaultLanguage();
923  }
924  $this->object->sendCodes($_POST['m_notsent'], $_POST['m_subject'], nl2br($_POST['m_message']), $lang);
925  ilUtil::sendSuccess($this->lng->txt('mail_sent'), true);
926  $this->ctrl->redirect($this, 'mailCodes');
927  }
928  } else {
929  $form_gui->setValuesByPost();
930  }
931  $this->tpl->setVariable("ADM_CONTENT", $form_gui->getHTML());
932  }
static sendSuccess($a_info="", $a_keep=false)
Send Success Message to Screen.
$ilUser
Definition: imgupload.php:18
static sendFailure($a_info="", $a_keep=false)
Send Failure Message to Screen.
Class FormMailCodesGUI.
setCodesSubtabs()
Set the tabs for the access codes section.
$_POST["username"]
+ Here is the call graph for this function:

◆ setCodeLanguageObject()

ilSurveyParticipantsGUI::setCodeLanguageObject ( )

Change survey language for direct access URL's.

Definition at line 529 of file class.ilSurveyParticipantsGUI.php.

References $_POST, $ilUser, $user, and ilUtil\sendSuccess().

530  {
531  if (strcmp($_POST["lang"], "-1") != 0) {
533  $ilUser->writePref("survey_code_language", $_POST["lang"]);
534  }
535  ilUtil::sendSuccess($this->lng->txt('language_changed'), true);
536  $this->ctrl->redirect($this, 'codes');
537  }
static sendSuccess($a_info="", $a_keep=false)
Send Success Message to Screen.
$ilUser
Definition: imgupload.php:18
$_POST["username"]
+ Here is the call graph for this function:

◆ setCodesSubtabs()

ilSurveyParticipantsGUI::setCodesSubtabs ( )

Set the tabs for the access codes section.

private

Definition at line 240 of file class.ilSurveyParticipantsGUI.php.

References $data, $tabs, $template, array, isAnonymousListActive(), and object.

Referenced by codesObject(), deleteSavedMessageObject(), editCodesObject(), importAccessCodesObject(), importExternalMailRecipientsFromFileFormObject(), importExternalMailRecipientsFromTextFormObject(), insertSavedMessageObject(), inviteObject(), listParticipantsObject(), mailCodesObject(), maintenanceObject(), and sendCodesMailObject().

241  {
242  $ilTabs = $this->tabs;
243 
244  // not used in 360° mode
245 
246  // maintenance
247  $ilTabs->addSubTabTarget(
248  "sub_tab_dashboard",
249  $this->ctrl->getLinkTarget($this, 'maintenance'),
250  array("maintenance", "deleteAllUserData"),
251  ""
252  );
253 
254  if ($this->isAnonymousListActive()) {
255  $ilTabs->addSubTabTarget(
256  "svy_anonymous_participants_svy",
257  $this->ctrl->getLinkTarget($this, 'listParticipants'),
258  array("listParticipants"),
259  ""
260  );
261  }
262 
263  if (!$this->object->isAccessibleWithoutCode()) {
264  $ilTabs->addSubTabTarget(
265  "codes",
266  $this->ctrl->getLinkTarget($this, 'codes'),
267  array("codes", "editCodes", "createSurveyCodes", "setCodeLanguage", "deleteCodes", "exportCodes",
268  "importExternalMailRecipientsFromFileForm", "importExternalMailRecipientsFromTextForm"),
269  ""
270  );
271  }
272 
273  $hidden_tabs = array();
274  $template = $this->object->getTemplate();
275  if ($template) {
276  include_once "Services/Administration/classes/class.ilSettingsTemplate.php";
278  $hidden_tabs = $template->getHiddenTabs();
279  }
280 
281  // #12277 - invite
282  if (!in_array("invitation", $hidden_tabs)) {
283  $ilTabs->addSubTabTarget(
284  "invitation",
285  $this->ctrl->getLinkTarget($this, 'invite'),
286  array("invite", "saveInvitationStatus",
287  "inviteUserGroup", "disinviteUserGroup"),
288  ""
289  );
290  }
291 
292  $data = $this->object->getExternalCodeRecipients();
293  if (count($data)) {
294  $ilTabs->addSubTabTarget(
295  "mail_survey_codes",
296  $this->ctrl->getLinkTarget($this, "mailCodes"),
297  array("mailCodes", "sendCodesMail", "insertSavedMessage", "deleteSavedMessage"),
298  ""
299  );
300  }
301  }
$template
Create styles array
The data for the language used.
Create new PHPExcel object
obj_idprivate
Settings template application class.
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ updateCodesObject()

ilSurveyParticipantsGUI::updateCodesObject ( )

Definition at line 638 of file class.ilSurveyParticipantsGUI.php.

References $_POST, $error, $errors, $id, array, object, ilUtil\sendFailure(), and ilUtil\sendSuccess().

639  {
640  if (!is_array($_POST["chb_code"])) {
641  $this->ctrl->redirect($this, 'codes');
642  }
643 
644  $errors = array();
645  $error_message = "";
646  foreach ($_POST["chb_code"] as $id) {
647  if (!$this->object->updateCode(
648  $id,
649  $_POST["chb_mail"][$id],
650  $_POST["chb_lname"][$id],
651  $_POST["chb_fname"][$id],
652  $_POST["chb_sent"][$id]
653  )) {
654  array_push($errors, array($_POST["chb_mail"][$id], $_POST["chb_lname"][$id], $_POST["chb_fname"][$id]));
655  };
656  }
657  if (empty($errors)) {
658  ilUtil::sendSuccess($this->lng->txt('settings_saved'), true);
659  } else {
660  foreach ($errors as $error) {
661  $error_message .= sprintf($this->lng->txt("error_save_code"), $error[0], $error[1], $error[2]);
662  }
663  ilUtil::sendFailure($error_message, true);
664  }
665 
666  $this->ctrl->redirect($this, 'codes');
667  }
static sendSuccess($a_info="", $a_keep=false)
Send Success Message to Screen.
if(!array_key_exists('StateId', $_REQUEST)) $id
$error
Definition: Error.php:17
Create styles array
The data for the language used.
static sendFailure($a_info="", $a_keep=false)
Send Failure Message to Screen.
$errors
Definition: index.php:6
Create new PHPExcel object
obj_idprivate
$_POST["username"]
+ Here is the call graph for this function:

Field Documentation

◆ $access

◆ $ctrl

ilSurveyParticipantsGUI::$ctrl
protected

Definition at line 19 of file class.ilSurveyParticipantsGUI.php.

Referenced by executeCommand(), and listAppraiseesObject().

◆ $has_write

ilSurveyParticipantsGUI::$has_write
protected

◆ $lng

ilSurveyParticipantsGUI::$lng
protected

◆ $log

ilSurveyParticipantsGUI::$log
protected

◆ $object

ilSurveyParticipantsGUI::$object
protected

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

Referenced by getObject().

◆ $parent_gui

ilSurveyParticipantsGUI::$parent_gui
protected

Definition at line 61 of file class.ilSurveyParticipantsGUI.php.

◆ $rbacsystem

ilSurveyParticipantsGUI::$rbacsystem
protected

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

Referenced by inviteObject().

◆ $ref_id

ilSurveyParticipantsGUI::$ref_id
protected

Definition at line 63 of file class.ilSurveyParticipantsGUI.php.

Referenced by editRatersObject(), and listAppraiseesObject().

◆ $tabs

◆ $toolbar

ilSurveyParticipantsGUI::$toolbar
protected

◆ $tpl

ilSurveyParticipantsGUI::$tpl
protected

◆ $user


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