doushan15559 2014-01-17 10:30
浏览 20
已采纳

无法设置0%的税率

I'm using a fairly new Magento 1.8.0.0 installation, with no changes to the core. When trying to make a tax rate at 0%, Magento returns the following error upon save: Rate Percent should be a positive number.

Is this just a bug in Magento 1.8, keeping me from setting a tax rate with 0% tax, or am I missing something?

  • 写回答

2条回答 默认 最新

  • dongxie3681 2014-01-17 10:35
    关注

    So it seems that this behavior (introduced in CE 1.8.0.0 - it works as expected in CE 1.7.0.2) will be removed.

    In the meantime you could try to rewrite app/code/core/Mage/Tax/Model/Calculation/Rate.php and remove these lines:

    if (!is_numeric($this->getRate()) || $this->getRate() <= 0) {
            Mage::throwException(Mage::helper('tax')->__('Rate Percent should be a positive number.'));
        }
    

    Instead you also could change the code to test for $this->getRate() < 0 instead of $this->getRate() <= 0.

    It's working.

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
查看更多回答(1条)

报告相同问题?

悬赏问题

  • ¥15 素材场景中光线烘焙后灯光失效
  • ¥15 请教一下各位,为什么我这个没有实现模拟点击
  • ¥15 执行 virtuoso 命令后,界面没有,cadence 启动不起来
  • ¥50 comfyui下连接animatediff节点生成视频质量非常差的原因
  • ¥20 有关区间dp的问题求解
  • ¥15 多电路系统共用电源的串扰问题
  • ¥15 slam rangenet++配置
  • ¥15 有没有研究水声通信方面的帮我改俩matlab代码
  • ¥15 ubuntu子系统密码忘记
  • ¥15 保护模式-系统加载-段寄存器