ILIAS  release_8 Revision v8.24
ilAppointmentCourseFileHandler Class Reference

Course appointment file handler. More...

+ Inheritance diagram for ilAppointmentCourseFileHandler:
+ Collaboration diagram for ilAppointmentCourseFileHandler:

Public Member Functions

 getFiles ()
 @inheritDoc More...
 
- Public Member Functions inherited from ilAppointmentBaseFileHandler
 __construct (array $a_appointment)
 
 getCatId (int $a_entry_id)
 
 getCatInfo ()
 
 getFiles ()
 

Additional Inherited Members

- Protected Attributes inherited from ilAppointmentBaseFileHandler
array $appointment
 
ilLogger $logger
 
ilAccessHandler $access
 
ilRbacSystem $rbacsystem
 
ilObjUser $user
 

Detailed Description

Course appointment file handler.

Author
Alex Killing killi.nosp@m.ng@l.nosp@m.eifos.nosp@m..de

Definition at line 14 of file class.ilAppointmentCourseFileHandler.php.

Member Function Documentation

◆ getFiles()

ilAppointmentCourseFileHandler::getFiles ( )

@inheritDoc

Implements ilAppointmentFileHandler.

Definition at line 19 of file class.ilAppointmentCourseFileHandler.php.

19 : array
20 {
21 $cat_info = $this->getCatInfo();
22
23 //checking permissions of the parent object.
24 // get course ref id (this is possible, since courses only have one ref id)
25 $refs = ilObject::_getAllReferences($cat_info['obj_id']);
26 $crs_ref_id = current($refs);
27
28 $files = [];
29 if ($this->access->checkAccessOfUser($this->user->getId(), "read", "", $crs_ref_id)) {
30 $course_files = ilCourseFile::_readFilesByCourse($cat_info['obj_id']);
31 foreach ($course_files as $course_file) {
32 $file_property = new ilFileProperty();
33 $file_property->setAbsolutePath($course_file->getAbsolutePath());
34 $file_property->setFileName($course_file->getFileName());
35 $files[] = $file_property;
36 }
37 }
38 return $files;
39 }
static _readFilesByCourse(int $a_course_id)
static _getAllReferences(int $id)
get all reference ids for object ID

References ilObject\_getAllReferences(), ilCourseFile\_readFilesByCourse(), ILIAS\Repository\access(), and ilAppointmentBaseFileHandler\getCatInfo().

+ Here is the call graph for this function:

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