Jump to content

How to add new tab in back office by using custom modules?


mdusamaansari

Recommended Posts

Hi Mates,

 

I am using Prestashop version 1.5.6.1.

 

In Back office, Under Catalogs -> Products -> Edit (Product Edit Page), we have tabbed menu on left side with options like Information, Prices, SEO etc.

 

I need to create another tabbed menu on bottom of the menu after Warehouses or Suppliers etc.

 

I am in to creating a module, I have developed a skeleton of my module. The tabbed menu contains a input field which takes expiry date of product offer.

 

While submitting, the input field value, product ID, Category ID, employee ID, dateadd and dateupd should be inserted into a new table named offerdate.

 

Likewise,

 

In Back office, Catalog -> Product -> Add new page also.

 

Please help me in this regard,

 

Thanks in advance.

  • Like 1
Link to comment
Share on other sites

in your module use this hook:

 

    public function hookDisplayAdminProductsExtra($params) {
        return $this->display(__FILE__, 'views/admin/MyTab.tpl');
    }

then create template file and insert there form with fields you want to save.

then create another hook:

public function hookactionProductSave($params) {
}

where you can create sql query to add new row to any table you want.

  • Like 1
Link to comment
Share on other sites

  • 10 months later...

in your module use this hook:

 

    public function hookDisplayAdminProductsExtra($params) {
        return $this->display(__FILE__, 'views/admin/MyTab.tpl');
    }

then create template file and insert there form with fields you want to save.

then create another hook:

public function hookactionProductSave($params) {
}

where you can create sql query to add new row to any table you want.

 

 

hello,

but how i pass MyTab.tpl form data to the actionProductSave hook ? Plz help me because i got same problem.

Link to comment
Share on other sites

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...