Questions tagged [category-tree]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
0
votes
0answers
12 views

How can I check if a category is in the sitemap?

Magento v1.9 I load a category object by querying against that categories particular id. Once I've loaded it, is there a way I can check whether or not that particular category exists within the ...
0
votes
1answer
22 views

How do I correctly move products and categories between stores in magento1?

I currently have a magento 1.9 installation which uses two stores. I'm at the moment trying to move a category (as well as the subcategories and products) from one store to the other but I'm running ...
0
votes
1answer
50 views

SQL code to get the Product details with category tree heirarchy

I'm using Magento 1.9, We have a requirement to show the product details with category tree heirarchy. Have searched this in google and haven't find any answers. I have to create a report(using a BI ...
0
votes
0answers
26 views

Sort Menu items in aphabetical order magento 2 in observer

I am creating menu items in magento 2. I is working fine and generated according to category order in admin dashboard. But I wanted to sort the menu items alphabetically on store front ir-respective ...
0
votes
0answers
30 views

Browsing and organizing categories

We re migrating from a custom solution to Magento 2.3.x Everything looks on place, except for our categories organization. As our catalog is a bit complex. An example, easy to understand, motorbike ...
0
votes
0answers
23 views

Magento2: Display 3 level menu on hover of level 1 menu

I want to display 3rd level submenu once we hover on 1st level menu. Like if I hover on WOMEN then Tops sub-menu auto shows. The file I assume for the menu is: /var/www/html/magento233/lib/web/...
0
votes
0answers
148 views

Sub categories are not showing for the category in the backend Magento 2

I moved the category Ducati clothing inside Ducati Accessories category and then pushed it back as original but after this, when I click on the category Ducati clothing it is not showing the ...
0
votes
0answers
18 views

Add Category Selection like Magento2 Product Add/Edit in Custom Form

In my custom module I have created a form using block method in admin. I have to add the Category selection in it same as Magento2 product Add/Edit. I referred this link how to add Category tree ...
0
votes
0answers
18 views

SQLSTATE[42000] while creating categories using REST API?

I created categories using REST api by below code. <?php $objectManager = \Magento\Framework\App\ObjectManager::getInstance(); $directory = $objectManager->get('\Magento\Framework\Filesystem\...
0
votes
1answer
31 views

Sql to delete category and its descendants

I am working with a Magento 2 store with a very large category tree (over 10000 categories). I used CategoryRepository and deleted one by one but this is very time-consuming since delete a brand with ...
2
votes
0answers
82 views

Tree categories from products collection

If I have a collection like this: $collection = Mage::getResourceModel('catalog/product') ->getCollection() ->addAttributeToFilter('my_custom_attribbute','my custom value'); What is the ...
2
votes
2answers
107 views

Magento 2 : Get category level

I want to get the category level in product/list.phtml to check if (categorylevel == 1) { hide product list }else { show product list } How can I do that? Any helps? Thank in advance.
2
votes
1answer
37 views

How to get the categories child category list per store in magento2 rest api

I need to retrieve categories and child-category list per store. I have two store have store code grocery and fruit.
0
votes
0answers
21 views

Magento 2 : Admin for category selector field does not saved a value in DB

In magento2, admin for category selector field does not saved a value in db sales_rule_form.xml <field name="category_ids"> <argument name="data" xsi:type="array"> ...
0
votes
0answers
16 views

Creating 2 menus from 2 separate categories

So, I am trying to accomplish this design. My issue is trying to populate 2 separate menus because it seems as though I have to create two root categories(which I understand why that is stupid) or ...
0
votes
1answer
52 views

URL rewrite magento 2 admin-side issue

Magento2 - facing issue with below error in admin panel error in console category:1 Uncaught SyntaxError: Unexpected token C in JSON at position 473 at JSON.parse (<anonymous>) at getData (...
1
vote
1answer
335 views

Magento 2 : Add custom array in multiselect UI dropdown in custom UI form

In Magento 2, I want to add multiselect UI dropdown with custom my custom array. I take reference from product edit form "Categories" field and also find out from where UI multiselect tree option ...
0
votes
0answers
91 views

Magento 2 Facing Problem :Could not save product “3194” with position 0 to category 12

I am facing a problem whenever I go into catalog->products->edit product and delete the category from product and click on save button the error is coming. Could not save product "3194" with ...
0
votes
1answer
27 views

Magento 2.3: Is it possible import/create a category tree with category_id assigned

I have to import a 3rd party catalog into Magento 2.3. I need to recreate in Magento the category tree with the same category_id in the original tree because I need it when I update inventory. How can ...
0
votes
2answers
259 views

Magento 2 How to get disable/enable child categories?

I am working with display all categories on a custom page, either it is enabled or disabled. When I try to get child categories with "getChildrenCategories()", but it is returning only enabled child ...
4
votes
0answers
65 views

Magento 2 How to duplicate the category with same structure?

I want to duplicate the category with the same structure and data. How to duplicate child categories here? It is working correctly for a single category. In my controller file, I have the parent ...
1
vote
0answers
37 views

default store view is not selected by deafult when open any category in magento 2 admin

I have migrated Magento 1.9.3.1 to Magento 2.3.0 I am getting an issue in the admin. When I open category in admin side then English store is selected by default. How can I make default_store_view ...
3
votes
2answers
814 views

Magento 2 - How to get category name and category tree for product or for category id?

Magento 2.2.7 I have to output category name and "tree" or path for product. For instance if my product is in category Lg775 my output should be: Hardware/Motherboards/Intel/Lg775 so far I have this ...
2
votes
0answers
28 views

Magento2.3.0 How to do in left side navigation custom category tree structure create it?

I am using Magento2.3.0 I need in left side layer navigation instead replace category section there our custom category tree display on it and its work as on fronted side only.If any one this type ...
1
vote
0answers
32 views

Problem With Recursion (categories and subcategories)

I'm testing a code from the answer by @digitalsteez on this question: Get Categories and Its Sub Categories I've tested it onto two Magento instance, one has no problems but on the other I'm ...
1
vote
0answers
45 views

Third level categories Url is not working in magento 2

Shop Colors Rushmore Boston Mill Little Cottonwood This my category structure. But child category URLs are not working. Link: mysite.com/shop/colors/rushmore.html
0
votes
1answer
155 views

Magento 2 Auto-remove empty categories from menu?

I am using Magento 2.3.1 and the pearl theme. My site has many different categories and I wanted to know if there is a way to have magento automatically remove categories that don't have product in ...
2
votes
0answers
80 views

how to create a custom tree similar to the back office category one in Magento 2?

I'm trying to create a left menu like the category one in a custom module to display my own hierarchy. I want to use a custom model from a custom table. I was able to get the category tree in my ...
1
vote
2answers
411 views

Get a list of all category names and ID's - Magento 2

How can I get a list of all category names and their ID's from a store on Magento 2.2? For example something like this Clothes 2 Shirts 5 T-shirts 7 T-shirts 8 Shoes 10 Sport shoes 12 ... It can be ...
0
votes
1answer
105 views

How to customise category top menu navigation by custom category id in Magento 2?

By default Magento 2 showing the all store categories in top menu with a tree structure, I want to filter with custom category ids and only that filtered category need to show in category top menu ...
0
votes
2answers
19 views

Magento 2 Error “URL key for specified store already exists

Basically i am adding a custom category the problem is when i add two child category with same NAME in to one parent category where child category is already present then this shows error of URL KEY. ...
2
votes
1answer
526 views

Magento 2 Add category chooser without UI component

I am trying to add category chooser in my custom admin form without ui component but unfortunately I am getting error in system.log [2019-03-22 09:27:47] main.CRITICAL: Vendor\Module\Block\...
1
vote
0answers
20 views

How to get category detail along with subcategories and products in PHP file not PHTML?

I have looked over internet but can't find a solution to get detail in my controller or block file i have tried Registry Tried get id of category from param Also tried from Magento\Catalog\Model\...
2
votes
1answer
514 views

magento 2 Infortis ultimo theme display category tree menu on the left of the search result page

I am using the Infortis ultimo theme, in the included feature, i was able to add the category tree menu on the left bar of each category page, but how can i add it to the search result page? is this ...
3
votes
2answers
237 views

Unlink and link product to category

Need a script where current existing products needs to unlink and link to other categories. let me know the process also
1
vote
1answer
1k views

Multiselect category dropdown on admin form

I have created custom CRUD on new database table. I just wanted to save comma separated categories in a field. I have this code for multiselect categories: $fieldset->addField( 'categories', ...
0
votes
1answer
625 views

Magento 2 Product Form Categories Sort Alphabetically From the Backend

I want to sort Categories alphabetically of the product form, how can I? For more clarification please look onto the below picture. As I checked, by default Magento 2 sort according to the category ...
1
vote
0answers
20 views

How to skip any category in seo meta title template?

We have magento 2 on website we have 4 categories, we sell photocopier parts, let me give an example what issue we are facing and what we want. Konica Minolta - Bizhub Color Series- Bizhub 203 - ...
1
vote
0answers
355 views

Magento 2 - Layered navigation Parent and Child Category Filter issue

I am using WeltPixel layered navigation Free extension. In category filter, third level categories was not showing in filter navigation by default. I added some code to get third level categories. ...
0
votes
1answer
37 views

Can't choose any category in admin

I can't choose any category in the admin panel for editing. You will always see the creation of a new category. Magento 1.9.4.0 clean setup, mariaDB 10.3, php 7.1.25, CentOS.
3
votes
1answer
270 views

Get all 3rd level categories

is there any chance how to get ALL third level categories available? I have searched whole internet and found only getting categories based on parent category but it doesnt return whole store 3rd ...
3
votes
1answer
30 views

Magento 2: Can't select “categories” on cart pricerule

I have try to make a price rule in Magento 2. But I can't see the option "categories". Someone know where I can activate it? Or did i do something wrong?
1
vote
0answers
122 views

magento 2 get all category id of a specific store including all level nested child category

i want to get all category id of a specific store in magneto2 including its all root category and all level nested child category id of all root category i am trying with following cod but using this ...
1
vote
0answers
136 views

Magento2 How to get the category collection as tree structure under multiselect field programmatically.?

I want show category collection as tree structure for custom multiselect field at admin end as reference like below
0
votes
1answer
18 views

Load category, but only with limited data to build a Breadcrumb

Based on the helper catalog there is a function that returns a path for the breadcrumb to be displayed in Magento when viewing a Product. I want to enhance this method to return the full path of the ...
2
votes
1answer
2k views

How to add multi-select category tree at admin end in magento 2?

I would like to display *Category Tree Names** in multi select field in magento 2 admin end? I have tried with below code but displaying only first cateogires could you please any one help on this? ...
1
vote
0answers
35 views

Duplicating Categories

I am trying to set up a new website which has been migrated from an older site. This migration carried over the old category structure. Within the new structure i want to build, I am creating new ...
4
votes
1answer
249 views

A-Z Category Listing Magento 2 Static Block

I am attempting to create a A-Z category listing within a static block, something like the attached image. The static block will be on the parent category, and the listing will show the parent ...
1
vote
1answer
501 views

Magento 2: How does the category tree/node work?

I must admit that I am having trouble understanding the category tree/node thing in magento. I have extended the Topmenu class to build my own supermenu. It works fine except the category children are ...
2
votes
1answer
68 views

Magento2: Intercept category moved inside tree

I am trying to intercept when a category is moved inside the category tree. At the beginning I thought to observe the event catalog_category_tree_move_after with an Observer class but I found that ...

1
2 3 4 5