Error with custom field in 2024.10
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!
Always add your Laravel, Aimeos and PHP version as well as your environment (Linux/Mac/Win)
Spam and unrelated posts will be removed immediately!
Error with custom field in 2024.10
Hi,
we have added custom field "custid" to customer address data (not base data). Worked fine in 2022.10 and 2023.10.
Now after upgrading to 2024.10 we are getting error:
SQLSTATE[42601]: Syntax error: 7 ERROR: syntax error at or near "custid"
LINE 2: ...rthday", "longitude", "latitude", "pos", "mcusad."custid""...
in /src/MShop/Customer/Manager/Address/Decorator/MyCustIdAddress.php
in shop.php
is "mcusad" still the correct SQL alias?
https://github.com/aimeos/aimeos-core/b ... stomer.php changed from 2023 to 2024
Thank you
we have added custom field "custid" to customer address data (not base data). Worked fine in 2022.10 and 2023.10.
Now after upgrading to 2024.10 we are getting error:
SQLSTATE[42601]: Syntax error: 7 ERROR: syntax error at or near "custid"
LINE 2: ...rthday", "longitude", "latitude", "pos", "mcusad."custid""...
in /src/MShop/Customer/Manager/Address/Decorator/MyCustIdAddress.php
Code: Select all
namespace Aimeos\MShop\Customer\Manager\Address\Decorator;
class MyCustIdAddress extends \Aimeos\MShop\Common\Manager\Decorator\Base
{
private $attr = [
'custid' => [
'internalcode' => 'mcusad."custid"',
'label' => 'Kundennummer',
'type' => 'string',
],
];
...
Code: Select all
'mshop' => [
'customer' => [
'manager' => [
'address' => [
'decorators' =>[
'local' => ['MyCustIdAddress']
],
],
],
],
],
is "mcusad" still the correct SQL alias?
https://github.com/aimeos/aimeos-core/b ... stomer.php changed from 2023 to 2024
Thank you
Re: Error with custom field in 2024.10
This is a bug because until 2025, the implementation should be backwards compatible with your code. A new version of the aimeos/aimeos-core package with the required fix has been released now.
Starting with 2024.10 and later, the recommended code is described here: https://aimeos.org/docs/latest/models/e ... -decorator
Starting with 2024.10 and later, the recommended code is described here: https://aimeos.org/docs/latest/models/e ... -decorator
Professional support and custom implementation are available at Aimeos.com
If you like Aimeos,
give us a star
If you like Aimeos,
