Product attribute manipulation

Help for integrating the Laravel package
Forum rules
Always add your Laravel, Aimeos and PHP version as well as your environment (Linux/Mac/Win)
Spam and unrelated posts will be removed immediately!
Sergunik
Posts: 12
Joined: 16 Mar 2018, 14:14

Product attribute manipulation

Post by Sergunik » 16 Mar 2018, 14:23

Lets look at documentation (https://aimeos.org/docs/Developers/Libr ... gers_items):
"Usually, it's only rarely necessary to extend existing managers and items because most of the data can be associated to items via the list tables. The data can then be stored as attributes, texts or properties (in case of product items) instead."
But how? How can I use attributes? Where I could find documentation about working with attribute?

I have an issue:
Need to add 1 boolean attribute to product.
The attribute should be readable from product page. And should be changeable on admin product page (simple checkbox).

I know that's covered by attribute but have no idea how?

Travin
Posts: 70
Joined: 18 Dec 2017, 03:12

Re: Product attribute manipulation

Post by Travin » 17 Mar 2018, 14:30

Please tell more clearly what do you need to do wih it
Laravel 6.18.19 | php 7.4.7 | Xubuntu | Aimeos Laravel 2019.10.5

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

Re: Product attribute manipulation

Post by aimeos » 17 Mar 2018, 17:40

You can associate attributes you've created in the "Attribute" panel of the admin interface in the product detail view ("Characteristics" subpanel). In the template, you can retrieve the attributes again with

Code: Select all

$product->getRefItems( 'attribute', '<attribute type>', '<list type>' )
Professional support and custom implementation are available at Aimeos.com
If you like Aimeos, Image give us a star

Post Reply