chore(governance): batch mark activated requires unsynced scope

This commit is contained in:
萝卜
2026-03-16 19:04:40 +08:00
parent 33ab55b10a
commit dbb88f59f6
4 changed files with 12 additions and 2 deletions

View File

@@ -1818,11 +1818,15 @@ class PlatformOrderController extends Controller
'refund_inconsistent' => (string) $request->input('refund_inconsistent', ''),
];
// 防误操作:批量“仅标记为已生效”默认要求当前筛选口径为「已支付 + 待处理(pending)」
// 防误操作:批量“仅标记为已生效”默认要求当前筛选口径为「已支付 + 待处理(pending) + 未同步(unsynced)
if ($scope === 'filtered') {
if (($filters['payment_status'] ?? '') !== 'paid' || ($filters['status'] ?? '') !== 'pending') {
return redirect()->back()->with('warning', '为避免误操作,请先筛选「支付状态=已支付」且「订单状态=待处理」,再执行批量仅标记为已生效。');
}
if (($filters['sync_status'] ?? '') !== 'unsynced') {
return redirect()->back()->with('warning', '为避免把同步失败等异常单混入,请先锁定「同步状态=未同步(sync_status=unsynced)」(建议用快捷筛选「待生效」)再执行批量仅标记为已生效。');
}
}
// 防误操作scope=all 需要二次确认