aboutsummaryrefslogtreecommitdiffhomepage
path: root/application/front/controllers/ShaarliController.php
diff options
context:
space:
mode:
Diffstat (limited to 'application/front/controllers/ShaarliController.php')
-rw-r--r--application/front/controllers/ShaarliController.php14
1 files changed, 14 insertions, 0 deletions
diff --git a/application/front/controllers/ShaarliController.php b/application/front/controllers/ShaarliController.php
index 2b828588..0c5d363e 100644
--- a/application/front/controllers/ShaarliController.php
+++ b/application/front/controllers/ShaarliController.php
@@ -30,6 +30,20 @@ abstract class ShaarliController
30 return $this; 30 return $this;
31 } 31 }
32 32
33 /**
34 * Assign variables to RainTPL template through the PageBuilder.
35 *
36 * @param mixed $data Values to assign to the template and their keys
37 */
38 protected function assignAllView(array $data): self
39 {
40 foreach ($data as $key => $value) {
41 $this->assignView($key, $value);
42 }
43
44 return $this;
45 }
46
33 protected function render(string $template): string 47 protected function render(string $template): string
34 { 48 {
35 $this->assignView('linkcount', $this->container->bookmarkService->count(BookmarkFilter::$ALL)); 49 $this->assignView('linkcount', $this->container->bookmarkService->count(BookmarkFilter::$ALL));