Single basket per user
Forum rules
Always add your Aimeos and PHP version as well as your environment (Linux/Mac/Win)
Spam and unrelated posts will be removed immediately!
Always add your Aimeos and PHP version as well as your environment (Linux/Mac/Win)
Spam and unrelated posts will be removed immediately!
Single basket per user
Hello,
PHP version: 8.1
Laravel version: 10
Aimeos version: 2023.10
Environment: Linux
I have seen that user can have many baskets in the database. I mean that in the database exists user baskets archive. I want to prevent that and change the functionality to 'single basket per user'. What is the entry point/file for that ?
PHP version: 8.1
Laravel version: 10
Aimeos version: 2023.10
Environment: Linux
I have seen that user can have many baskets in the database. I mean that in the database exists user baskets archive. I want to prevent that and change the functionality to 'single basket per user'. What is the entry point/file for that ?
Last edited by Gagik on 07 Feb 2024, 07:15, edited 2 times in total.
Re: Single basket per user
You have to overwrite this class:
https://github.com/aimeos/aimeos-core/b ... andard.php
Up to 2023.10, the relevant getSession()/setSession() methods you need to overwrite are in the Base.php:
https://github.com/aimeos/aimeos-core/b ... p#L60-L147
In 2024.01+, the methods have been moved to a trait but can be overwritten the same way:
https://github.com/aimeos/aimeos-core/b ... ession.php
https://github.com/aimeos/aimeos-core/b ... andard.php
Up to 2023.10, the relevant getSession()/setSession() methods you need to overwrite are in the Base.php:
https://github.com/aimeos/aimeos-core/b ... p#L60-L147
In 2024.01+, the methods have been moved to a trait but can be overwritten the same way:
https://github.com/aimeos/aimeos-core/b ... ession.php
Professional support and custom implementation are available at Aimeos.com
If you like Aimeos, give us a star
If you like Aimeos, give us a star