3

I have created new tab for order view, but it will display at first . How can I set priority for display at last

enter image description here

I have used below code for add new tab

<referenceContainer name="left">
            <referenceBlock name="sales_order_tabs">
        <action method="addTab">
                    <argument name="name" xsi:type="string">*****_****</argument>
                    <argument name="block" xsi:type="string">******\*****\*****\****\****\****\****</argument>
        </action>
            </referenceBlock>
        </referenceContainer>
  • - Its Solved :) – Camit1dk Jul 25 '17 at 6:27
3

To avoid custom tab opening by default, please add sequence in your module.xml

 <module name="Vendor_Module" setup_version="2.0.0">
    <sequence>
        <module name="Magento_Sales"/>
    </sequence>
</module>
|improve this answer|||||
2

I got solution :)

  1. replace addTab with addTabAfter in action method

  2. add new argument in action tab

    <argument name="after" xsi:type="string">order_history</argument>

|improve this answer|||||
1

I had the same problem, and I add the "addTabAfter" instead "addTab", and it is works, but it is selected by default, even isn't first tab

<referenceBlock name="sales_order_tabs">
   <action method="addTabAfter">
     <argument name="label" xsi:type="string">modulename</argument>
     <argument name="block" xsi:type="string">VENTOR\MODULE\Block\Adminhtml\Order\View\Tab\Custom</argument>
     <argument name="after" xsi:type="string">order_info</argument>
   </action>
</referenceBlock>
|improve this answer|||||

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.