Opencart 3.x — Admin Order same/detailed email as customer


By default, in Opencart 2-3.x, a letter about a new order of goods arrives to the site administrator in this form:



In order for the letter to be the same type as it is sent to the buyer, you need to modify the standard functionality.


Open file \catalog\controller\mail\order.php


about 270 string

$mail->setSender(html_entity_decode($order_info['store_name'], ENT_QUOTES, 'UTF-8'));
$mail->setSubject(html_entity_decode(sprintf($language->get('text_subject'), $order_info['store_name'], $order_info['order_id']), ENT_QUOTES, 'UTF-8'));
$mail->setHtml($this->load->view('mail/order_add', $data));

after that code – paste

$mail->setSender(html_entity_decode($order_info['store_name'], ENT_QUOTES, 'UTF-8'));
$mail->setSubject(html_entity_decode(sprintf($this->language->get('text_subject'), $this->config->get('config_name'), $order_info['order_id']), ENT_QUOTES, 'UTF-8'));
$mail->setHtml($this->load->view('mail1/order_alert', $data));

Further, in the directory of your theme or in the folder of the standard theme (option 2 will be in 90% of cases)



create the folder mail1, create a file in it called order_alert.twig, the contents of this file will be exactly like in the file




Then, in the admin panel, we update the modifications and in the settings (System – Settings – Mail) we remove the check in the New order so that you would not receive two copies of the letter as the administrator.


As a result, after the order you as a site administrator will receive a detailed letter of this kind:






Please enter your comment!
Please enter your name here