chore(governance): block batch mark activated when reconcile/refund inconsistent

This commit is contained in:
萝卜
2026-03-16 23:16:25 +08:00
parent a26be5de9e
commit 75d64195d6
6 changed files with 89 additions and 2 deletions

View File

@@ -1884,6 +1884,11 @@ class PlatformOrderController extends Controller
if ((string) ($filters['syncable_only'] ?? '') === '1') {
return redirect()->back()->with('warning', '当前已勾选「只看可同步」:该集合语义为“已生效(activated)+未同步”,与本动作处理的“待处理(pending)”互斥。请先取消只看可同步后再执行。');
}
// 治理优先:当筛选集合命中“对账不一致/退款不一致”时,不允许直接批量生效
if ((string) ($filters['reconcile_mismatch'] ?? '') === '1' || (string) ($filters['refund_inconsistent'] ?? '') === '1') {
return redirect()->back()->with('warning', '当前筛选集合包含「对账不一致/退款不一致」订单,为避免带病推进,请先完成金额/状态治理(补回执/核对退款/修正状态)后再执行批量仅标记为已生效。');
}
}
// 防误操作scope=all 需要二次确认

View File

@@ -132,6 +132,9 @@ class PlatformOrderToolsGuard
if ((string) ($filters['syncable_only'] ?? '') === '1') {
return '当前已勾选「只看可同步」:该集合语义为“已生效(activated)+未同步”,与本动作处理的“待处理(pending)”互斥。请先取消只看可同步后再执行。';
}
if (((string) ($filters['reconcile_mismatch'] ?? '') === '1') || ((string) ($filters['refund_inconsistent'] ?? '') === '1')) {
return '当前集合包含「对账不一致/退款不一致」治理集合:建议先完成金额/状态治理(补回执/核对退款/修正状态)后再批量生效。';
}
return '';
}