I've created an override by copying the original file here and then making my changes:
I have created a layout XML to remove blocks (named "items_grid") associated with the original layout folder, and then use my override file instead. (Assuming I've done correctly)
<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd"> <body> <referenceBlock name="items_grid" remove="true"/> <referenceBlock name="content"> <block class="Magento\Sales\Block\Adminhtml\Order\Create\Items\Grid" template="Vendor_Module::order/create/items/grid.phtml" name="items_grid_new"> </block> </referenceBlock> </body> </page>
However, when I load the page, I received the below error:
Fatal error: Uncaught Error: Call to a member function getItems() on boolean in vendor/magento/module-sales/Block/Adminhtml/Order/Create/Items/Grid.php on line 132
Note: When I checked my code by updating directly in the core file, it worked fine. It just seems to be this override module setup that's causing the issue.