weizong song 2 years ago
parent a0c2035d00
commit c208bd422b

@ -400,7 +400,7 @@ class Orders extends SoftDeletesModel
foreach ($paramedics as $paramedic) { foreach ($paramedics as $paramedic) {
$product_item = ProductItems::where("product_id", $product->id)->where("patient_quantity", "<=", $paramedic->ongoing_orders_count + 1)->orderBy("patient_quantity", "desc")->first(); $product_item = ProductItems::where("product_id", $product->id)->where("patient_quantity", "<=", $paramedic->ongoing_orders_count + 1)->orderBy("patient_quantity", "desc")->first();
$price = $paramedic->levelInProject->price??0 + $product_item->price??0; $price = $paramedic->levelInProject->price??0 + $product_item->price??0;
dump($price); dump($paramedic->levelInProject->price,$product_item->price);
foreach ($factors as $factor) { foreach ($factors as $factor) {
$price += $factor["price"]??0; $price += $factor["price"]??0;
} }

Loading…
Cancel
Save