I am creating a custom addon for my code.
Now when in my func.php I call this line to show the output
$view->displayMail('orders/commission_invoice.tpl', false, $area, $order_info['company_id'], $lang_code);
so i placed the files print_commission_invoice.tpl in the folder
design/backend/mail/templates/addons/commission_invoice/orders/
but the error below comes for the same in php_error_log file and the output doesnt render
[Tue Jul 25 20:02:01.255346 2017] [:error] [pid 11608] [client 122.160.10.114:4675] PHP Fatal error: Uncaught → Smarty: Unable to load template tygh ‘orders/commission_invoice.tpl’ ← \n thrown in /var/www/html/app/lib/other/smarty/sysplugins/smarty_internal_templatebase.php on line 128
I am creating a custom addon for my code.
Now when in my func.php I call this line to show the output
$view->displayMail('orders/commission_invoice.tpl', false, $area, $order_info['company_id'], $lang_code);
so i placed the files print_commission_invoice.tpl in the folder
design/backend/mail/templates/addons/commission_invoice/orders/
but the error below comes for the same in php_error_log file and the output doesnt render
[Tue Jul 25 20:02:01.255346 2017] [:error] [pid 11608] [client 122.160.10.114:4675] PHP Fatal error: Uncaught → Smarty: Unable to load template tygh ‘orders/commission_invoice.tpl’ ← \n thrown in /var/www/html/app/lib/other/smarty/sysplugins/smarty_internal_templatebase.php on line 128
Hello! There is no file. Your file should called commission_invoice.tpl instead of print_commission_invoice.tpl
UPD:
Or you must put in your func.php:
$view->displayMail('addons/commission_invoice/orders/print_commission_invoice.tpl', false, $area, $order_info['company_id'], $lang_code);