From ec98b37c8bc358f4d9f41f1c6e4fbda1a88b7d53 Mon Sep 17 00:00:00 2001
From: Kevin Paxman <kpaxman@uwaterloo.ca>
Date: Thu, 12 Sep 2024 12:50:29 -0400
Subject: [PATCH] ISTWCMS-6978: refactor, add next link at bottom, and make
 URLs relative so they should work on Pantheon

---
 src/Plugin/Block/FormsListBlock.php | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/src/Plugin/Block/FormsListBlock.php b/src/Plugin/Block/FormsListBlock.php
index 14f9b29..f7f74b9 100644
--- a/src/Plugin/Block/FormsListBlock.php
+++ b/src/Plugin/Block/FormsListBlock.php
@@ -133,10 +133,8 @@ class FormsListBlock extends BlockBase implements ContainerFactoryPluginInterfac
     // a link to view all the webforms to the info part of the
     // render array.
     if ($total_num_of_results > 50) {
-      $html = $this->t('@count webforms', ['@count' => $total_num_of_results]);
-      $html .= '<br />';
-      $html .= $this->t('There are more than 50 webforms, <a href="/admin/structure/webform">View all webforms</a>');
-      $build['entity_list']['info']['#markup'] = $html;
+      $build['entity_list']['info']['#markup'] .= $this->t('<br><a href="../admin/structure/webform">View all webforms</a>');
+      $build['entity_list']['more_info']['#markup'] = $this->t('<p class="pager__items"><a href="../admin/structure/webform?page=1">Next ›</a></p>');
     }
 
     // Remove the pager from the webform list.
-- 
GitLab