소스 검색

Merge branch 'dev_wf' of wugg/phpstock into version1.5

wufeng 2 년 전
부모
커밋
3962414715
1개의 변경된 파일4개의 추가작업 그리고 3개의 파일을 삭제
  1. 4 3
      app/admin/controller/Goodup.php

+ 4 - 3
app/admin/controller/Goodup.php

@@ -450,8 +450,9 @@ class Goodup extends Base
                         $lemp['mark_fee'] = $value['mark_fee'];
                         $lemp['package_fee'] = $value['package_fee'];
                         $lemp['other_fee'] = $value['other_fee'];
-                        if($is_gold_price==1){
+                        if($is_gold_price==1 && $cat_id==6){
 
+                            //$is_gold_price==1 表示启用实时金价,cat_id==6表示贵金属
                             //$gold = Db::name("gold_price1")->where(["type" => $noble_metal, "status" => 1, "is_del" => 0])->order("addtime desc")->find();
                             //$lemp['nake_total'] = $noble_weight * $gold['price'] + $value['cost_fee'] * $noble_weight + $value['mark_fee'] + $value['package_fee'] + $value['cert_fee'] + $value['nake_fee'] + $value['delivery_fee'] + $value['other_fee'];
                             //成本合计=贵金属重量*供应商采购金价 + 工艺费*贵金属重量+加标费+包装费+证书费+成本裸价+运费+其他费用
@@ -804,7 +805,7 @@ class Goodup extends Base
                         $lemp['mark_fee'] = $value['mark_fee'];
                         $lemp['package_fee'] = $value['package_fee'];
                         $lemp['other_fee'] = $value['other_fee'];
-                        if($is_gold_price==1){
+                        if($is_gold_price==1 && $datas['cat_id']==6){
                             //$gold =Db::name("gold_price1")->where(["type"=>$noble_metal,"status"=>1,"is_del"=>0])->order("addtime desc")->find();
                             //$lemp['nake_total'] =$noble_weight*$gold['price'] + $value['cost_fee']*$noble_weight+$value['mark_fee']+$value['package_fee']+$value['cert_fee']+$value['nake_fee']+$value['delivery_fee']+$value['other_fee'];
                             //成本合计=贵金属重量*供应商采购金价 + 工艺费*贵金属重量+加标费+包装费+证书费+成本裸价+运费+其他费用
@@ -1722,7 +1723,7 @@ class Goodup extends Base
                         $lemp['mark_fee'] = $value['mark_fee'];
                         $lemp['package_fee'] = $value['package_fee'];
                         $lemp['other_fee'] = $value['other_fee'];
-                        if($is_gold_price==1){
+                        if ($is_gold_price == 1 && $cat_id == 6) {
                             //$gold =Db::name("gold_price1")->where(["type"=>$noble_metal,"status"=>1,"is_del"=>0])->order("addtime desc")->find();
 
                             //$lemp['nake_total'] =$noble_weight*$gold['price'] + $value['cost_fee']*$noble_weight+$value['mark_fee']+$value['package_fee']+$value['cert_fee']+$value['nake_fee']+$value['delivery_fee']+$value['other_fee'];