giorinsrl Posted April 11, 2014 Share Posted April 11, 2014 Hi Guys, i want to show an icon if in the order there is a NOTE, how can i do?! I found this in "tpl" and i have think that i have to do like this.. $this->fields_list['herewhatdoIput?!'] = array( 'title' => $this->l('herewhatdoIput?!'), 'width' => 40 ); But i'm not sure that it's ok. What do you think!? Thank you Link to comment Share on other sites More sharing options...
giorinsrl Posted April 11, 2014 Author Share Posted April 11, 2014 i have found all, but I can't able to solve it.. in table ps_message i have 'id_order' and 'message', and my message is in 'message' this is the select: $this->_select = ' a.id_currency, a.id_order AS id_pdf, CONCAT(LEFT(c.`firstname`, 1), \'. \', c.`lastname`) AS `customer`, osl.`name` AS `osname`, os.`color`, IF((SELECT COUNT(so.id_order) FROM `' . _DB_PREFIX_ . 'orders` so WHERE so.id_customer = a.id_customer) > 1, 0, 1) as new, GROUP_CONCAT(od.product_name separator \', \') as products'; $this->_join = ' LEFT JOIN `' . _DB_PREFIX_ . 'customer` c ON (c.`id_customer` = a.`id_customer`) LEFT JOIN `' . _DB_PREFIX_ . 'order_state` os ON (os.`id_order_state` = a.`current_state`) LEFT JOIN `' . _DB_PREFIX_ . 'order_state_lang` osl ON (os.`id_order_state` = osl.`id_order_state` AND osl.`id_lang` = ' . (int)$this->context->language->id . ') LEFT JOIN `'._DB_PREFIX_. 'order_detail` od ON (od.id_order = a.id_order )'; $this->_orderBy = 'id_order'; $this->_orderWay = 'DESC'; $this->_group = 'GROUP BY a.id_order'; and i think that this fields_list is correct 'message' => array( 'title' => $this->l('Message'), 'havingFilter' => true, 'align' => 'center', 'icon' => array( 0 => 'blank.gif', 1 => array( 'src' => 'note.png', 'alt' => $this->l('#heretextofmessage'), ) ), 'width' => 35 ), but i don't have the JOIN! Please help me Link to comment Share on other sites More sharing options...
giorinsrl Posted April 14, 2014 Author Share Posted April 14, 2014 Anyone? Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now