feat(shipping-notice): 新增通用解析能力,优化性能并清理遗留废弃代码

This commit is contained in:
hugo committed 2026-08-23 00:27:18 +08:00
1 parent 935bf26fa6
commit 7cfd5d167e
230 files changed
+9337 -10989

No files matched your search

@@ -73,6 +73,16 @@ function evidenceRoleLabel(role: string | undefined | null): string {
return te(key) ? t(key) : code;
}
/**
* 显示服务端指定的恢复动作;页面只解释并复用既有顶部操作,不自行发起重识别。
*/
function recoveryActionLabel(action: string | undefined | null): string {
const code = String(action || '').trim();
if (!code) return '';
const key = `chat.shippingOrderReview.fieldConflict.recoveryAction.${code}`;
return te(key) ? t(key) : code;
}
/**
* 定位冲突字段到草稿/证据区。
*/
@@ -311,6 +321,13 @@ async function submitCustom(conflict: ShippingOrderReviewFieldConflict) {
<span class="text-muted">{{ scopeLabel(issue.scope) }} · </span>
<span class="font-mono">{{ fieldLabel(issue.field_code) }}</span>
</span>
<span
v-if="recoveryActionLabel(issue.recovery_action)"
class="text-[11px] text-amber-800 dark:text-amber-200"
data-testid="review-evidence-issue-recovery-action"
>
{{ recoveryActionLabel(issue.recovery_action) }}
</span>
<button
type="button"
class="text-[11px] text-primary underline-offset-2 hover:underline"