ILIAS  release_5-3 Revision v5.3.23-19-g915713cf615
ilAppointmentCourseFileHandler Class Reference

Course appointment file handler. More...

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

Public Member Functions

 getFiles ()
 Get files (for appointment) More...
 
- Public Member Functions inherited from ilAppointmentBaseFileHandler
 __construct ($a_appointment)
 Constructor. More...
 
 getCatId ($a_entry_id)
 
 getCatInfo ()
 

Additional Inherited Members

- Static Public Member Functions inherited from ilAppointmentBaseFileHandler
static getInstance ($a_appointment)
 Get instance. More...
 
- Protected Attributes inherited from ilAppointmentBaseFileHandler
 $appointment
 

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 ( )

Get files (for appointment)

Parameters

Implements ilAppointmentFileHandler.

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

References $files, ilObject\_getAllReferences(), ilCourseFile\_readFilesByCourse(), array, and ilAppointmentBaseFileHandler\getCatInfo().

23  {
24  $cat_info = $this->getCatInfo();
25 
26  //checking permissions of the parent object.
27  // get course ref id (this is possible, since courses only have one ref id)
28  $refs = ilObject::_getAllReferences($cat_info['obj_id']);
29  $crs_ref_id = current($refs);
30 
31  $files = array();
32  if ($this->access->checkAccessOfUser($this->user->getId(), "read", "", $crs_ref_id)) {
33  include_once "./Modules/Course/classes/class.ilCourseFile.php";
34  $course_files = ilCourseFile::_readFilesByCourse($cat_info['obj_id']);
35 
36  foreach ($course_files as $course_file) {
37  $file_name_system_path = $course_file->getInfoDirectory() . "/" . $course_file->getFileId();
38  $file_name_web = $course_file->getInfoDirectory() . "/" . $course_file->getFileName();
39  $files[$file_name_system_path] = $file_name_web;
40  }
41  }
42 
43  return $files;
44  }
$files
Definition: add-vimline.php:18
static _getAllReferences($a_id)
get all reference ids of object
static _readFilesByCourse($a_course_id)
Create styles array
The data for the language used.
+ Here is the call graph for this function:

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