AEM6.4 - Multifield with Show checkbox in javascript | Community
Skip to main content
This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.

3 replies

smacdonald2008
January 8, 2019

Looks like your JavaScript is not correct to work within a MultiField. I will look for examples.

Gaurav-Behl
January 8, 2019

($("coral-checkbox[name='./includebutton'] :checked")  will evaluate to a boolean value either true or false

After that,  (boolean value).length ===1 doesn't make sense hence its breaking and going inside if block

Try this

if($("coral-checkbox[name='./includebutton'] :checked")) {..... }

smacdonald2008
January 8, 2019

Also - check this article - as suggested by our AEM team member -- http://experience-aem.blogspot.com/2017/06/aem-63-touch-ui-nested-coral2-composite-multifield.html

January 8, 2019

Dear All, Actually wrongly I have changed sling:resourcetype to granite/ui/components/foundation/form/select . That is why it was not working. Now I have changed to granite/ui/components/coral/foundation/form/select and it is working fine now. Thanks a lot all of your help.

smacdonald2008
January 8, 2019

I am very happy to hear you have it working.