feat(CommissionProductLogic): updated calc logic for prod comm, added loss calc, & updated rel db fields
This commit is contained in:
parent
bf5a070046
commit
ae0faa68c2
@ -167,7 +167,7 @@ class CommissionProductLogic extends BaseLogic
|
|||||||
{
|
{
|
||||||
$total_price = bcmul($find['price'], $find['cart_num'], 2);
|
$total_price = bcmul($find['price'], $find['cart_num'], 2);
|
||||||
$purchase_price = bcmul($product['purchase'], $find['cart_num'], 2);
|
$purchase_price = bcmul($product['purchase'], $find['cart_num'], 2);
|
||||||
$price = $product['price'];
|
$price = $find['price'];
|
||||||
|
|
||||||
$rose=0;
|
$rose=0;
|
||||||
$rose_price = bcsub($price, $product['purchase'], 2);
|
$rose_price = bcsub($price, $product['purchase'], 2);
|
||||||
@ -216,7 +216,7 @@ class CommissionProductLogic extends BaseLogic
|
|||||||
{
|
{
|
||||||
$total_price = bcmul($find['price'], $find['cart_num'], 2);
|
$total_price = bcmul($find['price'], $find['cart_num'], 2);
|
||||||
$purchase_price = bcmul($product['purchase'], $find['cart_num'], 2);
|
$purchase_price = bcmul($product['purchase'], $find['cart_num'], 2);
|
||||||
$price = $product['purchase'];
|
$price = $find['price'];
|
||||||
|
|
||||||
$rose=0;
|
$rose=0;
|
||||||
$rose_price = bcsub($price, $product['purchase'], 2);
|
$rose_price = bcsub($price, $product['purchase'], 2);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user