|
|
@@ -1199,7 +1199,7 @@ sql
|
|
|
list($fee,$tax) = $exe($order->logistic->type,$order->owner_id, $order->logistic_id, $partAmount, $package->weight);
|
|
|
$result["logisticFee"] += $fee;
|
|
|
$result["logisticTaxFee"] += $tax;
|
|
|
- $GLOBALS["FEE_INFO"]["total_fee"] = $fee;
|
|
|
+ $GLOBALS["FEE_INFO"]["total_fee"] = $fee?:0;
|
|
|
if ($order->logistic->type=='快递')$result["fee_info"][] = $GLOBALS["FEE_INFO"];
|
|
|
}
|
|
|
$result["items"][] = [
|
|
|
@@ -1217,7 +1217,7 @@ sql
|
|
|
|
|
|
list($result["logisticFee"],$result["logisticTaxFee"]) =
|
|
|
$exe($order->logistic->type,$order->owner_id, $order->logistic_id, $result["amount"], $result["weight"]);
|
|
|
- $GLOBALS["FEE_INFO"]["total_fee"] = $result["logisticFee"];
|
|
|
+ $GLOBALS["FEE_INFO"]["total_fee"] = $result["logisticFee"]?:0;
|
|
|
if ($order->logistic->type=='快递')$result["fee_info"][] = $GLOBALS["FEE_INFO"];
|
|
|
}
|
|
|
if ($result["logisticFee"]<0)$result["logisticFee"] = null;
|
|
|
@@ -1244,9 +1244,9 @@ sql
|
|
|
$logisticInfo = $this->getLogisticFeeInfo($order);
|
|
|
|
|
|
//信息仍然不完整
|
|
|
- if (!$logisticInfo["fee_info"])return false;
|
|
|
+ if ($logisticInfo["logisticFee"] && $logisticInfo["fee_info"])OwnerFeeExpress::query()->insert($logisticInfo["fee_info"]);
|
|
|
//向指定表插入标记
|
|
|
- OwnerFeeExpress::query()->insert($logisticInfo["fee_info"]);
|
|
|
+
|
|
|
//获取作业费
|
|
|
/** @var OwnerPriceOperationService $service */
|
|
|
$service = app("OwnerPriceOperationService");
|
|
|
@@ -1388,7 +1388,8 @@ sql
|
|
|
//获取运输费
|
|
|
$logisticInfo = $this->getLogisticFeeInfo($order);
|
|
|
//向指定表插入标记
|
|
|
- if ($logisticInfo["fee_info"])OwnerFeeExpress::query()->insert($logisticInfo["fee_info"]);
|
|
|
+ if (!$logisticInfo["logisticFee"] || !$logisticInfo["fee_info"])return false;
|
|
|
+ OwnerFeeExpress::query()->insert($logisticInfo["fee_info"]);
|
|
|
foreach ($logisticInfo["items"] as &$item)$item["owner_fee_detail_id"] = $feeBill->id;
|
|
|
if (count($logisticInfo["items"])>1)OwnerFeeDetailLogistic::query()->insert($logisticInfo["items"]);
|
|
|
|