Get attributes in product list in v22

Questions around the TYPO3 integration and plugins
Forum rules
Always add your TYPO3, Aimeos and PHP version as well as your environment (Linux/Mac/Win)
Spam and unrelated posts will be removed immediately!
User avatar
loeffe1
Posts: 52
Joined: 21 Feb 2020, 10:33

Get attributes in product list in v22

Post by loeffe1 » 30 Jan 2023, 14:06

With older versions I was able to get the product attributes via

Code: Select all

$myattribute = $productItem->getRefItems( 'attribute', 'myattribute', 'default' );
after having modified the catalog lists domains to include 'attribute'.
With v22, $productItem->getRefItems() will show my attribute, however I don't know how to fetch it anymore.
The debug output will only display this:

Code: Select all

Aimeos\Mapprototypeobject (empty)
   methods => protectedarray(empty)
   delim => protected'/' (1 chars)
   list => protectedarray(empty)
   sep => protected'/' (1 chars)
What changed?

User avatar
aimeos
Administrator
Posts: 7866
Joined: 01 Jan 1970, 00:00

Re: Get attributes in product list in v22

Post by aimeos » 01 Feb 2023, 09:10

The only difference is that items are lazy loaded now.
Professional support and custom implementation are available at Aimeos.com
If you like Aimeos, Image give us a star

User avatar
loeffe1
Posts: 52
Joined: 21 Feb 2020, 10:33

Re: Get attributes in product list in v22

Post by loeffe1 » 06 Feb 2023, 15:45

I had falsely added the attribute as an option instead of a characteristic.

Post Reply