ILIAS  release_8 Revision v8.25-1-g13de6a5eca6
class.ilDashboardContentBlockGUI.php
Go to the documentation of this file.
1<?php
2
20{
21 public static string $block_type = "dashcontent";
22 protected int $currentitemnumber;
23 protected string $content;
24
25 public function __construct()
26 {
27 global $DIC;
28
29 $this->ctrl = $DIC->ctrl();
30 $this->lng = $DIC->language();
31 $this->user = $DIC->user();
32
34
35 $this->setEnableNumInfo(false);
36 $this->setLimit(99999);
37 $this->setPresentation(self::PRES_MAIN_LEG);
38 $this->allow_moving = false;
39 }
40
41 public function getBlockType(): string
42 {
43 return self::$block_type;
44 }
45
46 public function setCurrentItemNumber(int $a_currentitemnumber): void
47 {
48 $this->currentitemnumber = $a_currentitemnumber;
49 }
50
51 public function getCurrentItemNumber(): int
52 {
54 }
55
56 protected function isRepositoryObject(): bool
57 {
58 return false;
59 }
60
61 public function getHTML(): string
62 {
63 return parent::getHTML();
64 }
65
66 public function getContent(): string
67 {
68 return $this->content;
69 }
70
71 public function setContent(string $a_content): void
72 {
73 $this->content = $a_content;
74 }
75
76 public function fillDataSection(): void
77 {
78 $this->tpl->setVariable("BLOCK_ROW", $this->getContent());
79 }
80
81 public function fillFooter(): void
82 {
83 //$this->fillFooterLinks();
85
86 if (is_array($this->data)) {
87 $this->max_count = count($this->data);
88 }
89
90 // table footer numinfo
91 if ($this->getEnableNumInfo()) {
92 $numinfo = "(" . $this->getCurrentItemNumber() . " " .
93 strtolower($lng->txt("of")) . " " . $this->max_count . ")";
94
95 if ($this->max_count > 0) {
96 $this->tpl->setVariable("NUMINFO", $numinfo);
97 }
98 }
99 }
100
101 public function fillPreviousNext(): void
102 {
103 }
104}
This class represents a block method of a block.
ilLanguage $lng
setPresentation(int $type)
setLimit(int $a_limit)
setEnableNumInfo(bool $a_enablenuminfo)
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
isRepositoryObject()
Returns whether block has a corresponding repository object.
setCurrentItemNumber(int $a_currentitemnumber)
fillDataSection()
Standard implementation for row based data.
txt(string $a_topic, string $a_default_lang_fallback_mod="")
gets the text for a given topic if the topic is not in the list, the topic itself with "-" will be re...
global $DIC
Definition: feed.php:28
__construct(Container $dic, ilPlugin $plugin)
@inheritDoc