Jump to content

[Solved]Merchant Copy Of Invoice By Mail[Solved]

Recommended Posts



I solve the problem.


I do this modify:

1.   I create new template file in /mails/en/merchantXX.html and merchantXX.txt

2.   I modify the file classes/orders/OrderHistory.php at line 442:


Mail::Send((int)$order->id_lang, $result['template'], $topic, $data, $result['email'], $result['firstname'].' '.$result['lastname'],null, null, $file_attachement, null, _PS_MAIL_DIR_, false, (int)$order->id_shop);




I add this code:



                if ( $file_attachement != null ) {
                    $dataXXYY = array(
                                '{lastname}' => 'Name',
                                '{firstname}' => 'Surname',
                                '{id_order}' => (int)$this->id_order,
                                '{order_name}' => $order->getUniqReference()

                    //var_dump (_PS_MAIL_DIR_);

                    Mail::Send((int)$order->id_lang, 'merchantXX', $topic, $dataXXYY, '[email protected]' , 'Name'.' '.'Surname',null, null, $file_attachement, null, _PS_MAIL_DIR_, false, (int)$order->id_shop);





Share this post

Link to post
Share on other sites

  • 1 year later...
  • 2 years later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Create New...

Important Information

Cookies ensure the smooth running of our services. Using these, you accept the use of cookies. Learn More