完善付款回单凭证核验与本地重检(09-17-company-loan-principal-repayment)
区分正式付款回单、非最终回执与未知凭证,在核验构建、人工证据重建和最终核销时使用同一份有效依据。非最终说明、入账方向、状态矛盾及重复交易不能经人工覆盖。 正式回单无字面成功状态时,允许财务按原件实际记账支出、日期及说明提出核验,由本批次适用的确认人确认;不补造银行成功文字。旧核验可显式本地重检,新版本与审计原子保存,不重新外发 OCR,不沿用旧人工批准或改写已核销历史。 本地验证:82 个迁移、借款 HTTP 116 组、关联电脑/手机 18 组、共享回单数据库与真实认证 38 组、共享报销页面限定重验 24 项、最新回单/报销定向 292 项通过;9 个资金守卫变异均被捕获。服务端全量 4554 项通过、1 项既有可选跳过,后续合成数据及零页详情改动由最新定向验证覆盖。 本次无新增迁移,新增本地 PDF 文本解析依赖。后续对本提交运行完整 verify-candidate,实际候选与结果以本轮回执为准。 限制:独立代码复核及真实还款验收待完成;历史材料预验不证明真实还本或银行提交对应。未推送、未部署、未访问生产或写入真实业务数据。
这个提交包含在:
@@ -196,7 +196,9 @@ export async function reimbursementPaymentFlow(page: Page) {
|
||||
await page.goto(`/payment-batches?id=${batch.id}`);
|
||||
expect((await finance.api.post(`/api/payment-batches/${batch.id}/execute`, {data: {}})).status()).toBe(409);
|
||||
checkpoint("receipt-upload:start");
|
||||
const receiptPdf = await syntheticPdf(`Synthetic receipt ${batch.id}`);
|
||||
const receiptPdf = await requireServer('../scripts/qa/synthetic-bank-receipt.cjs').syntheticBankReceiptPdf({
|
||||
tag: `Synthetic receipt ${batch.id}`, reference: `SYNTHETIC-${batch.id}`, payerAccount: payer, payeeAccount: payee,
|
||||
});
|
||||
const uploading = page.waitForResponse(response => response.request().method() === "POST" && new URL(response.url()).pathname === `/api/payment-batches/${batch.id}/receipt-attachments`);
|
||||
await page.getByTestId("payment-batch-receipt-file-input").setInputFiles({name: "synthetic-receipt.pdf", mimeType: "application/pdf", buffer: receiptPdf});
|
||||
const upload = await uploading;
|
||||
|
||||
@@ -582,9 +582,10 @@ async function mockSystemActionApis(
|
||||
const verificationPath = `/api/payment-batches/${paymentBatchId}/receipt-attachments/${paymentReceiptId}/manual-verification`;
|
||||
if (path === verificationPath && request.method() === "GET") {
|
||||
const facts = { pageNumber: 1, amount: "88.00", currency: "CNY", payerAccountMasked: "0000****2222",
|
||||
payeeAccountMasked: "0000****4444", reference: "SYN-MANUAL-UI", transactionStatus: "success" };
|
||||
payeeAccountMasked: "0000****4444", reference: "SYN-MANUAL-UI", transactionStatus: "success",
|
||||
document: { version: 1, kind: "bank_receipt", source: "pdf_text", direction: "debit", explicitSuccess: true, issues: [] } };
|
||||
await fulfillJson(route, { item: { version: 3, state: options.receiptManualReview ? "pending_review" : "needs_review",
|
||||
canReview: Boolean(options.receiptManualReview), pagesExpected: 1, pages: [facts],
|
||||
canReview: Boolean(options.receiptManualReview), documentInspectionRequired: false, pagesExpected: 1, pages: [facts],
|
||||
proposal: options.receiptManualReview ? { id: "synthetic-proposal", status: "pending_review",
|
||||
proposedBy: "another-finance", reviewedBy: null, reason: "合成核验说明",
|
||||
changedFields: [{ pageNumber: 1, fields: ["amount"] }],
|
||||
|
||||
在新工单中引用
屏蔽一个用户