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

Adding attachment in mail template doesn't work #34512

Closed
RickR2H opened this issue Jun 14, 2021 · 13 comments
Closed

Adding attachment in mail template doesn't work #34512

RickR2H opened this issue Jun 14, 2021 · 13 comments

Comments

@RickR2H
Copy link
Member

RickR2H commented Jun 14, 2021

Steps to reproduce the issue

  1. Go to System -> Mail Templates -> open the "Global Configuration: Test Mail" mail template.
  2. Try to add an attachment by clicking the "Plus button".
  3. There should be a field to upload and add the attachment, but only a blank space is added.

screen shot 2021-06-14 at 10 12 24

@richard67
Copy link
Member

@RickR2H I can't reproduce this on a clean, new installation of current 4.0-dev. In this case, the "Attachments Folder" option in the Media Manager component's options is empty, so there is no "+" button shown in any of the mail templates to add an attachment.

So my questions are:

  1. Have you used a new installation of current 4.0-dev or latest nightly? Or have you used an installation which was updated in past? If so, please let us know the update history.
  2. What is the value of the "Attachments Folder" option in the Media Manager component's options of your installation?

@joomdonation
Copy link
Contributor

@richard67 I can confirm the issue. Currently, look like subform is not working at all. For example, we can add a new custom field checkbox and could not add options for the custom field anymore

@ghost
Copy link

ghost commented Jun 14, 2021

I got the issue reported by @RickR2H if i set in options of mail templates the Attachment Folder to images.

@richard67
Copy link
Member

I got the issue reported by @RickR2H if i set in options of mail templates the Attachment Folder to images.

Confirmed.

@richard67
Copy link
Member

@richard67 I can confirm the issue. Currently, look like subform is not working at all. For example, we can add a new custom field checkbox and could not add options for the custom field anymore

@joomdonation Last change for subforms in J4 was #31567 . Could it be related to that PR? Or has the upmerge from 3.10-dev broken something from that PR?

@richard67
Copy link
Member

@joomdonation Could you open an issue for the general subforms issue and we make it a release blocker? Or should we use this issue here to continue and make it a release blocker?

@joomdonation
Copy link
Contributor

@richard67 We could use this issue here to continue. I don't know subform code enough to confirm where this issue comes from. Maybe @Fedik could help ?

@Fedik
Copy link
Member

Fedik commented Jun 14, 2021

I will try to look what's going on

@joomdonation
Copy link
Contributor

Sorry @dgrammatiko . Look like it causes by Joomla.sanitizeHtml too. If we change this line of code to https://github.com/joomla/joomla-cms/blob/4.0-dev/build/media_source/system/js/fields/joomla-field-subform.w-c.es6.js#L186 to :

tmpEl.innerHTML = this.template;

The issue is gone. Could you please look at this?

@joomdonation
Copy link
Contributor

Ah, we added comment at the same time :).

@dgrammatiko
Copy link
Contributor

@joomdonation here's a PR: #34514

@joomdonation
Copy link
Contributor

Fixed on PR #34514 , so closing this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

6 participants