Skip to content

Trigger events field with ^ parent selector does not work (nestedform) #716

@AIC-BV

Description

@AIC-BV

Winter CMS Build

1.2

PHP Version

8.1

Database engine

MySQL/MariaDB

Plugins installed

Winter.Sitemap, Winter.Pages, Winter.TinyPNG, Winter.Translate, Winter.Redirects, Aic.Globals, Aic.ExtendWinterPages, Aic.Blog, Aic.Team, Aic.Account, Aic.Contact, Aic.Invoice, Aic.Discount, Aic.Aftersales, Aic.Reviews, Aic.Faq, StudioBosco.BackendNotifications, StudioBosco.BackendComments, ...

Issue description

Adding a trigger to your form with the fields parent selector does not work

block_gallery:
    name: Gallery
    icon: icon-camera-retro
    fields:
        type:
            label: Type
            type: balloon-selector
            default: grid
            options:
                grid: Grid
                slider: Slider
        data:
            type: nestedform
            usePanelStyles: false
            cssClass: custom-nested-form
            form:
                tabs:
                        images:
                            tab: Images
                            type: repeater
                            form:
                                fields:
                                    caption:
                                        label: Caption
                                        type: richeditor
                                        size: small
                                        trigger:
                                            action: hide
                                            field: ^^type
                                            condition: value[grid]

No matter how many thingies ^^^ I add, the trigger never happens

Steps to replicate

  1. Create a plugin
  2. Use the code above
  3. Check the trigger and notice it won't trigger

Workaround

I added a comment, which is an -ok acceptable- workaround for my case
commentAbove: Not for type - GRID

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions