|
@@ -722,21 +722,22 @@ class Consult extends Base
|
|
|
|
|
|
// $saleprice = $open_fee/$zxinfo['num'] + $weight* $gold["price"] + $cost_fee/(1-$budget)* $weight+$pakge_fee+$mark_fee+$cert_fee+$nake_fee;
|
|
|
//$saleprice(最终售价) = (开模费/购买数量 + 商品重量* 最新金价 + 工艺费* 商品重量+包装费+加标费+证书费+产品裸价)/(1-成本售价/100);
|
|
|
- $saleprice = ($open_fee / $zxinfo['num'] + $weight * $gold["price"] + $cost_fee * $weight + $pakge_fee + $mark_fee + $cert_fee + $nake_fee) / (1 - $budget);
|
|
|
+// $saleprice = ($open_fee / $zxinfo['num'] + $weight * $gold["price"] + $cost_fee * $weight + $pakge_fee + $mark_fee + $cert_fee + $nake_fee) / (1 - $budget);
|
|
|
+ $saleprice = $total_fee/ (1 - $budget);
|
|
|
|
|
|
//销售工艺费=((开模费/购买数量 + 商品重量* 最新金价 + 工艺费* 商品重量+包装费+加标费+证书费+产品裸价)/(1-成本售价/100)-(打样费/购买数量 + 开模费/购买数量 +包装费+加标费+证书费+产品裸价0+运费) )/商品重量-最新金价
|
|
|
- $sale_cost_fee = (($open_fee / $zxinfo['num'] + $weight * $gold["price"] + $cost_fee * $weight + $pakge_fee + $mark_fee + $cert_fee + $nake_fee) / (1 - $budget) - ($demo_fee / $zxinfo['num'] + $open_fee / $zxinfo['num'] + $pakge_fee + $mark_fee + $cert_fee + $nake_fee + $delivery_fee)) / $weight - $gold["price"];
|
|
|
+ $sale_cost_fee = ($saleprice - ($demo_fee / $zxinfo['num'] + $open_fee / $zxinfo['num'] + $pakge_fee + $mark_fee + $cert_fee + $nake_fee + $delivery_fee)) / $weight - $gold["price"];
|
|
|
|
|
|
}else{
|
|
|
|
|
|
if($nake_fee){
|
|
|
- $saleprice = ($open_fee / $zxinfo['num'] + $cost_fee * $weight + $pakge_fee + $mark_fee + $cert_fee +
|
|
|
- $nake_fee)/ (1 - $budget);
|
|
|
- $total_fee = $open_fee / $zxinfo['num'] + $cost_fee * $weight + $pakge_fee + $mark_fee + $cert_fee + $nake_fee;
|
|
|
+ $saleprice = ($demo_fee / $zxinfo['num']+$delivery_fee+$open_fee / $zxinfo['num'] + $cost_fee * $weight +
|
|
|
+ $pakge_fee + $mark_fee + $cert_fee +$nake_fee)/ (1 - $budget);
|
|
|
+ $total_fee = $demo_fee / $zxinfo['num']+$delivery_fee+$open_fee / $zxinfo['num'] + $cost_fee * $weight + $pakge_fee + $mark_fee + $cert_fee + $nake_fee;
|
|
|
}else{
|
|
|
- $saleprice = ($open_fee / $zxinfo['num'] + $cost_fee * $weight + $pakge_fee + $mark_fee + $cert_fee) /
|
|
|
+ $saleprice = ($demo_fee/$zxinfo['num']+$delivery_fee+$open_fee / $zxinfo['num'] + $cost_fee * $weight + $pakge_fee + $mark_fee + $cert_fee) /
|
|
|
(1 - $budget);
|
|
|
- $total_fee = $open_fee / $zxinfo['num'] + $cost_fee * $weight + $pakge_fee + $mark_fee + $cert_fee;
|
|
|
+ $total_fee = $demo_fee/$zxinfo['num']+$delivery_fee+$open_fee / $zxinfo['num'] + $cost_fee * $weight + $pakge_fee + $mark_fee + $cert_fee;
|
|
|
}
|
|
|
|
|
|
}
|
|
@@ -1049,14 +1050,15 @@ class Consult extends Base
|
|
|
|
|
|
// $saleprice = $open_fee/$zxinfo['num'] + $weight* $gold["price"] + $cost_fee/(1-$budget)* $weight+$pakge_fee+$mark_fee+$cert_fee+$nake_fee;
|
|
|
//$saleprice(最终售价) = (开模费/购买数量 + 商品重量* 最新金价 + 工艺费* 商品重量+包装费+加标费+证书费+产品裸价)/(1-成本售价/100);
|
|
|
- $saleprice = ($open_fee / $zxinfo['num'] + $weight * $gold["price"] + $cost_fee * $weight + $pakge_fee + $mark_fee + $cert_fee + $nake_fee) / (1 - $budget);
|
|
|
+ $saleprice = $total_fee / (1 - $budget);
|
|
|
|
|
|
//销售工艺费=((开模费/购买数量 + 商品重量* 最新金价 + 工艺费* 商品重量+包装费+加标费+证书费+产品裸价)/(1-成本售价/100)-(打样费/购买数量 + 开模费/购买数量 +包装费+加标费+证书费+产品裸价0+运费) )/商品重量-最新金价
|
|
|
- $sale_cost_fee = (($open_fee / $zxinfo['num'] + $weight * $gold["price"] + $cost_fee * $weight + $pakge_fee + $mark_fee + $cert_fee + $nake_fee) / (1 - $budget) - ($demo_fee / $zxinfo['num'] + $open_fee / $zxinfo['num'] + $pakge_fee + $mark_fee + $cert_fee + $nake_fee + $delivery_fee)) / $weight - $gold["price"];
|
|
|
+ $sale_cost_fee = ( $saleprice- ($demo_fee / $zxinfo['num'] + $open_fee / $zxinfo['num'] + $pakge_fee + $mark_fee + $cert_fee + $nake_fee + $delivery_fee)) / $weight - $gold["price"];
|
|
|
|
|
|
}else{
|
|
|
- $saleprice = ($open_fee / $zxinfo['num'] + $cost_fee * $weight + $pakge_fee + $mark_fee + $cert_fee + $nake_fee) / (1 - $budget);
|
|
|
- $total_fee = $open_fee / $zxinfo['num'] + $cost_fee * $weight + $pakge_fee + $mark_fee + $cert_fee + $nake_fee;
|
|
|
+ $saleprice = ($demo_fee / $zxinfo['num']+$delivery_fee+$open_fee / $zxinfo['num'] + $cost_fee * $weight + $pakge_fee +
|
|
|
+ $mark_fee + $cert_fee + $nake_fee) / (1 - $budget);
|
|
|
+ $total_fee = $demo_fee / $zxinfo['num']+$delivery_fee+$open_fee / $zxinfo['num'] + $cost_fee * $weight + $pakge_fee + $mark_fee + $cert_fee + $nake_fee;
|
|
|
}
|
|
|
Db::startTrans();
|
|
|
try{
|
|
@@ -1208,8 +1210,8 @@ class Consult extends Base
|
|
|
$gold = Db::name("gold_price1")->where(["type"=>$info['metal_id'],"is_del"=>0,"status"=>1])->order("addtime desc")
|
|
|
->find();
|
|
|
|
|
|
- $bargain_price = ($info['open_fee'] / $consult['num'] + $info['weight'] * $gold["price"] + $cost_price *$info['weight'] +
|
|
|
- $info['pakge_fee'] + $info['mark_fee'] +$info['cert_fee'] +$info['nake_fee']) / (1 - $budget);
|
|
|
+ $bargain_price = ($info['demo_fee'] / $consult['num']+$info['delivery_fee']+$info['open_fee'] /$consult['num'] +
|
|
|
+ $info['weight'] * $gold["price"] + $cost_price *$info['weight'] + $info['pakge_fee'] + $info['mark_fee'] +$info['cert_fee'] +$info['nake_fee']) / (1 - $budget);
|
|
|
}
|
|
|
|
|
|
$bargain_reason = isset($this->post['bargain_reason'])&& $this->post['bargain_reason']!=""?trim($this->post['bargain_reason']):"";
|
|
@@ -1401,23 +1403,26 @@ class Consult extends Base
|
|
|
->find();
|
|
|
// $saleprice = $open_fee/$zxinfo['num'] + $weight* $gold["price"] + $cost_fee/(1-$budget)* $weight+$pakge_fee+$mark_fee+$cert_fee+$nake_fee;
|
|
|
//$saleprice(最终售价) = (开模费/购买数量 + 商品重量* 最新金价 + 工艺费* 商品重量+包装费+加标费+证书费+产品裸价)/(1-成本售价/100);
|
|
|
- $saleprice = ($bids['open_fee'] / $coninfo['num'] + $bids['weight']* $gold["price"] + $bids['cost_fee']*$bids['weight'] + $bids['pakge_fee'] +$bids['mark_fee'] + $bids['cert_fee'] + $bids['nake_fee']) / (1 - $budget);
|
|
|
- $rate_price = ($bids['open_fee'] / $coninfo['num'] + $bids['weight']* $gold["price"] +$bids['cost_fee']*$bids['weight'] +$bids['pakge_fee'] +$bids['mark_fee'] + $bids['cert_fee'] + $bids['nake_fee']) / (1 - $rate);
|
|
|
- $money_price = ($bids['open_fee'] / $coninfo['num'] + $bids['weight']* $gold["price"] +$bids['cost_fee']*$bids['weight'] +$bids['pakge_fee'] +$bids['mark_fee'] + $bids['cert_fee'] + $bids['nake_fee']) / (1 - $money_rate);
|
|
|
- $lower_price = ($bids['open_fee'] / $coninfo['num'] + $bids['weight']* $gold["price"] +$bids['cost_fee']*$bids['weight'] + $bids['pakge_fee'] +$bids['mark_fee'] + $bids['cert_fee'] + $bids['nake_fee']) / (1 - $lower_rate);
|
|
|
+ $total_fe= $bids['demo_fee'] / $coninfo['num']+$bids['delivery_fee']+$bids['open_fee'] / $coninfo['num'] +
|
|
|
+ $bids['weight']*$gold["price"] +$bids['cost_fee']*$bids['weight'] + $bids['pakge_fee'] +$bids['mark_fee'] + $bids['cert_fee'] + $bids['nake_fee'];
|
|
|
+ $saleprice =$total_fe / (1 - $budget);
|
|
|
+ $rate_price = $total_fe / (1 - $rate);
|
|
|
+ $money_price =$total_fe / (1 - $money_rate);
|
|
|
+ $lower_price =$total_fe / (1 - $lower_rate);
|
|
|
}else{
|
|
|
-
|
|
|
+ $total_fe= $bids['demo_fee']/$coninfo['num']+$bids['delivery_fee']+$bids['open_fee'] /
|
|
|
+ $coninfo['num']+$bids['cost_fee']*$bids['weight']+$bids['pakge_fee'] +$bids['mark_fee']+ $bids['cert_fee'] + $bids['nake_fee'];
|
|
|
if($bids['nake_fee']!=0){
|
|
|
- $saleprice = ($bids['open_fee'] / $coninfo['num']+$bids['cost_fee']*$bids['weight']+$bids['pakge_fee'] +$bids['mark_fee']+ $bids['cert_fee'] + $bids['nake_fee'])/ (1 - $budget);
|
|
|
- $rate_price = ($bids['open_fee'] / $coninfo['num']+$bids['cost_fee']*$bids['weight']+$bids['pakge_fee'] +$bids['mark_fee']+ $bids['cert_fee'] + $bids['nake_fee'])/ (1 - $rate);
|
|
|
- $money_price =($bids['open_fee'] / $coninfo['num']+$bids['cost_fee']*$bids['weight']+$bids['pakge_fee'] +$bids['mark_fee']+ $bids['cert_fee'] + $bids['nake_fee'])/ (1 - $money_rate);
|
|
|
- $lower_price = ($bids['open_fee'] / $coninfo['num']+$bids['cost_fee']*$bids['weight']+$bids['pakge_fee'] +$bids['mark_fee']+ $bids['cert_fee'] + $bids['nake_fee']) / (1 - $lower_rate);
|
|
|
+ $saleprice = ($total_fe)/ (1 - $budget);
|
|
|
+ $rate_price = ($total_fe)/ (1 - $rate);
|
|
|
+ $money_price =($total_fe)/ (1 - $money_rate);
|
|
|
+ $lower_price = ($total_fe) / (1 - $lower_rate);
|
|
|
|
|
|
}else{
|
|
|
- $saleprice = ($bids['open_fee']/$coninfo['num']+$bids['cost_fee']*$bids['weight']+$bids['pakge_fee'] +$bids['mark_fee']+ $bids['cert_fee']) / (1 - $budget);
|
|
|
- $rate_price =($bids['open_fee'] /$coninfo['num']+$bids['cost_fee']*$bids['weight']+$bids['pakge_fee'] +$bids['mark_fee']+ $bids['cert_fee'])/ (1 - $rate);
|
|
|
- $money_price =($bids['open_fee'] / $coninfo['num']+$bids['cost_fee']*$bids['weight']+$bids['pakge_fee'] +$bids['mark_fee']+ $bids['cert_fee']) / (1 - $money_rate);
|
|
|
- $lower_price = ($bids['open_fee'] / $coninfo['num']+$bids['cost_fee']*$bids['weight']+$bids['pakge_fee'] +$bids['mark_fee']+ $bids['cert_fee'])/ (1 - $lower_rate);
|
|
|
+ $saleprice = $total_fe / (1 - $budget);
|
|
|
+ $rate_price =$total_fe/ (1 - $rate);
|
|
|
+ $money_price =$total_fe / (1 - $money_rate);
|
|
|
+ $lower_price = $total_fe/ (1 - $lower_rate);
|
|
|
|
|
|
}
|
|
|
|
|
@@ -1821,7 +1826,8 @@ class Consult extends Base
|
|
|
|
|
|
//$total_fee(成本合计初始价格) =打样费/购买数量 + 开模费/购买数量 + 商品重量* 最新金价 + 工艺费* 商品重量+包装费+加标费+证书费+产品裸价0+运费;
|
|
|
//$saleprice(最终售价) = (开模费/购买数量 + 商品重量* 最新金价 + 工艺费* 商品重量+包装费+加标费+证书费+产品裸价)/(1-成本售价/100);
|
|
|
- $saleprice = ($value["open_fee"]/ $bidinfo['num'] + $value["weight"] * $gold["price"] + $value["cost_fee"] * $value["weight"] + $value["pakge_fee"]+ $value["mark_fee"] +$value["cert_fee"] +$value["nake_fee"]) / (1 - $budget);
|
|
|
+ $saleprice = ($value['demo_fee']/$bidinfo['num']+$value['delivery_fee']+$value["open_fee"]/$bidinfo['num'] +$value["weight"] *$gold["price"] +
|
|
|
+ $value["cost_fee"] * $value["weight"] + $value["pakge_fee"]+ $value["mark_fee"] +$value["cert_fee"] +$value["nake_fee"]) / (1 - $budget);
|
|
|
|
|
|
// //销售工艺费=((开模费/购买数量 + 商品重量* 最新金价 + 工艺费* 商品重量+包装费+加标费+证书费+产品裸价)/(1-成本售价/100)-(打样费/购买数量 + 开模费/购买数量 +包装费+加标费+证书费+产品裸价0+运费) )/商品重量-最新金价
|
|
|
// $sale_cost_fee = (($open_fee / $zxinfo['num'] + $weight * $gold["price"] + $cost_fee * $weight + $pakge_fee + $mark_fee + $cert_fee + $nake_fee) / (1 - $budget) - ($demo_fee / $zxinfo['num'] + $open_fee / $zxinfo['num'] + $pakge_fee + $mark_fee + $cert_fee + $nake_fee + $delivery_fee)) / $weight - $gold["price"];
|
|
@@ -1829,10 +1835,10 @@ class Consult extends Base
|
|
|
}else{
|
|
|
|
|
|
if($value["nake_fee"]){
|
|
|
- $saleprice = ($value["open_fee"]/ $bidinfo['num']+$value["cost_fee"] * $value["weight"]+ $value["pakge_fee"]+ $value["mark_fee"] +$value["cert_fee"] +$value["nake_fee"])/ (1 - $budget);
|
|
|
+ $saleprice = ($value['demo_fee']/$bidinfo['num']+$value['delivery_fee']+$value["open_fee"]/$bidinfo['num']+$value["cost_fee"] * $value["weight"]+ $value["pakge_fee"]+ $value["mark_fee"] +$value["cert_fee"] +$value["nake_fee"])/ (1 - $budget);
|
|
|
|
|
|
}else{
|
|
|
- $saleprice = ($value["open_fee"]/ $bidinfo['num']+$value["cost_fee"] * $value["weight"]+ $value["pakge_fee"]+ $value["mark_fee"] +$value["cert_fee"] +$value["nake_fee"]) /
|
|
|
+ $saleprice = ($value['demo_fee']/$bidinfo['num']+$value['delivery_fee']+$value["open_fee"]/$bidinfo['num']+$value["cost_fee"] * $value["weight"]+ $value["pakge_fee"]+ $value["mark_fee"] +$value["cert_fee"] +$value["nake_fee"]) /
|
|
|
(1 - $budget);
|
|
|
|
|
|
}
|