Hello Magento Friends,

In this Magento 2 tutorial, I will explain How to Add Editable Field in the Admin Order View Page in Magento 2.

The checkout page is the final stage for order placement. Magento 2 merchants customize the checkout page to provide a better user experience. The store owners can determine checkout options for a quick checkout procedure. Admin can add custom checkout fields for a smooth order fulfillment process.

When you have added custom fields at the checkout page and now the admin needs to edit the custom checkout fields value from the backend order view page. You can accomplish it using the below steps.

Steps to Add Editable Field in Admin Order View Page in Magento 2:

Step 1: Go to the below file path

app\code\Vendor\Extension\view\adminhtml\layout\sales_order_view.xml

Then add the below code

Step 2: Next, move to the following file path

app\code\Vendor\Extension\Block\Adminhtml\Order\Checkoutcustomformedit.php

Now add the below-mentioned code snippet

Step 3: Now navigate to the below file path

app\code\Vendor\Extension\view\adminhtml\templates\Checkoutcustomformedit.phtml

Now add the code as follows

Step 4: At last, move to the following file path

app\code\Vendor\Extension\Controller\Adminhtml\Queue\Update.php

And add the code mentioned below

Conclusion:

This way you can Add an editable field in the admin order view page in Magento 2. If you face any difficulty, share it with me through the comment section. Stay updated with us for more Magento solutions.

Happy Coding!

Click to rate this post!
[Total: 6 Average: 3.7]