Jump to content
thirty bees forum
  • 0

Order confirmation page - Add order price + Order ID


Question

Posted

On the order-confirmation page, I would like to add the "total order price" and "order ID".
How is that possible?

 

The data will be used for Google conversiontracking.

2 answers to this question

Recommended Posts

  • 0
Posted

Order confirmation page contains various JS variables.

'bought_products'          => $varProducts,
'total_products_tax_incl'  => $order->total_products_wt,
'total_products_tax_excl'  => $order->total_products,
'total_shipping_tax_incl'  => $order->total_shipping_tax_incl,
'total_shipping_tax_excl'  => $order->total_shipping_tax_excl,
'total_discounts_tax_incl' => $order->total_discounts_tax_incl,
'total_discounts_tax_excl' => $order->total_discounts_tax_excl,
'total_paid_tax_incl'      => $order->total_paid_tax_incl,
'total_paid_tax_excl'      => $order->total_paid_tax_excl,
'id_customer'              => $this->context->customer->id,

if you need order id as JS variable you will have to override orderconfirmation controller and add it your self.

btw: order id is available in order confirmation template as smarty var

  • 0
Posted (edited)
On 8/5/2021 at 1:16 AM, yaniv14 said:

Order confirmation page contains various JS variables.

'bought_products'          => $varProducts,
'total_products_tax_incl'  => $order->total_products_wt,
'total_products_tax_excl'  => $order->total_products,
'total_shipping_tax_incl'  => $order->total_shipping_tax_incl,
'total_shipping_tax_excl'  => $order->total_shipping_tax_excl,
'total_discounts_tax_incl' => $order->total_discounts_tax_incl,
'total_discounts_tax_excl' => $order->total_discounts_tax_excl,
'total_paid_tax_incl'      => $order->total_paid_tax_incl,
'total_paid_tax_excl'      => $order->total_paid_tax_excl,
'id_customer'              => $this->context->customer->id,

if you need order id as JS variable you will have to override orderconfirmation controller and add it your self.

btw: order id is available in order confirmation template as smarty var friday night funkin

Thanks for the information. It really helped me!

Edited by ociephipps

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...