Questions tagged [product-attribute]

Questions about creating, managing and using product attributes

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

How to get filterable attribute option after category attribute selection in magento 2 programmatically

I used the below code and list out all the attribute options by current category wise. But, I want to list out available attribute options by selected attribute option with product results. In my case,...
0
votes
2answers
33 views

How to filter product collection in such way where I can use having and addfiledtofilter with AND condition?

I am having product collection where I am getting one custom product attribute called "keep_disabled" and another column which was added on runtime which is sum of quantities 'sum_qty'. I ...
0
votes
1answer
53 views
+100

country_of_manufacture issues with names in Magento 2

I am having issues with country_of_manufacture attribute. I recently made a copy of production site to prep our new server for migration from old server. The issue comes in when I do import testing - ...
0
votes
0answers
19 views

How to Edit Invoice in Magento 2 using programmatically

I want to add colour with the name of product Like - If the product name is Jeans and the selected colour is Blue then I want to print name on invoice is like Blue Jeans in name section. How to do ...
0
votes
1answer
15 views

M2 - Admin related product, grid columns

In Magento 2 you can select your own attributes you want to show on the normal product grid in the admin. But when you are editing a product and want to add some related product, all the attributes ...
0
votes
1answer
12 views

Magento 2 not allowed Superscript(“®”,“™”) with product name!

If we have to display product name with superscript tag like "®","™", Magento 2 doesn't support and it display as it is without parsing tag. For example, if we have to display ...
0
votes
0answers
34 views

Adding UPC Attribute to Product Page

I am trying to figure how to add an attribute (UPC) to display just under the SKU on the my product page. I have tried in the past with no such luck. I really need this to work. I have found several ...
1
vote
1answer
87 views

updateAttributes cannot be used to enable a product? (price index not updated)

We are enabling a disabled product with \Magento\Catalog\Model\Product\Action::updateAttributes $this->productAction->updateAttributes([$magentoProductId], [ 'status' => \Magento\Catalog\...
0
votes
0answers
16 views

I want to add “per meter” in specific product pages

I want to sell this product according to length (i.e per meter or feet). I've tried a few extensions but they were not very useful. I just want to add the per meter or per feet feature for user so the ...
0
votes
0answers
10 views

How to clone a product while preserving attribute values set per Storeview?

In a Magento 2.4 store with a single website and several storeviews (i.e. one for each language), I want to duplicate an existing product (Save & Duplicate). This product has some storeview-...
0
votes
1answer
21 views

Magento 2: Observer or Plugin for Mass Update Product Attribute

I have a custom attribute that I need to observe after the mass update product has been finished, this custom attribute is related to a category in another custom table, so if this custom attribute ...
0
votes
1answer
38 views

Magento 2 - Create Product attribute programmatically without InstallData

We need to create a script that creates product attributes. Product attribute comes from third-party API when creating a product its check product attribute available or not If that is not available ...
0
votes
1answer
20 views

Change product attribute type in magento 2

Hope everything is well at all of your end. I am changing type of product attribute. But I am bit confuse after changing type of attribute, it will assigned to all products the same or not. Please ...
0
votes
0answers
31 views

Magento 2 Cannot update specialPrice per website

I'm trying to update specialPrice per website in a Magento 2.3.6 website. The problem is that when i am updating the price using the Product model , the specialPrice is removed from all storeviews ( ...
0
votes
1answer
28 views

Magento 2 : attribute not appearing in product

"tax_class_id" is the attribute i am looking for in product, but i cannot find it. I can confirm the attribute is added in "Default" attribute set & product has also same set ...
0
votes
1answer
11 views

magento 2: how to checked use default value for product status programmtically?

I have to update and checked checkbox for use default field for product status. But I do not know how to update and checked that checkbox ? here is my code $objectManager = \Magento\Framework\App\...
0
votes
1answer
31 views

REST API and custom attributes

My magento installation has 3 stores (domain+language). I would like to update custom attributes for products. When I call GET products/my_test_sku?storeId=1 i get something like the following json: {...
0
votes
0answers
31 views

Customizable options for Virtual Products

I am trying to access the customizable options of a virtual product whose visibility is set to 'Not Visible Individually' through the GQL query, { products(filter: { sku: { eq: "sample_sku"...
0
votes
0answers
15 views

How to add Product Attribute Values from Custom Model Data

I'm building a module for Supplier Inventory. I created a UI Component for creating Suppliers in the dashboard. In my Model\Data I added the Supplier Name. class Supplier extends ...
0
votes
2answers
17 views

Custom product attribute storefront property 'Used for Sorting in Product Listing' is disabled

Stores > Attributes > Product > My Custom Attribute > Storefront Properties tab I'm not able to change the Storefront Properties 'Used for Sorting in Product Listing', since it is ...
0
votes
1answer
30 views

Magento 2: Get all the option label (per store scope) from attribute code

Currently my code is use Magento\Eav\Model\Attribute; use Magento\Eav\Model\AttributeRepository; use Magento\Framework\Api\SearchCriteriaBuilder; $searchCriteria = $this->searchCriteriaBuilder-&...
0
votes
0answers
11 views

How to create my custom visual swatch color attribute in my own module Vendor/Module/Setup/Patch/Data/MyOwnColorAttribute?

I take from https://github.com/magento/magento2/blob/2.3/dev/tests/integration/testsuite/Magento/Swatches/_files/product_visual_swatch_attribute.php like example, but my own color attribute patch didn'...
0
votes
2answers
27 views

Magento2 | Add select-box with search/filter option | Auto suggestor

I am try to add a search bar to the product custom dropdown attribute. I am able to add it using xml and data is also getting saved, but after loading the product again, it is not showing in admin. ...
0
votes
0answers
14 views

Magento2 Product doesn't return extention attributes

Today I have encountered an error when getting product detail as describing here. Everything work fine except extension_attributes return empty despite it has data. I don't have any idea about how it ...
0
votes
0answers
11 views

Magento 2 Product Super Attributes

can someone give me a good documentation or resource on where can i understand how product super attributes works? its the catalog_product_super_attribute table. Thanks
0
votes
0answers
14 views

Filter Category Options are differente when I change from one page to another?

I am facing something weird in one project that I don't know if is normal (I hadn't seen this behavior in another project). The customer reports to me that when you enter to Category first page, ...
0
votes
0answers
18 views

How to make textarea product attribute value to use default value for specific store?

I'm using magento 2.4.1 and I tried to set the product textarea attribute to use default value like this for specific store id: $insertAttData['textarea_attribute'] = NULL; $this->productAction->...
0
votes
0answers
20 views

manual migration of magento 2 products, done incorrectly

I'm on a project that made the migration from magento 1 to magento 2, and a manual migration of products from magento 1 to magento 2 was made, but after registering many products we realized that they ...
0
votes
2answers
64 views

Max length as input validation for product name attribute

I want that the maximum of character of product name attribute is 50 character per example in the back office. I can not find that on default input validation on product name attribute managing. Help ...
0
votes
0answers
14 views

Magento 2.3.5: Link product page attribute to category page

How can I link (href) a product page attribute to it's category page? For example: I have a visible attribute on the product page called "Artist" and the product is in 3 categories "...
0
votes
1answer
39 views

Product attribute create/update using rest api and assign it to attribute set

I am creating product attributes using rest API with the below request body. End point rest/V1/products/attributes/ { "attribute": { "is_wysiwyg_enabled": false, &...
-1
votes
1answer
48 views

Adding custom customer attribute with declarative schema and db_schema

I added a custom attribute in de customer_entity table with db_schema.xml. I can get the value of that attribute with getdata('debtor_id') but I can't set it with setData('debtor_id' ,2). Did I miss a ...
0
votes
2answers
40 views

Magento 2.4.2 How to add Key Features to the product detail page

I need to add Key Features to the product detail page.The function should be a new attribute, but I don't know how to add it. Do you have a simple and quick way. Key Features can be replaced with any ...
0
votes
1answer
22 views

Magento 2: Alternative solution to large number of values inside 1 attribute

We have Product Attribute called "Authors" with "Multiselect option". It has entries up to 51k. When we edit product page in backend it becomes very slow to load page and specially ...
0
votes
0answers
12 views

Saving Product Attribute First Time Erases Store Labels, Second Time Saves the New Addition

We have the loop below, which is supposed to update the store labels and options and then save the product attribute. The first time the attribute repository saves the attribute, it completely wipes ...
0
votes
0answers
36 views

Magento 2 - Get Swatch Options from Product Attribute Source Model

we are trying to create swatch visual and text product attribute programmatically, we need to give swatch Options Like Source Model. \Magento\Catalog\Model\Product::ENTITY, ...
0
votes
0answers
69 views

Magento2 Graphql get select attribute options label instead of option id

I am using v2.4 in which in the products query I am getting the Optionid of select attribute instead of attribute option label. Like if i try to get color(select type) then I get value of red instead ...
0
votes
0answers
14 views

Show product attribute by modifier

guys. I'm working with product attribute. I have a multi-select attribute, but I wanna add search option for it. I use Modifier, this is my code: public function modifyData(array $data) { return $...
0
votes
0answers
12 views

Omnichannel magento solution api requests int

the company i work for is having difficulty linking a new Epos system to our new Magento 2 website. Our previous Magento 1 website was connected to a legacy Epos system and for most of the time it ...
0
votes
0answers
13 views

Magento 2 Attribute Sets and Attributes optimization

In terms of optimization and speed improvement, is it better to use: many Attribute Sets with few Attributes. few Attribute Sets with many Attributes
0
votes
0answers
57 views

Customise UI component Dynamic Row layout

Hopefully this is simple, but I'm struggling to figure this out. I have a custom product attribute that stores serialized data in a text field. It's exported from an old site with 10k SKUs each using ...
0
votes
1answer
28 views

Magento 2 attribute search product results

I have a multi-select attribute with n number of options. I have assigned some options for the products. For example, I have an attribute color and have options like blue, red, green, and yellow ...
0
votes
0answers
44 views

Add filter Options in existing product attribute

I want to add filter option on product attribute which is a dropdown. but I am not able to add this functionality on current attribute. Below are the code which I used for above select with search ...
1
vote
1answer
26 views

Product attribute creation error in admin catalog product

I have UpgradeData.php script that will install the attributes which I need, if (version_compare($context->getVersion(), '1.4.6', '<')) { $groupName = 'Data ...
0
votes
1answer
23 views

Why wont the product description attribute, when set to TextArea, convert line breaks to <br>

Magento v2.4.2 My product description attribute was set to TextArea, and its worked fine for the last year. New lines where rendered as in HTML on the product page. I decided to change it to ...
1
vote
1answer
32 views

Move Product Attribiutes from More information Tab to details tab

I would like to move all product attributes from selected product to details tab. I try to do something like this: <move element="product.attribute" destination="content" after=&...
0
votes
0answers
30 views

Magento2 - Attribute taking 0 as default value

I have a strange issue and not sure what is wrong, I have identical attributes (see image below), but the strange part is when I keep Metal 02 Weight blank and save the product its taking 0 value ...
0
votes
1answer
30 views

Add attributes to bundle-product options

How can I display custom product attributes for bundled products options? Products that are used as bundle-option are not fully loaded, so i cant access all/custom attributes. (Right?) E.g. I'd like ...
0
votes
1answer
19 views

Removing attributes from New Cart Price Rule - Actions tab

At New Cart Price Rule -> Action Tab. There is a green plus mark, where I can choose Conditions. The problem is, that I see there all added attributes to Magento but I need only few. Is there a way ...
0
votes
1answer
12 views

possible to write product custom attributes into session?

I have a product custom attribute, want to write in session when then product detail page was load. So I can get use the session value on the other block on the same page. Anyone can give me an advise?...

1
2 3 4 5
36