Jump to content

Recommended Posts

Hi all,

 

I wonder about something, today

 

I want to customize that add more information about product on admin panel

 

when I edit or add product, some fields have shown in information tab.

 

Name, Reference, Short description and whatever

 

so I want to add more fields(textarea, input, radio and etc) that I can fill.

 

what can i do?

 

( i'm not native english speaker, so my english writing is very poor )

 

thank you.

Link to comment
Share on other sites

The best (the safer) way is to create a module that adds a Tab at the "Edit Product" page.

 

What you need is:

 

1. In the module to register the required hooks: displayAdminProductsExtra, actionProductUpdate, actionProductSave, actionProductDelete, etc .

 

2. To implemet the hooks (in the module):

 

public function hookDisplayAdminProductsExtra($params) {
 return '<input type="text" name="pt" value="ppp" /> ';
}

(sample "return" from ADMIN\themes\default\template\controllers\products\seo.tpl)

 

   public function hookActionProductUpdate($params){
       die(Tools::getValue('pt'));
   }

(sample code from:controllers\admin\AdminProductsController.php processWarehouses() method)

Link to comment
Share on other sites

×
×
  • Create New...