31 $lng->loadLanguageModule(
"exc");
33 $tpl =
new ilTemplate(
"tpl.assignment_head.html",
true,
true,
"Modules/Exercise");
44 $tpl->setCurrentBlock(
"prop");
45 $tpl->setVariable(
"PROP", $lng->txt(
"exc_ended_on"));
46 $tpl->setVariable(
"PROP_VAL",
48 $tpl->parseCurrentBlock();
54 $tpl->setCurrentBlock(
"prop");
55 $tpl->setVariable(
"PROP", $lng->txt(
"exc_peer_review_deadline"));
56 $tpl->setVariable(
"PROP_VAL",
58 $tpl->parseCurrentBlock();
63 $tpl->setCurrentBlock(
"prop");
64 $tpl->setVariable(
"PROP", $lng->txt(
"exc_starting_on"));
65 $tpl->setVariable(
"PROP_VAL",
67 $tpl->parseCurrentBlock();
72 $tpl->setCurrentBlock(
"prop");
73 $tpl->setVariable(
"PROP", $lng->txt(
"exc_time_to_send"));
74 $tpl->setVariable(
"PROP_VAL", $time_str);
75 $tpl->parseCurrentBlock();
79 $tpl->setCurrentBlock(
"prop");
80 $tpl->setVariable(
"PROP", $lng->txt(
"exc_edit_until"));
81 $tpl->setVariable(
"PROP_VAL",
83 $tpl->parseCurrentBlock();
88 $tpl->setCurrentBlock(
"prop");
89 $tpl->setVariable(
"PROP", $lng->txt(
"exc_individual_deadline"));
90 $tpl->setVariable(
"PROP_VAL",
92 $tpl->parseCurrentBlock();
99 $mand =
" (".$lng->txt(
"exc_mandatory").
")";
107 $tpl->setVariable(
"ALT_STATUS", $lng->txt(
"exc_".$stat));
117 $this->current_ass_id = $a_ass->
getId();
119 $tpl =
new ilTemplate(
"tpl.assignment_body.html",
true,
true,
"Modules/Exercise");
121 include_once(
"./Services/InfoScreen/classes/class.ilInfoScreenGUI.php");
122 include_once(
"./Services/UIComponent/Button/classes/class.ilLinkButton.php");
125 $info->setTableClass(
"");
130 if ($this->exc->getShowSubmissions())
141 $tpl->setVariable(
"CONTENT",
$info->getHTML());
156 $a_info->
addSection($lng->txt(
"exc_instruction"));
158 $is_html = (strlen($inst) != strlen(strip_tags($inst)));
174 $a_info->
addSection($lng->txt(
"exc_schedule"));
189 $late_dl =
"<br />".sprintf($lng->txt(
"exc_late_submission_warning"), $late_dl);
190 $late_dl =
'<span class="warning">'.$late_dl.
'</span>';
204 $a_info->
addProperty($lng->txt(
"exc_edit_until"), $until);
218 $a_info->
addProperty($lng->txt(
"exc_individual_deadline"), $until);
223 $a_info->
addProperty($lng->txt(
"exc_time_to_send"),
224 "<b>".$this->getTimeString($idl).
"</b>");
235 $button->setCaption(
"exc_list_submission");
238 $a_info->
addProperty($lng->txt(
"exc_public_submission"), $button->render());
242 $a_info->
addProperty($lng->txt(
"exc_public_submission"),
243 $lng->txt(
"exc_msg_public_submission"));
266 $a_info->
addSection($lng->txt(
"exc_your_submission"));
268 include_once
"Modules/Exercise/classes/class.ilExSubmission.php";
271 include_once
"Modules/Exercise/classes/class.ilExSubmissionGUI.php";
275 if($submission->hasSubmitted())
277 $last_sub = $submission->getLastSubmission();
281 $a_info->
addProperty($lng->txt(
"exc_last_submission"), $last_sub);
285 include_once
"Modules/Exercise/classes/class.ilExPeerReviewGUI.php";
312 if ($lpcomment !=
"" ||
314 $status !=
"notgraded" ||
316 $a_show_global_feedback)
318 $a_info->
addSection($lng->txt(
"exc_feedback_from_tutor"));
319 if ($lpcomment !=
"")
335 else if ($status !=
"notgraded")
337 $img =
'<img src="'.ilUtil::getImagePath(
"scorm/".$status.
".svg").
'" '.
338 ' alt="'.$lng->txt(
"exc_".$status).
'" title="'.$lng->txt(
"exc_".$status).
341 $img.
" ".$lng->txt(
"exc_".$status));
346 $a_info->
addSection($lng->txt(
"exc_fb_files").
347 '<a name="fb'.$a_ass->getId().
'"></a>');
351 $files = $storage->getFeedbackFiles($a_feedback_id);
355 $lng->txt(
"download"),
362 if($a_show_global_feedback)
364 $a_info->
addSection($lng->txt(
"exc_global_feedback_file"));
367 $lng->txt(
"download"),
380 if ($a_deadline == 0)
382 return $lng->txt(
"exc_no_deadline_specified");
385 if ($a_deadline -
time() <= 0)
387 $time_str = $lng->txt(
"exc_time_over_short");
401 if(is_array($a_params))
403 foreach($a_params as $name => $value)
405 $ilCtrl->setParameterByClass(
"ilexsubmissiongui", $name, $value);
409 $ilCtrl->setParameterByClass(
"ilexsubmissiongui",
"ass_id", $this->current_ass_id);
410 $url = $ilCtrl->getLinkTargetByClass(
"ilexsubmissiongui", $a_cmd);
411 $ilCtrl->setParameterByClass(
"ilexsubmissiongui",
"ass_id",
"");
413 if(is_array($a_params))
415 foreach($a_params as $name => $value)
417 $ilCtrl->setParameterByClass(
"ilexsubmissiongui", $name,
"");
getPeerReview()
Get peer review status.
addSubmissionFeedback(ilInfoScreenGUI $a_info, ilExAssignment $a_ass, $a_feedback_id, $a_show_global_feedback)
static getOverviewContent(ilInfoScreenGUI $a_info, ilExSubmission $a_submission)
getMemberStatus($a_user_id=null)
getPersonalDeadline($a_user_id)
Get individual deadline.
addPublicSubmissions(ilInfoScreenGUI $a_info, ilExAssignment $a_ass)
getFeedbackDate()
Get (global) feedback file availability date.
getStartTime()
Get start time (timestamp)
getId()
Get assignment id.
getDeadline()
Get deadline (timestamp)
addInstructions(ilInfoScreenGUI $a_info, ilExAssignment $a_ass)
addSection($a_title)
add a new section
addSchedule(ilInfoScreenGUI $a_info, ilExAssignment $a_ass)
GUI class for exercise assignments.
getExerciseId()
Get exercise id.
getOverviewBody(ilExAssignment $a_ass)
Get assignment body for overview.
getTimeString($a_deadline)
Get time string for deadline.
addFiles(ilInfoScreenGUI $a_info, ilExAssignment $a_ass)
static getImagePath($img, $module_path="", $mode="output", $offline=false)
get image path (for images located in a template directory)
static makeClickable($a_text, $detectGotoLinks=false)
makeClickable In Texten enthaltene URLs und Mail-Adressen klickbar machen
special template class to simplify handling of ITX/PEAR
static period2String(ilDateTime $a_from, $a_to=null)
Return a string of time period.
static formatDate(ilDateTime $date)
Format a date public.
getFeedbackFile()
Get (global) feedback file.
Create styles array
The data for the language used.
__construct(ilObjExercise $a_exc)
Constructor.
getMandatory()
Get mandatory.
getOverviewHeader(ilExAssignment $a_ass)
Get assignment header for overview.
afterDeadlineStrict($a_include_personal=true)
const FEEDBACK_DATE_DEADLINE
addProperty($a_name, $a_value, $a_link="")
add a property to current section
getInstruction()
Get instruction.
addSubmission(ilInfoScreenGUI $a_info, ilExAssignment $a_ass)
static getOverviewContent(ilInfoScreenGUI $a_info, ilExSubmission $a_submission)
getPeerReviewDeadline()
Get peer review deadline (timestamp)
countFeedbackFiles($a_user_id)
Count number of feedback files for a user.
Add data(end) time
Method that wraps PHPs time in order to allow simulations with the workflow.
if(!file_exists("$old.txt")) if($old===$new) if(file_exists("$new.txt")) $file
getSubmissionLink($a_cmd, array $a_params=null)