[Tep-j-general] Re: 注文管理での税額の端数処理

Back to archive index

TAMURA Toshihiko tamur****@bitsc*****
2004年 9月 28日 (火) 11:59:03 JST


こんにちは、田村です。

山本さん:

> 注文管理の税額の端数処理が効いていないのではないですか?
> 
> catalog\includes\functions\general.php と同様に、
> admin\includes\functions\general.php の1239行目を以下のようにしないと
> 税額の端数処理が効かないと思うのですが
> 
>    // return tep_round($price * $tax / 100,
> $currencies->currencies[DEFAULT_CURRENCY]['decimal_places']);
>     return $currencies->round_off($price * $tax / 100);

はい、そうですね。ここはまちがっています。

catalog/includes/functions/general.php の tep_calculate_tax を
次のように変更する必要があります。
------------------------------------------------------------
  function tep_calculate_tax($price, $tax) {
    global $currencies;
    return $currencies->round_off($price * $tax / 100);
  }
------------------------------------------------------------

この問題の影響範囲を調べたんですが、
管理画面の注文管理と納品書のページの[価格(税込)]に影響します。
小計や合計は、注文成立時の金額を記録していますので影響しません。

-- 
田村敏彦 / 株式会社ビットスコープ
E-mail:tamur****@bitsc*****
http://www.bitscope.co.jp/




Tep-j-general メーリングリストの案内
Back to archive index