Jump to content

Stock Movement - adding reference field


Juhy

Recommended Posts

Hi,

i need help for adding product "reference" field into "Stock Movement" (PS v1.4.4.1)

Like this:

ID | Reference | Name | Quantity | Reason | Employee

 

this is original code:

$this->_select = 'CONCAT(pl.name, \' \', GROUP_CONCAT(IFNULL(al.name, \'\'), \'\')) product_name, CONCAT(e.lastname, \' \', e.firstname) employee, mrl.name reason';
 $this->_join = 'LEFT JOIN `'._DB_PREFIX_.'product_lang` pl ON (a.id_product = pl.id_product AND pl.id_lang = '.(int)$cookie->id_lang.')
   LEFT JOIN `'._DB_PREFIX_.'stock_mvt_reason_lang` mrl ON (a.id_stock_mvt_reason = mrl.id_stock_mvt_reason AND mrl.id_lang = '.(int)$cookie->id_lang.')
   LEFT JOIN `'._DB_PREFIX_.'employee` e ON (e.id_employee = a.id_employee)
   LEFT JOIN `'._DB_PREFIX_.'product_attribute_combination` pac ON (pac.id_product_attribute = a.id_product_attribute)
   LEFT JOIN `'._DB_PREFIX_.'attribute_lang` al ON (al.id_attribute = pac.id_attribute AND al.id_lang = '.(int)$cookie->id_lang.')';
 $this->_group = 'GROUP BY a.id_stock_mvt';
 parent::__construct();

 

Also good feature would be to export this data to CSV

 

Thnx for any response or help.

Bestregards

Gasper

Link to comment
Share on other sites

  • 5 years 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...