Price rules applied in catalog but not in basket
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!
Price rules applied in catalog but not in basket
As the subject says, I've setup a price rule with -10% on a specific category.
I've added catalog to domains per the instructions here:
https://aimeos.org/docs/2021.x/manual/rule-decorators/
And the price is adjusted in lists and product detail page, exactly as advertized, but the price in the basket is the unchanged, standard price.
I've searched the forums and from earlier answers, tried turning off all plugins related to price, ProductPrice, TaxRates plus two custom plugins, no change.
The section client/html/catalog in my conf file looks like this:
I know the docs say:
What am I missing here?
I've added catalog to domains per the instructions here:
https://aimeos.org/docs/2021.x/manual/rule-decorators/
And the price is adjusted in lists and product detail page, exactly as advertized, but the price in the basket is the unchanged, standard price.
I've searched the forums and from earlier answers, tried turning off all plugins related to price, ProductPrice, TaxRates plus two custom plugins, no change.
The section client/html/catalog in my conf file looks like this:
Code: Select all
'catalog' => [
'selection' => [
'type' => array('Vikt' => 'radio', 'Volym' => 'radio'),
],
'lists' => [
'basket-add' => true,
'domains' => array('catalog', 'attribute', 'media', 'media/property', 'price', 'product', 'product/property', 'supplier' => array('text', 'media', 'supplier/address'), 'text'),
'pagination' => ['enable' => 1],
'size' => 100,
'sort' => 'relevance'
],
'detail' => [
'basket-add' => false,
],
'filter' => [
'attribute' => [
'types-option' => ['Varutyp'],
],
],
'stock' => [
'level' => [
'low' => 3
]
],
#'domains' => array('catalog', 'media', 'media/property', 'price', 'text')
],
as the commented out line in conf, but if I use that line and don't have "catalog" under catalog/lists/domains it does not work at all.You need to add catalog to the client/html/catalog/domains configuration setting so the Category rule decorator is used, e.g. ['catalog', 'media', 'media/property', 'price', 'text'].
What am I missing here?
- Attachments
-
- Screenshot 2022-05-24 at 15.42.14.png (223.63 KiB) Viewed 1519 times
_____________
Laravel 8 with Aimeos 2021.10.7 + Marketplace. Setup via composer. Mac with Valet and MySql 8.0.25
Laravel 8 with Aimeos 2021.10.7 + Marketplace. Setup via composer. Mac with Valet and MySql 8.0.25
Re: Price rules applied in catalog but not in basket
The referenced documentation is only for displaying the correct price but the source of the problem was in the basket/standard code which had missed the "catalog" domain when fetching products.
Can you please update and try again:
Can you please update and try again:
Code: Select all
composer req aimeos/ai-client-html:2021.10.x-dev
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
Re: Price rules applied in catalog but not in basket
I see.
Will try this and report back.
Thank you
Will try this and report back.
Thank you
_____________
Laravel 8 with Aimeos 2021.10.7 + Marketplace. Setup via composer. Mac with Valet and MySql 8.0.25
Laravel 8 with Aimeos 2021.10.7 + Marketplace. Setup via composer. Mac with Valet and MySql 8.0.25
Re: Price rules applied in catalog but not in basket
I would just like to add to this issue in case someone runs on similar case.
When price rules were applied, from some reason changes were not applied to the basket.
Disabling ProductPrice plugin helped so pricing was applied correctly to the basket.
In addition to that Session/Pinned was not applying pricing correctly. Session/Seen works just fine.
Suggestion is to make change on this line to following, as everything works well once when 'catalog' was added.
When price rules were applied, from some reason changes were not applied to the basket.
Disabling ProductPrice plugin helped so pricing was applied correctly to the basket.
In addition to that Session/Pinned was not applying pricing correctly. Session/Seen works just fine.
Suggestion is to make change on this line to following, as everything works well once when 'catalog' was added.
Code: Select all
$domains = $config->get( 'client/html/catalog/domains', ['catalog', 'media', 'price', 'text'] );
============================
Aimeos 2022.10+ (2022.10.3)
PHP 8.1.12 / Laravel
Win (Develop)
Aimeos 2022.10+ (2022.10.3)
PHP 8.1.12 / Laravel
Win (Develop)
Re: Price rules applied in catalog but not in basket
This has been fixed now:
https://github.com/aimeos/aimeos-core/c ... 16b87dbf66
Can you install and test so that we can release a new version?
Code: Select all
composer req aimeos/aimeos-core:2022.10.x-dev
Thanks, this has been also changed now. Please test:aimeosenv wrote: ↑17 Dec 2022, 19:55 In addition to that Session/Pinned was not applying pricing correctly.
Suggestion is to make change on this line to following, as everything works well once when 'catalog' was added.
Code: Select all
$domains = $config->get( 'client/html/catalog/domains', ['catalog', 'media', 'price', 'text'] );
Code: Select all
composer req aimeos/ai-client-html:2022.10.x-dev
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
Re: Price rules applied in catalog but not in basket
Thank you!
I have just installed updated aimeos-core and with ProductPrice plugin enabled all works well now.
Other package (Pinned) as well works fine after update via req process.
There is still bug with this part:
Once when change up or down in quantity is performed, FULL price is applied and not one with price rules applied.
Just one more quick question/note related to these updates.
One other note is strange here. In both cases when composer req was done, this file was overwritten:
Actually all files here were overwritten:
I have noticed only aimeos.css since I've made modifications to it, but shouldn't this be part of custom theme (extension) and not be overwritten? Have I placed it in wrong dir or something and it gets overwritten?
I have just installed updated aimeos-core and with ProductPrice plugin enabled all works well now.
Other package (Pinned) as well works fine after update via req process.
There is still bug with this part:
Code: Select all
minibutton change down
minibutton change up
Located here:
packages/mycustom-theme/templates/client/html/common/summary/detail.php
Just one more quick question/note related to these updates.
One other note is strange here. In both cases when composer req was done, this file was overwritten:
Code: Select all
public/vendor/shop/themes/mycustom-theme/aimeos.css
Code: Select all
public/vendor/shop/themes/mycustom-theme/
============================
Aimeos 2022.10+ (2022.10.3)
PHP 8.1.12 / Laravel
Win (Develop)
Aimeos 2022.10+ (2022.10.3)
PHP 8.1.12 / Laravel
Win (Develop)
Re: Price rules applied in catalog but not in basket
The "catalog" domain has been added here to:
https://github.com/aimeos/ai-controller ... d.php#L399
Can you please check:
Please create a new topic for your other question as it doesn't fit in this thread.
https://github.com/aimeos/ai-controller ... d.php#L399
Can you please check:
Code: Select all
composer req aimeos/ai-controller-frontend:2022.10.x-dev
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