Jump to content

How to customize new varibales for email template in core files?


shampresta

Recommended Posts

Hi,

 

What i need is to sent email to customer when the status is changed to delivered.

 

- I created one new email template for delivery message. so, what is did is,

 

- I copied one of the .html and .txt from email folder and renamed as delivery.html and delivery.txt

 

- In admin back-office, i edited the status action and changed the template to delivery from drop-down.

 

- Email also working fine.

 

But i want to get the product details like {products}. Where and which classes files or controllers files i have to edit?

 

To get new values for delivery. For example.

 

For "order confirmation" we are using the below code

'{products}' => $this->formatProductAndVoucherForEmail($products_list),
'{discounts}' => $this->formatProductAndVoucherForEmail($cart_rules_list),

.

.

.

..

Mail::Send(
    (int)$order->id_lang,
    'order_conf',
    Mail::l('Order confirmation', (int)$order->id_lang),
    $data,
    $this->context->customer->email,
    $this->context->customer->firstname.' '.$this->context->customer->lastname,
    null,
    null,
    $file_attachement,
    null, _PS_MAIL_DIR_, false, (int)$order->id_shop
);

which is located in classes/PaymentModule.php

 

Like that i want to use for delivery template. So, In which file i have to edit. Please explain.

 

From which files the delivery status working?

 

Please help. thanks

post-384962-0-99213400-1412277102_thumb.png

Edited by shampresta (see edit history)
Link to comment
Share on other sites

  • 1 year 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...