From e1beae19b86dd64e718b052f2643d1c69ba832c1 Mon Sep 17 00:00:00 2001
From: ebremner <ebremner@uwaterloo.ca>
Date: Tue, 15 Jun 2021 15:44:43 -0400
Subject: [PATCH] ISTWCMS-4704: adding node page for contact and updating
 preprocess for contact to include node page

---
 templates/node/node--uw-ct-contact.html.twig | 6 ++++++
 uw_fdsu_theme_resp.theme                     | 2 +-
 2 files changed, 7 insertions(+), 1 deletion(-)
 create mode 100644 templates/node/node--uw-ct-contact.html.twig

diff --git a/templates/node/node--uw-ct-contact.html.twig b/templates/node/node--uw-ct-contact.html.twig
new file mode 100644
index 00000000..c4ed0bba
--- /dev/null
+++ b/templates/node/node--uw-ct-contact.html.twig
@@ -0,0 +1,6 @@
+<div class="layout uw-contained-width">
+  {% include '@components/contact/contact.twig' with {
+    'contact': contact,
+    'is_open': 'true',
+  } %}
+</div>
diff --git a/uw_fdsu_theme_resp.theme b/uw_fdsu_theme_resp.theme
index 81f5170f..24a34abe 100644
--- a/uw_fdsu_theme_resp.theme
+++ b/uw_fdsu_theme_resp.theme
@@ -373,7 +373,7 @@ function uw_fdsu_theme_resp_preprocess_node(&$variables) {
     unset($variables['content']);
   }
 
-  if ($variables['node']->getType() == 'uw_ct_contact' && $variables['view_mode'] == 'teaser') {
+  if ($variables['node']->getType() == 'uw_ct_contact') {
 
     // The UW service object.
     $uwService = \Drupal::service('uw_cfg_common.uw_service');
-- 
GitLab