Ignore:
Timestamp:
2014/05/13 13:03:33 (10 years ago)
Author:
pineray
Message:

#2448 (typo修正・ソース整形・ソースコメントの改善)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/version-2_13-dev/data/class/helper/SC_Helper_TaxRule.php

    r23405 r23415  
    3434     * 設定情報に基づいて税金付与した金額を返す 
    3535     * 
    36      * @param  integer $price 計算対象の金額 
    37      * @return integer 税金付与した金額 
    38      */ 
    39     public function sfCalcIncTax($price, $product_id = 0, $product_class_id = 0, $pref_id =0, $country_id = 0) 
     36     * @param int $price 計算対象の金額 
     37     * @param int $product_id 商品ID 
     38     * @param int $product_class_id 商品規格ID 
     39     * @param int $pref_id 都道府県ID 
     40     * @param int $country_id 国ID 
     41     * @return int 税金付与した金額 
     42     */ 
     43    public static function sfCalcIncTax($price, $product_id = 0, $product_class_id = 0, $pref_id =0, $country_id = 0) 
    4044    { 
    4145        return $price + SC_Helper_TaxRule_Ex::sfTax($price, $product_id, $product_class_id, $pref_id, $country_id); 
     
    4549     * 設定情報に基づいて税金の金額を返す 
    4650     * 
    47      * @param  integer $price 計算対象の金額 
    48      * @return integer 税金した金額 
    49      */ 
    50     public function sfTax($price, $product_id = 0, $product_class_id = 0, $pref_id =0, $country_id = 0) 
     51     * @param int $price 計算対象の金額 
     52     * @param int $product_id 商品ID 
     53     * @param int $product_class_id 商品規格ID 
     54     * @param int $pref_id 都道府県ID 
     55     * @param int $country_id 国ID 
     56     * @return int 税金付与した金額 
     57     */ 
     58    public static function sfTax($price, $product_id = 0, $product_class_id = 0, $pref_id =0, $country_id = 0) 
    5159    { 
    5260        $arrTaxRule = SC_Helper_TaxRule_Ex::getTaxRule($product_id, $product_class_id, $pref_id, $country_id); 
     
    5967     * (受注データのようにルールが決まっている場合用) 
    6068     * 
    61      * @param  integer $price 計算対象の金額 
    62      * @return integer 税金付与した金額 
    63      */ 
    64     public function calcIncTaxFromRuleId($price, $tax_rule_id = 0) 
     69     * @param int $price 計算対象の金額 
     70     * @param int $tax_rule_id 税規約ID 
     71     * @return int 税金付与した金額 
     72     */ 
     73    public static function calcIncTaxFromRuleId($price, $tax_rule_id = 0) 
    6574    { 
    6675        return $price + SC_Helper_TaxRule_Ex::calcTaxFromRuleId($price, $tax_rule_id); 
     
    7180     * (受注データのようにルールが決まっている場合用) 
    7281     * 
    73      * @param  integer $price 計算対象の金額 
    74      * @return integer 税金した金額 
    75      */ 
    76     public function calcTaxFromRuleId($price, $tax_rule_id = 0) 
     82     * @param int $price 計算対象の金額 
     83     * @param int $tax_rule_id 税規約ID 
     84     * @return int 税金付与した金額 
     85     */ 
     86    public static function calcTaxFromRuleId($price, $tax_rule_id = 0) 
    7787    { 
    7888        $arrTaxRule = SC_Helper_TaxRule_Ex::getTaxRuleData($tax_rule_id); 
     
    8494     * 税金額を計算する 
    8595     * 
    86      * @param integer $price 計算対象の金額 
    87      * @param integer $tax   税率(%単位) 
    88      *     XXX integer のみか不明 
    89      * @param  integer $tax_rule 端数処理 
    90      * @return integer 税金額 
    91      */ 
    92     public function calcTax ($price, $tax, $calc_rule, $tax_adjust = 0) 
     96     * @param int $price 計算対象の金額 
     97     * @param int $tax 税率(%単位) 
     98     *     XXX int のみか不明 
     99     * @param int $calc_rule 端数処理 
     100     * @param int $tax_adjust 調整額 
     101     * @return int 税金額 
     102     */ 
     103    public static function calcTax ($price, $tax, $calc_rule, $tax_adjust = 0) 
    93104    { 
    94105        $real_tax = $tax / 100; 
     
    119130     * 現在有効な税率設定情報を返す 
    120131     * 
    121      * @param  integer $price 計算対象の金額 
    122      * @return array   税設定情報 
    123      */ 
    124     public function getTaxRule($product_id = 0, $product_class_id = 0, $pref_id = 0, $country_id = 0) 
     132     * @param int $product_id 商品ID 
     133     * @param int $product_class_id 商品規格ID 
     134     * @param int $pref_id 都道府県ID 
     135     * @param int $country_id 国ID 
     136     * @return array 税設定情報 
     137     */ 
     138    public static function getTaxRule($product_id = 0, $product_class_id = 0, $pref_id = 0, $country_id = 0) 
    125139    { 
    126140        // 複数回呼出があるのでキャッシュ化 
     
    229243     * 税率設定情報を登録する(商品管理用) 
    230244     * 
    231      * @param  decimal $tax_rate        消費税率 
    232      * @param  integer $product_id      商品ID 
    233      * @param  integer $product_class_id 商品規格ID 
    234      * @param  decimal $tax_adjust      消費税加算額 
    235      * @param  integer $pref_id          県ID 
    236      * @param  integer $country_id      国ID 
     245     * @param float $tax_rate 消費税率 
     246     * @param int $product_id 商品ID 
     247     * @param int $product_class_id 商品規格ID 
     248     * @param float|int $tax_adjust 消費税加算額 
     249     * @param int $pref_id 県ID 
     250     * @param int $country_id 国ID 
    237251     * @return void 
    238252     */ 
    239     public function setTaxRuleForProduct($tax_rate, $product_id = 0, $product_class_id = 0, $tax_adjust=0, $pref_id = 0, $country_id = 0) 
     253    public static function setTaxRuleForProduct($tax_rate, $product_id = 0, $product_class_id = 0, $tax_adjust=0, $pref_id = 0, $country_id = 0) 
    240254    { 
    241255        // 基本設定を取得 
     
    256270     * 税率設定情報を登録する(仮)リファクタする(memo:規格設定後に商品編集を行うと消費税が0になるのを対応が必要) 
    257271     * 
    258      * @param 
    259      * @return 
     272     * @param int $calc_rule 端数処理 
     273     * @param int $tax_rate 税率 
     274     * @param int|string $apply_date 適用日時 
     275     * @param null $tax_rule_id 税規約ID 
     276     * @param int $tax_adjust 調整額 
     277     * @param int $product_id 商品ID 
     278     * @param int $product_class_id 商品規格ID 
     279     * @param int $pref_id 都道府県ID 
     280     * @param int $country_id 国ID 
     281     * @return void 
    260282     */ 
    261283    public function setTaxRule($calc_rule, $tax_rate, $apply_date, $tax_rule_id=NULL, $tax_adjust=0, $product_id = 0, $product_class_id = 0, $pref_id = 0, $country_id = 0) 
     
    297319    } 
    298320 
     321    /** 
     322     * @param bool $has_deleted 
     323     * @return array|null 
     324     */ 
    299325    public function getTaxRuleList($has_deleted = false) 
    300326    { 
     
    313339    } 
    314340 
     341    /** 
     342     * @param int $tax_rule_id 
     343     * @param bool $has_deleted 
     344     * @return array 
     345     */ 
    315346    public function getTaxRuleData($tax_rule_id, $has_deleted = false) 
    316347    { 
     
    324355    } 
    325356 
     357    /** 
     358     * @param int|string $apply_date 
     359     * @param bool $has_deleted 
     360     * @return mixed 
     361     */ 
    326362    public function getTaxRuleByTime($apply_date, $has_deleted = false) 
    327363    { 
     
    339375     * 税規約の削除. 
    340376     * 
    341      * @param  integer $tax_rule_id 税規約ID 
     377     * @param  int $tax_rule_id 税規約ID 
    342378     * @return void 
    343379     */ 
Note: See TracChangeset for help on using the changeset viewer.