przemokon Posted January 23, 2014 Share Posted January 23, 2014 Hi! We have a shop on Prestashop version 1.5.5.0 . Is it possible to check wich of employee added a product to the shop? Sometimes products in shop have little bad info and i wanna know who make the mistake. For sure we can't find this info in BO, but maybe is it possible to find that in db? Link to comment Share on other sites More sharing options...
PhpMadman Posted January 23, 2014 Share Posted January 23, 2014 No it's not. Not without modifying the db and the class / controller files. Link to comment Share on other sites More sharing options...
przemokon Posted January 23, 2014 Author Share Posted January 23, 2014 And is it hard to modify these files/db? Maybe you seen somewhere a solution how to do that? Link to comment Share on other sites More sharing options...
PhpMadman Posted January 23, 2014 Share Posted January 23, 2014 Yes, a bit. You would need to add 2 fields to the ps_product, to store employe id, one for add and one for update. And then those fields need to be added to Product class. And then in the controller or the class, you need to tell it to set the id at add / update. Then you also need to retrieve the fields to display them in BO. I don't think anyone has done anything similar, so probably wont find any similar solution. And I don't have time to do it. Link to comment Share on other sites More sharing options...
vekia Posted January 23, 2014 Share Posted January 23, 2014 i think that it will be a bit more complicated. sometimes many employees can change product. what's then? i think that for this it will be necessary to add separate table with: id_product, id_employee, date then you will be able to store information about all changes for product. but as the previous speaker said: it will be a bit complicated, especially part with coding. Link to comment Share on other sites More sharing options...
rajlaskar Posted January 28, 2014 Share Posted January 28, 2014 (edited) it can be easily achieved like that add a filed in employee table supplier_id , connect that employee table and supplier table through this filed, i mean associate supplier id with employee id then create a employee profile with only catalog privileges change the code in "AdminProductsController" in where clause check which supplier, this will show only that employee linked with the supplier id can anyone please tell me where to set the cookie for new employee table filed "supplier_id" or can be done by entering employee id as supplier id while inserting the product data. Edited January 29, 2014 by rajlaskar (see edit history) Link to comment Share on other sites More sharing options...
Recommended Posts