|
|
@@ -898,9 +898,18 @@ class PurchaseOrderClass extends BaseClass
|
|
|
if (isset($orderInfo['tkPrice']) && $orderInfo['tkPrice'] > 0) {
|
|
|
$content .= '退款金额:' . floatval($orderInfo['tkPrice']) . '元<BR>';
|
|
|
}
|
|
|
- $content .= '<B>订单金额:' . floatval($orderInfo['realPrice']) . '</B><BR>';
|
|
|
- if (isset($orderInfo['debt']) && $orderInfo['debt'] == 1) {
|
|
|
- $content .= '实付金额:0元<BR>';
|
|
|
+ $content .= '<B>金额:' . floatval($orderInfo['realPrice']) . '</B><BR>';
|
|
|
+ if (isset($orderInfo['debtPrice']) && $orderInfo['debtPrice'] > 0) {
|
|
|
+ $remainDebt = bcadd((string)($orderInfo['remainDebtPrice'] ?? '0'), '0', 2);
|
|
|
+ $totalRefund = bcadd((string)($orderInfo['tkPrice'] ?? '0'), (string)($orderInfo['nextDayTkPrice'] ?? '0'), 2);
|
|
|
+ if($totalRefund > 0) {
|
|
|
+ $content .= '退款:' . floatval($totalRefund) . '元<BR>';
|
|
|
+ }
|
|
|
+ if($remainDebt > 0) {
|
|
|
+ $content .= '<B>待结:' . floatval($remainDebt) . '</B><BR>';
|
|
|
+ }else{
|
|
|
+ $content .= '<B>本单已结清!</B><BR>';
|
|
|
+ }
|
|
|
} else {
|
|
|
$content .= '实付金额:' . floatval($orderInfo['realPrice']) . '元<BR>';
|
|
|
}
|