Page 1 of 3

payment e-mail

Posted: 27 Dec 2015, 15:05
by Alexander
Hello all,

I have some questions about payment e-mails.
How is it possible to remove all html-parts from the e-mail? - It should be text-only.
How can I add a little imprint to this e-mail? Is there a simple TypoScript-command?
There's also a bit strange problem with sending e-mails, but I don't know if this has to do with Aimeos: As long as there are no e-mails to send, the task for sending e-mails is executed every minute (in planned tasks, the date/time-stamps are updated correctly), but as soon as there is actually an e-mail to send, no e-mail is being sent and "last execution" does not update anymore and "next execution" gets an "-". Manual execution of the task works, and the e-mail is being sent.
Thanks in advance!

Best regards

Alexander

Re: payment e-mail

Posted: 28 Dec 2015, 13:34
by aimeos
Alexander wrote:How is it possible to remove all html-parts from the e-mail? - It should be text-only.
You can remove the HTML subpart via configuration:
https://aimeos.org/docs/Configuration/C ... t/subparts
Alexander wrote:How can I add a little imprint to this e-mail? Is there a simple TypoScript-command?
There are two ways: Either overwrite the translation of the "outro" or "legal" subpart via TypoScript or replace the legal subpart with your own template. You can find all information about adapting the e-mails in these articles: https://aimeos.org/docs/Configuration/C ... tml#E-mail
Alexander wrote:There's also a bit strange problem with sending e-mails, but I don't know if this has to do with Aimeos: As long as there are no e-mails to send, the task for sending e-mails is executed every minute (in planned tasks, the date/time-stamps are updated correctly), but as soon as there is actually an e-mail to send, no e-mail is being sent and "last execution" does not update anymore and "next execution" gets an "-". Manual execution of the task works, and the e-mail is being sent.
Are there any error messages in the log (admin interface, first tab, second panel) resp. in the madmin_log table?

Re: payment e-mail

Posted: 28 Dec 2015, 17:29
by Alexander
Thank you very much for your help!
It's working now except the imprint.
How can I append to the legal part? - Sorry for asking stupid questions. I am new to TYPO3 and Aimeos. I even don't know where to find the necessary information.
In the tasks TypoScript-configuration I was just trying this: client.html.email.payment.text.legal := appendString(Imprint)
What's the variable of the processed legal-string, or is there an .appendto-field?

Re: payment e-mail

Posted: 29 Dec 2015, 22:07
by aimeos
Alexander wrote: How can I append to the legal part? - Sorry for asking stupid questions. I am new to TYPO3 and Aimeos. I even don't know where to find the necessary information.
There's no TypoScript variable available where you can append text - you can only overwrite the translations. How translations are overwritten can be found here: https://aimeos.org/docs/TYPO3/Overwrite_translations

You need the original English string which in case of the legal text is rather long:
https://github.com/aimeos/aimeos-core/b ... t.html#L12

In TypoScript it would be:

Code: Select all

... {
  domain = client/html
  string = All deliveries shipped are subject to our terms and conditions, which are available on our website and which you accepted when placing your order.\n\nThis email contains confidential information and is exclusively for the use of the person addressed. Should you not be that person then please reply to this e-mail and delete the e-mail and attachments afterwards.
  trans = ...
}

Re: payment e-mail

Posted: 30 Dec 2015, 14:10
by Alexander
Thanks, but unfortunately it's not working.
In the e-mail-tasks TypoScript configuration I have:

plugin.tx_aimeos.settings.client.html.email.payment.default.subparts {
0=text
}
plugin.tx_aimeos.settings.i18n.en.0 {
domain = client/html
string = If you have any questions, please reply to this e-mail
trans = If you have any questions, please reply to this e-mail\n\nIMPRINT
}
plugin.tx_aimeos.settings.i18n.de.0 {
domain = client/html
string = If you have any questions, please reply to this e-mail
trans = Falls Sie Fragen haben sollten, antworten Sie bitte auf diese E-Mail\n\nIMPRESSUM
}

The first command works well, and removes the html part, thus is being executed, but the others have no effect. Is there a mistake in this code?

Re: payment e-mail

Posted: 30 Dec 2015, 16:09
by aimeos
Alexander wrote:

Code: Select all

plugin.tx_aimeos.settings.i18n.de.0 {
  domain = client/html
  string = If you have any questions, please reply to this e-mail
  trans = Falls Sie Fragen haben sollten, antworten Sie bitte auf diese E-Mail\n\nIMPRESSUM
}
The TypoScript code is OK. Which TYPO3 version are you using and what scheduler task (E-Mail or Extbase)?

Re: payment e-mail

Posted: 30 Dec 2015, 16:24
by Alexander
It's TYPO3 7.6.0 and the task is aimeos->Planer for Aimeos Shop E-Mails.

Re: payment e-mail

Posted: 30 Dec 2015, 17:15
by aimeos
Alexander wrote:It's TYPO3 7.6.0 and the task is aimeos->Planer for Aimeos Shop E-Mails.
Are both languages active in the admin interface (Locale tab -> Language sub-tab)?
Can you try sending e-mails with the Extbase task for a quick test?

Re: payment e-mail

Posted: 30 Dec 2015, 19:39
by Alexander
aimeos wrote:Are both languages active in the admin interface (Locale tab -> Language sub-tab)?
Yes, they are. And the e-mails are sent in the correct language in dependence of the selected language in the ordering process.
aimeos wrote:Can you try sending e-mails with the Extbase task for a quick test?
I have just tried. As by sending with the aimeos-task the correct language is used. But unfortunately for TypoScript there is only an input-field not a textarea. That's why I can't paste the TypoScript code for translation there.

By the way: There's an interesting difference between the two methods sending e-mails. Sending with Extbase gives a nice HTML-mail but the Aimeos task does not - almost all of the formatting except line breaks is not visible at least in Thunderbird. That's why I wanted to use simple text.

Re: payment e-mail

Posted: 31 Dec 2015, 12:37
by aimeos
Alexander wrote:I have just tried. As by sending with the aimeos-task the correct language is used. But unfortunately for TypoScript there is only an input-field not a textarea. That's why I can't paste the TypoScript code for translation there.
Well, you can paste the code into the input field. It doesn't display nicely but it should work even if the TYPO3 Extbase command controller doesn't offer text area fields.
Alexander wrote:By the way: There's an interesting difference between the two methods sending e-mails. Sending with Extbase gives a nice HTML-mail but the Aimeos task does not - almost all of the formatting except line breaks is not visible at least in Thunderbird. That's why I wanted to use simple text.
Then you didn't enter a valid path to the theme files. The Extbase command controller uses "typo3conf/ext/aimeos/Resources/Public/Themes/elegance" by default. We added some code that this will be also set by default in the e-mail scheduler in the future.

The problem with the missing e-mail translation was a misnamed variable. We've fixed that in the git repository and it will be part of the next minor release.