ILIAS  release_4-4 Revision
ilBibliographicDetailsGUI Class Reference

Class ilBibliographicDetailsGUI The detailled view on each entry. More...

+ Collaboration diagram for ilBibliographicDetailsGUI:

Public Member Functions

 showDetails (ilObjBibliographic $bibl_obj)
 

Detailed Description

Class ilBibliographicDetailsGUI The detailled view on each entry.

Definition at line 9 of file class.ilBibliographicDetailsGUI.php.

Member Function Documentation

◆ showDetails()

ilBibliographicDetailsGUI::showDetails ( ilObjBibliographic  $bibl_obj)
Parameters
ilObjBibliographic$bibl_obj
Returns
void

Definition at line 16 of file class.ilBibliographicDetailsGUI.php.

References $_GET, $ilCtrl, $lng, $tpl, ilBibliographicEntry\getAttributes(), ilObjBibliographic\getFiletype(), and ilObject2\getRefId().

17  {
18  global $tpl, $ilTabs, $ilCtrl, $lng;
19 
20  include_once("Services/Form/classes/class.ilPropertyFormGUI.php");
21  $form = new ilPropertyFormGUI();
22 
23 
24  $ilTabs->clearTargets();
25  $ilTabs->setBackTarget("back", $ilCtrl->getLinkTarget($this, 'showContent'));
26 
27  $form->setTitle($lng->txt('detail_view'));
28 
29 
30  $entry = new ilBibliographicEntry($bibl_obj->getFiletype(), $_GET['entryId']);
31  $attributes = $entry->getAttributes();
32 
33  //translate array key in order to sort by those keys
34  foreach($attributes as $key => $attribute)
35  {
36  //Check if there is a specific language entry
37  if($lng->exists($key))
38  {
39  $strDescTranslated = $lng->txt($key);
40  }
41  //If not: get the default language entry
42  else
43  {
44  $arrKey = explode("_",$key);
45  $strDescTranslated = $lng->txt($arrKey[0]."_default_".$arrKey[2]);
46  }
47  unset($attributes[$key]);
48  $attributes[$strDescTranslated] = $attribute;
49  }
50 
51  // sort attributes alphabetically by their array-key
52  ksort($attributes, SORT_STRING);
53 
54  // render attributes to html
55  foreach($attributes as $key => $attribute)
56  {
57  $ci = new ilCustomInputGUI($key);
58  $ci->setHtml($attribute);
59  $form->addItem($ci);
60  }
61 
62  // set content and title
63  $tpl->setContent($form->getHTML());
64 
65  //Permanent Link
66  $tpl->setPermanentLink("bibl", $bibl_obj->getRefId(),"_".$_GET['entryId']);
67 
68  }
This class represents a property form user interface.
$_GET["client_id"]
global $ilCtrl
Definition: ilias.php:18
if(isset($_FILES['img_file']['size']) && $_FILES['img_file']['size'] > 0) $tpl
This class represents a custom property in a property form.
global $lng
Definition: privfeed.php:40
Class ilObjBibliographic.
+ Here is the call graph for this function:

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