how to call layout from UI component button?

by Asad Ullah   Last Updated March 14, 2019 17:09 PM

I want to jump from one UI_COMPONENT to another UI_COMPONENT through layout file and hopefully passing URL in button

This is my Ui_component file

<?xml version="1.0" encoding="UTF-8"?>
<form xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:module:Magento_Ui:etc/ui_configuration.xsd">
    <settings>
        <buttons>
            <button name="duplicate" >
            <url path ="duplicate/index/index"/>
                <label >duplicate </label>
            </button>

        </buttons>
    </settings>
</form>

and want to call my layout but it gives me 404 error this is my layout file name "duplicate_index_index"

<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
      xsi:noNamespaceSchemaLocation="../../../../../../../lib/internal/Magento/Framework/View/Layout/etc/page_configuration.xsd">
<update handle="styles"/>
<body>
    <referenceContainer name="content">
        <uiComponent name="duplicate_detail"/>
    </referenceContainer>
</body>
</page>


Related Questions


Updated April 06, 2016 09:03 AM

Updated March 04, 2016 01:04 AM

Updated August 20, 2016 08:03 AM

Updated January 11, 2017 08:03 AM

Updated February 24, 2017 13:09 PM