문제

I am trying to override sales_order_create_index.xml to remove the custom payment method but getting this error

1 exception(s): Exception #0 (Magento\Framework\Exception\ValidatorException): Invalid template file: 'Custom_Module:order/create/billing/method/info.phtml' in module: 'Magento_Sales' block's name: 'order_create_billing_form'

sales_order_create_index.xml

<?xml version="1.0"?>
<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
      xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
    <body>
        <referenceBlock name="order_create_billing_form">
            <action method="setTemplate">
                <argument name="template" xsi:type="string">Custom_Module::order/create/billing/method/info.phtml</argument>
            </action>
        </referenceBlock>
    </body>
</page>

Template Path:

enter image description here

도움이 되었습니까?

해결책

Your file name is form.phtml and you have set template name info.phtml. So either update your file name to info.phtml or update template name in xml file to form.phtml and clean cache once.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 magento.stackexchange
scroll top