54 $this->
setRowTemplate(
'tpl.bibliographic_record_table_row.html',
'Modules/Bibliographic');
56 $this->
addColumn($this->
lng->txt(
'a'),
'content',
'auto');
67 $available_field_ids_for_object = array_map(
function (
ilBiblField $field) {
68 return $field->
getId();
69 }, $this->facade->fieldFactory()->getAvailableFieldsForObjId($this->facade->iliasObjId()));
71 foreach ($this->facade->filterFactory()->getAllForObjectId($this->facade->iliasObjId()) as $item) {
72 if (in_array($item->getFieldId(), $available_field_ids_for_object)) {
74 $field = $filter_presentation->getFilterItem();
76 $this->filter_objects[$field->getPostVar()] = $item;
88 $field->readFromSession();
90 $this->applied_filter[$field->getPostVar()] = $field->getChecked();
93 $this->applied_filter[$field->getPostVar()] = $field->getValue();
98 public function fillRow(array $a_set):
void 101 $presentation_gui = $a_set[
'overview_gui'];
102 $this->tpl->setVariable(
104 $presentation_gui->getHtml()
108 $this->tpl->setVariable(
'DETAIL_LINK', $this->
ctrl->getLinkTarget($this->parent_obj,
'showDetails'));
110 $libraries = $this->facade->libraryFactory()->getAll();
111 $arr_library_link = array();
112 foreach ($libraries as $library) {
113 if ($library->getShowInList()) {
121 $arr_library_link[] = $presentation->getButton($this->facade, $presentation_gui->getEntry());
124 if ($arr_library_link !== []) {
125 $this->tpl->setVariable(
'LIBRARY_LINK', implode(
'<br/>', $arr_library_link));
130 protected function initData():
void 136 foreach ($this->applied_filter as $field_name => $field_value) {
137 if (!$field_value || (is_array($field_value) && count($field_value) == 0)) {
140 $filter = $this->filter_objects[$field_name];
142 $filter_info->setFieldName($field_name);
143 switch ($filter->getFilterType()) {
145 $filter_info->setFieldValue($field_value);
146 $filter_info->setOperator(
"IN");
149 $filter_info->setFieldValue($field_value);
150 $filter_info->setOperator(
"=");
153 $filter_info->setFieldValue(
"%{$field_value}%");
154 $filter_info->setOperator(
"LIKE");
158 $query->addFilter($filter_info);
162 $object_id = $this->facade->iliasObjId();
164 $this->facade->entryFactory()
165 ->filterEntryIdsForTableAsArray($object_id, $query) as $entry
168 $bibl_entry = $this->facade->entryFactory()->findByIdAndTypeString($entry[
'entry_id'], $entry[
'entry_type']);
170 $entry[
'content'] = strip_tags($overview_gui->getHtml());
171 $entry[
'overview_gui'] = $overview_gui;
175 usort($entries,
function (
$a,
$b) {
176 return strcmp(
$a[
'content'],
$b[
'content']);
const FILTER_TYPE_TEXT_INPUT
Class ilObjBibliographicGUI.
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
setFormAction(string $a_form_action, bool $a_multipart=false)
addFilterItem(ilTableFilterItem $a_input_item, bool $a_optional=false)
Class ChatMainBarProvider .
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
const FILTER_TYPE_MULTI_SELECT_INPUT
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
setFormName(string $a_name="")
addAndReadFilterItem(ilTableFilterItem $field)
setExternalSorting(bool $a_val)
setShowRowsSelector(bool $a_value)
Toggle rows-per-page selector.
__construct(protected ilObjBibliographicGUI $a_parent_obj, protected ilBiblFactoryFacade $facade, protected \ILIAS\DI\UIServices $ui)
ilBiblEntryTableGUI constructor.
fillRow(array $a_set)
Standard Version of Fill Row.
setDefaultOrderField(string $a_defaultorderfield)
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
setRowTemplate(string $a_template, string $a_template_dir="")
Set row template.
setOrderField(string $a_order_field)
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
setEnableNumInfo(bool $a_val)
$a
thx to https://mlocati.github.io/php-cs-fixer-configurator for the examples
addColumn(string $a_text, string $a_sort_field="", string $a_width="", bool $a_is_checkbox_action_column=false, string $a_class="", string $a_tooltip="", bool $a_tooltip_with_html=false)
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
const FILTER_TYPE_SELECT_INPUT
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
setEnableHeader(bool $a_enableheader)
setPrefix(string $a_prefix)