refactor(agent-runtime, shipping-notice, frontend): 重构上下文体系,修复重试RPA无响应问题

- 替换原有的hxops_context模块为全新的代理运行时上下文平台协议,统一跨业务上下文注入逻辑
- 新增多语言操作繁忙提示文案(覆盖中、繁、英、泰四语),前端绑定页面繁忙状态实现操作阻断
- 调整RPA库存导出重试策略:移除可配置的最大自动重试次数,改为固定单次自动重试,手动重试需用户显式触发
- 优化任务用户态状态展示逻辑,优先展示具体的pending原因而非通用状态文案
- 重构任务焦点切换逻辑,统一事件日志与处理流程,复用switch_batch_focus工具函数
- 修复clearAllHistory函数残留UI问题,确保清空会话后完全复位发货通知相关视图
- 更新OpenAPI文档与静态快照,补充工具使用约束说明
- 新增调试打点日志与问题排查文档,完善全套单元测试与快照校验用例
- 更新RPA脚本的README文档,调整登录方式说明与浏览器 profile 路径配置
- 删除废弃的hxops_context模块,迁移所有相关调用到新的上下文体系
This commit is contained in:
hugo committed 2026-07-03 17:01:42 +08:00
1 parent 60dd0c0f58
commit 8846ce159f
102 files changed
+18289 -9072

No files matched your search

@@ -24,6 +24,7 @@ import {
} from '@/features/chat/api/shipping.api';
import { getAuthHeaders } from '@/shared/utils/auth';
import { resolveShippingWorkflowSteps } from '@/features/chat/shipping';
import { sanitizeShippingRuntimeStatusText } from '@/features/chat/shipping/shippingText';
const props = defineProps<{
embedded?: boolean;
@@ -120,6 +121,15 @@ const detailStepProgress = computed<ShippingCurrentStepProgress | null>(() => {
const detailStepHasPercent = computed(() =>
typeof detailStepProgress.value?.progress_percent === 'number',
);
const detailStepMessage = computed(() =>
sanitizeShippingRuntimeStatusText(String(detailStepProgress.value?.message || '').trim()),
);
const detailStepDetail = computed(() =>
sanitizeShippingRuntimeStatusText(String(detailStepProgress.value?.detail || '').trim()),
);
const detailErrorMessage = computed(() =>
sanitizeShippingRuntimeStatusText(String(detail.value?.error_message || '').trim()),
);
const loadCases = async () => {
loading.value = true;
@@ -333,10 +343,10 @@ onMounted(async () => {
</div>
</div>
<div class="mt-1 text-sm text-secondary">
{{ detailStepProgress.message || t('chat.shippingNoticeUi.processing') }}
{{ detailStepMessage || t('chat.shippingNoticeUi.processing') }}
</div>
<div v-if="detailStepProgress.detail" class="mt-1 text-xs text-muted">
{{ detailStepProgress.detail }}
<div v-if="detailStepDetail" class="mt-1 text-xs text-muted">
{{ detailStepDetail }}
</div>
<div
v-if="detailStepProgress.current && detailStepProgress.total"
@@ -368,8 +378,8 @@ onMounted(async () => {
<div><dt class="text-muted">{{ $t('workspace.shippingNotice.fields.freightRef') }}</dt><dd>{{ detail.freight_ref_no || '—' }}</dd></div>
</dl>
<div v-if="detail.error_message" class="rounded-xl border border-rose-200 bg-rose-50 px-3 py-2 text-sm text-rose-700">
{{ detail.error_message }}
<div v-if="detailErrorMessage" class="rounded-xl border border-rose-200 bg-rose-50 px-3 py-2 text-sm text-rose-700">
{{ detailErrorMessage }}
</div>
<ShippingMatchResultCard