ILIAS  release_8 Revision v8.19
All Data Structures Namespaces Files Functions Variables Modules Pages
ILIAS\Notes\InternalGUIService Class Reference
+ Collaboration diagram for ILIAS\Notes\InternalGUIService:

Public Member Functions

 __construct (Container $DIC, InternalDataService $data_service, InternalDomainService $domain_service)
 
 standardRequest ()
 
 initJavascript (string $ajax_url="", ?\ilGlobalTemplateInterface $main_tpl=null)
 
 filter (string $filter_id, $class_path, string $cmd, bool $activated=true, bool $expanded=true)
 
 print ()
 

Protected Attributes

InternalDataService $data_service
 
InternalDomainService $domain_service
 

Detailed Description

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

Definition at line 30 of file class.InternalGUIService.php.

Constructor & Destructor Documentation

◆ __construct()

ILIAS\Notes\InternalGUIService::__construct ( Container  $DIC,
InternalDataService  $data_service,
InternalDomainService  $domain_service 
)

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

References ILIAS\Notes\InternalGUIService\$data_service, ILIAS\Notes\InternalGUIService\$domain_service, and ILIAS\Repository\initGUIServices().

41  {
42  $this->data_service = $data_service;
43  $this->domain_service = $domain_service;
44  $this->initGUIServices($DIC);
45  }
initGUIServices(\ILIAS\DI\Container $DIC)
global $DIC
Definition: feed.php:28
+ Here is the call graph for this function:

Member Function Documentation

◆ filter()

ILIAS\Notes\InternalGUIService::filter ( string  $filter_id,
  $class_path,
string  $cmd,
bool  $activated = true,
bool  $expanded = true 
)
Parameters
array | string$class_path

Definition at line 107 of file class.InternalGUIService.php.

113  : FilterAdapterGUI {
114  return new FilterAdapterGUI(
115  $filter_id,
116  $class_path,
117  $cmd,
118  $activated,
119  $expanded
120  );
121  }

◆ initJavascript()

ILIAS\Notes\InternalGUIService::initJavascript ( string  $ajax_url = "",
?\ilGlobalTemplateInterface  $main_tpl = null 
)

Definition at line 55 of file class.InternalGUIService.php.

References $DIC, $lng, $path, $ref_id, $tpl, $type, ilObject\_lookupType(), ILIAS\Repository\ctrl(), ilYuiUtil\initConnection(), iljQueryUtil\initjQuery(), ilModalGUI\initJS(), and ILIAS\Repository\mainTemplate().

58  : void {
59  $tpl = $main_tpl ?? $this->mainTemplate();
60  $lng = $this->domain_service->lng();
61  $ctrl = $this->ctrl();
62  // temporary patch to make this work...
63  global $DIC;
64  $ref_id = $DIC->repository()->internal()->gui()->standardRequest()->getRefId();
66  switch ($type) {
67  /*
68  case "cat":
69  $path = ["ilrepositorygui", "ilobjcategorygui", "ilcommonactiondispatchergui", "ilnotegui"];
70  break;
71  case "root":
72  $path = ["ilrepositorygui", "ilobjrootfoldergui", "ilcommonactiondispatchergui", "ilnotegui"];
73  break;
74  case "lm":
75  $path = ["illmpresentationgui", "ilcommonactiondispatchergui", "ilnotegui"];
76  break;
77  case "wiki":
78  $path = ["ilwikihandlergui", "ilobjwikigui", "ilcommonactiondispatchergui", "ilnotegui"];
79  break;*/
80  default: // not working
81  $path = ["ilcommonactiondispatchergui", "ilnotegui"];
82  break;
83  }
84 
85  if ($ajax_url === "") {
86  $ajax_url = $this->ctrl()->getLinkTargetByClass(
87  $path,
88  "",
89  "",
90  true,
91  false
92  );
93  }
94  $lng->loadLanguageModule("notes");
96 
97  $lng->toJS(array("private_notes", "notes_public_comments", "cancel"), $tpl);
100  $tpl->addJavaScript("./Services/Notes/js/ilNotes.js");
101  $tpl->addOnLoadCode("ilNotes.setAjaxUrl('" . $ajax_url . "');");
102  }
$type
$lng
static initJS(ilGlobalTemplateInterface $a_main_tpl=null)
$path
Definition: ltiservices.php:32
global $DIC
Definition: feed.php:28
$ref_id
Definition: ltiauth.php:67
static initjQuery(ilGlobalTemplateInterface $a_tpl=null)
inits and adds the jQuery JS-File to the global or a passed template
if($DIC->http() ->request() ->getMethod()=="GET" &&isset($DIC->http() ->request() ->getQueryParams()['tex'])) $tpl
Definition: latex.php:41
static _lookupType(int $id, bool $reference=false)
static initConnection(?ilGlobalTemplateInterface $a_main_tpl=null)
Init YUI Connection module.
+ Here is the call graph for this function:

◆ print()

ILIAS\Notes\InternalGUIService::print ( )

Definition at line 123 of file class.InternalGUIService.php.

References $provider, ILIAS\FileDelivery\http(), and ILIAS\Repository\ui().

123  : PrintProcessGUI
124  {
125  $provider = new PrintViewProvider();
126  return new PrintProcessGUI(
127  $provider,
128  $this->http(),
129  $this->ui(),
130  $this->domain_service->lng()
131  );
132  }
$provider
Definition: ltitoken.php:83
static http()
Fetches the global http state from ILIAS.
+ Here is the call graph for this function:

◆ standardRequest()

ILIAS\Notes\InternalGUIService::standardRequest ( )

Definition at line 47 of file class.InternalGUIService.php.

References ILIAS\FileDelivery\http().

47  : StandardGUIRequest
48  {
49  return new StandardGUIRequest(
50  $this->http(),
51  $this->domain_service->refinery()
52  );
53  }
static http()
Fetches the global http state from ILIAS.
+ Here is the call graph for this function:

Field Documentation

◆ $data_service

InternalDataService ILIAS\Notes\InternalGUIService::$data_service
protected

◆ $domain_service

InternalDomainService ILIAS\Notes\InternalGUIService::$domain_service
protected

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