平台订单工具区:可同步+治理筛选时加强风险提示

This commit is contained in:
萝卜
2026-03-11 08:21:04 +00:00
parent 200c2cff5a
commit 54549ee754
2 changed files with 19 additions and 0 deletions

View File

@@ -259,6 +259,7 @@
@php
$hasReconcileMismatchFilter = (($filters['reconcile_mismatch'] ?? '') === '1');
$hasRefundInconsistentFilter = (($filters['refund_inconsistent'] ?? '') === '1');
$hasSyncableOnlyFilter = (($filters['syncable_only'] ?? '') === '1');
@endphp
@if($hasReconcileMismatchFilter || $hasRefundInconsistentFilter)
@@ -275,6 +276,13 @@
@endif
。建议先完成金额/状态治理(补回执/核对退款)后,再执行批量同步订阅等工具动作。
</div>
@if($hasSyncableOnlyFilter)
<div class="muted text-danger mb-10">
注意:当前同时勾选了「只看可同步」—— 这类订单会被批量同步订阅命中。若仍存在对账/退款异常,建议先进入治理集合处理完毕,再回到可同步集合执行批量同步。
<a class="link" href="{{ request()->fullUrlWithQuery(['syncable_only' => null, 'page' => null]) }}">先去治理(取消只看可同步)</a>
</div>
@endif
@endif
<form method="get" action="/admin/platform-orders/export" class="mb-10">

View File

@@ -38,4 +38,15 @@ class AdminPlatformOrderToolsGovernanceHintTest extends TestCase
->assertSee('建议先完成金额/状态治理', false)
->assertSee('退款不一致', false);
}
public function test_platform_orders_tools_show_strong_hint_when_syncable_only_and_governance_filters_present(): void
{
$this->loginAsPlatformAdmin();
$this->get('/admin/platform-orders?syncable_only=1&reconcile_mismatch=1')
->assertOk()
->assertSee('注意:当前同时勾选了「只看可同步」', false)
->assertSee('先去治理(取消只看可同步)', false)
->assertSee('syncable_only=', false);
}
}