feat: platform order index sync failed reason link prefer batch run
This commit is contained in:
@@ -1477,14 +1477,58 @@
|
||||
<span class="muted">-</span>
|
||||
@else
|
||||
@if($syncErrMsg !== '')
|
||||
@php
|
||||
// 同步失败:默认落到“可执行集合”(优先同批次)
|
||||
$basRunIdRow = (string) (data_get($order->meta, 'batch_activation.last_result.run_id') ?? '');
|
||||
if ($basRunIdRow === '') {
|
||||
$basRunIdRow = (string) (data_get($order->meta, 'batch_activation.run_id') ?? '');
|
||||
}
|
||||
|
||||
$syncGoFailedUrl = $buildQuickFilterUrl([
|
||||
'sync_status' => 'failed',
|
||||
'page' => null,
|
||||
]);
|
||||
|
||||
$syncGoBatchFailedUrl = '';
|
||||
$syncGoBatchReasonUrl = '';
|
||||
if ($basRunIdRow !== '') {
|
||||
$syncGoBatchFailedUrl = $buildQuickFilterUrl([
|
||||
'batch_activation_run_id' => $basRunIdRow,
|
||||
'sync_status' => 'failed',
|
||||
'page' => null,
|
||||
]);
|
||||
|
||||
if (! $syncErrTooLong) {
|
||||
$syncGoBatchReasonUrl = $buildQuickFilterUrl([
|
||||
'batch_activation_run_id' => $basRunIdRow,
|
||||
'sync_status' => 'failed',
|
||||
'sync_error_keyword' => $syncErrMsg,
|
||||
'page' => null,
|
||||
]);
|
||||
}
|
||||
}
|
||||
|
||||
$syncGoReasonUrl = $buildQuickFilterUrl([
|
||||
'sync_error_keyword' => $syncErrMsg,
|
||||
'sync_status' => 'failed',
|
||||
'page' => null,
|
||||
]);
|
||||
|
||||
$syncErrorLinkUrl = $syncGoBatchReasonUrl !== '' ? $syncGoBatchReasonUrl : $syncGoReasonUrl;
|
||||
@endphp
|
||||
<div>
|
||||
<span class="muted muted-xs">同步:</span>
|
||||
@if($syncErrTooLong)
|
||||
<span class="muted text-danger" title="{{ $syncErrMsg }}">{{ mb_substr($syncErrMsg, 0, $SYNC_FAILED_REASON_TRUNCATE_LEN) }}</span>
|
||||
<div class="muted text-danger muted-xs">原因过长,请复制到筛选框</div>
|
||||
<a class="link" href="{!! $safeFullUrlWithQuery(['sync_status' => 'failed', 'page' => null]) !!}">进入同步失败集合</a>
|
||||
|
||||
@if($syncGoBatchFailedUrl !== '')
|
||||
<div class="muted muted-xs">治理:<a class="link" href="{!! $syncGoBatchFailedUrl !!}">进入本批次同步失败集合</a></div>
|
||||
@else
|
||||
<div class="muted muted-xs">治理:<a class="link" href="{!! $syncGoFailedUrl !!}">进入同步失败集合</a></div>
|
||||
@endif
|
||||
@else
|
||||
<a class="link text-danger" href="{!! $safeFullUrlWithQuery(['sync_error_keyword' => $syncErrMsg, 'sync_status' => 'failed', 'page' => null]) !!}">{{ mb_substr($syncErrMsg, 0, $SYNC_FAILED_REASON_TRUNCATE_LEN) }}</a>
|
||||
<a class="link text-danger" href="{!! $syncErrorLinkUrl !!}">{{ mb_substr($syncErrMsg, 0, $SYNC_FAILED_REASON_TRUNCATE_LEN) }}</a>
|
||||
@endif
|
||||
</div>
|
||||
@endif
|
||||
|
||||
Reference in New Issue
Block a user