ILIAS  release_5-4 Revision v5.4.26-12-gabc799a52e6
ilObjBibliographicGUI Class Reference

Class ilObjBibliographicGUI. More...

+ Inheritance diagram for ilObjBibliographicGUI:
+ Collaboration diagram for ilObjBibliographicGUI:

Public Member Functions

 __construct ($a_id=0, $a_id_type=self::REPOSITORY_NODE_ID, $a_parent_node_id=0)
 
 getStandardCmd ()
 getStandardCmd More...
 
 getType ()
 getType More...
 
 executeCommand ()
 executeCommand More...
 
 infoScreen ()
 this one is called from the info button in the repository not very nice to set cmdClass/Cmd manually, if everything works through ilCtrl in the future this may be changed More...
 
 infoScreenForward ()
 show information screen More...
 
 addLocatorItems ()
 Functions to be overwritten. More...
 
 save ()
 
 initEditForm ()
 Init object edit form. More...
 
 getEditFormCustomValues (array &$a_values)
 
 render ()
 
 showContent ()
 shows the overview page with all entries in a table More...
 
 sendFile ()
 provide file as a download More...
 
 showDetails ()
 
 view ()
 view object content (repository/workspace switch) More...
 
 updateCustom (ilPropertyFormGUI $a_form)
 updateSettings More...
 
 toggleNotification ()
 
 addNews ($obj_id, $change='created')
 
 addToDeskObject ()
 Add desktop item. More...
 
 removeFromDeskObject ()
 Remove from desktop. More...
 
 addToDesk ()
 Add desktop item. More...
 
 removeFromDesk ()
 Remove from desktop. More...
 
- Public Member Functions inherited from ilObject2GUI
 __construct ($a_id=0, $a_id_type=self::REPOSITORY_NODE_ID, $a_parent_node_id=0)
 Constructor. More...
 
 executeCommand ()
 execute command More...
 
 delete ()
 Display delete confirmation form (repository/workspace switch) More...
 
 confirmedDelete ()
 Delete objects (repository/workspace switch) More...
 
 getHTML ()
 
 withReferences ()
 Final/Private declaration of unchanged parent methods. More...
 
 setCreationMode ($a_mode=true)
 if true, a creation screen is displayed the current $_GET[ref_id] don't belong to the current class! the mode is determined in ilrepositorygui More...
 
 getCreationMode ()
 get creation mode More...
 
 prepareOutput ($a_show_subobjects=true)
 prepare output More...
 
 isVisible ($a_ref_id, $a_type)
 
 trash ()
 
 undelete ()
 
 cancelDelete ()
 
 removeFromSystem ()
 
 cloneAll ()
 
 view ()
 view object content (repository/workspace switch) More...
 
 getType ()
 Functions that must be overwritten. More...
 
 create ()
 Deleted in ilObject. More...
 
 save ()
 
 edit ()
 
 update ()
 
 cancel ()
 
 importFile ()
 Import. More...
 
 putObjectInTree (ilObject $a_obj, $a_parent_node_id=null)
 Add object to tree at given position. More...
 
- Public Member Functions inherited from ilObjectGUI
 executeCommand ()
 execute command More...
 
 withReferences ()
 determines wether objects are referenced or not (got ref ids or not) More...
 
 setCreationMode ($a_mode=true)
 if true, a creation screen is displayed the current $_GET[ref_id] don't belong to the current class! the mode is determined in ilrepositorygui More...
 
 getCreationMode ()
 get creation mode More...
 
 prepareOutput ($a_show_subobjects=true)
 prepare output More...
 
 getAdminTabs ()
 administration tabs show only permissions and trash folder More...
 
 getHTML ()
 
 confirmedDeleteObject ()
 confirmed deletion of object -> objects are moved to trash or deleted immediately, if trash is disabled More...
 
 cancelDeleteObject ()
 cancel deletion of object More...
 
 cancelObject ()
 cancel action and go back to previous page @access public More...
 
 createObject ()
 create new object form More...
 
 cancelCreation ()
 cancel create action and go back to repository parent More...
 
 saveObject ()
 save object More...
 
 getDidacticTemplateVar ($a_type)
 Get didactic template setting from creation screen. More...
 
 putObjectInTree (ilObject $a_obj, $a_parent_node_id=null)
 Add object to tree at given position. More...
 
 editObject ()
 edit object More...
 
 addExternalEditFormCustom (ilPropertyFormGUI $a_form)
 
 updateObject ()
 updates object entry in object_data More...
 
 getFormAction ($a_cmd, $a_formaction="")
 get form action for command (command is method name without "Object", e.g. More...
 
 isVisible ($a_ref_id, $a_type)
 
 viewObject ()
 list childs of current object More...
 
 deleteObject ($a_error=false)
 Display deletion confirmation screen. More...
 
 cloneAllObject ()
 Clone single (not container object) Method is overwritten in ilContainerGUI. More...
 
 redirectAfterCreation ()
 Redirect after creation, see https://docu.ilias.de/goto_docu_wiki_wpage_5035_1357.html. More...
 
 addToDeskObject ()
 Add desktop item @access public. More...
 
 removeFromDeskObject ()
 Remove from desktop @access public. More...
 

Static Public Member Functions

static _goto ($a_target)
 _goto Deep link More...
 
- Static Public Member Functions inherited from ilObject2GUI
static handleAfterSaveCallback (ilObject $a_obj, $a_callback_ref_id)
 After creation callback. More...
 
- Static Public Member Functions inherited from ilObjectGUI
static _gotoRepositoryRoot ($a_raise_error=false)
 Goto repository root. More...
 
static _gotoRepositoryNode ($a_ref_id, $a_cmd="frameset")
 Goto repository root. More...
 

Data Fields

const P_ENTRY_ID = 'entry_id'
 
const CMD_SHOW_CONTENT = 'showContent'
 
const CMD_SEND_FILE = "sendFile"
 
const TAB_CONTENT = "content"
 
const SUB_TAB_FILTER = "filter"
 
const CMD_VIEW = "view"
 
const TAB_EXPORT = "export"
 
const TAB_SETTINGS = self::SUBTAB_SETTINGS
 
const TAB_ID_RECORDS = "id_records"
 
const TAB_ID_PERMISSIONS = "id_permissions"
 
const TAB_ID_INFO = "id_info"
 
const CMD_SHOW_DETAILS = "showDetails"
 
const CMD_EDIT = "edit"
 
const SUBTAB_SETTINGS = "settings"
 
const CMD_EDIT_OBJECT = 'editObject'
 
const CMD_UPDATE_OBJECT = 'updateObject'
 
 $object
 
- Data Fields inherited from ilObject2GUI
 $tree
 
const OBJECT_ID = 0
 
const REPOSITORY_NODE_ID = 1
 
const WORKSPACE_NODE_ID = 2
 
const REPOSITORY_OBJECT_ID = 3
 
const WORKSPACE_OBJECT_ID = 4
 
const PORTFOLIO_OBJECT_ID = 5
 
- Data Fields inherited from ilObjectGUI
const COPY_WIZARD_NEEDS_PAGE = 1
 
 $objDefinition
 
 $tpl
 
 $tree
 
 $lng
 
 $data
 
 $object
 
 $ref_id
 
 $obj_id
 
 $maxcount
 
 $formaction
 
 $return_location
 
 $target_frame
 
 $tab_target_script
 
 $actions
 
 $sub_objects
 
 $omit_locator = false
 
const CFORM_NEW = 1
 
const CFORM_IMPORT = 2
 
const CFORM_CLONE = 3
 

Protected Member Functions

 initCreationForms ($a_new_type)
 
 initSubTabs ()
 
 initEditCustomForm (ilPropertyFormGUI $a_form)
 
 applyFilter ()
 
 resetFilter ()
 
- Protected Member Functions inherited from ilObject2GUI
 afterConstructor ()
 Do anything that should be done after constructor in here. More...
 
 assignObject ()
 create object instance as internal property (repository/workspace switch) More...
 
 getAccessHandler ()
 Get access handler. More...
 
 setLocator ()
 set Locator More...
 
 deleteConfirmation ()
 Display delete confirmation form (workspace specific) More...
 
 deleteConfirmedObjects ()
 Delete objects (workspace specific) More...
 
 setTitleAndDescription ()
 called by prepare output More...
 
 showUpperIcon ()
 
 omitLocator ($a_omit=true)
 
 getTargetFrame ($a_cmd, $a_target_frame="")
 get target frame for command (command is method name without "Object", e.g. More...
 
 setTargetFrame ($a_cmd, $a_target_frame)
 set specific target frame for command More...
 
 getCenterColumnHTML ()
 Get center column. More...
 
 getRightColumnHTML ()
 Display right column. More...
 
 setColumnSettings (ilColumnGUI $column_gui)
 May be overwritten in subclasses. More...
 
 checkPermission ($a_perm, $a_cmd="", $a_type="", $a_ref_id=null)
 Check permission and redirect on error. More...
 
 showPossibleSubObjects ()
 show possible subobjects (pulldown menu) More...
 
 redirectToRefId ($a_ref_id, $a_cmd="")
 redirects to (repository) view per ref id usually to a container and usually used at the end of a save/import method where the object gui type (of the new object) doesn't match with the type of the current $_GET["ref_id"] value More...
 
 fillCloneTemplate ($a_tpl_varname, $a_type)
 Fill object clone template This method can be called from any object GUI class that wants to offer object cloning. More...
 
 fillCloneSearchTemplate ($a_tpl_varname, $a_type)
 
 searchCloneSource ()
 
 buildCloneSelect ($existing_objs)
 
 addAdminLocatorItems ($a_do_not_add_object=false)
 should be overwritten to add object specific items (repository items are preloaded) More...
 
 setTabs ()
 create tabs (repository/workspace switch) More...
 
 getReturnLocation ($a_cmd, $a_location="")
 Deprecated functions. More...
 
 setReturnLocation ($a_cmd, $a_location)
 set specific return location for command More...
 
 showActions ()
 
 getTabs ()
 get tabs abstract method. More...
 
 __showButton ($a_cmd, $a_text, $a_target='')
 
 hitsperpageObject ()
 
__initTableGUI ()
 
 __setTableGUIBasicData (&$tbl, &$result_set, $a_from="")
 standard implementation for tables use 'from' variable use different initial setting of table More...
 
 addLocatorItems ()
 Functions to be overwritten. More...
 
 initCreationForms ($a_new_type)
 Init creation froms. More...
 
 checkPermissionBool ($a_perm, $a_cmd="", $a_type="", $a_node_id=null)
 Check permission. More...
 
 initHeaderAction ($a_sub_type=null, $a_sub_id=null)
 Add header action menu. More...
 
 redrawHeaderAction ()
 Updating icons after ajax call. More...
 
 getPermanentLinkWidget ($a_append=null, $a_center=false)
 
 handleAutoRating (ilObject $a_new_obj)
 
- Protected Member Functions inherited from ilObjectGUI
 getObjectService ()
 Get object service. More...
 
 assignObject ()
 
 setTitleAndDescription ()
 called by prepare output More...
 
 initHeaderAction ($a_sub_type=null, $a_sub_id=null)
 Add header action menu. More...
 
 insertHeaderAction ($a_list_gui)
 Insert header action into main template. More...
 
 addHeaderAction ()
 Add header action menu. More...
 
 redrawHeaderActionObject ()
 Ajax call: redraw action header only. More...
 
 showMountWebfolderIcon ()
 
 setTabs ()
 set admin tabs @access public More...
 
 setAdminTabs ()
 set admin tabs @access public More...
 
 setLocator ()
 set Locator More...
 
 addLocatorItems ()
 should be overwritten to add object specific items (repository items are preloaded) More...
 
 omitLocator ($a_omit=true)
 
 addAdminLocatorItems ($a_do_not_add_object=false)
 should be overwritten to add object specific items (repository items are preloaded) More...
 
 initCreationForms ($a_new_type)
 Init creation froms. More...
 
 getCreationFormsHTML (array $a_forms)
 Get HTML for creation forms (accordion) More...
 
 initCreateForm ($a_new_type)
 Init object creation form. More...
 
 initDidacticTemplate (ilPropertyFormGUI $form)
 Show didactic template types. More...
 
 addDidacticTemplateOptions (array &$a_options)
 Add custom templates. More...
 
 afterSave (ilObject $a_new_object)
 Post (successful) object creation hook. More...
 
 initEditForm ()
 Init object edit form. More...
 
 initEditCustomForm (ilPropertyFormGUI $a_form)
 Add custom fields to update form. More...
 
 getEditFormValues ()
 Get values for edit form. More...
 
 getEditFormCustomValues (array &$a_values)
 Add values to custom edit fields. More...
 
 validateCustom (ilPropertyFormGUI $a_form)
 Validate custom values (if not possible with checkInput()) More...
 
 updateCustom (ilPropertyFormGUI $a_form)
 Insert custom update form values into object. More...
 
 afterUpdate ()
 Post (successful) object update hook. More...
 
 initImportForm ($a_new_type)
 Init object import form. More...
 
 importFileObject ($parent_id=null, $a_catch_errors=true)
 Import. More...
 
 afterImport (ilObject $a_new_object)
 Post (successful) object import hook. More...
 
 setFormAction ($a_cmd, $a_formaction)
 set specific form action for command More...
 
 getReturnLocation ($a_cmd, $a_location="")
 get return location for command (command is method name without "Object", e.g. More...
 
 setReturnLocation ($a_cmd, $a_location)
 set specific return location for command More...
 
 getTargetFrame ($a_cmd, $a_target_frame="")
 get target frame for command (command is method name without "Object", e.g. More...
 
 setTargetFrame ($a_cmd, $a_target_frame)
 set specific target frame for command More...
 
 showPossibleSubObjects ()
 show possible subobjects (pulldown menu) More...
 
 getTemplateFile ($a_cmd, $a_type="")
 get a template blockfile format: tpl. More...
 
 getTabs ()
 get tabs abstract method. More...
 
 __showButton ($a_cmd, $a_text, $a_target='')
 
 hitsperpageObject ()
 
__initTableGUI ()
 
 __setTableGUIBasicData (&$tbl, &$result_set, $a_from="")
 standard implementation for tables use 'from' variable use different initial setting of table More...
 
 redirectToRefId ($a_ref_id, $a_cmd="")
 redirects to (repository) view per ref id usually to a container and usually used at the end of a save/import method where the object gui type (of the new object) doesn't match with the type of the current $_GET["ref_id"] value More...
 
 fillCloneTemplate ($a_tpl_varname, $a_type)
 Fill object clone template This method can be called from any object GUI class that wants to offer object cloning. More...
 
 getCenterColumnHTML ()
 Get center column. More...
 
 getRightColumnHTML ()
 Display right column. More...
 
 setColumnSettings (ilColumnGUI $column_gui)
 May be overwritten in subclasses. More...
 
 checkPermission ($a_perm, $a_cmd="", $a_type="", $a_ref_id=null)
 Check permission and redirect on error. More...
 
 checkPermissionBool ($a_perm, $a_cmd="", $a_type="", $a_ref_id=null)
 Check permission. More...
 
 enableDragDropFileUpload ()
 Enables the file upload into this object by dropping files. More...
 
 handleAutoRating (ilObject $a_new_obj)
 Activate rating automatically if parent container setting. More...
 

Protected Attributes

 $facade
 
 $translation_factory
 
 $field_factory
 
 $filter_factory
 
 $type_factory
 
 $cmd = self::CMD_SHOW_CONTENT
 
- Protected Attributes inherited from ilObject2GUI
 $object_id
 
 $node_id
 
 $creation_forms = array()
 
 $id_type = array()
 
 $parent_id
 
 $access_handler
 
- Protected Attributes inherited from ilObjectGUI
 $ilErr
 
 $locator
 
 $user
 
 $access
 
 $settings
 
 $rbacreview
 
 $toolbar
 
 $tmp_import_dir
 
 $tabs_gui = null
 
 $ctrl
 
 $object_service
 

Private Member Functions

 handleNonAccess ()
 

Detailed Description

Constructor & Destructor Documentation

◆ __construct()

ilObjBibliographicGUI::__construct (   $a_id = 0,
  $a_id_type = self::REPOSITORY_NODE_ID,
  $a_parent_node_id = 0 
)
Parameters
int$a_id
int$a_id_type
int$a_parent_node_id

Reimplemented from ilObject2GUI.

Definition at line 75 of file class.ilObjBibliographicGUI.php.

76 {
77 global $DIC;
78
79 parent::__construct($a_id, $a_id_type, $a_parent_node_id);
80 $DIC->language()->loadLanguageModule('bibl');
81
82 if (is_object($this->object)) {
83 $this->facade = new ilBiblFactoryFacade($this->object);
84 }
85 }
Class ilBiblFactoryFacade.
global $DIC
Definition: saml.php:7

References $DIC.

Member Function Documentation

◆ _goto()

static ilObjBibliographicGUI::_goto (   $a_target)
static

_goto Deep link

Parameters
string$a_target

Definition at line 248 of file class.ilObjBibliographicGUI.php.

249 {
250 global $DIC;
251
252 $id = explode("_", $a_target);
253 $DIC->ctrl()->initBaseClass(ilRepositoryGUI::class);
254 $DIC->ctrl()->setParameterByClass(ilObjBibliographicGUI::class, "ref_id", $id[0]);
255 // Detail-View
256 if ($id[1]) {
257 $DIC->ctrl()
258 ->setParameterByClass(ilObjBibliographicGUI::class, ilObjBibliographicGUI::P_ENTRY_ID, $id[1]);
259 $DIC->ctrl()->redirectByClass(
260 array(
261 ilRepositoryGUI::class,
262 ilObjBibliographicGUI::class,
263 ),
264 self::CMD_SHOW_DETAILS
265 );
266 } else {
267 $DIC->ctrl()->redirectByClass(
268 array(
269 ilRepositoryGUI::class,
270 ilObjBibliographicGUI::class,
271 ),
272 self::CMD_VIEW
273 );
274 }
275 }
if(!array_key_exists('StateId', $_REQUEST)) $id

References $DIC, $id, and P_ENTRY_ID.

◆ addLocatorItems()

ilObjBibliographicGUI::addLocatorItems ( )

Functions to be overwritten.

Reimplemented from ilObject2GUI.

Definition at line 232 of file class.ilObjBibliographicGUI.php.

233 {
234 global $DIC;
235 $ilLocator = $DIC['ilLocator'];
236 if (is_object($this->object)) {
237 $ilLocator->addItem($this->object->getTitle(), $this->ctrl->getLinkTarget($this, ""), "", $this->node_id);
238 }
239 }

References $DIC.

◆ addNews()

ilObjBibliographicGUI::addNews (   $obj_id,
  $change = 'created' 
)
Parameters
string$change

Definition at line 631 of file class.ilObjBibliographicGUI.php.

632 {
633 global $DIC;
634
635 $ilNewsItem = new ilNewsItem();
636 $ilNewsItem->setTitle($DIC->language()->txt('news_title_' . $change));
637 $ilNewsItem->setPriority(NEWS_NOTICE);
638 $ilNewsItem->setContext($obj_id, $this->getType());
639 $ilNewsItem->setUserId($DIC->user()->getId());
640 $ilNewsItem->setVisibility(NEWS_USERS);
641 $ilNewsItem->setContentTextIsLangVar(false);
642 $ilNewsItem->create();
643 }
const NEWS_USERS
const NEWS_NOTICE

References $DIC, ilObjectGUI\$obj_id, getType(), NEWS_NOTICE, and NEWS_USERS.

Referenced by updateCustom().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ addToDesk()

ilObjBibliographicGUI::addToDesk ( )

Add desktop item.

Alias for addToDeskObject.

@access public

Definition at line 681 of file class.ilObjBibliographicGUI.php.

682 {
683 $this->addToDeskObject();
684 }

References addToDeskObject().

+ Here is the call graph for this function:

◆ addToDeskObject()

ilObjBibliographicGUI::addToDeskObject ( )

Add desktop item.

@access public

Implements ilDesktopItemHandling.

Definition at line 651 of file class.ilObjBibliographicGUI.php.

652 {
653 global $DIC;
654
656 ilUtil::sendSuccess($DIC->language()->txt("added_to_desktop"), true);
657 $this->ctrl->redirect($this, self::CMD_VIEW);
658 }
static addToDesktop()
Add desktop item @access public.

References $DIC, and ilDesktopItemGUI\addToDesktop().

Referenced by addToDesk().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ applyFilter()

ilObjBibliographicGUI::applyFilter ( )
protected

Definition at line 515 of file class.ilObjBibliographicGUI.php.

516 {
517 $table = new ilBiblEntryTableGUI($this, $this->facade);
518 $table->writeFilterToSession();
519 $table->resetOffset();
520 $this->ctrl->redirect($this, self::CMD_SHOW_CONTENT);
521 }
Class ilDataCollectionField.
if(empty($password)) $table
Definition: pwgen.php:24

References $table.

◆ executeCommand()

ilObjBibliographicGUI::executeCommand ( )

executeCommand

Reimplemented from ilObject2GUI.

Definition at line 115 of file class.ilObjBibliographicGUI.php.

116 {
117 global $DIC;
118 $ilNavigationHistory = $DIC['ilNavigationHistory'];
119
120 // Navigation History
121 $link = $this->dic()->ctrl()->getLinkTarget($this, $this->getStandardCmd());
122 if ($this->object != null) {
123 $ilNavigationHistory->addItem($this->object->getRefId(), $link, "bibl");
124 $this->addHeaderAction();
125 }
126
127 // general Access Check, especially for single entries not matching the object
128 if ($this->object instanceof ilObjBibliographic && !$DIC->access()->checkAccess('visible', "", $this->object->getRefId())) {
129 $this->handleNonAccess();
130 }
131
132 $next_class = $this->dic()->ctrl()->getNextClass($this);
133 $this->cmd = $this->dic()->ctrl()->getCmd();
134 switch ($next_class) {
135 case strtolower(ilInfoScreenGUI::class):
136 $this->prepareOutput();
137 $this->dic()->tabs()->activateTab(self::TAB_ID_INFO);
138 $this->infoScreenForward();
139 break;
140 case strtolower(ilCommonActionDispatcherGUI::class):
141 $gui = ilCommonActionDispatcherGUI::getInstanceFromAjaxCall();
142 $this->ctrl->forwardCommand($gui);
143 break;
144 case strtolower(ilPermissionGUI::class):
145 $this->prepareOutput();
146 $this->dic()->tabs()->activateTab(self::TAB_ID_PERMISSIONS);
147 $this->ctrl->forwardCommand(new ilPermissionGUI($this));
148 break;
149 case strtolower(ilObjectCopyGUI::class):
150 $cp = new ilObjectCopyGUI($this);
151 $cp->setType('bibl');
152 $this->dic()['tpl']->getStandardTemplate();
153 $this->ctrl->forwardCommand($cp);
154 break;
155 case strtolower(ilObjFileGUI::class):
156 $this->prepareOutput();
157 $this->dic()->tabs()->setTabActive(self::TAB_ID_RECORDS);
158 $this->ctrl->forwardCommand(new ilObjFile($this));
159 break;
160 case strtolower(ilExportGUI::class):
161 $this->prepareOutput();
162 $this->dic()->tabs()->setTabActive(self::TAB_EXPORT);
163 $exp_gui = new ilExportGUI($this);
164 $exp_gui->addFormat("xml");
165 $this->ctrl->forwardCommand($exp_gui);
166 break;
167 case strtolower(ilBiblFieldFilterGUI::class):
168 $this->prepareOutput();
169 $this->dic()->tabs()->setTabActive(self::TAB_SETTINGS);
170 $this->initSubTabs();
171 $this->tabs_gui->activateSubTab(self::SUB_TAB_FILTER);
172 $this->ctrl->forwardCommand(new ilBiblFieldFilterGUI($this->facade));
173 break;
174 default:
175 $this->prepareOutput();
176 $cmd = $this->ctrl->getCmd(self::CMD_SHOW_CONTENT);
177 switch ($cmd) {
178 case 'edit':
179 case 'update':
182 $this->initSubTabs();
183 $this->tabs_gui->activateSubTab(self::SUBTAB_SETTINGS);
184 $this->{$cmd}();
185 break;
186 default:
187 $this->{$cmd}();
188 break;
189 }
190 break;
191 }
192
193 return true;
194 }
Class ilBiblFieldFilterGUI.
Class ilCommonActionDispatcherGUI.
Export User Interface Class.
infoScreenForward()
show information screen
Class ilObjBibliographic.
Class ilObjFile.
prepareOutput($a_show_subobjects=true)
prepare output
GUI class for the workflow of copying objects.
setType($type)
Sets $type.
addHeaderAction()
Add header action menu.
New PermissionGUI (extends from old ilPermission2GUI) RBAC related output.

References $cmd, $DIC, ilObjectGUI\addHeaderAction(), CMD_EDIT_OBJECT, CMD_UPDATE_OBJECT, ilCommonActionDispatcherGUI\getInstanceFromAjaxCall(), getStandardCmd(), handleNonAccess(), infoScreenForward(), initSubTabs(), and ilObject2GUI\prepareOutput().

+ Here is the call graph for this function:

◆ getEditFormCustomValues()

ilObjBibliographicGUI::getEditFormCustomValues ( array &  $a_values)
Parameters
array$a_values
Returns
array

Reimplemented from ilObjectGUI.

Definition at line 459 of file class.ilObjBibliographicGUI.php.

460 {
461 $a_values["is_online"] = $this->object->getOnline();
462
463 return $a_values;
464 }

◆ getStandardCmd()

ilObjBibliographicGUI::getStandardCmd ( )

getStandardCmd

Returns
String

Definition at line 93 of file class.ilObjBibliographicGUI.php.

References CMD_VIEW.

Referenced by executeCommand().

+ Here is the caller graph for this function:

◆ getType()

ilObjBibliographicGUI::getType ( )

getType

Returns
String
Deprecated:
REFACTOR use type factory via Facade

Reimplemented from ilObject2GUI.

Definition at line 106 of file class.ilObjBibliographicGUI.php.

107 {
108 return "bibl";
109 }

Referenced by addNews(), and save().

+ Here is the caller graph for this function:

◆ handleNonAccess()

ilObjBibliographicGUI::handleNonAccess ( )
private

Definition at line 712 of file class.ilObjBibliographicGUI.php.

713 {
714 global $DIC;
715
716 unset($_GET);
717 ilUtil::sendFailure($DIC->language()->txt("no_permission"), true);
719 }
$_GET["client_id"]
static _gotoRepositoryRoot($a_raise_error=false)
Goto repository root.
static sendFailure($a_info="", $a_keep=false)
Send Failure Message to Screen.

References $_GET, $DIC, ilObjectGUI\_gotoRepositoryRoot(), and ilUtil\sendFailure().

Referenced by executeCommand(), sendFile(), showContent(), showDetails(), and updateCustom().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ infoScreen()

ilObjBibliographicGUI::infoScreen ( )

this one is called from the info button in the repository not very nice to set cmdClass/Cmd manually, if everything works through ilCtrl in the future this may be changed

Definition at line 202 of file class.ilObjBibliographicGUI.php.

203 {
204 $this->ctrl->setCmd("showSummary");
205 $this->ctrl->setCmdClass(ilInfoScreenGUI::class);
206 $this->infoScreenForward();
207 }

References infoScreenForward().

+ Here is the call graph for this function:

◆ infoScreenForward()

ilObjBibliographicGUI::infoScreenForward ( )

show information screen

Definition at line 213 of file class.ilObjBibliographicGUI.php.

214 {
215 global $DIC;
216
217 if (!$this->checkPermissionBoolAndReturn("visible") && !$this->checkPermissionBoolAndReturn('read')) {
218 ilUtil::sendFailure($DIC['lng']->txt("msg_no_perm_read"), true);
219 $this->ctrl->redirectByClass('ilPersonalDesktopGUI', '');
220 }
221 $DIC->tabs()->activateTab(self::TAB_ID_INFO);
222 $info = new ilInfoScreenGUI($this);
223 $info->enablePrivateNotes();
224 $info->addMetaDataSections($this->object->getId(), 0, $this->object->getType());
225 $this->ctrl->forwardCommand($info);
226 }
Class ilInfoScreenGUI.
$info
Definition: index.php:5

References $DIC, $info, and ilUtil\sendFailure().

Referenced by executeCommand(), and infoScreen().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ initCreationForms()

ilObjBibliographicGUI::initCreationForms (   $a_new_type)
protected
Parameters
string$a_new_type
Returns
array

Reimplemented from ilObject2GUI.

Definition at line 283 of file class.ilObjBibliographicGUI.php.

284 {
285 global $DIC;
286
287 $forms = parent::initCreationForms($a_new_type);
288 // Add File-Upload
289 $in_file = new ilFileInputGUI($DIC->language()->txt("bibliography_file"), "bibliographic_file");
290 $in_file->setSuffixes(array("ris", "bib", "bibtex"));
291 $in_file->setRequired(true);
292 $forms[self::CFORM_NEW]->addItem($in_file);
293 $this->ctrl->saveParameterByClass('ilobjrootfoldergui', 'new_type');
294 $forms[self::CFORM_NEW]->setFormAction($this->ctrl->getFormActionByClass('ilobjrootfoldergui', "save"));
295
296 return $forms;
297 }
This class represents a file property in a property form.

References $DIC, and ilObjectGUI\CFORM_NEW.

Referenced by save().

+ Here is the caller graph for this function:

◆ initEditCustomForm()

ilObjBibliographicGUI::initEditCustomForm ( ilPropertyFormGUI  $a_form)
protected
Parameters
ilPropertyFormGUI$a_form

Reimplemented from ilObjectGUI.

Definition at line 443 of file class.ilObjBibliographicGUI.php.

444 {
445 global $DIC;
446
447 $DIC->tabs()->activateTab(self::SUBTAB_SETTINGS);
448 // is_online
449 $cb = new ilCheckboxInputGUI($DIC->language()->txt("online"), "is_online");
450 $a_form->addItem($cb);
451 }
This class represents a checkbox property in a property form.
addItem($a_item)
Add Item (Property, SectionHeader).

References $DIC, and ilPropertyFormGUI\addItem().

+ Here is the call graph for this function:

◆ initEditForm()

ilObjBibliographicGUI::initEditForm ( )

Init object edit form.

Returns
ilPropertyFormGUI

Reimplemented from ilObjectGUI.

Definition at line 413 of file class.ilObjBibliographicGUI.php.

414 {
415 global $DIC;
416
417 $form = parent::initEditForm();
418 // Add File-Upload
419 $in_file = new ilFileInputGUI(
420 $DIC->language()
421 ->txt("bibliography_file"),
422 "bibliographic_file"
423 );
424 $in_file->setSuffixes(array("ris", "bib", "bibtex"));
425 $in_file->setRequired(false);
426 $cb_override = new ilCheckboxInputGUI(
427 $DIC->language()
428 ->txt("override_entries"),
429 "override_entries"
430 );
431 $cb_override->addSubItem($in_file);
432
433 $form->addItem($cb_override);
434 $form->setFormAction($DIC->ctrl()->getFormAction($this, "save"));
435
436 return $form;
437 }
if(isset($_POST['submit'])) $form

References $DIC, and $form.

◆ initSubTabs()

ilObjBibliographicGUI::initSubTabs ( )
protected

Definition at line 395 of file class.ilObjBibliographicGUI.php.

396 {
397 global $DIC;
398 $DIC->tabs()->addSubTab(
399 self::SUBTAB_SETTINGS,
400 $DIC->language()
401 ->txt(self::SUBTAB_SETTINGS),
402 $this->ctrl->getLinkTarget($this, self::CMD_EDIT_OBJECT)
403 );
404 $DIC->tabs()->addSubTab(
405 self::SUB_TAB_FILTER,
406 $DIC->language()
407 ->txt("bibl_filter"),
408 $this->ctrl->getLinkTargetByClass(ilBiblFieldFilterGUI::class, ilBiblFieldFilterGUI::CMD_STANDARD)
409 );
410 }

References $DIC, and ilBiblFieldFilterGUI\CMD_STANDARD.

Referenced by executeCommand().

+ Here is the caller graph for this function:

◆ removeFromDesk()

ilObjBibliographicGUI::removeFromDesk ( )

Remove from desktop.

Alias for removeFromDeskObject.

@access public

Definition at line 692 of file class.ilObjBibliographicGUI.php.

693 {
694 $this->removeFromDeskObject();
695 }
removeFromDeskObject()
Remove from desktop.

References removeFromDeskObject().

+ Here is the call graph for this function:

◆ removeFromDeskObject()

ilObjBibliographicGUI::removeFromDeskObject ( )

Remove from desktop.

@access public

Implements ilDesktopItemHandling.

Definition at line 666 of file class.ilObjBibliographicGUI.php.

667 {
668 global $DIC;
669
671 ilUtil::sendSuccess($DIC->language()->txt("removed_from_desktop"), true);
672 $this->ctrl->redirect($this, self::CMD_VIEW);
673 }
static removeFromDesktop()
Remove item from personal desktop @access public.

References $DIC, and ilDesktopItemGUI\removeFromDesktop().

Referenced by removeFromDesk().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ render()

ilObjBibliographicGUI::render ( )

Definition at line 467 of file class.ilObjBibliographicGUI.php.

468 {
469 $this->showContent();
470 }
showContent()
shows the overview page with all entries in a table

References showContent().

+ Here is the call graph for this function:

◆ resetFilter()

ilObjBibliographicGUI::resetFilter ( )
protected

Definition at line 524 of file class.ilObjBibliographicGUI.php.

525 {
526 $table = new ilBiblEntryTableGUI($this, $this->facade);
527 $table->resetFilter();
528 $table->resetOffset();
529 $this->ctrl->redirect($this, self::CMD_SHOW_CONTENT);
530 }

References $table.

◆ save()

ilObjBibliographicGUI::save ( )

Reimplemented from ilObject2GUI.

Definition at line 300 of file class.ilObjBibliographicGUI.php.

301 {
302 global $DIC;
303
304 $form = $this->initCreationForms($this->getType());
305 if ($form[self::CFORM_NEW]->checkInput()) {
306 parent::save();
307 } else {
309 $form->setValuesByPost();
310 $DIC->ui()->mainTemplate()->setContent($form->getHtml());
311 }
312 }

References $DIC, $form, ilObjectGUI\CFORM_NEW, getType(), and initCreationForms().

+ Here is the call graph for this function:

◆ sendFile()

ilObjBibliographicGUI::sendFile ( )

provide file as a download

Definition at line 536 of file class.ilObjBibliographicGUI.php.

537 {
538 global $DIC;
539
540 if ($DIC['ilAccess']->checkAccess('read', "", $this->object->getRefId())) {
541 $file_path = $this->object->getLegacyAbsolutePath();
542 if ($file_path) {
543 if (is_file($file_path)) {
544 ilFileDelivery::deliverFileAttached($file_path, $this->object->getFilename(), 'application/octet-stream');
545 } else {
546 ilUtil::sendFailure($DIC['lng']->txt("file_not_found"));
547 $this->showContent();
548 }
549 }
550 } else {
551 $this->handleNonAccess();
552 }
553 }
static deliverFileAttached($path_to_file, $download_file_name='', $mime_type='', $delete_file=false)
void

References $DIC, ilFileDelivery\deliverFileAttached(), handleNonAccess(), ilUtil\sendFailure(), and showContent().

+ Here is the call graph for this function:

◆ showContent()

ilObjBibliographicGUI::showContent ( )

shows the overview page with all entries in a table

Definition at line 476 of file class.ilObjBibliographicGUI.php.

477 {
478 global $DIC;
479
480 // if user has read permission and object is online OR user has write permissions
481 $read_access = $DIC->access()->checkAccess('read', "", $this->object->getRefId());
482 $online = $this->object->getOnline();
483 $write_access = $DIC->access()->checkAccess('write', "", $this->object->getRefId());
484 if (($read_access && $online) || $write_access) {
485 $DIC->tabs()->activateTab(self::TAB_CONTENT);
486
488 $b->setCaption('download_original_file');
489 $b->setUrl($DIC->ctrl()->getLinkTargetByClass(self::class, self::CMD_SEND_FILE));
490 $b->setPrimary(true);
491 $DIC->toolbar()->addButtonInstance($b);
492
493 $table = new ilBiblEntryTableGUI($this, $this->facade);
494 $html = $table->getHTML();
495 $DIC->ui()->mainTemplate()->setContent($html);
496
497 //Permanent Link
498 $DIC->ui()->mainTemplate()->setPermanentLink("bibl", $this->object->getRefId());
499 } else {
500 $object_title = ilObject::_lookupTitle(ilObject::_lookupObjId($_GET["ref_id"]));
502 sprintf(
503 $DIC->language()
504 ->txt("msg_no_perm_read_item"),
505 $object_title
506 ),
507 true
508 );
509 //redirect to repository without any parameters
510 $this->handleNonAccess();
511 }
512 }
static getInstance()
Factory.
static _lookupObjId($a_id)
static _lookupTitle($a_id)
lookup object title
$html
Definition: example_001.php:87

References $_GET, $DIC, $html, $table, ilObject\_lookupObjId(), ilObject\_lookupTitle(), ilLinkButton\getInstance(), handleNonAccess(), and ilUtil\sendFailure().

Referenced by render(), sendFile(), and view().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ showDetails()

ilObjBibliographicGUI::showDetails ( )

Definition at line 556 of file class.ilObjBibliographicGUI.php.

557 {
558 global $DIC;
559
560 if ($DIC->access()->checkAccess('read', "", $this->object->getRefId())) {
561 $id = $DIC->http()->request()->getQueryParams()[self::P_ENTRY_ID];
562 $entry = $this->facade->entryFactory()
563 ->findByIdAndTypeString($id, $this->object->getFileTypeAsString());
564 $bibGUI = new ilBiblEntryDetailPresentationGUI($entry, $this->facade);
565
566 $DIC->ui()->mainTemplate()->setContent($bibGUI->getHTML());
567 } else {
568 $this->handleNonAccess();
569 }
570 }

References $DIC, $id, handleNonAccess(), and P_ENTRY_ID.

+ Here is the call graph for this function:

◆ toggleNotification()

ilObjBibliographicGUI::toggleNotification ( )

Definition at line 600 of file class.ilObjBibliographicGUI.php.

601 {
602 global $DIC;
603
604 switch ($_GET["ntf"]) {
605 case 1:
608 $DIC->user()
609 ->getId(),
610 $this->obj_id,
611 false
612 );
613 break;
614 case 2:
617 $DIC->user()
618 ->getId(),
619 $this->obj_id,
620 true
621 );
622 break;
623 }
624 $DIC->ctrl()->redirect($this, "");
625 }
static setNotification($type, $user_id, $id, $status=true)
Set notification status for object and user.

References $_GET, $DIC, ilNotification\setNotification(), and ilNotification\TYPE_DATA_COLLECTION.

+ Here is the call graph for this function:

◆ updateCustom()

ilObjBibliographicGUI::updateCustom ( ilPropertyFormGUI  $a_form)

updateSettings

Reimplemented from ilObjectGUI.

Definition at line 582 of file class.ilObjBibliographicGUI.php.

583 {
584 global $DIC;
585
586 if ($DIC->access()->checkAccess('write', "", $this->object->getRefId())) {
587 if ($this->object->getOnline() != $a_form->getInput("is_online")) {
588 $this->object->setOnline($a_form->getInput("is_online"));
589 }
590
591 if (!empty($_FILES['bibliographic_file']['name'])) {
592 $this->addNews($this->object->getId(), 'updated');
593 }
594 } else {
595 $this->handleNonAccess();
596 }
597 }
addNews($obj_id, $change='created')
getInput($a_post_var, $ensureValidation=true)
Returns the value of a HTTP-POST variable, identified by the passed id.

References $DIC, addNews(), ilPropertyFormGUI\getInput(), and handleNonAccess().

+ Here is the call graph for this function:

◆ view()

ilObjBibliographicGUI::view ( )

view object content (repository/workspace switch)

Reimplemented from ilObject2GUI.

Definition at line 573 of file class.ilObjBibliographicGUI.php.

574 {
575 $this->showContent();
576 }

References showContent().

+ Here is the call graph for this function:

Field Documentation

◆ $cmd

ilObjBibliographicGUI::$cmd = self::CMD_SHOW_CONTENT
protected

Definition at line 67 of file class.ilObjBibliographicGUI.php.

Referenced by executeCommand().

◆ $facade

ilObjBibliographicGUI::$facade
protected

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

◆ $field_factory

ilObjBibliographicGUI::$field_factory
protected

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

◆ $filter_factory

ilObjBibliographicGUI::$filter_factory
protected

Definition at line 59 of file class.ilObjBibliographicGUI.php.

◆ $object

ilObjBibliographicGUI::$object

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

◆ $translation_factory

ilObjBibliographicGUI::$translation_factory
protected

Definition at line 51 of file class.ilObjBibliographicGUI.php.

◆ $type_factory

ilObjBibliographicGUI::$type_factory
protected

Definition at line 63 of file class.ilObjBibliographicGUI.php.

◆ CMD_EDIT

const ilObjBibliographicGUI::CMD_EDIT = "edit"

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

◆ CMD_EDIT_OBJECT

const ilObjBibliographicGUI::CMD_EDIT_OBJECT = 'editObject'

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

Referenced by executeCommand().

◆ CMD_SEND_FILE

const ilObjBibliographicGUI::CMD_SEND_FILE = "sendFile"

Definition at line 26 of file class.ilObjBibliographicGUI.php.

◆ CMD_SHOW_CONTENT

const ilObjBibliographicGUI::CMD_SHOW_CONTENT = 'showContent'

◆ CMD_SHOW_DETAILS

const ilObjBibliographicGUI::CMD_SHOW_DETAILS = "showDetails"

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

◆ CMD_UPDATE_OBJECT

const ilObjBibliographicGUI::CMD_UPDATE_OBJECT = 'updateObject'

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

Referenced by executeCommand().

◆ CMD_VIEW

const ilObjBibliographicGUI::CMD_VIEW = "view"

Definition at line 29 of file class.ilObjBibliographicGUI.php.

Referenced by getStandardCmd().

◆ P_ENTRY_ID

const ilObjBibliographicGUI::P_ENTRY_ID = 'entry_id'

◆ SUB_TAB_FILTER

const ilObjBibliographicGUI::SUB_TAB_FILTER = "filter"

Definition at line 28 of file class.ilObjBibliographicGUI.php.

◆ SUBTAB_SETTINGS

const ilObjBibliographicGUI::SUBTAB_SETTINGS = "settings"

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

◆ TAB_CONTENT

const ilObjBibliographicGUI::TAB_CONTENT = "content"

Definition at line 27 of file class.ilObjBibliographicGUI.php.

◆ TAB_EXPORT

const ilObjBibliographicGUI::TAB_EXPORT = "export"

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

◆ TAB_ID_INFO

const ilObjBibliographicGUI::TAB_ID_INFO = "id_info"

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

◆ TAB_ID_PERMISSIONS

const ilObjBibliographicGUI::TAB_ID_PERMISSIONS = "id_permissions"

Definition at line 33 of file class.ilObjBibliographicGUI.php.

◆ TAB_ID_RECORDS

const ilObjBibliographicGUI::TAB_ID_RECORDS = "id_records"

Definition at line 32 of file class.ilObjBibliographicGUI.php.

◆ TAB_SETTINGS

const ilObjBibliographicGUI::TAB_SETTINGS = self::SUBTAB_SETTINGS

Definition at line 31 of file class.ilObjBibliographicGUI.php.

Referenced by ilBiblFieldFilterGUI\executeCommand().


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