feat: platform order show hint reconcile mismatch and link to filter
This commit is contained in:
@@ -239,6 +239,18 @@
|
||||
<h3>支付回执(对账留痕)</h3>
|
||||
<p class="muted muted-tight">用于“线下收款/转账/人工核对”的留痕记录(当前阶段先落 meta,不引入独立表)。</p>
|
||||
|
||||
@php
|
||||
$isReconcileMismatch = (bool) $order->isReconcileMismatch();
|
||||
@endphp
|
||||
|
||||
@if($isReconcileMismatch)
|
||||
<div class="muted text-danger" style="margin-top:10px; margin-bottom:10px;">
|
||||
提示:该订单「回执总额 vs 已付金额」存在差异,可能对账不一致。
|
||||
<span class="muted">|</span>
|
||||
<a class="link" href="/admin/platform-orders?reconcile_mismatch=1">查看全部对账不一致订单</a>
|
||||
</div>
|
||||
@endif
|
||||
|
||||
@if(count($paymentReceipts) > 0)
|
||||
@php $items = array_slice(array_reverse($paymentReceipts), 0, 20); @endphp
|
||||
<table>
|
||||
@@ -298,16 +310,8 @@
|
||||
<p class="muted muted-tight">用于记录退款动作与对账轨迹(先落 meta,不引入独立表)。追加退款后,系统会自动把支付状态推进为“部分退款/已退款”(仅在订单当前为已支付时)。</p>
|
||||
|
||||
@php
|
||||
// 退款不一致(与列表/筛选口径保持一致,按分取整 + 0.01 容差)
|
||||
$paidAmountFloat3 = (float) ($order->paid_amount ?? 0);
|
||||
$isRefundInconsistent3 = false;
|
||||
if ($paidAmountFloat3 > 0) {
|
||||
if ((string) $order->payment_status === 'refunded') {
|
||||
$isRefundInconsistent3 = (round($refundTotal * 100) + 1) < round($paidAmountFloat3 * 100);
|
||||
} else {
|
||||
$isRefundInconsistent3 = round($refundTotal * 100) >= round($paidAmountFloat3 * 100);
|
||||
}
|
||||
}
|
||||
// 退款不一致(统一口径:模型方法)
|
||||
$isRefundInconsistent3 = (bool) $order->isRefundInconsistent();
|
||||
@endphp
|
||||
|
||||
@if($isRefundInconsistent3)
|
||||
|
||||
Reference in New Issue
Block a user