56 public function __construct($a_data, $a_id = 0, $a_call_by_reference =
true, $a_prepare_output =
true)
61 $this->tpl = $DIC[
'tpl'];
62 $this->ctrl = $DIC[
'ilCtrl'];
63 $this->usr = $DIC[
'ilUser'];
64 $this->error_object = $DIC[
'ilErr'];
65 $this->lng = $DIC[
'lng'];
66 $this->lng->loadLanguageModule(
'iass');
67 $this->tpl->loadStandardTemplate();
74 if (is_object($this->
object)) {
75 $this->locator->addItem($this->object->getTitle(), $this->ctrl->getLinkTarget($this,
"view"),
"", $this->
object->getRefId());
82 $this->object->getType(),
83 $this->
object->getRefId(),
84 $this->
object->getId(),
91 $next_class = $this->ctrl->getNextClass($this);
92 $cmd = $this->ctrl->getCmd();
96 switch ($next_class) {
97 case 'ilpermissiongui':
98 $this->tabs_gui->activateTab(self::TAB_PERMISSION);
100 $this->ctrl->forwardCommand($ilPermissionGUI);
102 case 'ilindividualassessmentsettingsgui':
103 $this->tabs_gui->activateTab(self::TAB_SETTINGS);
104 $gui = $this->
object->getSettingsGUI();
105 $this->ctrl->forwardCommand($gui);
107 case 'ilindividualassessmentmembersgui':
110 case 'ilinfoscreengui':
111 $this->tabs_gui->activateTab(self::TAB_INFO);
113 $this->ctrl->forwardCommand($info);
115 case 'illearningprogressgui':
116 if (!$this->object->accessHandler()->mayViewObject()) {
119 $this->tabs_gui->activateTab(self::TAB_LP);
122 $this->object->getRefId(),
125 $this->ctrl->forwardCommand($learning_progress);
127 case "ilcommonactiondispatchergui":
129 $this->ctrl->forwardCommand($gui);
132 $this->tabs_gui->activateTab(self::TAB_EXPORT);
134 $exp_gui->addFormat(
"xml");
135 $ret = $this->ctrl->forwardCommand($exp_gui);
137 case 'ilobjectmetadatagui':
139 $this->tabs_gui->activateTab(self::TAB_META_DATA);
141 $this->ctrl->forwardCommand($md_gui);
143 case 'ilobjectcopygui':
146 $this->ctrl->forwardCommand($cp);
151 if ($this->object->accessHandler()->mayEditMembers()) {
152 $this->ctrl->setCmdClass(
'ilIndividualassessmentmembersgui');
164 $this->tabs_gui->activateTab(self::TAB_INFO);
165 $this->ctrl->setCmd(
'showSummary');
166 $this->ctrl->setCmdClass(
'ilinfoscreengui');
168 $this->ctrl->forwardCommand($info);
174 $this->tabs_gui->activateTab(self::TAB_MEMBERS);
175 $gui = $this->
object->getMembersGUI();
176 $this->ctrl->forwardCommand($gui);
185 $record_gui->parse();
187 $info->addMetaDataSections($this->object->getId(), 0, $this->
object->getType());
190 if ($this->object->loadMembers()->userAllreadyMember($this->usr)) {
200 $member = $this->
object->membersStorage()->loadMember($this->
object, $this->usr);
202 if ($member->finalized()) {
205 if ($member->notify() && $member->finalized()) {
206 $info->
addProperty($this->
txt(
'grading_record'), nl2br($member->record()));
207 if (($member->viewFile() || $view_self) && $member->fileName() && $member->fileName() !=
"") {
208 $tpl =
new ilTemplate(
"tpl.iass_user_file_download.html",
true,
true,
"Modules/IndividualAssessment");
209 $tpl->setVariable(
"FILE_NAME", $member->fileName());
210 $tpl->setVariable(
"HREF", $this->ctrl->getLinkTarget($this,
"downloadFile"));
220 $member = $this->
object->membersStorage()->loadMember($this->
object, $this->usr);
221 $file_storage = $this->
object->getFileStorage();
222 $file_storage->setUserId($this->usr->getId());
228 $content = $this->
object->getSettings()->getContent();
229 if ($content !== null && $content !==
'') {
238 $info_settings = $this->
object->getInfoSettings();
241 $info->
addProperty($this->
txt(
'iass_contact'), $info_settings->getContact());
242 $info->
addProperty($this->
txt(
'iass_responsibility'), $info_settings->getResponsibility());
243 $info->
addProperty($this->
txt(
'iass_phone'), $info_settings->getPhone());
244 $info->
addProperty($this->
txt(
'iass_mails'), $info_settings->getMails());
245 $info->
addProperty($this->
txt(
'iass_consultation_hours'), $info_settings->getConsultationHours());
253 if ($val !== null && $val !==
'') {
257 if ($val !== null && $val !==
'') {
261 if ($val !== null && $val !==
'') {
265 if ($val !== null && $val !==
'') {
269 if ($val !== null && $val !==
'') {
277 if ($this->object->accessHandler()->mayViewObject()) {
278 $this->tabs_gui->addTab(
280 $this->
txt(
'info_short'),
284 if ($this->object->accessHandler()->mayEditObject()) {
285 $this->tabs_gui->addTab(
287 $this->
txt(
'settings'),
291 $mdtab = $mdgui->getTab();
293 $this->tabs_gui->addTab(
295 $this->
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->
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->
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);
358 $this->ctrl->redirectToURL($link);
368 $this->error_object->raiseError($this->
txt(
"msg_no_perm_read"), $this->error_object->WARNING);
371 public static function _goto($a_target, $a_add =
'')
374 if ($DIC[
'ilAccess']->checkAccess(
'write',
'', $a_target)) {
377 if ($DIC[
'ilAccess']->checkAccess(
'read',
'', $a_target)) {
386 return $this->
txt(
'iass_status_pending');
389 return $this->
txt(
'iass_status_completed');
392 return $this->
txt(
'iass_status_failed');
399 ilUtil::sendSuccess($this->
txt(
"iass_added"),
true);
400 $this->ctrl->setParameter($this,
"ref_id", $a_new_object->
getRefId());
401 ilUtil::redirect($this->ctrl->getLinkTargetByClass(
'ilIndividualassessmentsettingsgui',
'edit',
'',
false,
false));
407 if ($this->object->accessHandler()->mayViewObject()) {
414 protected function txt(
string $code) : string
416 return $this->lng->txt($code);
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.
__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.
initEditForm()
Init object edit form.
Navigation History of Repository Items.
addProperty($a_name, $a_value, $a_link="")
add a property to current section
__construct(Container $dic, ilPlugin $plugin)
const LP_CONTEXT_REPOSITORY
getCreationMode()
get creation mode
getRefId()
get reference id public
New PermissionGUI (extends from old ilPermission2GUI) RBAC related output.
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)