ILIAS  trunk Revision v11.0_alpha-3011-gc6b235a2e85
class.DomainService.php
Go to the documentation of this file.
1<?php
2
19declare(strict_types=1);
20
22
25
30{
33
34 protected static array $managers = [];
35
36 public function __construct(
39 ) {
40 $this->domain_service = $domain_service;
41 $this->repo_service = $repo_service;
42 }
43
44 public function run(
45 \ilObjSurvey $survey,
46 int $user_id,
47 int $appraisee_id = 0
48 ): RunManager {
49 $appraisee_id = ($survey->getMode() === \ilObjSurvey::MODE_SELF_EVAL)
50 ? $user_id
51 : $appraisee_id;
52 if (!isset(self::$managers[RunManager::class][$survey->getId()][$user_id][$appraisee_id])) {
53 self::$managers[RunManager::class][$survey->getId()][$user_id][$appraisee_id] =
54 new RunManager(
55 $this->repo_service,
56 $this->domain_service,
57 $survey,
59 $appraisee_id
60 );
61 }
62 return self::$managers[RunManager::class][$survey->getId()][$user_id][$appraisee_id];
63 }
64}
run(\ilObjSurvey $survey, int $user_id, int $appraisee_id=0)
__construct(InternalRepoService $repo_service, InternalDomainService $domain_service)
Survey Run Note: The manager should get the current user id passed.
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...