Issue Bug Closed

#70378switchableControllerActions overrides configuration of non-cacheable actions

Viktor Livakivskyi 10/05/15, 12:39 updated 02/19/22, 10:46

Description

I have a number of actions in my controller. Part of them are executed in one plugin (on first page), and another part is executed in another plugin (on second page).

For making this possible I’m using FlexForm with switchableControllerActions:

<switchableControllerActions>
    <TCEforms>
        <label>Label</label>
        <config>
            <type>select</type>
            <items type="array">
                <numIndex index="0" type="array">
                    <numIndex index="0">Plugin 1</numIndex>
                    <numIndex index="1">Controller->action1;Controller->action2</numIndex>
                </numIndex>
                <numIndex index="1" type="array">
                    <numIndex index="0">Plugin 2</numIndex>
                    <numIndex index="1">Controller->action3;Controller->action4</numIndex>
                </numIndex>
            </items>
            <minitems>1</minitems>
            <maxitems>1</maxitems>
            <size>1</size>
        </config>
    </TCEforms>
</switchableControllerActions>

All the actions are defined in ext_localconf.php as uncached.

If I make a link from “Plugin 1” to “action3”, it will be correctly created, but will contain a cHash. If I include “action3” into “Plugin 1” via switchableControllerActions, same link will not contain cHash.

Same happens, when redirect() is called from within a Controller.

I expect, that ‘switchableControllerActions’ wouldn’t affect cacheable and non-cacheable plugin definitions, so it looks like a bug.

Reviews 0

No change resolves or names this issue in its commit message, and no comment links one.