@Delete for multifield

Avatar

Avatar

arturl43391132

Avatar

arturl43391132

arturl43391132

15-11-2019

Hello, AEM Community

Could you help please?

I added multifield to my dialog:

<overrideParentalRatingDisplay
   jcr:primaryType="nt:unstructured"
   sling:resourceType="orion2/components/ui/components/foundation/form/multifield"
   composite="{Boolean}true">
  <field
   jcr:primaryType="nt:unstructured"
   sling:resourceType="granite/ui/components/foundation/container"
   name="./settings/overrideParentalRatingDisplay">
  <items jcr:primaryType="nt:unstructured">
  <key
   jcr:primaryType="nt:unstructured"
   sling:resourceType="granite/ui/components/foundation/form/numberfield"
   name="./key"/>
  <value
   jcr:primaryType="nt:unstructured"
   sling:resourceType="granite/ui/components/foundation/form/textfield"
   name="./value"/>
  </items>
  </field>
  <granite:data
   jcr:primaryType="nt:unstructured"
   cq-msm-lockable="settings/overrideParentalRatingDisplay"/>
</overrideParentalRatingDisplay>

In crx result looks like this:

1854526_pastedImage_2.png

I want multifield node to be deleted if e.g. item0, item1 will be deleted. I added:

<overrideParentalRatingDisplay-Delete
   jcr:primaryType="nt:unstructured"
   sling:resourceType="granite/ui/components/foundation/form/hidden"
   value="{Boolean}true"
   name="./settings/overrideParentalRatingDisplay@Delete"/>

But it doesn't work. Empty node stayed:

1855775_pastedImage_23.png

Do I do something wrong or some different solution exist?

I created multifield component - orion2/components/ui/components/foundation/form/multifield, because multifield situated in libs doesn't support composite multifields.

AEM 6.3

Thanks.

View Entire Topic

Avatar

Avatar

arturl43391132

Avatar

arturl43391132

arturl43391132

30-11-2019

Thanks.