Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Textarea fields in Notification messages don't keep line breaks #9494

Closed
SinergiaCRM opened this issue Feb 4, 2022 · 0 comments
Closed

Textarea fields in Notification messages don't keep line breaks #9494

SinergiaCRM opened this issue Feb 4, 2022 · 0 comments
Labels
Area: Emails Issues & PRs related to all things regarding emails & email module Priority:Moderate Issues & PRs that are minor; broken styling, cosmetic, warnings - there are practical workarounds Status:Fix Proposed A issue that has a PR related to it that provides a possible resolution Type:Bug Bugs within the core SuiteCRM codebase

Comments

@SinergiaCRM
Copy link
Contributor

Whenever you have a text in a notification email that contains line breaks, the message received won't keep/display them. Appearing all the text in a single line.

For example:

The file include/language/en_us.notify_template.html contains this meeting invitation:

<!-- BEGIN: Meeting_Subject -->
<p>SuiteCRM Meeting - {MEETING_SUBJECT}</p>
<!-- END: Meeting_Subject -->
<!-- BEGIN: Meeting -->
<p>To: {MEETING_TO}</p>
<p><b>{ASSIGNER}</b> has invited you to a Meeting</p>
<p>
Subject: {MEETING_SUBJECT}<br/>
Location: {MEETING_LOCATION}<br/>
Start Date: {MEETING_STARTDATE}<br/>
End Date: {MEETING_ENDDATE}
</p>
<p>
<!-- BEGIN: Meeting_External_API -->
Meeting URL: {MEETING_URL}
</p>
<!-- END: Meeting_External_API -->
<p>Description: {MEETING_DESCRIPTION}<br/>
</p>
<p>---</p>
<p><a href={ACCEPT_URL}&accept_status=accept>Accept this meeting</a>.</p>
<p><a href={ACCEPT_URL}&accept_status=tentative>Tentatively Accept this meeting</a>.</p>
<p><a href={ACCEPT_URL}&accept_status=decline>Decline this meeting</a>.</p>
<!-- END: Meeting -->

If the {MEETING_DESCRIPTION} contains line breaks, they won't be displayed properly in the email. Instead it will appear everything in same line.
Selection_429
Selection_428

Issue

Notification emails removes line breaks of textarea fields.

Expected Behavior

The text should appear as it is formatted in the textarea field

Actual Behavior

All the text in the textarea field appears in the same line.

Possible Fix

It's possible to add HTML line break tags within the text area field, but a more generic solution would be wraping those fields in "

" tags/style

Steps to Reproduce

  1. Create a Meeting
  2. Add text in Description field that contains line breaks
  3. Add a Contact to send invitation
  4. Send invitation
  5. Check in the received invitation email that the Description text appears in one line

Context

If line breaks aren't displayed properly, the information might be misunderstood. And it isn't aesthetically complying.

Your Environment

SuiteCRM Version used: Version 7.12.2
Browser name and version: Chrome Versión 97.0.4692.71 (Build oficial) (64 bits)
Environment name and version: MySQL, PHP 7
Operating System and version: Ubuntu 18.04

SinergiaCRM added a commit to SinergiaTIC/SuiteCRM that referenced this issue Feb 4, 2022
@johnM2401 johnM2401 added Area: Emails Issues & PRs related to all things regarding emails & email module Priority:Moderate Issues & PRs that are minor; broken styling, cosmetic, warnings - there are practical workarounds Type:Bug Bugs within the core SuiteCRM codebase Status:Fix Proposed A issue that has a PR related to it that provides a possible resolution labels Feb 11, 2022
SinergiaCRM added a commit to SinergiaTIC/SuiteCRM that referenced this issue Feb 14, 2022
SinergiaCRM added a commit to SinergiaTIC/SuiteCRM that referenced this issue Feb 14, 2022
SinergiaCRM added a commit to SinergiaTIC/SuiteCRM that referenced this issue Feb 14, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area: Emails Issues & PRs related to all things regarding emails & email module Priority:Moderate Issues & PRs that are minor; broken styling, cosmetic, warnings - there are practical workarounds Status:Fix Proposed A issue that has a PR related to it that provides a possible resolution Type:Bug Bugs within the core SuiteCRM codebase
Projects
None yet
Development

No branches or pull requests

2 participants