From 8e0132711a2bd571912384c4170d7bff0a019968 Mon Sep 17 00:00:00 2001 From: Pat Date: Mon, 9 Dec 2024 15:45:08 -0700 Subject: [PATCH] Newsletters: allow unpublished to show in Email HTML preview --- ...ph--newsletter-section--email-html.html.twig | 17 ----------------- 1 file changed, 17 deletions(-) diff --git a/templates/paragraphs/paragraph--newsletter-section--email-html.html.twig b/templates/paragraphs/paragraph--newsletter-section--email-html.html.twig index 595462e8..23a5d98c 100644 --- a/templates/paragraphs/paragraph--newsletter-section--email-html.html.twig +++ b/templates/paragraphs/paragraph--newsletter-section--email-html.html.twig @@ -25,14 +25,6 @@ {% for key, item in paragraph.field_newsletter_section_select %} {% if key|first != '#' %} - {# Unpublished check #} - {% if (item.entity.field_newsletter_article_select.entity and - item.entity.field_newsletter_article_select.entity.isPublished()) or - (item.entity.field_newsletter_content_title and - item.entity.field_newsletter_content_title.value|render) - or - item.entity.field_newsletter_content_text.value|render - %} {# Code to render selected article content (thumbnail) #} @@ -148,19 +140,11 @@
{% endif %} - {% endif %} {% endfor %} {% else %} {% for key, item in paragraph.field_newsletter_section_select %} {% if key|first != '#' %} - {# Unpublished check #} - {% if (item.entity.field_newsletter_article_select.entity and - item.entity.field_newsletter_article_select.entity.isPublished()) or - (item.entity.field_newsletter_content_title and - item.entity.field_newsletter_content_title.value|render) - or - item.entity.field_newsletter_content_text.value|render %}
@@ -274,7 +258,6 @@
- {% endif %} {% endif %} {% endfor %} {% endif %}