Skip to content

Commit

Permalink
[FIX] 0042890: Failed test: Recht „Anzeigen“ und „Lesezugriff“
Browse files Browse the repository at this point in the history
  • Loading branch information
chfsx committed Jan 28, 2025
1 parent 3b98510 commit 4b6ee48
Showing 1 changed file with 11 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -420,6 +420,10 @@ protected function settings(): void

private function replaceBibliograficFileInit(): void
{
if (!$DIC->access()->checkAccess('write', "", $this->object->getRefId())) {
$this->ctrl->redirect($this, self::CMD_SHOW_CONTENT);
return;
}
$this->tabs()->clearTargets();
$this->tabs()->setBackTarget(
$this->lng->txt('back'),
Expand Down Expand Up @@ -704,11 +708,13 @@ public function showContent(): void
);
$this->toolbar->addComponent($btn_download_original_file);

$btn_overwrite_bibliographic_file = $this->ui()->factory()->button()->standard(
$this->lng->txt('replace_bibliography_file'),
$this->ctrl()->getLinkTargetByClass(self::class, self::CMD_OVERWRITE_BIBLIOGRAPHIC_FILE)
);
$this->toolbar->addComponent($btn_overwrite_bibliographic_file);
if ($write_access) {
$btn_overwrite_bibliographic_file = $this->ui()->factory()->button()->standard(
$this->lng->txt('replace_bibliography_file'),
$this->ctrl()->getLinkTargetByClass(self::class, self::CMD_OVERWRITE_BIBLIOGRAPHIC_FILE)
);
$this->toolbar->addComponent($btn_overwrite_bibliographic_file);
}

$table_gui = new ilBiblEntryTableGUI($this, $this->facade, $this->ui());
$DIC->ui()->mainTemplate()->setContent($table_gui->getRenderedTableAndExistingFilters());
Expand Down

0 comments on commit 4b6ee48

Please sign in to comment.