InduStone Posted April 9, 2018 Share Posted April 9, 2018 Hi, I'm adding new subcategories to one of the category, but they are not showing in the category list (footer or left menu). These new categories are visible in the DB, but the 'nleft' and 'nright' values are equal 0. I also noticed that the parent category has limited range by nleft and nright and all values in this range have been already taken by existing subcategories, thus my new categories can't get category numbers. Is there a way to recalculate it? I'd really appreciate your answer. Link to comment Share on other sites More sharing options...
InduStone Posted June 7, 2018 Author Share Posted June 7, 2018 Hi, Does sombody have experience with nleft and nright values? Is it save modify this parameters? I wonder why no one answered... Link to comment Share on other sites More sharing options...
NemoPS Posted June 7, 2018 Share Posted June 7, 2018 What's your ps version? It's not a good idea to edit those values manually. Try to run "Category::regenerateEntireNtree();" from any script, see if it regenerates it properly Link to comment Share on other sites More sharing options...
InduStone Posted June 7, 2018 Author Share Posted June 7, 2018 Thank you NemoPS. PS 1.6.1.18. Will try to regenerate tree, however the categories/sub-categories numbers are visible in the url's, so shouldn't be changed... Am I right? Link to comment Share on other sites More sharing options...
NemoPS Posted June 8, 2018 Share Posted June 8, 2018 Those will not change, the tree on regenerates nleft and nright Link to comment Share on other sites More sharing options...
InduStone Posted November 3, 2018 Author Share Posted November 3, 2018 Hi, Unfortunately it didn't help. I've created new subcategory, added some products to it, but when I select it from the list of subcategories it shows: "Category not found" Any idea? Moreover, when I checked the ps_category table in DB if found that this newly created table has values of nleft and nright equal to zero. I'd appreciate your answer. Looking forward to your reply. Regards B Link to comment Share on other sites More sharing options...
vicko2017 Posted December 3, 2019 Share Posted December 3, 2019 I have the same problem. Still no solution for this ? Link to comment Share on other sites More sharing options...
InduStone Posted December 4, 2019 Author Share Posted December 4, 2019 Hi I've found several empty categories in the DB table. These categories were not visible from backoffice. I manually deleted them and that solved the issue. B Link to comment Share on other sites More sharing options...
Sergio Posted January 23, 2020 Share Posted January 23, 2020 Hi, I´m facing a problem in subcategories when i update from 1.6.1.9 to 1.6.1.24. When i click to edit subcategories the backoffice comes back to home categories. I can see they all have 1 in the position, but i haven't change anything, just updated. Can you please help solve it? Attached are two images with the problem. Thank you very much for any help Link to comment Share on other sites More sharing options...
NemoPS Posted January 23, 2020 Share Posted January 23, 2020 open controllers/front/CategoryController.php. in the initContent method, add this at the beginning: Category::regenerateEntireNtree(); Access a category in the front office, then remove the modification. See if it's fixed. Link to comment Share on other sites More sharing options...
Sergio Posted February 15, 2020 Share Posted February 15, 2020 On 1/23/2020 at 1:39 PM, NemoPS said: open controllers/front/CategoryController.php. in the initContent method, add this at the beginning: Category::regenerateEntireNtree(); Access a category in the front office, then remove the modification. See if it's fixed. Thank you for the information. I haven't tested your solution because i have built all the categories and sub-categories from scratch. But i'll keep your solution to another time if it happens again, because it took me days to build it all over. Thanks. Link to comment Share on other sites More sharing options...
burki Posted February 21, 2021 Share Posted February 21, 2021 On 1/23/2020 at 4:39 PM, NemoPS said: open controllers/front/CategoryController.php. in the initContent method, add this at the beginning: Category::regenerateEntireNtree(); Access a category in the front office, then remove the modification. See if it's fixed. Hi, I have tested that but it didn’t work, I using ps 1.7.6.3 please help me. Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now