Skip to content

Commit

Permalink
Merge pull request #1541 from CuBoulder/issue/1517
Browse files Browse the repository at this point in the history
Newsletters: allow unpublished to show in Email HTML preview
  • Loading branch information
jcsparks authored and web-flow committed Dec 10, 2024
2 parents 71bfac8 + 8e01327 commit 92fc932
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 17 deletions.
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,14 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

- ### Newsletters: allow unpublished to show in Email HTML preview
Previously the Email HTML of Newsletters would not display unpublished Articles. Now they will display so site-editors can verify and proof content before mailing. There is a content warning on the Node of any Articles that are unpublished.

Note: Articles must still be manually published before sending the email, or could result in email recipients getting broken links.

Resolves https://github.com/CuBoulder/tiamat-theme/issues/1517
---

- ### Remove wrap from info footer
Resolves #1525.
Removes wrapping from the site info contact footer to remove the extra space.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,14 +25,6 @@
<!--Feature Style Section-->
{% 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) #}
<!--Feature Article-->
<table role="presentation" width="600" style="padding-bottom: 20px;">
Expand Down Expand Up @@ -148,19 +140,11 @@
</tbody>
</table>
{% endif %}
{% endif %}
{% endfor %}
{% else %}
<!--Teaser Section-->
{% 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 %}
<!--Teaser Article-->
<center align="left">
<table role="presentation" width="600" style="padding-top:20px; padding-bottom: 20px; border-bottom: solid 1px #cccccc;">
Expand Down Expand Up @@ -274,7 +258,6 @@
</tbody>
</table>
</center>
{% endif %}
{% endif %}
{% endfor %}
{% endif %}
Expand Down

0 comments on commit 92fc932

Please sign in to comment.