To create a support ticket, start a search

Orders Grid: adding 'id_transaction' field


Target

We would like to add a column displaying Transaction ID within the order interface.

 

Setup

To add the field to the list of available fields for your grids, click on the in the 'Add a field' panel and enter the following information:

What is the field ID?: transaction_id

 

Sc creates the field, you now need to populate the grid with:

Field name: Transaction ID
Table: Another table
Type: only display

 

From the Advanced Properties panel on the right handside:

- select the menu SQL Select and enter:

return ' , sc_op.transaction_id ';

 

- select the menu SQL Left Join and enter:

return " LEFT JOIN "._DB_PREFIX_."order_payment sc_op ON (sc_op.order_reference=o.reference)";

 

Exit the editing window.

The new field is now present in the list of available fields and you can add it to your Order grids.