Jump to content
thirty bees forum

How to show products in order list


zimmer-media

Recommended Posts

copy your AdminOrdersController.php from /controllers/admin to the folder /override/controllers/admin/

After changing you can see the ordered products with variants on order list. Don´t forget to clear the cache!

change this os.`color`, IF((SELECT so.id_order FROM `'._DB_PREFIX_.'orders` so WHERE so.id_customer = a.id_customer AND so.id_order < a.id_order LIMIT 1) > 0, 0, 1) as new, country_lang.name as cname,

to os.`color`, (SELECT GROUP_CONCAT(odd.product_name SEPARATOR ", ") FROM `'._DB_PREFIX_.'order_detail` odd WHERE odd.id_order = a.id_order) as products, IF((SELECT so.id_order FROM `'._DB_PREFIX_.'orders` so WHERE so.id_customer = a.id_customer AND so.id_order < a.id_order LIMIT 1) > 0, 0, 1) as new, country_lang.name as cname,

and change this $this->fields_list = array_merge( $this->fields_list, [ 'total_paid_tax_incl' => [ 'title' => $this->l('Total'), 'align' => 'text-right', 'type' => 'price', 'currency' => true, 'callback' => 'setOrderCurrency', 'badge_success' => true, ], 'payment' => [ 'title' => $this->l('Payment'), ],

to ``` $this->fieldslist = arraymerge( $this->fieldslist, [ 'totalpaidtaxincl' => [ 'title' => $this->l('Total'), 'align' => 'text-right', 'type' => 'price', 'currency' => true, 'callback' => 'setOrderCurrency', 'badgesuccess' => true, ], 'products' => [ 'title' => $this->l('Products'), 'havingFilter' => true, 'filterkey' => 'products',

        ],
            'payment'             => [
                'title' => $this->l('Payment'),
            ],

```


before 0_1514306264334_7cfdc20e-19b7-4451-979a-18735ab8f4b1-grafik.png


after changing 0_1514306286397_f38de6b1-aed3-43eb-957d-8bb04efcb318-grafik.png

Link to comment
Share on other sites

  • 10 months 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...