0

How can I add an event when changes select box dropdown value and I will trigger Ajax when change value in the dropdown, Below are my code.

<fieldset name="sample_fieldset">
    <argument name="data" xsi:type="array">
        <item name="config" xsi:type="array">
            <item name="label" xsi:type="string" translate="true">Attribute Information</item>
        </item>
    </argument>
    <field name="attr">
        <argument name="data" xsi:type="array">
            <item name="options" xsi:type="object">vendor\module\Model\Source\option</item>
            <item name="config" xsi:type="array">
                <item name="dataType" xsi:type="string">text</item>
                <item name="label" xsi:type="string" translate="true">Select Attribute</item>
                <item name="formElement" xsi:type="string">select</item>
                <item name="source" xsi:type="string">splitattr</item>
                <item name="dataScope" xsi:type="string">attr</item>
                <item name="default" xsi:type="string">0</item>
                <item name="validation" xsi:type="array">
                    <item name="required-entry" xsi:type="boolean">true</item>
                </item>
            </item>
        </argument>
    </field>

Below is the output which created enter image description here

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.