Jump to content

How delete Tab from Admin BO?


Cosmin T.

Recommended Posts

Hi!

 

First of all, it's important to say that you have Prestashop 1.7.x, so this solution is also related to this version.

 

 

Problem:

So let's say I have some items in the sidebar that were added by some module. The module has been already uninstalled, but the items remain in the sidebar.  (Screenshot "problem.png")

 

 

 

Solution #1 (the clean one):

Please make sure to archive your DB first. Just in case.

 

Access you DB and locate the table "prefix_tab". View the content of the table. You can find all the items that are in the sidebar.

(screenshot "db1.png")

As you can see, I can quickly locate all the rows that are related to the module "ptm_controlcenter". Check the "id_tab" column and now remember all the IDs related to this module (in this case it's 132-137

 

Now access the table "prefix_tab_lang" and remove all rows that have the column ID between 132-137 in the "id_tab". (screenshot "db2.png")

 

Get back to "prefix_tab" table and remove these rows ("id_tab" between 132-137) as well.

 

Done! (screenshot "solved.png")

 

 

Solution #2 (the quick one):

Please make sure to archive your DB first. Just in case.

 

Access you DB and locate the table "prefix_tab". View the content of the table. You can find all the items that are in the sidebar. 

(screenshot "db1.png")

Change the value "1" to "0" in the Active column for all the related rows.

 

Done! (screenshot "solved.png")

post-48475-0-58867900-1494503192_thumb.png

post-48475-0-73534600-1494503226_thumb.png

post-48475-0-60594200-1494503749_thumb.png

post-48475-0-69109400-1494503751_thumb.png

Edited by Andrej Stas (see edit history)
  • Like 2
Link to comment
Share on other sites

  • 4 years later...
16 hours ago, SmartDataSoft said:

Hello, which module is this one. You can search the tab name in tab and tab language the remove it.

 

Then it will remove.

 

Thank you

i was playing around with module Slick Slider Homefeatured, see link, and when changed  0 to another tab numbers in line 29: ($parent_tab->id_parent = 0; // Home tab) - messed up the BO.

I did not seen any reference to Slick Slider in "prefix_tab_lang", that is why I wrote - in PS 1.7.6.5 probably no need to go to this table in database

Link to comment
Share on other sites

3 minutes ago, SmartDataSoft said:

@Yulia Vitun

 

The module which you post do not create any admin tab. it work with configutation. Did you post wrong one?

 

Thank you

sorry, you are right,

I did other things too while trying to get this module work, unsuccessful though,

I think I added a similar pice of code:

  public function addModuleToTab()
    {
        $tab = new Tab();
        $tab->name[(int)Configuration::get('PS_LANG_DEFAULT')] = \Tools::ucfirst($this->name);
        $tab->class_name = 'AdminSlickSlider';
        $tab->id_parent = (int)Tab::getIdFromClassName('CONFIGURE');
        $tab->module = $this->name;
        $tab->add();
    }

 

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