Prestashop 1.6 产品在使用特定价格折扣时显示错误的价格组合 [英] Prestashop 1.6 Product Showing wrong price combination when using specific price discount

查看:61
本文介绍了Prestashop 1.6 产品在使用特定价格折扣时显示错误的价格组合的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何重复:

  1. 安装 prestashop 1.6.1.4

  2. 创建产品牛仔裤 - 批发价 53.87,零售价 74.82(缺货时允许下单,无税)

  3. 为牛仔裤添加 28% 的特定价格折扣

  4. 添加产品组合 - 在我的情况下,我希望客户选择尺寸和颜色:Size - 29W x 30L, Color - Bleach FadeSize - 29W x30L,颜色 - 浅黄色,均具有 批发价格:29.9 和 对价格的影响 - 降低 33.29

结果:当我进入产品页面时,如果我选择第一个组合尺寸 - 29W x 30L,颜色 - 漂白淡化 我得到的价格是 29.9,这正是我所期望的.

但是当我选择第二个选项时尺寸 - 29W x 30L,颜色 - Buff 我得到的价格是 53.87 美元,而不是我预期的 29.9.

注意:当我将产品添加到购物车时,它会计算两种组合的正确价格 (29.9) - 因此此错误仅出现在产品显示中

我该如何解决这个问题?

我认为这是代码中的一个错误,因此欢迎任何代码修复.

背景:

我正在将我的站点从 PrestaShop™ 1.4.5.1 升级到 1.6.1.4,我有一个包含大量专有代码的复杂站点,但是这种情况在 1.4.5.1 中无法重现,即重复相同步骤的结果第二个产品的正确价格 (29.9).

注意:这是该错误的最小化版本,在实际产品中我有更多组合,其中一些具有真正的74.82"价格.

解决方案

应用此修复程序以更正问题:

https://github.com/PrestaShop/PrestaShop/commit/56fe9925c2703ba07d13b6ba56a92494d38ba45e" rel="nofollow">https://github.com/PrestaShop/PrestaShop/commit/56fe9925c2703ba07d13b6ba56a92492/p>

用您的 prestashop 安装替换此修复程序中的文件

注意:如果您不使用默认主题,请将新的 tpl 复制到您的主题文件夹中.

How to repeat:

  1. install prestashop 1.6.1.4

  2. create a product JEANS - Wholesale price 53.87, Retail price 74.82 (Allow orders When out of stock, No Tax)

  3. add specific price discount of 28% to JEANS

  4. add product combinations - in my case I want the client to choose a size and a color: Size - 29W x 30L, Color - Bleach Fade and Size - 29W x 30L, Color - Buff, both with a Wholesale price: 29.9, and Impact on price - Decrease 33.29

result: when I go to product page, if I choose the first combination Size - 29W x 30L, Color - Bleach Fade I get the price 29.9, which is what I expect.

BUT when I choose the second option Size - 29W x 30L, Color - Buff I get price $53.87 instead of the 29.9 I expected.

NOTE: when I add the product to the cart then it calculate the correct price (29.9) for both combination - thus this bug is only in the product display

How can I fix this?

I assume this is a bug in the code so any code fix will be welcome.

Background:

I'm upgrading my site from PrestaShop™ 1.4.5.1 to 1.6.1.4, I have a complicated site with a lot of proprietary code, however this scenario is not reproducible in the 1.4.5.1, i.e. repeating the same steps result with a correct price (29.9) in the second product.

Note: this is a minimized version of the bug, in a real product I have more combinations, some with the real '74.82' price.

解决方案

Apply this fix to correct the problem:

https://github.com/PrestaShop/PrestaShop/commit/56fe9925c2703ba07d13b6ba56a92494d38ba45e

replace the file in this fix with your prestashop installation

Note: if you are not using the default theme than copy the new tpl to your theme folder.

这篇关于Prestashop 1.6 产品在使用特定价格折扣时显示错误的价格组合的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆