1

I'm trying to put an accordion into another, and the lonely way I found is to not use the same widget into another.

Exemple, the parent is an accordion, the different children can be tabs.

The opposite works.

But, if i'm right, I understood that it's not possible to use the same widget for the parent and the children.

My problem, I have an accordion who has 4 forms, each form as several tabs (if you select this, you have this input...) AND I need to put another accordion or tab in the last tab.

What can I do ?

  • do you need in admin side? – sudo55 Feb 13 '19 at 17:04
0

add this code in your UI component form.

<fieldset name="general">
<argument name="data" xsi:type="array">
<item name="config" xsi:type="array">
    <item name="collapsible" xsi:type="boolean">true</item>
    <item name="label" xsi:type="string" translate="true">Aditional Options</item>
    <item name="sortOrder" xsi:type="number">100</item>
</item>
</argument>
<fieldset name="banners">
<argument name="data" xsi:type="array">
    <item name="config" xsi:type="array">
        <item name="collapsible" xsi:type="boolean">true</item>
        <item name="label" xsi:type="string" translate="true">Top Banner On Product Pager</item>
        <item name="sortOrder" xsi:type="number">100</item>
    </item>
</argument>
<field name="product_top_banner_alt">
    <argument name="data" xsi:type="array">
        <item name="config" xsi:type="array">
            <item name="label" xsi:type="string">Alt Text:</item>
            <item name="visible" xsi:type="boolean">true</item>
            <item name="dataType" xsi:type="string">text</item>
            <item name="formElement" xsi:type="string">input</item>
            <item name="source" xsi:type="string">catalog_rule</item>
            <item name="validation" xsi:type="array">
                <item name="required-entry" xsi:type="boolean">false</item>
            </item>
        </item>
    </argument>
</field>
</fieldset>
<!--After Product-->
<fieldset name="after_banners">
<argument name="data" xsi:type="array">
    <item name="config" xsi:type="array">
        <item name="collapsible" xsi:type="boolean">true</item>
        <item name="label" xsi:type="string" translate="true">After Product Description Banner</item>
        <item name="sortOrder" xsi:type="number">160</item>
    </item>
</argument>
<field name="product_after_banner_alt">
    <argument name="data" xsi:type="array">
        <item name="config" xsi:type="array">
            <item name="label" xsi:type="string">Alt Text:</item>
            <item name="visible" xsi:type="boolean">true</item>
            <item name="dataType" xsi:type="string">text</item>
            <item name="formElement" xsi:type="string">input</item>
            <item name="source" xsi:type="string">catalog_rule</item>
            <item name="validation" xsi:type="array">
                <item name="required-entry" xsi:type="boolean">false</item>
            </item>
        </item>
    </argument>
</field>
</fieldset>
<!--Label-->
<fieldset name="labels">
<argument name="data" xsi:type="array">
    <item name="config" xsi:type="array">
        <item name="collapsible" xsi:type="boolean">true</item>
        <item name="label" xsi:type="string" translate="true">Labels</item>
        <item name="sortOrder" xsi:type="number">170</item>
    </item>
</argument>

<field name="product_labels_alt">
    <argument name="data" xsi:type="array">
        <item name="config" xsi:type="array">
            <item name="label" xsi:type="string">Alt Text:</item>
            <item name="visible" xsi:type="boolean">true</item>
            <item name="dataType" xsi:type="string">text</item>
            <item name="formElement" xsi:type="string">input</item>
            <item name="source" xsi:type="string">product_labels_alt</item>
            <item name="validation" xsi:type="array">
                <item name="required-entry" xsi:type="boolean">false</item>
            </item>
        </item>
    </argument>
</field>

Your Answer

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.