基数计算
This commit is contained in:
parent
6b46eeb702
commit
896d91a0e3
@ -41,7 +41,7 @@ class Settlements extends Base
|
||||
// 购户获得预获产品券最高占产品额比例?%
|
||||
// $buyerPreProductNum = round(($totalMoney + $order->deliverMoney),5);//1
|
||||
$buyerPreProductNum = round(($discountMoney * (dataConf('couponPercentCanUsetGet')*0.01)),5);//1
|
||||
$buyerMaxCouponsNum = round(($totalMoney + $order->deliverMoney)* (dataConf('buyerPreProductInProductScale')*0.01),5);//1
|
||||
$buyerMaxCouponsNum = round(($totalMoney)* (dataConf('buyerPreProductInProductScale')*0.01),5);//1
|
||||
$buyerPreCoupousNum = round($discountMoney * (dataConf('buyerPreCoupousInSaleScale')*0.01),5);//2
|
||||
// $buyerPreProductNum += round($order->productHandlingFee * (dataConf('buyerPreProductInHandlingFeeScale')*0.01),2);//3
|
||||
// $buyerPreProductNum += round($order->productTaxFee * (dataConf('buyerPreProductInTaxFeeScale')*0.01),2);//4
|
||||
@ -51,7 +51,8 @@ class Settlements extends Base
|
||||
$buyerPreProductNum = $buyerPreProductNum > $totalMoney ? $totalMoney : $buyerPreProductNum;
|
||||
if($buyerPreProductNum > 0 || $buyerPreCoupousNum > 0){
|
||||
if(3 == $order->goodsType){
|
||||
Model('common/UserVouchers')->insertVouchersNotice($order->userId,$orderId,$buyerPreProductNum,$buyerPreCoupousNum*((float)dataConf('helpSaleCouponsCalBase')/100),'交易订单【'.$order->orderNo.'】购户购物所得');
|
||||
// helpSaleCouponsCalBase == 基数
|
||||
Model('common/UserVouchers')->insertVouchersNotice($order->userId,$orderId,$buyerPreProductNum*((float)dataConf('helpSaleCouponsCalBase')/100),$buyerPreCoupousNum*((float)dataConf('helpSaleCouponsCalBase')/100),'交易订单【'.$order->orderNo.'】购户购物所得');
|
||||
}else{
|
||||
Model('common/UserVouchers')->insertVouchersNotice($order->userId,$orderId,$buyerPreProductNum,$buyerPreCoupousNum,'交易订单【'.$order->orderNo.'】购户购物所得');
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user