40 $this->task_action = $derived_task_action;
43 $this->lng->loadLanguageModule(
"exc");
64 foreach ($this->task_action->getOpenAssignmentsOfUser($user_id) as $ass) {
70 $title = str_replace(
"%1", $ass->getTitle(),
$lng->txt(
"exc_task_submission"));
71 $tasks[] = $this->task_service->derived()->factory()->task(
74 (
int) $state->getOfficialDeadline(),
75 (int) $state->getGeneralStart()
80 foreach ($this->task_action->getOpenPeerReviewsOfUser($user_id) as $ass) {
86 $title = str_replace(
"%1", $ass->getTitle(),
$lng->txt(
"exc_task_peer_feedback"));
87 $tasks[] = $this->task_service->derived()->factory()->task(
90 (
int) $state->getPeerReviewDeadline(),
96 foreach ($this->task_action->getOpenGradingsOfUser($user_id) as $ass) {
101 $title = str_replace(
"%1", $ass->getTitle(),
$lng->txt(
"exc_task_grading"));
102 $tasks[] = $this->task_service->derived()->factory()->task($title, $ref_id, 0, 0);
121 if (
$access->checkAccessOfUser($user_id, $perm,
"", $ref_id)) {
isActive()
Is provider active?bool
__construct(ilTaskService $task_service, \ilAccess $access, \ilLanguage $lng, ilExerciseDerivedTaskAction $derived_task_action)
Constructor.
static _getAllReferences($a_id)
get all reference ids of object
static getInstanceByIds($a_ass_id, $a_user_id=0)
Get instance by IDs (recommended for consumer code)
getFirstRefIdWithPermission($perm, int $obj_id, int $user_id)
Get first ref id for an object id with permission.
getTasks(int $user_id)
Get providers.ilDerivedTask[]
Action class for derived tasks, mostly getting user reponsibilities by respecting permissions as well...
Exercise derived task provider.