ILIAS  release_10 Revision v10.1-43-ga1241a92c2f
ilObjFileUploadDropzone Class Reference
+ Collaboration diagram for ilObjFileUploadDropzone:

Public Member Functions

 __construct (int $target_ref_id, string $content=null)
 
 isUploadAllowed (string $obj_type)
 
 getDropzoneHtml ()
 

Protected Member Functions

 getUIFactory ()
 
 getLanguage ()
 
 getRefinery ()
 

Protected Attributes

ilObjectDefinition $definition
 
ilCtrlInterface $ctrl
 
UploadHandler $upload_handler
 
ilLanguage $language
 
ilAccess $access
 
UIServices $ui
 
ILIAS Refinery Factory $refinery
 
LOMServices $lom_services
 
int $target_ref_id
 
string $content
 

Private Member Functions

 isCopyrightSelectionActive ()
 

Detailed Description

Constructor & Destructor Documentation

◆ __construct()

ilObjFileUploadDropzone::__construct ( int  $target_ref_id,
string  $content = null 
)

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

References $content, $DIC, $target_ref_id, ILIAS\Repository\access(), ILIAS\Repository\ctrl(), ILIAS\UI\examples\Symbol\Glyph\Language\language(), ILIAS\Repository\refinery(), and ILIAS\Repository\ui().

47  {
48  global $DIC;
49 
50  $this->definition = $DIC['objDefinition'];
51  $this->language = $DIC->language();
52  $this->language->loadLanguageModule('file');
53  $this->access = $DIC->access();
54  $this->ctrl = $DIC->ctrl();
55  $this->ui = $DIC->ui();
56  $this->refinery = $DIC->refinery();
57  $this->lom_services = $DIC->learningObjectMetadata();
58 
59  $this->upload_handler = new ilObjFileUploadHandlerGUI();
60  $this->target_ref_id = $target_ref_id;
61  $this->content = $content;
62  }
global $DIC
Definition: shib_login.php:25
language()
description: > Example for rendring a language glyph.
Definition: language.php:25
+ Here is the call graph for this function:

Member Function Documentation

◆ getDropzoneHtml()

ilObjFileUploadDropzone::getDropzoneHtml ( )

Definition at line 148 of file class.ilObjFileUploadDropzone.php.

References ILIAS\Repository\ui().

148  : string
149  {
150  return $this->ui->renderer()->render($this->getDropzone());
151  }
+ Here is the call graph for this function:

◆ getLanguage()

ilObjFileUploadDropzone::getLanguage ( )
protected

Definition at line 158 of file class.ilObjFileUploadDropzone.php.

References $language.

158  : \ilLanguage
159  {
160  return $this->language;
161  }
language handling

◆ getRefinery()

ilObjFileUploadDropzone::getRefinery ( )
protected

Definition at line 163 of file class.ilObjFileUploadDropzone.php.

References $refinery.

164  {
165  return $this->refinery;
166  }
Builds data types.
Definition: Factory.php:35

◆ getUIFactory()

ilObjFileUploadDropzone::getUIFactory ( )
protected

Definition at line 153 of file class.ilObjFileUploadDropzone.php.

References ILIAS\Repository\ui().

154  {
155  return $this->ui->factory();
156  }
+ Here is the call graph for this function:

◆ isCopyrightSelectionActive()

ilObjFileUploadDropzone::isCopyrightSelectionActive ( )
private

Definition at line 64 of file class.ilObjFileUploadDropzone.php.

References ilObjFileGUI\CMD_UPLOAD_FILES, ILIAS\Repository\ctrl(), ILIAS\UI\examples\Symbol\Glyph\Language\language(), ilObjFile\OBJECT_TYPE, ilObjFileGUI\PARAM_DESCRIPTION, ilObjFileGUI\PARAM_TITLE, ilObjFileGUI\PARAM_UPLOAD_ORIGIN, ILIAS\Repository\ui(), ilObjFileGUI\UPLOAD_MAX_FILES, ilObjFileGUI\UPLOAD_ORIGIN_DROPZONE, and ILIAS\UI\Implementation\Component\Input\ViewControl\withAdditionalTransformation().

64  : bool
65  {
66  static $active;
67  if ($active === null) {
68  $active = $this->lom_services->copyrightHelper()->isCopyrightSelectionActive();
69  }
70  return $active;
71  }
+ Here is the call graph for this function:

◆ isUploadAllowed()

ilObjFileUploadDropzone::isUploadAllowed ( string  $obj_type)

Definition at line 139 of file class.ilObjFileUploadDropzone.php.

References ILIAS\Repository\access().

139  : bool
140  {
141  if ($this->definition->isContainer($obj_type) && $obj_type !== "orgu") {
142  return $this->access->checkAccess('create_file', '', $this->target_ref_id, 'file');
143  }
144 
145  return false;
146  }
+ Here is the call graph for this function:

Field Documentation

◆ $access

ilAccess ilObjFileUploadDropzone::$access
protected

Definition at line 38 of file class.ilObjFileUploadDropzone.php.

◆ $content

string ilObjFileUploadDropzone::$content
protected

Definition at line 44 of file class.ilObjFileUploadDropzone.php.

Referenced by __construct().

◆ $ctrl

ilCtrlInterface ilObjFileUploadDropzone::$ctrl
protected

Definition at line 35 of file class.ilObjFileUploadDropzone.php.

◆ $definition

ilObjectDefinition ilObjFileUploadDropzone::$definition
protected

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

◆ $language

ilLanguage ilObjFileUploadDropzone::$language
protected

Definition at line 37 of file class.ilObjFileUploadDropzone.php.

Referenced by getLanguage().

◆ $lom_services

LOMServices ilObjFileUploadDropzone::$lom_services
protected

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

◆ $refinery

ILIAS Refinery Factory ilObjFileUploadDropzone::$refinery
protected

Definition at line 40 of file class.ilObjFileUploadDropzone.php.

Referenced by getRefinery().

◆ $target_ref_id

int ilObjFileUploadDropzone::$target_ref_id
protected

Definition at line 43 of file class.ilObjFileUploadDropzone.php.

Referenced by __construct().

◆ $ui

UIServices ilObjFileUploadDropzone::$ui
protected

Definition at line 39 of file class.ilObjFileUploadDropzone.php.

◆ $upload_handler

UploadHandler ilObjFileUploadDropzone::$upload_handler
protected

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


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