powermail icon indicating copy to clipboard operation
powermail copied to clipboard

Manipulate values not working

Open instruccionesaldorso opened this issue 5 years ago • 4 comments

TYPO3 9.5.6-dev EXT:powermail 7.3.0

Having a field of type "Checkboxes [check]", whose "marker" is "interest" and "settings" field is defined like:

Eventvermarktung | 1 Online-Registrierung | 2 Zahlungsabwicklung | 3 Einlassmanagement | 4 Event Data Intelligence | 5 Schnittstellen / APIs | 6

and the next TypoScript:

plugin.tx_powermail { settings.setup { manipulateVariablesInPowermailAllMarker { receiverMail { interest = CASE interest { key.field = value 1 = TEXT 1.value = Eventvermarktung 2 = TEXT 2.value = Online-Registrierung 3 = TEXT 3.value = Zahlungsabwicklung 4 = TEXT 4.value = Einlassmanagement 5 = TEXT 5.value = Event Data Intelligence 6 = TEXT 6.value = Schnittstellen / APIs default = TEXT default.value = [No value selected] } } } } }

If I select checkboxes 1, 2, 3, I receive in the receiver mail the next:

Interest | [No value selected], [No value selected], [No value selected]

I thought single values would work, but neither:

Interest | [No value selected]

This is tested over a clean TYPO3 environment. Can this be tested?

instruccionesaldorso avatar May 20 '19 10:05 instruccionesaldorso

I tested the changes of @alexkue7911 in TYPO3 9.5.11 and EXT:powermail 7.3.1 This doesn't work for me. The powermail_all values of the checkboxes in the receiverMail are empty when using manipulateVariablesInPowermailAllMarker (works with selects, not with checkboxes).

Is there no easy way to let powermail use the labels that are already set in the backend setup of the checkboxes? ...instead of adding the labels again by TypoScript?

Eventvermarktung | 1
Online-Registrierung | 2
Zahlungsabwicklung | 3
Einlassmanagement | 4
Event Data Intelligence | 5
Schnittstellen / APIs | 6

(I changed the value with a custom ViewHelper in Partials/PowermailAll/Mail.html, since there seems to be no better option for now.)

cepheiVV avatar Nov 11 '19 11:11 cepheiVV

Is there no easy way to let powermail use the labels that are already set in the backend [...]?

I added the following Line in /Partials/PowermailAll/Web.html for testing:

<f:debug title="answer" inline="0">{answer}</f:debug>

I found that answer.field.settings contains the information that connects label and value (for select as well as for checkboxes).

answer.field.settings
'Daslabel|thevalue
Daslabel2|thevalue2' (38 chars)

Could this be used to access the label without having to add it in the code? Like, look up answer.value and select the matching label? Or am I thinking too far around the corners?

ursbraem avatar Aug 11 '20 19:08 ursbraem

Hi, This is still not working. The problem is line 63 in ext/powermail/Classes/ViewHelpers/Misc/ManipulateValueWithTypoScriptViewHelper.php: if( isset($this->typeToTypoScriptType[$type]) && $this->typeToTypoScriptType is not defined anywhere which means that the function does not work.

Kind regards Tomas

tomashavner avatar Sep 22 '22 11:09 tomashavner

This is already fixed with commit db3e08e1d6b48dc319d40a114719aec867e949bf - and will be released with the upcoming version.

einpraegsam avatar Sep 26 '22 07:09 einpraegsam

Fixed with version 10.5.0

mschwemer avatar Aug 18 '23 09:08 mschwemer