修正 ERP 边界与资产页面一致性(05-30-fix-erp-boundary-asset-consistency)
这个提交包含在:
@@ -56,7 +56,6 @@ const MANAGEMENT_ACTIVE_PATHS = [
|
||||
"/system/reimbursement-templates",
|
||||
"/system/master-data",
|
||||
"/system/notification-channels",
|
||||
"/system/integrations/erp",
|
||||
"/system/users",
|
||||
"/system/departments",
|
||||
"/system/cutover",
|
||||
|
||||
@@ -178,7 +178,9 @@ export function Topbar() {
|
||||
</span>
|
||||
) : null}
|
||||
</div>
|
||||
<div className="mt-0.5 text-xs text-[var(--color-text-secondary)]">{me ? `${me.name} · 当前工作区` : "海音达 OA"}</div>
|
||||
<div className="mt-0.5 text-xs text-[var(--color-text-secondary)]">
|
||||
{me ? `${me.name} · ${me.employeeNo}` : "海音达 OA"}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -293,8 +295,8 @@ export function Topbar() {
|
||||
|
||||
<DropdownMenu>
|
||||
<DropdownMenuTrigger asChild>
|
||||
<Button data-testid="topbar-profile-trigger" variant="secondary" type="button" className="max-w-[160px] truncate">
|
||||
{me?.name ?? "账号"}
|
||||
<Button data-testid="topbar-profile-trigger" variant="secondary" type="button" className="max-w-[190px] truncate">
|
||||
{me ? `${me.name} · ${me.employeeNo}` : "账号"}
|
||||
</Button>
|
||||
</DropdownMenuTrigger>
|
||||
|
||||
|
||||
@@ -58,7 +58,7 @@ export function TravelOrderMarkPaidDialog({
|
||||
<DialogHeader>
|
||||
<DialogTitle>标记差旅订单已支付</DialogTitle>
|
||||
<DialogDescription>
|
||||
确认订单 `{order?.externalOrderNo ?? "-"}` 已完成对公支付;系统会按幂等键复用现有 ERP journal 出站记录。
|
||||
确认订单 `{order?.externalOrderNo ?? "-"}` 已完成对公支付;系统会按幂等键复用现有财务交接记录。
|
||||
</DialogDescription>
|
||||
</DialogHeader>
|
||||
|
||||
|
||||
@@ -66,7 +66,7 @@ function erpStageLabel(order: TravelPaymentOrder) {
|
||||
if (order.erpStage.binding?.externalId) {
|
||||
return "已同步";
|
||||
}
|
||||
return "ERP 出站未开启";
|
||||
return "摘要导出未开启";
|
||||
}
|
||||
|
||||
type TravelPaymentTrackCardProps = {
|
||||
@@ -178,7 +178,7 @@ export function TravelPaymentTrackCard({ travelRequestId }: TravelPaymentTrackCa
|
||||
<div className="flex items-start justify-between gap-3">
|
||||
<div>
|
||||
<h3 className="text-base font-semibold text-zinc-900">对公支付轨道</h3>
|
||||
<p className="mt-1 text-sm text-zinc-500">授权、交易、发票绑定与 ERP 支付出站在此统一查看。</p>
|
||||
<p className="mt-1 text-sm text-zinc-500">授权、交易、发票绑定与财务交接导出在此统一查看。</p>
|
||||
</div>
|
||||
{canManagePayments ? <span className="text-xs text-zinc-500">具备支付管理权限</span> : null}
|
||||
</div>
|
||||
@@ -257,7 +257,7 @@ export function TravelPaymentTrackCard({ travelRequestId }: TravelPaymentTrackCa
|
||||
<div>金额:{order.amount} {order.currency}</div>
|
||||
<div>付款凭证:{order.paymentVoucherNo ?? "-"}</div>
|
||||
<div>付款日期:{order.paymentDate ?? "-"} · 渠道:{paymentChannelLabel(order.paymentChannel)}</div>
|
||||
<div>ERP 状态:{erpStageLabel(order)}</div>
|
||||
<div>导出状态:{erpStageLabel(order)}</div>
|
||||
</div>
|
||||
</div>
|
||||
{canManagePayments ? (
|
||||
|
||||
@@ -244,7 +244,7 @@ export function TravelReconciliationTab({ selectedBatchId, onSelectBatch }: Trav
|
||||
},
|
||||
onSuccess: async () => {
|
||||
await queryClient.invalidateQueries({ queryKey: ['travel-reconciliation', 'erp-track', selectedBatchId] });
|
||||
toast.success('ERP 摘要桥已重新入队');
|
||||
toast.success('交接摘要已重新入队');
|
||||
},
|
||||
onError: (error) => {
|
||||
toast.error(resolveError(error));
|
||||
@@ -418,7 +418,7 @@ export function TravelReconciliationTab({ selectedBatchId, onSelectBatch }: Trav
|
||||
) : null}
|
||||
|
||||
{!selectedBatchId ? (
|
||||
<EmptyStateCard title="请选择对账批次" description="从左侧选择一个批次查看 KPI、异常项与 ERP 摘要桥轨道。" />
|
||||
<EmptyStateCard title="请选择对账批次" description="从左侧选择一个批次查看 KPI、异常项与交接摘要。" />
|
||||
) : null}
|
||||
|
||||
{detail ? (
|
||||
@@ -445,7 +445,7 @@ export function TravelReconciliationTab({ selectedBatchId, onSelectBatch }: Trav
|
||||
) : null}
|
||||
{track?.permissions.canRetry ? (
|
||||
<Button type="button" variant="secondary" onClick={() => requeueMutation.mutate()} disabled={requeueMutation.isPending}>
|
||||
{requeueMutation.isPending ? '重试中...' : 'Requeue ERP'}
|
||||
{requeueMutation.isPending ? '重试中...' : '重试导出'}
|
||||
</Button>
|
||||
) : null}
|
||||
</div>
|
||||
@@ -473,14 +473,14 @@ export function TravelReconciliationTab({ selectedBatchId, onSelectBatch }: Trav
|
||||
|
||||
<div className="card-std space-y-4 p-6">
|
||||
<div>
|
||||
<h3 className="text-base font-semibold text-zinc-900">ERP 摘要桥</h3>
|
||||
<p className="mt-1 text-sm text-zinc-500">批次级 `erp.travel.export` 轨道,不会回改订单、申请或预算原值。</p>
|
||||
<h3 className="text-base font-semibold text-zinc-900">交接摘要</h3>
|
||||
<p className="mt-1 text-sm text-zinc-500">批次级摘要导出轨道,不会回改订单、申请或预算原值。</p>
|
||||
</div>
|
||||
|
||||
{trackQuery.isLoading ? <CardSkeleton lines={4} /> : null}
|
||||
{trackQuery.isError ? (
|
||||
<p className="rounded-lg border border-amber-200 bg-amber-50 px-3 py-2 text-sm text-amber-700">
|
||||
ERP 轨道加载失败:{resolveError(trackQuery.error)}
|
||||
摘要轨道加载失败:{resolveError(trackQuery.error)}
|
||||
</p>
|
||||
) : null}
|
||||
|
||||
|
||||
在新工单中引用
屏蔽一个用户