admin: dashboard scanline show sync status as none/success/failed

This commit is contained in:
萝卜
2026-03-18 05:27:15 +08:00
parent cd9634113e
commit 807202482c
2 changed files with 85 additions and 1 deletions

View File

@@ -883,7 +883,14 @@
? ($po->isRefundInconsistent() ? '异常' : ($hasRefundTrace ? '有' : '无'))
: '-';
$syncStatusText = $syncErrMsg !== '' ? '失败' : '正常';
// 同步摘要口径(更贴近治理/复核):
// - 有 error.message失败
// - 无 error 且有 subscription_activation.subscription_id成功已同步
// - 否则:无(尚未同步)
$syncSubscriptionId = (string) (data_get($po->meta, 'subscription_activation.subscription_id') ?? '');
$syncStatusText = $syncErrMsg !== ''
? '失败'
: ($syncSubscriptionId !== '' ? '成功' : '无');
// BMPA 摘要口径(更贴近治理/复核):
// - 有 error.message失败