Expand my Community achievements bar.

Join us in celebrating the outstanding achievement of our AEM Community Member of the Year!

Add event handler on pathfield widget on dialog AEM6.3

Avatar

Level 2

Hey Guys,

I have been trying to capture select event on pathfield on TouchUI dialog, to populate next widget(textfield) based on the value selected in pathfield.

I tried with adding class attribute on pathfield , and capturing the event on('change:value').

I think this works well for with 'select' widget (dropdown) and for pathfiel its does not seems working.

    var ASSET_PATH_CLASS = ".cq-dialog-asset-path";

    $( document ).on("foundation-contentloaded", function(e) {

     

        $( ASSET_PATH_CLASS ).on('change:value', function(event, payload) {

    var $form =  el.closest("form.foundation-form");

            var $selected = $form.find(ASSET_PATH_CLASS);

          getJsonData($selected.val(), $form);

        });

    });

Can you correct me if I'm trying to capture correct event.?Or if anybody has implemented event on pathfield in granite.

0 Replies