V
V
Vitaly2020-04-17 07:08:45
Prestashop
Vitaly, 2020-04-17 07:08:45

Any idea how to send a Custom Field from One Page checkout to an order email?

Installed Prestashop 1.7 and a module for quick checkout. Any idea how to send a Custom Field from One Page checkout to an order email? Added there radio buttons for selecting the delivery time interval, this is an additional item in the order letter. the field does not go away. Thank you!

Answer the question

In order to leave comments, you need to log in

2 answer(s)
D
Denis Verbin, 2020-04-25
@phpros

If we are talking about Onepagecheckout PS - here is the solution .

V
Vitaliy, 2020-04-30
@phpros

The code does not come out to adapt. Help me please.

public function GetCustomFields($order, $id_lang)
  {
     $order = new Order($order->id);
     $query = new DbQuery();
     $query->SELECT field_value FROM ps_zooprvelsof_supercheckout_fields_data ORDER BY ps_zooprvelsof_supercheckout_fields_data DESC;
     $field_options = Db::getInstance()->executeS($query);
     if (!count($field_options)) {
        return;
     }
     foreach ($field_options as $field)
     return $field['field_value'] '<br/';
  }

5eaa65e0a957a497156035.jpeg
What is wrong in the code? I need to pick up the "field_value" value from the database, sorting by "ps_zooprvelsof_supercheckout_fields_data"

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question