ILIAS  release_7 Revision v7.30-3-g800a261c036
ilExSubmissionBaseGUI Class Reference

Exercise submission base gui. More...

+ Inheritance diagram for ilExSubmissionBaseGUI:
+ Collaboration diagram for ilExSubmissionBaseGUI:

Public Member Functions

 __construct (ilObjExercise $a_exercise, ilExSubmission $a_submission)
 
 returnToParentObject ()
 

Static Public Member Functions

static getOverviewContent (ilInfoScreenGUI $a_info, ilExSubmission $a_submission)
 

Protected Member Functions

 handleTabs ()
 
 handleNewUpload ($a_no_notifications=false)
 
 handleRemovedUpload ()
 
 triggerAssignmentTool ()
 Trigger assigment tool. More...
 

Protected Attributes

 $ctrl
 
 $tabs_gui
 
 $lng
 
 $tpl
 
 $exercise
 
 $submission
 
 $assignment
 
 $mandatory_manager
 
 $tool_context
 
 $type_guis
 

Detailed Description

Exercise submission base gui.

This is an abstract base class for all types of submissions

Author
Jörg Lützenkirchen luetz.nosp@m.enki.nosp@m.rchen.nosp@m.@lei.nosp@m.fos.c.nosp@m.om

Definition at line 12 of file class.ilExSubmissionBaseGUI.php.

Constructor & Destructor Documentation

◆ __construct()

ilExSubmissionBaseGUI::__construct ( ilObjExercise  $a_exercise,
ilExSubmission  $a_submission 
)

Reimplemented in ilExSubmissionFileGUI, and ilExSubmissionTextGUI.

Definition at line 53 of file class.ilExSubmissionBaseGUI.php.

54 {
55 global $DIC;
56
57 $ilCtrl = $DIC->ctrl();
58 $ilTabs = $DIC->tabs();
59 $lng = $DIC->language();
60 $tpl = $DIC["tpl"];
61
62 $this->exercise = $a_exercise;
63 $this->submission = $a_submission;
64 $this->assignment = $a_submission->getAssignment();
65
66 $this->mandatory_manager = $DIC->exercise()->internal()->service()->getMandatoryAssignmentManager($this->exercise);
67
68 // :TODO:
69 $this->ctrl = $ilCtrl;
70 $this->tabs_gui = $ilTabs;
71 $this->lng = $lng;
72 $this->tpl = $tpl;
73
74 $this->type_guis = ilExAssignmentTypesGUI::getInstance();
75 $this->tool_context = $DIC->globalScreen()->tool()->context();
76 }
global $DIC
Definition: goto.php:24

References $DIC, $lng, $tpl, ilExSubmission\getAssignment(), and ilExAssignmentTypesGUI\getInstance().

+ Here is the call graph for this function:

Member Function Documentation

◆ getOverviewContent()

static ilExSubmissionBaseGUI::getOverviewContent ( ilInfoScreenGUI  $a_info,
ilExSubmission  $a_submission 
)
staticabstract

◆ handleNewUpload()

ilExSubmissionBaseGUI::handleNewUpload (   $a_no_notifications = false)
protected

Definition at line 110 of file class.ilExSubmissionBaseGUI.php.

111 {
112 $has_submitted = $this->submission->hasSubmitted();
113
114 $this->exercise->processExerciseStatus(
115 $this->assignment,
116 $this->submission->getUserIds(),
117 $has_submitted,
118 $this->submission->validatePeerReviews()
119 );
120
121 if ($has_submitted &&
122 !$a_no_notifications) {
124
125 $not = new ilExerciseMailNotification();
127 $not->setAssignmentId($this->assignment->getId());
128 $not->setRefId($this->exercise->getRefId());
129 $not->setRecipients($users);
130 $not->send();
131 }
132 }
static getNotificationsForObject($type, $id, $page_id=null, $ignore_threshold=false)
Get all users for given object.

References ilNotification\getNotificationsForObject(), ilNotification\TYPE_EXERCISE_SUBMISSION, and ilExerciseMailNotification\TYPE_SUBMISSION_UPLOAD.

Referenced by handleRemovedUpload(), ilExSubmissionObjectGUI\submitBlog(), ilExSubmissionObjectGUI\submitPortfolio(), ilExSubmissionTextGUI\updateAssignmentTextObject(), ilExSubmissionFileGUI\uploadFileObject(), and ilExSubmissionFileGUI\uploadZipObject().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ handleRemovedUpload()

ilExSubmissionBaseGUI::handleRemovedUpload ( )
protected

Definition at line 134 of file class.ilExSubmissionBaseGUI.php.

135 {
136 // #16532 - always send notifications
137 $this->handleNewUpload();
138 }
handleNewUpload($a_no_notifications=false)

References handleNewUpload().

Referenced by ilExSubmissionObjectGUI\createPortfolioObject(), ilExSubmissionFileGUI\deleteDeliveredObject(), ilExSubmissionObjectGUI\saveBlogObject(), ilExSubmissionObjectGUI\setSelectedBlogObject(), ilExSubmissionObjectGUI\setSelectedPortfolioObject(), and ilExSubmissionTextGUI\updateAssignmentTextObject().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ handleTabs()

ilExSubmissionBaseGUI::handleTabs ( )
protected

Definition at line 80 of file class.ilExSubmissionBaseGUI.php.

81 {
82 $this->tabs_gui->clearTargets();
83 $this->tabs_gui->setBackTarget(
84 $this->lng->txt("back"),
85 $this->ctrl->getLinkTarget($this, "returnToParent")
86 );
87
88 $this->tabs_gui->addTab(
89 "submission",
90 $this->lng->txt("exc_submission"),
91 $this->ctrl->getLinkTarget($this, "")
92 );
93 $this->tabs_gui->activateTab("submission");
94
95 if ($this->assignment->hasTeam()) {
97 }
98 }

References ilExSubmissionTeamGUI\handleTabs().

Referenced by ilExSubmissionObjectGUI\createBlogObject(), ilExSubmissionTextGUI\editAssignmentTextObject(), ilExSubmissionObjectGUI\selectBlogObject(), ilExSubmissionObjectGUI\selectPortfolioObject(), ilExSubmissionTextGUI\showAssignmentTextObject(), and ilExSubmissionFileGUI\submissionScreenObject().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ returnToParentObject()

◆ triggerAssignmentTool()

ilExSubmissionBaseGUI::triggerAssignmentTool ( )
protected

Trigger assigment tool.

Definition at line 143 of file class.ilExSubmissionBaseGUI.php.

144 {
145 $ass_ids = [$this->assignment->getId()];
146 $this->tool_context->current()->addAdditionalData(ilExerciseGSToolProvider::SHOW_EXC_ASSIGNMENT_INFO, true);
147 $this->tool_context->current()->addAdditionalData(ilExerciseGSToolProvider::EXC_ASS_IDS, $ass_ids);
148 }

References ilExerciseGSToolProvider\EXC_ASS_IDS, and ilExerciseGSToolProvider\SHOW_EXC_ASSIGNMENT_INFO.

Referenced by ilExSubmissionTextGUI\editAssignmentTextObject(), and ilExSubmissionFileGUI\submissionScreenObject().

+ Here is the caller graph for this function:

Field Documentation

◆ $assignment

ilExSubmissionBaseGUI::$assignment
protected

Definition at line 36 of file class.ilExSubmissionBaseGUI.php.

◆ $ctrl

◆ $exercise

ilExSubmissionBaseGUI::$exercise
protected

Definition at line 34 of file class.ilExSubmissionBaseGUI.php.

◆ $lng

◆ $mandatory_manager

ilExSubmissionBaseGUI::$mandatory_manager
protected

Definition at line 41 of file class.ilExSubmissionBaseGUI.php.

◆ $submission

ilExSubmissionBaseGUI::$submission
protected

◆ $tabs_gui

ilExSubmissionBaseGUI::$tabs_gui
protected

Definition at line 22 of file class.ilExSubmissionBaseGUI.php.

◆ $tool_context

ilExSubmissionBaseGUI::$tool_context
protected

Definition at line 46 of file class.ilExSubmissionBaseGUI.php.

◆ $tpl

◆ $type_guis

ilExSubmissionBaseGUI::$type_guis
protected

Definition at line 51 of file class.ilExSubmissionBaseGUI.php.


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