21 require_once
'Services/Object/classes/class.ilObjectGUI.php';
22 require_once
'Modules/IndividualAssessment/classes/class.ilIndividualAssessmentLP.php';
23 require_once
'Services/Tracking/classes/class.ilObjUserTracking.php';
36 public function __construct($a_data, $a_id = 0, $a_call_by_reference =
true, $a_prepare_output =
true)
41 $this->tpl = $DIC[
'tpl'];
42 $this->ctrl = $DIC[
'ilCtrl'];
43 $this->usr = $DIC[
'ilUser'];
44 $this->
ilias = $DIC[
'ilias'];
45 $this->lng = $DIC[
'lng'];
47 $this->lng->loadLanguageModule(
'iass');
48 $this->tpl->getStandardTemplate();
49 $this->locator = $DIC[
'ilLocator'];
51 parent::__construct($a_data, $a_id, $a_call_by_reference, $a_prepare_output);
56 if (is_object($this->
object)) {
57 $this->locator->addItem($this->object->getTitle(), $this->ctrl->getLinkTarget($this,
"view"),
"", $this->
object->getRefId());
64 $this->object->getType(),
65 $this->
object->getRefId(),
66 $this->
object->getId(),
74 $next_class = $this->ctrl->getNextClass($this);
75 $cmd = $this->ctrl->getCmd();
79 switch ($next_class) {
80 case 'ilpermissiongui':
81 $this->tabs_gui->setTabActive(self::TAB_PERMISSION);
82 require_once
'Services/AccessControl/classes/class.ilPermissionGUI.php';
84 $this->ctrl->forwardCommand($ilPermissionGUI);
86 case 'ilindividualassessmentsettingsgui':
87 $this->tabs_gui->setTabActive(self::TAB_SETTINGS);
88 require_once
'Modules/IndividualAssessment/classes/class.ilIndividualAssessmentSettingsGUI.php';
90 $this->ctrl->forwardCommand($gui);
92 case 'ilindividualassessmentmembersgui':
95 case 'ilinfoscreengui':
96 $this->tabs_gui->setTabActive(self::TAB_INFO);
97 require_once
'Services/InfoScreen/classes/class.ilInfoScreenGUI.php';
99 $this->ctrl->forwardCommand(
$info);
101 case 'illearningprogressgui':
102 if (!$this->object->accessHandler()->mayViewObject()) {
105 require_once
'Services/Tracking/classes/class.ilLearningProgressGUI.php';
106 $this->tabs_gui->setTabActive(self::TAB_LP);
109 $this->object->getRefId(),
112 $this->ctrl->forwardCommand($learning_progress);
114 case "ilcommonactiondispatchergui":
115 include_once(
"Services/Object/classes/class.ilCommonActionDispatcherGUI.php");
117 $this->ctrl->forwardCommand($gui);
120 include_once(
"./Services/Export/classes/class.ilExportGUI.php");
121 $this->tabs_gui->setTabActive(self::TAB_EXPORT);
123 $exp_gui->addFormat(
"xml");
124 $ret = $this->ctrl->forwardCommand($exp_gui);
126 case 'ilobjectmetadatagui':
128 $this->tabs_gui->activateTab(self::TAB_META_DATA);
129 include_once
'Services/Object/classes/class.ilObjectMetaDataGUI.php';
131 $this->ctrl->forwardCommand($md_gui);
133 case 'ilobjectcopygui':
134 include_once
'./Services/Object/classes/class.ilObjectCopyGUI.php';
137 $this->ctrl->forwardCommand($cp);
142 if ($this->object->accessHandler()->mayEditMembers()) {
143 $this->ctrl->setCmdClass(
'ilIndividualassessmentmembersgui');
160 $this->tabs_gui->setTabActive(self::TAB_INFO);
161 require_once
'Services/InfoScreen/classes/class.ilInfoScreenGUI.php';
162 $this->ctrl->setCmd(
'showSummary');
163 $this->ctrl->setCmdClass(
'ilinfoscreengui');
165 $this->ctrl->forwardCommand(
$info);
171 $this->tabs_gui->setTabActive(self::TAB_MEMBERS);
172 require_once
'Modules/IndividualAssessment/classes/class.ilIndividualAssessmentMembersGUI.php';
174 $this->ctrl->forwardCommand($gui);
181 include_once(
'Services/AdvancedMetaData/classes/class.ilAdvancedMDRecordGUI.php');
184 $record_gui->parse();
186 $info->addMetaDataSections($this->object->getId(), 0, $this->
object->getType());
189 if ($this->object->loadMembers()->userAllreadyMember($this->usr)) {
199 $member = $this->
object->membersStorage()->loadMember($this->
object, $this->usr);
200 $info->
addSection($this->lng->txt(
'grading_info'));
201 if ($member->finalized()) {
204 if ($member->notify() && $member->finalized()) {
205 $info->
addProperty($this->lng->txt(
'grading_record'), nl2br($member->record()));
206 if (($member->viewFile() || $view_self) && $member->fileName() && $member->fileName() !=
"") {
207 $tpl =
new ilTemplate(
"tpl.iass_user_file_download.html",
true,
true,
"Modules/IndividualAssessment");
208 $tpl->setVariable(
"FILE_NAME", $member->fileName());
209 $tpl->setVariable(
"HREF", $this->ctrl->getLinkTarget($this,
"downloadFile"));
219 $member = $this->
object->membersStorage()->loadMember($this->
object, $this->usr);
220 $file_storage = $this->
object->getFileStorage();
221 $file_storage->setUserId($this->usr->getId());
227 $content = $this->
object->getSettings()->content();
228 if ($content !== null && $content !==
'') {
229 $info->
addSection($this->lng->txt(
'general'));
230 $info->
addProperty($this->lng->txt(
'content'), $content);
237 $info_settings = $this->
object->getInfoSettings();
239 $info->
addSection($this->lng->txt(
'iass_contact_info'));
240 $info->
addProperty($this->lng->txt(
'iass_contact'), $info_settings->contact());
241 $info->
addProperty($this->lng->txt(
'iass_responsibility'), $info_settings->responsibility());
242 $info->
addProperty($this->lng->txt(
'iass_phone'), $info_settings->phone());
243 $info->
addProperty($this->lng->txt(
'iass_mails'), $info_settings->mails());
244 $info->
addProperty($this->lng->txt(
'iass_consultation_hours'), $info_settings->consultationHours());
251 $val = $info_settings->
contact();
252 if ($val !== null && $val !==
'') {
256 if ($val !== null && $val !==
'') {
259 $val = $info_settings->
phone();
260 if ($val !== null && $val !==
'') {
263 $val = $info_settings->
mails();
264 if ($val !== null && $val !==
'') {
268 if ($val !== null && $val !==
'') {
276 if ($this->object->accessHandler()->mayViewObject()) {
277 $this->tabs_gui->addTab(
279 $this->lng->txt(
'info_short'),
283 if ($this->object->accessHandler()->mayEditObject()) {
284 $this->tabs_gui->addTab(
286 $this->lng->txt(
'settings'),
289 include_once
"Services/Object/classes/class.ilObjectMetaDataGUI.php";
291 $mdtab = $mdgui->getTab();
293 $this->tabs_gui->addTab(
295 $this->lng->txt(
"meta_data"),
300 if ($this->object->accessHandler()->mayEditMembers()
301 || $this->
object->accessHandler()->mayGradeUser()
302 || $this->
object->accessHandler()->mayAmendGradeUser()
303 || $this->
object->accessHandler()->mayViewUser()) {
304 $this->tabs_gui->addTab(
306 $this->lng->txt(
'il_iass_members'),
310 if (($this->object->accessHandler()->mayViewUser()
311 || $this->
object->accessHandler()->mayGradeUser()
312 || ($this->
object->loadMembers()->userAllreadyMember($this->usr)
313 && $this->
object->isActiveLP()))
315 $this->tabs_gui->addTab(
317 $this->lng->txt(
'learning_progress'),
318 $this->ctrl->getLinkTargetByClass(
'illearningprogressgui')
322 if ($this->object->accessHandler()->mayEditObject()) {
323 $this->tabs_gui->addTarget(
325 $this->ctrl->getLinkTargetByClass(
'ilexportgui',
''),
331 if ($this->object->accessHandler()->mayEditPermissions()) {
332 $this->tabs_gui->addTarget(
333 self::TAB_PERMISSION,
334 $this->ctrl->getLinkTargetByClass(
'ilpermissiongui',
'perm'),
344 if ($a_cmd ==
'settings') {
345 return $this->ctrl->getLinkTargetByClass(
'ilindividualassessmentsettingsgui',
'edit');
347 if ($a_cmd ==
'info') {
348 return $this->ctrl->getLinkTarget($this,
'view');
350 if ($a_cmd ==
'members') {
351 return $this->ctrl->getLinkTargetByClass(
'ilindividualassessmentmembersgui',
'view');
353 return $this->ctrl->getLinkTarget($this, $a_cmd);
364 $DIC[
'ilias']->raiseError($DIC[
'lng']->txt(
"msg_no_perm_read"), $DIC[
'ilias']->error_obj->WARNING);
367 public static function _goto($a_target, $a_add =
'')
370 if ($DIC[
'ilAccess']->checkAccess(
'write',
'', $a_target)) {
373 if ($DIC[
'ilAccess']->checkAccess(
'read',
'', $a_target)) {
382 return $this->lng->txt(
'iass_status_pending');
385 return $this->lng->txt(
'iass_status_completed');
388 return $this->lng->txt(
'iass_status_failed');
395 ilUtil::sendSuccess($this->lng->txt(
"iass_added"),
true);
396 $this->ctrl->setParameter($this,
"ref_id", $a_new_object->
getRefId());
397 ilUtil::redirect($this->ctrl->getLinkTargetByClass(
'ilIndividualassessmentsettingsgui',
'edit',
'',
false,
false));
403 if ($this->object->accessHandler()->mayViewObject()) {
static _recordReadEvent( $a_type, $a_ref_id, $obj_id, $usr_id, $isCatchupWriteEvents=true, $a_ext_rc=false, $a_ext_time=false)
Records a read event and catches up with write events.
GUI class for the workflow of copying objects.
A simple carrier for iass info-settings.
__construct($a_data, $a_id=0, $a_call_by_reference=true, $a_prepare_output=true)
For the purpose of streamlining the grading and learning-process status definition outside of tests...
shouldShowContactInfo(ilIndividualAssessmentInfoSettings $info_settings)
addSection($a_title)
add a new section
addMemberDataToInfo(ilInfoScreenGUI $info)
recordIndividualAssessmentRead()
getEntryForStatus($a_status)
Export User Interface Class.
prepareOutput($a_show_subobjects=true)
prepare output
static _enabledLearningProgress()
check wether learing progress is enabled or not
addItem( $a_ref_id, $a_link, $a_type, $a_title="", $a_sub_obj_id="", $a_goto_link="")
Add an item to the stack.
addContactDataToInfo(ilInfoScreenGUI $info)
setInfoObject($info)
get info sections
addGeneralDataToInfo(ilInfoScreenGUI $info)
static _gotoRepositoryNode($a_ref_id, $a_cmd="frameset")
Goto repository root.
Class ilObjectGUI Basic methods of all Output classes.
special template class to simplify handling of ITX/PEAR
redirection script todo: (a better solution should control the processing via a xml file) ...
initEditForm()
Init object edit form.
Navigation History of Repository Items.
addProperty($a_name, $a_value, $a_link="")
add a property to current section
const LP_CONTEXT_REPOSITORY
getCreationMode()
get creation mode
getRefId()
get reference id public
New PermissionGUI (extends from old ilPermission2GUI) RBAC related output.
For the purpose of streamlining the grading and learning-process status definition outside of tests...
static redirect($a_script)
checkPermissionBool($a_perm, $a_cmd="", $a_type="", $a_ref_id=null)
Check permission.
Class ilObjUserTrackingGUI.
static _getLink($a_ref_id, $a_type='', $a_params=array(), $append="")
static getInstanceFromAjaxCall()
(Re-)Build instance from ajax call
static deliverFile( $a_file, $a_filename, $a_mime='', $isInline=false, $removeAfterDelivery=false, $a_exit_after=true)
deliver file for download via browser.
static _goto($a_target, $a_add='')
afterSave(ilObject $a_new_object)