Jump to content

 

Bart-PDX

Member Since 12 Jun 2017
Offline Last Active Jan 03 2019 03:35 PM
-----

Posts I've Made

In Topic: Different Email Template For 2 Stores

21 December 2018 - 05:33 PM

My response from CS-Cart for this has been:

 

Unfortunately this variable is not present in backend PHP controller (the corresponding file is app\addons\reward_points\controllers\backend\reward_points.php).

 

You can modify the mentioned file to register the company_id value in user_data variable. Find the line:

$user_data = db_get_row("SELECT firstname, email, lang_code FROM ?:users WHERE user_id = ?i", $_REQUEST['user_id']);

and replace it with the following:

$user_data = db_get_row("SELECT firstname, email, lang_code, company_id FROM ?:users WHERE user_id = ?i", $_REQUEST['user_id']);

Use a {{ user_data.company_id }} in your templates then.

I hope this information is helpful.


In Topic: Different Email Template For 2 Stores

18 December 2018 - 02:46 PM

Thanks eComLabs,

 

I'll speak with CS-Cart directly and see what they say


In Topic: Different Email Template For 2 Stores

18 December 2018 - 12:39 PM

Thank you for your help with this.

 

I've just looked where you mention about the variables. The ones shown are:

 

  • company_name
  • company_data
  • logos
  • styles
  • settings
  • product
  • url

As order_info isn't displayed i guess this is why no data is returned. I am also assuming that you can put any variable into a snippet but it depends which template is pulling the snippet as to what will work.

 

So i can see that company_id is part of the company_data variable. How can i find the other variable attributes eg company_data.???


In Topic: Different Email Template For 2 Stores

17 December 2018 - 05:34 PM

Just had a go adding the variable order_info.company_id into my footer. This works ok when i change an order status but for the reward points email when i manually add them this doesn't seem to bring any value back.

 

Can you please let me know where i can find a list of the varaibles? Thanks


In Topic: Different Email Template For 2 Stores

17 December 2018 - 10:22 AM

I agree too. This works when an order is placed on the website however when i add or subtract reward points from within admin the email that is sent to the customer the company_id value is 0.