One such example that I have mentioned here is to add custom message to admin sales order view, invoice, and credit memo in Magento 2.
Thank you for subscribing.
Store admins tend to improve their stores’ admin panel by customizing admin functionalities, adding custom messages, columns, adding filters or removing them in the grid, etc.
 How to Add Custom Message to Admin Sales Order View, Invoice, and Credit Memo in Magento 2
How to Add Custom Message to Admin Sales Order View, Invoice, and Credit Memo in Magento 2
For example, you may want to display a custom message when an order contains gift while processing that order from the admin panel.

Steps to Add Custom Message to Admin Sales Order View, Invoice, and Credit Memo in Magento 2

  1. Create layout files.
  • Method to add a custom message to admin sales order view

If you have any doubts, just mention them in the Comments section below.
That’s all!

  • Method to add a custom message to the invoice

Check out the below solution for implementing such examples in your store:
Create sales_order_creditmemo_view.xml at Vendor/Module/view/adminhtml/layout/

  • Method to add a custom message to the credit memo

Create sales_order_invoice_view.xml at Vendor/Module/view/adminhtml/layout/
 How to Add Custom Message to Admin Sales Order View, Invoice, and Credit Memo in Magento 2

I would be happy to help.

2. Now, create customMessage.php at Vendor/Module/Block/Adminhtml/Order/View/

Create sales_order_view.xml at Vendor/Module/view/adminhtml/layout/

Default Magento 2 provides a user-friendly interface and customization facility for the admin to address their requirements efficiently.
Something went wrong.
Feel free to share the solution with Magento Community via social media.
Never miss Magento tips, tricks, tutorials, and news.

Get Weekly Updates

Thank You.

Magento 2 store admins not only strive to make their store convenient to customers but also continuously implement various tactics to make the store convenient for themselves!
3. Create customMessage.phtml at Vendor/Module/view/adminhtml/templates/order/view

/**/

/*.mfp-bg{background:#000000d4}
/*]]>*/

/*.mfp-bg.mfp-ready{opacity:.6}
/*]]>*/

(based on 0 Reviews)

Similar Posts